Offices¶
Deprecated endpoint
This endpoint is deprecated. Use Organizations for the unified federal hierarchy. This endpoint will be removed in a future version.
Offices are sub-agency organizations exposed at /api/offices/.
If you need the unified Federal Hierarchy model (departments/agencies/offices all as one tree), see Organizations. For field definitions, see the Organizations Data Dictionary.
Endpoints¶
GET /api/offices/(list)GET /api/offices/{code}/(detail)
Filtering¶
| Param | What it does |
|---|---|
search | Full-text search over offices (vector-backed). |
Ordering¶
/api/offices/ does not support ordering=....
Pagination¶
Offices use standard page-number pagination:
page(default 1)limit(max 100)
Response shaping¶
This endpoint supports response shaping via the shape query parameter.
- Leaves:
code,name, plus flat aliasesoffice_code,office_name,agency_code,agency_name,department_code,department_name - Expansions:
agency(code,name,abbreviation)department(code,name,abbreviation,description,cgac,website,congressional_justification)
Default shape (no ?shape= param): office_code,office_name,agency_code,agency_name,department_code,department_name (flat aliases)
# Default flat format
/api/offices/?shape=office_code,office_name,agency_name
# Direct leaves with nested expansion
/api/offices/4700/?shape=code,name,agency(code,name,abbreviation)
# Office with department details
/api/offices/4700/?shape=code,name,department(name,description,website)
SDK examples¶
The SDKs don’t yet expose a first-class list_offices() / listOffices() method. You can still call the endpoint via the SDK’s internal HTTP helper.