# Many offices

Page: https://app.myclaimhouse.com/docs/many-offices

For software that puts many offices on one Claim House organization. None of this changes anything for an organization with one office.

## Organization, practice group, office

An office belongs to your organization (see [Offices](https://app.myclaimhouse.com/docs/offices.md)). Between the two there can be one optional level, the **practice group**: a practice that owns several offices. An office is in one group or none (standalone). Groups hold offices, never groups, and belong to a mode like offices: a test office joins only a test group.

Practice groups are off until Claim House turns them on for your organization: ask us. Once on, you manage your own groups. While they are off:

- Every practice-group endpoint, `practice_group_id` on [`POST /offices`](https://app.myclaimhouse.com/docs/api/createOffice.md) and [`PATCH /offices/{id}`](https://app.myclaimhouse.com/docs/api/updateOffice.md), and every `practice_group_id` filter answer `403 FEATURE_NOT_ENABLED`.
- An office still shows `practice_group_id: null`.
- [`GET /me`](https://app.myclaimhouse.com/docs/api/getCurrentKey.md) shows `organization.practice_groups_enabled`.

```bash runnable status=403
curl "https://app.myclaimhouse.com/api/v1/offices?practice_group_id=none" -H "Authorization: Bearer $CLAIMHOUSE_KEY"
```

Usage by office and the per-office limit work either way. The switch can be turned off again only while the organization has no groups.

## Billing, treating and pay-to addresses

The office on a claim is its billing provider. Where the treatment happened and where payment goes can each be another address:

| Address | Where it is set | On the claim file |
| --- | --- | --- |
| Billing | The office's address (never a PO box) | Billing provider (2010AA) |
| Treatment | The claim's `service_location`, else the office's `default_service_location` | Service facility (2310C), only when it is not the billing address |
| Payment | The office's `pay_to_address` (a PO box is fine) | Pay-to address (2010AB), only when it is not the billing address |

For centralized billing, send every claim with the billing office's `office_id` and, for each claim, the `service_location` where it was treated (`name`, `address`, and an optional `npi`). An office that always treats at one other address sets `default_service_location` instead. Set both on an office with [`PATCH /offices/{id}`](https://app.myclaimhouse.com/docs/offices.md#change-an-office). A provider's license is chosen by the state of the treatment address (see [Providers](https://app.myclaimhouse.com/docs/providers.md#licenses-by-state)).

## Moving claims to another office

[`POST /offices/{id}/move_claims`](https://app.myclaimhouse.com/docs/api/moveOfficeClaims.md) moves an office's unsent claims to another office of the same organization and mode, for example when a practice's billing is centralized:

```bash runnable status=201 capture=BILLING_OFFICE_ID=id
curl "https://app.myclaimhouse.com/api/v1/offices" \
  -H "Authorization: Bearer $CLAIMHOUSE_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{ "name": "Sample Central Billing", "address_line1": "300 Sample Avenue", "city": "Sampleville", "state": "GA", "postal_code": "303010300", "phone": "404-555-0101", "npi": "1999999000", "tax_id": "00-0000001", "specialty": "general" }'
```

```bash runnable status=200
curl "https://app.myclaimhouse.com/api/v1/offices/$OFFICE_ID/move_claims" \
  -H "Authorization: Bearer $CLAIMHOUSE_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d "{ \"to_office_id\": \"$BILLING_OFFICE_ID\" }"
```

The answer counts the claims moved by the state each was in, with `total` and `more`.

- **Moved:** drafts, claims that need attention, validated and queued claims, and rejected claims the payer never numbered.
- **Stay** with the office that sent them, with their files and ERAs: sent claims, claims the payer has numbered, open corrections and void transactions.
- At most 100 a call, queued ones first, all or none. While `more` is `true`, send it again with a new `Idempotency-Key`.
- Each moved claim gets a `moved` timeline entry and is validated for its new office. A queued one is queued again when it still validates (events `claim.needs_attention`, `claim.validated`, `claim.queued`), with a new `snapshot`. A claim treated at the old office's address needs a `service_location` to keep saying so.
- Attachments stay on their claims, under the office they were made for.
- A key with `submit` and no `read` moves only the claims it made.

## Practice groups

A group has a `name` (1 to 120 characters) and an optional `client_reference`. Its ID starts with `pgr_`.

- [`POST /practice_groups`](https://app.myclaimhouse.com/docs/api/createPracticeGroup.md) creates one (`Idempotency-Key`, `submit`).
- [`GET /practice_groups`](https://app.myclaimhouse.com/docs/api/listPracticeGroups.md) lists them, with `?client_reference=`. Each has `office_count`.
- [`GET /practice_groups/{id}`](https://app.myclaimhouse.com/docs/api/getPracticeGroup.md) reads one; [`PATCH /practice_groups/{id}`](https://app.myclaimhouse.com/docs/api/updatePracticeGroup.md) renames it or changes its `client_reference`.
- [`DELETE /practice_groups/{id}`](https://app.myclaimhouse.com/docs/api/deletePracticeGroup.md) removes a group with no offices; otherwise `409 CONFLICT`.

A group of another organization or mode is `404 NOT_FOUND`.

## Putting an office in a group

Send `practice_group_id` and `client_reference` on [`POST /offices`](https://app.myclaimhouse.com/docs/api/createOffice.md) or [`PATCH /offices/{id}`](https://app.myclaimhouse.com/docs/api/updateOffice.md); `"practice_group_id": null` makes an office standalone again.

```bash runnable status=200
curl -X PATCH "https://app.myclaimhouse.com/api/v1/offices/$OFFICE_ID" \
  -H "Authorization: Bearer $CLAIMHOUSE_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{"client_reference": "sample-office-0001"}'
```

## Your own references

`client_reference` is your own ID for an office or a group, up to 120 characters, shown on the object and in usage and statement rows. Claim House does not read it or require it to be unique. [`GET /offices`](https://app.myclaimhouse.com/docs/api/listOffices.md) and [`GET /practice_groups`](https://app.myclaimhouse.com/docs/api/listPracticeGroups.md) take `?client_reference=`, so you need no table of `off_` IDs.

## Paging through offices

[`GET /offices`](https://app.myclaimhouse.com/docs/api/listOffices.md) pages with `limit` (default 50, up to 100) and `cursor`, by name then ID: pass `next_cursor` back as `cursor` until it is `null`. A rename between pages skips or repeats nothing.

```bash runnable status=200
curl "https://app.myclaimhouse.com/api/v1/offices?limit=2" -H "Authorization: Bearer $CLAIMHOUSE_KEY"
```

Narrow it with `q` (part of a name, city, NPI or client reference), `registration` (the attachment network registration state, such as `pending`), `client_reference`, or `practice_group_id` (a group, or `none` for standalone offices; `403` while groups are off).

## Filtering by group

Every list that takes `office_id` also takes `practice_group_id`: [eligibility checks](https://app.myclaimhouse.com/docs/api/listEligibilityChecks.md), [claims](https://app.myclaimhouse.com/docs/api/listClaims.md), [patients](https://app.myclaimhouse.com/docs/api/listPatients.md) and [patient search](https://app.myclaimhouse.com/docs/api/searchPatients.md), [attachments](https://app.myclaimhouse.com/docs/api/listAttachments.md), [ERAs](https://app.myclaimhouse.com/docs/api/listEras.md) and [usage records](https://app.myclaimhouse.com/docs/api/listUsageUnits.md). Both at once is `422` ("Use office_id or practice_group_id, not both."), as is a group that is not yours. A record is in the group its office is in now.

```bash
curl "https://app.myclaimhouse.com/api/v1/eligibility?practice_group_id=pgr_1234567890abcdef&created_after=2026-09-01T06:00:00Z" \
  -H "Authorization: Bearer $CLAIMHOUSE_KEY"
```

## Usage by office

Every usage record carries its office: of the check, claim or attachment, or the payee office of an ERA. [`GET /usage/units`](https://app.myclaimhouse.com/docs/api/listUsageUnits.md) shows `office_id` and takes `?office_id=` and `?practice_group_id=`. An ERA held without a payee office has no office until one is set; then its records not yet on a statement take it.

[`GET /usage/offices`](https://app.myclaimhouse.com/docs/api/listUsageByOffice.md) gives a month office by office, a page at a time:

```bash runnable status=200
curl "https://app.myclaimhouse.com/api/v1/usage/offices?limit=25" -H "Authorization: Bearer $CLAIMHOUSE_KEY"
```

It takes `month=YYYY-MM` (default the current month, as [`GET /usage`](https://app.myclaimhouse.com/docs/api/getUsage.md)) and `practice_group_id`. Each row is an office with usage that month: `office_id`, `office_name`, `client_reference`, `practice_group_id`, `practice_group_name` and, per product, `billable` and `not_billed` counts. A last row with `office_id: null` counts records with no office. An open month uses each office's name and group as they are now; a closed month is read from its statement.

These are counts, never dollars: eligibility is priced in tiers on your whole month with a minimum on the total, so a per-office amount would be made up. Set your own prices from the counts.

## Statements by office

A closed month's statement stores each office's counts with its name, `client_reference` and group as they were then. [`GET /statements/{id}/offices`](https://app.myclaimhouse.com/docs/api/listStatementOffices.md) reads them in the shape of `GET /usage/offices`; they never change. Late usage is counted under its office on the statement that takes it, as an adjustment. See [Pricing and usage](https://app.myclaimhouse.com/docs/pricing.md#read-your-usage). On the Usage & billing screen, **By office** sits under each month, grouped by practice group, with a CSV download.

## The limit for one office

Eligibility checks have a limit per office on top of the key, organization and payer limits of [Rate limits](https://app.myclaimhouse.com/docs/errors-and-idempotency.md#rate-limits): 5 a second, with bursts of up to 50. When your payer limit is raised, all offices together may go faster, but no single office faster than its own. A check over it gets `429 TOO_MANY_REQUESTS` with `Retry-After` naming the office; other offices are not held back. A check counts against its `office_id`, or your only office.
