Skip to content

Organizations

Create a new organization. You become the admin automatically.

Body:

{
"name": "Acme Inc",
"slug": "acme-inc",
"description": "Optional"
}

Response: Organization object + JWT tokens (auto-switches to new org).

Get organization details. You must be a member.

Update organization name, slug, or description. You must be a member.

Body:

{
"name": "Updated Name",
"slug": "updated-slug"
}

Delete an organization. Requires Admin role.

Invite a user to the organization. Requires Admin role.

Body:

{
"invitedEmail": "newuser@example.com",
"desired_role": "user"
}

Response:

{
"id": 1,
"code": "inv_abc123...",
"invitedEmail": "newuser@example.com",
"invite_role": "user",
"status": "pending"
}