This page documents the canonical HTTP contract for this endpoint.
The example uses explicit IDs. For descriptor mode, use the Companies workspace selection contract and preserve the same search, filters, owner and table context used to identify the selection. The route writes the supplied user_id but does not verify that the target is an organization member; resolve and verify the user through the organization user catalog before calling.
Body parameters
selection· optionalobject
Company workspace selection. When both a non-empty dictionary selection and company_ids are present, selection takes precedence; otherwise company_ids is adapted to an explicit-ID selection.
company_ids· optionalarray<string>
Optional legacy explicit company IDs; used when no non-empty dictionary selection is supplied.
user_idrequiredstring
Non-empty user ID to write as owner. The route does not verify that this ID belongs to an organization member; supply a previously verified organization user ID.
| Name | Type | Description |
|---|---|---|
| selection | object | Company workspace selection. When both a non-empty dictionary selection and company_ids are present, selection takes precedence; otherwise company_ids is adapted to an explicit-ID selection. |
| company_ids | array<string> | Optional legacy explicit company IDs; used when no non-empty dictionary selection is supplied. |
| user_idrequired | string | Non-empty user ID to write as owner. The route does not verify that this ID belongs to an organization member; supply a previously verified organization user ID. |
Errors
| Status | Meaning |
|---|---|
| 401 | Authentication is missing or invalid. |
| 403 | The credential is invalid or lacks the required scope. |
| 400 | Selection or payload is invalid. |
| 422 | A missing or malformed JSON body cannot be parsed; route-level payload validation errors are returned as 400. |
| 404 | No companies match the selection. |
