Team & roles
A tenant can have many members, each with a role that grants a set of scopes. Membership lives in a junction (a user can belong to multiple tenants), so roles are per-tenant.
Members
Section titled “Members”GET /v1/tenants/me/membersPATCH /v1/tenants/me/members/:userId # change roleDELETE /v1/tenants/me/members/:userId # removeInvitations
Section titled “Invitations”You invite by email — invitations never create pre-activated accounts:
POST /v1/tenants/me/members/invitationsGET /v1/tenants/me/members/invitationsDELETE /v1/tenants/me/members/invitations/:invitationIdThe invitation email carries a link and a six-digit code to type by hand; both
expire after 7 days. The invitee accepts with either one
(POST /v1/auth/accept-invitation takes the email and the code) and joins
with the assigned role. Seat limits come from the plan — inviting over the cap
returns MEMBER_LIMIT_REACHED.
Roles & scopes
Section titled “Roles & scopes”Six built-in roles map to scope sets (owner, admin, issuer, accountant, …). You can define custom roles with a tailored scope set:
GET /v1/tenants/me/rolesPOST /v1/tenants/me/rolesPATCH /v1/tenants/me/roles/:slugDELETE /v1/tenants/me/roles/:slugScopes gate individual actions (invoices:write, documents:accept,
audit:read, webhooks:manage, …) and are the same axis as API-key scopes —
though some scopes are JWT-only and can’t be granted to a key. Scopes are checked
independently of plan entitlements; a gated write must pass
both.
Ownership transfer
Section titled “Ownership transfer”Exactly one member is the owner. Transfer is a two-step, confirmed handoff:
POST /v1/tenants/me/members/transfer-ownership/requestPOST /v1/tenants/me/members/transfer-ownership/confirmDELETE /v1/tenants/me/members/transfer-ownership/pendingEvery membership and role change is recorded in the audit log.