Organization
8 endpoints under /v1/organizations.
Read the caller's current organization.
/v1/organizations/currentRequiresorganizations:admin
Headers
X-Organization-IDstringoptional
Failures return the error envelope; branch on error_code.
Update org name, billing email or settings.
/v1/organizations/currentAudited atomically with the mutation: ORGANIZATION_RENAMED iff name changed, otherwise ORGANIZATION_UPDATED.
Requiresorganizations:admin
Headers
X-Organization-IDstringoptional
Request body
namestringoptionalbilling_emailstring (email)optionalsettingsobjectoptional
Failures return the error envelope; branch on error_code.
List pending (unaccepted, unexpired) invitations.
/v1/organizations/current/invitationsRequiresorganizations:admin
Headers
X-Organization-IDstringoptional
Failures return the error envelope; branch on error_code.
Invite a new member to the org.
/v1/organizations/current/invitationsThe member_invite OperationSpec enforces max_members, shared with the agent-tool path. The ORG_INVITATION_SENT audit row commits with the invitation.
Requiresorganizations:admin
Headers
X-Organization-IDstringoptional
Request body
emailstring (email)requiredrolestringoptional
Failures return the error envelope; branch on error_code.
Revoke a pending invitation.
/v1/organizations/current/invitations/{invitation_id}Ownership by the caller's org is checked before delegating, since the service takes only the invitation id; this blocks cross-org deletion.
Requiresorganizations:admin
Path parameters
invitation_idstring (uuid)required
Headers
X-Organization-IDstringoptional
Failures return the error envelope; branch on error_code.
List every member of the caller's org.
/v1/organizations/current/membersRequiresorganizations:admin
Headers
X-Organization-IDstringoptional
Failures return the error envelope; branch on error_code.
Change a member's role.
/v1/organizations/current/members/{user_id}Emits ORG_MEMBER_ROLE_CHANGED; demoting the last owner is refused (RemoveMemberError).
Requiresorganizations:admin
Path parameters
user_idstring (uuid)required
Headers
X-Organization-IDstringoptional
Request body
rolestringrequired
Failures return the error envelope; branch on error_code.
Remove a member from the org, revoking the API keys they owned.
/v1/organizations/current/members/{user_id}Requiresorganizations:admin
Path parameters
user_idstring (uuid)required
Headers
X-Organization-IDstringoptional
Failures return the error envelope; branch on error_code.