Get the immediate child companies (accounts/locations) directly under the authenticated user's own company, formatted as value/label option pairs for dropdowns.
Auth: Both — authentication. Role-agnostic account prefix: the target company is always the current user's company. The endpoint resolves the children as (direct one-level children only, not a recursive tree walk). If the user has account assignments, results are further restricted to the ids returned. The role only differs in reachable scope: a partner user sees its account/location children, an account user sees its own children — the same single query applies to both.
Rate limit: No rate limit.
Request
- Query:
search(string, optional, max 255) — filters by account name or client account id (partial match). - Query:
limit(integer, optional) — page size for the filtered mode; 10–50 (values below 10 are raised to 10), default 10. - Passing
searchorlimitswitches to a name-ordered, limited slice (for autocomplete); passing neither returns the full list.
Response — { data: [.] } envelope; an array of option objects from the select.
value(integer) — the child company id (aliased from the account'sid).label(string) — the child company name, suffixed with" - {client account id}"when one is set. When the child hasbundle_id = 1(a partner row) the label is suffixed with" (Partner)"instead.
Note: the OpenAPI attribute on the method advertises a client_account_id field, but the actual query select only returns value and label. client_account_id is NOT in the response.
Returns 404 with Company not found. in errors if the authenticated user has no associated company.
Errors: 422 on validation failure.
| Time | Status | User Agent | |
|---|---|---|---|
Retrieving recent requests… | |||
