HTTP API

Auth

PUT/admin/auth/org/{id}/sso
PUT
/admin/auth/org/{id}/sso

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Path Parameters

id*string

Organization ID

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Request payload for setting an organization's single sign-on policy.

Response Body

application/json

curl -X PUT "https://example.com/admin/auth/org/string/sso" \  -H "Content-Type: application/json" \  -d '{    "sso_enforced": true  }'
{  "created_at": "2019-08-24T14:15:22Z",  "created_by": "string",  "logo_url": "string",  "member_count": 0,  "metadata": null,  "name": "string",  "org_id": "string",  "slug": "string",  "sso_enforced": true,  "updated_at": "2019-08-24T14:15:22Z",  "sso_exempt_user_ids": [    "string"  ]}
GET/admin/auth/sessions
GET
/admin/auth/sessions

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Query Parameters

user_id?string

Filter sessions by user ID.

Constrained because it reaches a TAG filter, where ',' and '|' separate values.

page?integer

1-indexed page number.

Formatint64
Range0 <= value
page_size?integer

Page size (max 100).

Formatint64
Range0 <= value

Response Body

application/json

curl -X GET "https://example.com/admin/auth/sessions"
{  "pagination": {    "has_more": true,    "page": 0,    "page_size": 0,    "total": 0  },  "sessions": [    {      "active": true,      "created_at": "2019-08-24T14:15:22Z",      "expires_at": "2019-08-24T14:15:22Z",      "id": "string",      "impersonated_by": "string",      "ip_address": "string",      "user_agent": "string",      "user_id": "string"    }  ]}
DELETE/admin/auth/sessions/{id}
DELETE
/admin/auth/sessions/{id}

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Path Parameters

id*string

Session ID

Response Body

application/json

curl -X DELETE "https://example.com/admin/auth/sessions/string"
{  "message": "string"}
GET/admin/auth/users
GET
/admin/auth/users

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Query Parameters

q?string

Free-text search on name/email/username.

Bounded because it reaches a TAG filter as well as the text index.

page?integer

1-indexed page number.

Formatint64
Range0 <= value
page_size?integer

Page size (max 100).

Formatint64
Range0 <= value
role?string

Filter by role (e.g., "user" or "admin").

Constrained because it reaches a TAG filter, where ',' and '|' separate values.

banned?boolean

Filter by banned status.

email_verified?boolean

Filter by email verified status.

Response Body

application/json

curl -X GET "https://example.com/admin/auth/users"
{  "pagination": {    "has_more": true,    "page": 0,    "page_size": 0,    "total": 0  },  "users": [    {      "banned": true,      "created_at": "2019-08-24T14:15:22Z",      "display_name": "string",      "email": "string",      "email_verified": true,      "id": "string",      "role": "user",      "two_factor_enabled": true,      "username": "string"    }  ]}
GET/admin/auth/users/{id}
GET
/admin/auth/users/{id}

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Path Parameters

id*string

User ID

Response Body

application/json

curl -X GET "https://example.com/admin/auth/users/string"
{  "active_session_count": 0,  "api_key_count": 0,  "ban": null,  "identities": [    {      "id": "string",      "linked_at": "2019-08-24T14:15:22Z",      "provider": "string",      "provider_display_name": "string",      "provider_email": "string"    }  ],  "org_memberships": [    {      "org_id": "string",      "org_name": "string",      "role": "owner"    }  ],  "passkey_count": 0,  "user": {    "banned": true,    "created_at": "2019-08-24T14:15:22Z",    "display_name": "string",    "email": "string",    "email_verified": true,    "id": "string",    "role": "user",    "two_factor_enabled": true,    "username": "string"  }}
PATCH/admin/auth/users/{id}
PATCH
/admin/auth/users/{id}

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Path Parameters

id*string

User ID

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Request payload for updating a user via admin endpoint.

Response Body

application/json

curl -X PATCH "https://example.com/admin/auth/users/string" \  -H "Content-Type: application/json" \  -d '{}'
{  "banned": true,  "created_at": "2019-08-24T14:15:22Z",  "display_name": "string",  "email": "string",  "email_verified": true,  "id": "string",  "role": "user",  "two_factor_enabled": true,  "username": "string"}
DELETE/admin/auth/users/{id}
DELETE
/admin/auth/users/{id}

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Path Parameters

id*string

User ID

Response Body

application/json

curl -X DELETE "https://example.com/admin/auth/users/string"
{  "message": "string"}
POST/admin/auth/users/{id}/ban
POST
/admin/auth/users/{id}/ban

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Path Parameters

id*string

User ID

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Request payload for banning a user.

Response Body

application/json

curl -X POST "https://example.com/admin/auth/users/string/ban" \  -H "Content-Type: application/json" \  -d '{    "reason": "string"  }'
{  "message": "string"}
POST/admin/auth/users/{id}/impersonate
POST
/admin/auth/users/{id}/impersonate

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Path Parameters

id*string

Target user ID

Response Body

application/json

curl -X POST "https://example.com/admin/auth/users/string/impersonate"
{  "access_token": "string",  "expires_in": 0,  "refresh_token": "string",  "requires_2fa": true,  "token_type": "string",  "two_factor_token": "string",  "user": null}
POST/admin/auth/users/{id}/unban
POST
/admin/auth/users/{id}/unban

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Path Parameters

id*string

User ID

Response Body

application/json

curl -X POST "https://example.com/admin/auth/users/string/unban"
{  "message": "string"}
POST/api/v1/auth/2fa/backup/regenerate
POST
/api/v1/auth/2fa/backup/regenerate

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Request payload for verifying a TOTP code (used in setup verification, disable, and backup regeneration).

Response Body

application/json

curl -X POST "https://example.com/api/v1/auth/2fa/backup/regenerate" \  -H "Content-Type: application/json" \  -d '{    "code": "string"  }'
{  "backup_codes": [    "string"  ]}
GET/api/v1/auth/2fa/status
GET
/api/v1/auth/2fa/status

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Response Body

application/json

curl -X GET "https://example.com/api/v1/auth/2fa/status"
{  "backup_codes_remaining": 0,  "enabled": true}
POST/api/v1/auth/2fa/totp/disable
POST
/api/v1/auth/2fa/totp/disable

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Request payload for verifying a TOTP code (used in setup verification, disable, and backup regeneration).

Response Body

application/json

curl -X POST "https://example.com/api/v1/auth/2fa/totp/disable" \  -H "Content-Type: application/json" \  -d '{    "code": "string"  }'
{  "message": "string"}
POST/api/v1/auth/2fa/totp/setup
POST
/api/v1/auth/2fa/totp/setup

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Response Body

application/json

curl -X POST "https://example.com/api/v1/auth/2fa/totp/setup"
{  "backup_codes": [    "string"  ],  "qr_code_uri": "string",  "secret": "string"}
POST/api/v1/auth/2fa/totp/verify-setup
POST
/api/v1/auth/2fa/totp/verify-setup

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Request payload for verifying a TOTP code (used in setup verification, disable, and backup regeneration).

Response Body

application/json

curl -X POST "https://example.com/api/v1/auth/2fa/totp/verify-setup" \  -H "Content-Type: application/json" \  -d '{    "code": "string"  }'
{  "message": "string"}
POST/api/v1/auth/account/link
POST
/api/v1/auth/account/link

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Request payload for linking an OAuth account to the authenticated user.

Response Body

application/json

curl -X POST "https://example.com/api/v1/auth/account/link" \  -H "Content-Type: application/json" \  -d '{    "code": "string",    "provider": "string",    "redirect_uri": "string"  }'
{  "id": "string",  "linked_at": "2019-08-24T14:15:22Z",  "provider": "string",  "provider_display_name": "string",  "provider_email": "string"}
POST/api/v1/auth/account/unlink
POST
/api/v1/auth/account/unlink

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Request payload for unlinking an OAuth account from the authenticated user.

Response Body

application/json

curl -X POST "https://example.com/api/v1/auth/account/unlink" \  -H "Content-Type: application/json" \  -d '{    "provider": "string"  }'
{  "message": "string"}
GET/api/v1/auth/accounts
GET
/api/v1/auth/accounts

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Response Body

application/json

curl -X GET "https://example.com/api/v1/auth/accounts"
{  "accounts": [    {      "id": "string",      "linked_at": "2019-08-24T14:15:22Z",      "provider": "string",      "provider_display_name": "string",      "provider_email": "string"    }  ]}
GET/api/v1/auth/api-keys
GET
/api/v1/auth/api-keys

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Query Parameters

page?integer

1-indexed page number.

Formatint64
Range0 <= value
page_size?integer

Page size (max 100).

Formatint64
Range0 <= value

Response Body

application/json

curl -X GET "https://example.com/api/v1/auth/api-keys"
{  "api_keys": [    {      "api_key_id": "string",      "created_at": "2019-08-24T14:15:22Z",      "expires_at": "2019-08-24T14:15:22Z",      "key_prefix": "string",      "last_used_at": "2019-08-24T14:15:22Z",      "name": "string",      "org_id": "string",      "revoked": true,      "scopes": [        "string"      ]    }  ],  "pagination": {    "has_more": true,    "page": 0,    "page_size": 0,    "total": 0  }}
POST/api/v1/auth/api-keys
POST
/api/v1/auth/api-keys

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Request payload for creating a new API key.

Response Body

application/json

curl -X POST "https://example.com/api/v1/auth/api-keys" \  -H "Content-Type: application/json" \  -d '{    "name": "string",    "scopes": [      "string"    ]  }'
{  "api_key_id": "string",  "created_at": "2019-08-24T14:15:22Z",  "expires_at": "2019-08-24T14:15:22Z",  "key": "string",  "key_prefix": "string",  "name": "string",  "org_id": "string",  "scopes": [    "string"  ]}
GET/api/v1/auth/api-keys/{id}
GET
/api/v1/auth/api-keys/{id}

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Path Parameters

id*string

API key ID

Response Body

application/json

curl -X GET "https://example.com/api/v1/auth/api-keys/string"
{  "api_key_id": "string",  "created_at": "2019-08-24T14:15:22Z",  "expires_at": "2019-08-24T14:15:22Z",  "key_prefix": "string",  "last_used_at": "2019-08-24T14:15:22Z",  "name": "string",  "org_id": "string",  "revoked": true,  "scopes": [    "string"  ]}
PATCH/api/v1/auth/api-keys/{id}
PATCH
/api/v1/auth/api-keys/{id}

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Path Parameters

id*string

API key ID

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Request payload for updating an existing API key (PATCH pattern: all fields optional).

Response Body

application/json

curl -X PATCH "https://example.com/api/v1/auth/api-keys/string" \  -H "Content-Type: application/json" \  -d '{}'
{  "api_key_id": "string",  "created_at": "2019-08-24T14:15:22Z",  "expires_at": "2019-08-24T14:15:22Z",  "key_prefix": "string",  "last_used_at": "2019-08-24T14:15:22Z",  "name": "string",  "org_id": "string",  "revoked": true,  "scopes": [    "string"  ]}
DELETE/api/v1/auth/api-keys/{id}
DELETE
/api/v1/auth/api-keys/{id}

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Path Parameters

id*string

API key ID

Response Body

application/json

curl -X DELETE "https://example.com/api/v1/auth/api-keys/string"
{  "message": "string"}
POST/api/v1/auth/cli/session/{id}/complete
POST
/api/v1/auth/cli/session/{id}/complete

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Path Parameters

id*string

CLI session ID

Response Body

curl -X POST "https://example.com/api/v1/auth/cli/session/string/complete"
Empty
POST/api/v1/auth/email/verify/send
POST
/api/v1/auth/email/verify/send

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Request payload for sending a verification email (optionally with a redirect URL).

Response Body

application/json

curl -X POST "https://example.com/api/v1/auth/email/verify/send" \  -H "Content-Type: application/json" \  -d '{}'
{  "message": "string"}
GET/api/v1/auth/invitations
GET
/api/v1/auth/invitations

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Query Parameters

page?integer

1-indexed page number.

Formatint64
Range0 <= value
page_size?integer

Page size (max 100).

Formatint64
Range0 <= value

Response Body

application/json

curl -X GET "https://example.com/api/v1/auth/invitations"
{  "invitations": [    {      "created_at": "2019-08-24T14:15:22Z",      "email": "string",      "expires_at": "2019-08-24T14:15:22Z",      "invitation_id": "string",      "org_id": "string",      "org_name": "string",      "role": "owner",      "status": "pending"    }  ],  "pagination": {    "has_more": true,    "page": 0,    "page_size": 0,    "total": 0  }}
GET/api/v1/auth/me
GET
/api/v1/auth/me

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Response Body

application/json

curl -X GET "https://example.com/api/v1/auth/me"
{  "created_at": "2019-08-24T14:15:22Z",  "display_name": "string",  "email": "string",  "email_verified": true,  "id": "string",  "image_url": "string",  "role": "user",  "two_factor_enabled": true,  "updated_at": "2019-08-24T14:15:22Z",  "username": "string"}
POST/api/v1/auth/org
POST
/api/v1/auth/org

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Request payload for creating a new organization.

Response Body

application/json

curl -X POST "https://example.com/api/v1/auth/org" \  -H "Content-Type: application/json" \  -d '{    "name": "string",    "slug": "string"  }'
{  "created_at": "2019-08-24T14:15:22Z",  "created_by": "string",  "logo_url": "string",  "member_count": 0,  "metadata": null,  "name": "string",  "org_id": "string",  "slug": "string",  "sso_enforced": true,  "updated_at": "2019-08-24T14:15:22Z"}
POST/api/v1/auth/org/accept-invite/{id}
POST
/api/v1/auth/org/accept-invite/{id}

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Path Parameters

id*string

Invitation ID

Response Body

application/json

curl -X POST "https://example.com/api/v1/auth/org/accept-invite/string"
{  "created_at": "2019-08-24T14:15:22Z",  "member_id": "string",  "role": "owner",  "user_display_name": "string",  "user_email": "string",  "user_id": "string"}
GET/api/v1/auth/org/check-slug
GET
/api/v1/auth/org/check-slug

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Query Parameters

slug*string

The slug to check.

Constrained like the slug it is checking for: the value reaches a TAG filter, where ',' and '|' separate values, so an unconstrained one answers for a batch of slugs at once rather than the one asked about.

Response Body

application/json

curl -X GET "https://example.com/api/v1/auth/org/check-slug?slug=string"
{  "available": true}
POST/api/v1/auth/org/clear-active
POST
/api/v1/auth/org/clear-active

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Response Body

application/json

curl -X POST "https://example.com/api/v1/auth/org/clear-active"
{  "access_token": "string",  "expires_in": 0}
POST/api/v1/auth/org/decline-invite/{id}
POST
/api/v1/auth/org/decline-invite/{id}

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Path Parameters

id*string

Invitation ID

Response Body

curl -X POST "https://example.com/api/v1/auth/org/decline-invite/string"
Empty
GET/api/v1/auth/org/{id}
GET
/api/v1/auth/org/{id}

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Path Parameters

id*string

Organization ID

Response Body

application/json

curl -X GET "https://example.com/api/v1/auth/org/string"
{  "created_at": "2019-08-24T14:15:22Z",  "created_by": "string",  "logo_url": "string",  "member_count": 0,  "metadata": null,  "name": "string",  "org_id": "string",  "slug": "string",  "sso_enforced": true,  "updated_at": "2019-08-24T14:15:22Z"}
PATCH/api/v1/auth/org/{id}
PATCH
/api/v1/auth/org/{id}

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Path Parameters

id*string

Organization ID

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Request payload for updating an organization (PATCH pattern: all fields optional).

Response Body

application/json

curl -X PATCH "https://example.com/api/v1/auth/org/string" \  -H "Content-Type: application/json" \  -d '{}'
{  "created_at": "2019-08-24T14:15:22Z",  "created_by": "string",  "logo_url": "string",  "member_count": 0,  "metadata": null,  "name": "string",  "org_id": "string",  "slug": "string",  "sso_enforced": true,  "updated_at": "2019-08-24T14:15:22Z"}
DELETE/api/v1/auth/org/{id}
DELETE
/api/v1/auth/org/{id}

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Path Parameters

id*string

Organization ID

Response Body

curl -X DELETE "https://example.com/api/v1/auth/org/string"
Empty
GET/api/v1/auth/org/{id}/invitations
GET
/api/v1/auth/org/{id}/invitations

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Path Parameters

id*string

Organization ID

Query Parameters

page?integer

1-indexed page number.

Formatint64
Range0 <= value
page_size?integer

Page size (max 100).

Formatint64
Range0 <= value

Response Body

application/json

curl -X GET "https://example.com/api/v1/auth/org/string/invitations"
{  "invitations": [    {      "created_at": "2019-08-24T14:15:22Z",      "email": "string",      "expires_at": "2019-08-24T14:15:22Z",      "invitation_id": "string",      "org_id": "string",      "org_name": "string",      "role": "owner",      "status": "pending"    }  ],  "pagination": {    "has_more": true,    "page": 0,    "page_size": 0,    "total": 0  }}
POST/api/v1/auth/org/{id}/invite
POST
/api/v1/auth/org/{id}/invite

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Path Parameters

id*string

Organization ID

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Request payload for inviting a member to an organization.

Response Body

application/json

curl -X POST "https://example.com/api/v1/auth/org/string/invite" \  -H "Content-Type: application/json" \  -d '{    "email": "string",    "role": "owner"  }'
{  "created_at": "2019-08-24T14:15:22Z",  "email": "string",  "expires_at": "2019-08-24T14:15:22Z",  "invitation_id": "string",  "org_id": "string",  "org_name": "string",  "role": "owner",  "status": "pending"}
GET/api/v1/auth/org/{id}/members
GET
/api/v1/auth/org/{id}/members

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Path Parameters

id*string

Organization ID

Query Parameters

page?integer

1-indexed page number.

Formatint64
Range0 <= value
page_size?integer

Page size (max 100).

Formatint64
Range0 <= value

Response Body

application/json

curl -X GET "https://example.com/api/v1/auth/org/string/members"
{  "members": [    {      "created_at": "2019-08-24T14:15:22Z",      "member_id": "string",      "role": "owner",      "user_display_name": "string",      "user_email": "string",      "user_id": "string"    }  ],  "pagination": {    "has_more": true,    "page": 0,    "page_size": 0,    "total": 0  }}
DELETE/api/v1/auth/org/{id}/members/{mid}
DELETE
/api/v1/auth/org/{id}/members/{mid}

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Path Parameters

id*string

Organization ID

mid*string

Member ID

Response Body

curl -X DELETE "https://example.com/api/v1/auth/org/string/members/string"
Empty
PATCH/api/v1/auth/org/{id}/members/{mid}/role
PATCH
/api/v1/auth/org/{id}/members/{mid}/role

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Path Parameters

id*string

Organization ID

mid*string

Member ID

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Request payload for changing a member's role.

Response Body

application/json

curl -X PATCH "https://example.com/api/v1/auth/org/string/members/string/role" \  -H "Content-Type: application/json" \  -d '{    "role": "owner"  }'
{  "created_at": "2019-08-24T14:15:22Z",  "member_id": "string",  "role": "owner",  "user_display_name": "string",  "user_email": "string",  "user_id": "string"}
GET/api/v1/auth/org/{id}/providers
GET
/api/v1/auth/org/{id}/providers

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Path Parameters

id*string

Organization ID

Response Body

application/json

curl -X GET "https://example.com/api/v1/auth/org/string/providers"
[  {    "authorization_endpoint": "string",    "client_id": "string",    "created_at": "2019-08-24T14:15:22Z",    "enabled": true,    "issuer": "string",    "name": "string",    "org_id": "string",    "provider_id": "string",    "redirect_uri": "string",    "scopes": [      "string"    ],    "teardown_in_progress": true,    "token_endpoint": "string",    "updated_at": "2019-08-24T14:15:22Z",    "userinfo_endpoint": "string"  }]
POST/api/v1/auth/org/{id}/providers
POST
/api/v1/auth/org/{id}/providers

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Path Parameters

id*string

Organization ID

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Request payload for registering an organization's own identity provider.

Response Body

application/json

curl -X POST "https://example.com/api/v1/auth/org/string/providers" \  -H "Content-Type: application/json" \  -d '{    "authorization_endpoint": "string",    "client_id": "string",    "client_secret": "string",    "name": "string",    "token_endpoint": "string",    "userinfo_endpoint": "string"  }'
{  "authorization_endpoint": "string",  "client_id": "string",  "created_at": "2019-08-24T14:15:22Z",  "enabled": true,  "issuer": "string",  "name": "string",  "org_id": "string",  "provider_id": "string",  "redirect_uri": "string",  "scopes": [    "string"  ],  "teardown_in_progress": true,  "token_endpoint": "string",  "updated_at": "2019-08-24T14:15:22Z",  "userinfo_endpoint": "string"}
GET/api/v1/auth/org/{id}/providers/{provider_id}
GET
/api/v1/auth/org/{id}/providers/{provider_id}

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Path Parameters

id*string

Organization ID

provider_id*string

Provider ID

Response Body

application/json

curl -X GET "https://example.com/api/v1/auth/org/string/providers/string"
{  "authorization_endpoint": "string",  "client_id": "string",  "created_at": "2019-08-24T14:15:22Z",  "enabled": true,  "issuer": "string",  "name": "string",  "org_id": "string",  "provider_id": "string",  "redirect_uri": "string",  "scopes": [    "string"  ],  "teardown_in_progress": true,  "token_endpoint": "string",  "updated_at": "2019-08-24T14:15:22Z",  "userinfo_endpoint": "string"}
PATCH/api/v1/auth/org/{id}/providers/{provider_id}
PATCH
/api/v1/auth/org/{id}/providers/{provider_id}

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Path Parameters

id*string

Organization ID

provider_id*string

Provider ID

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Request payload for changing an organization's identity provider.

Absent means "leave alone" for every field, so a caller who wants to flip enabled does not have to resend the whole configuration and risk clobbering a setting someone else changed in between.

Response Body

application/json

curl -X PATCH "https://example.com/api/v1/auth/org/string/providers/string" \  -H "Content-Type: application/json" \  -d '{}'
{  "authorization_endpoint": "string",  "client_id": "string",  "created_at": "2019-08-24T14:15:22Z",  "enabled": true,  "issuer": "string",  "name": "string",  "org_id": "string",  "provider_id": "string",  "redirect_uri": "string",  "scopes": [    "string"  ],  "teardown_in_progress": true,  "token_endpoint": "string",  "updated_at": "2019-08-24T14:15:22Z",  "userinfo_endpoint": "string"}
DELETE/api/v1/auth/org/{id}/providers/{provider_id}
DELETE
/api/v1/auth/org/{id}/providers/{provider_id}

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Path Parameters

id*string

Organization ID

provider_id*string

Provider ID

Response Body

curl -X DELETE "https://example.com/api/v1/auth/org/string/providers/string"
Empty
GET/api/v1/auth/org/{id}/providers/{provider_id}/domains
GET
/api/v1/auth/org/{id}/providers/{provider_id}/domains

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Path Parameters

id*string

Organization ID

provider_id*string

Provider ID

Response Body

application/json

curl -X GET "https://example.com/api/v1/auth/org/string/providers/string/domains"
[  {    "created_at": "2019-08-24T14:15:22Z",    "domain": "string",    "domain_id": "string",    "last_checked_at": "2019-08-24T14:15:22Z",    "provider_id": "string",    "verification_record_name": "string",    "verification_record_value": "string",    "verified": true,    "verified_at": "2019-08-24T14:15:22Z"  }]
POST/api/v1/auth/org/{id}/providers/{provider_id}/domains
POST
/api/v1/auth/org/{id}/providers/{provider_id}/domains

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Path Parameters

id*string

Organization ID

provider_id*string

Provider ID

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Request payload for claiming an email domain for an organization's provider.

Response Body

application/json

curl -X POST "https://example.com/api/v1/auth/org/string/providers/string/domains" \  -H "Content-Type: application/json" \  -d '{    "domain": "string"  }'
{  "created_at": "2019-08-24T14:15:22Z",  "domain": "string",  "domain_id": "string",  "last_checked_at": "2019-08-24T14:15:22Z",  "provider_id": "string",  "verification_record_name": "string",  "verification_record_value": "string",  "verified": true,  "verified_at": "2019-08-24T14:15:22Z"}
DELETE/api/v1/auth/org/{id}/providers/{provider_id}/domains/{domain_id}
DELETE
/api/v1/auth/org/{id}/providers/{provider_id}/domains/{domain_id}

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Path Parameters

id*string

Organization ID

provider_id*string

Identity provider ID

domain_id*string

Domain claim ID

Response Body

curl -X DELETE "https://example.com/api/v1/auth/org/string/providers/string/domains/string"
Empty
POST/api/v1/auth/org/{id}/providers/{provider_id}/domains/{domain_id}/verify
POST
/api/v1/auth/org/{id}/providers/{provider_id}/domains/{domain_id}/verify

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Path Parameters

id*string

Organization ID

provider_id*string

Provider ID

domain_id*string

Domain ID

Response Body

application/json

curl -X POST "https://example.com/api/v1/auth/org/string/providers/string/domains/string/verify"
{  "created_at": "2019-08-24T14:15:22Z",  "domain": "string",  "domain_id": "string",  "last_checked_at": "2019-08-24T14:15:22Z",  "provider_id": "string",  "verification_record_name": "string",  "verification_record_value": "string",  "verified": true,  "verified_at": "2019-08-24T14:15:22Z"}
GET/api/v1/auth/org/{id}/providers/{provider_id}/drift
GET
/api/v1/auth/org/{id}/providers/{provider_id}/drift

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Path Parameters

id*string

Organization ID

provider_id*string

Identity provider ID

Response Body

application/json

curl -X GET "https://example.com/api/v1/auth/org/string/providers/string/drift"
{  "links_truncated": true,  "orphaned_links": [    {      "email": "string",      "external_id": "string",      "user_id": "string"    }  ],  "recent_failures": [    {      "at": "string",      "detail": "string",      "status": 0    }  ],  "unlinked_members": [    {      "email": "string",      "external_id": "string",      "user_id": "string"    }  ]}
POST/api/v1/auth/org/{id}/set-active
POST
/api/v1/auth/org/{id}/set-active

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Path Parameters

id*string

Organization ID

Response Body

application/json

curl -X POST "https://example.com/api/v1/auth/org/string/set-active"
{  "access_token": "string",  "expires_in": 0,  "name": "string",  "org_id": "string",  "role": "owner",  "slug": "string"}
GET/api/v1/auth/orgs
GET
/api/v1/auth/orgs

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Query Parameters

page?integer

1-indexed page number.

Formatint64
Range0 <= value
page_size?integer

Page size (max 100).

Formatint64
Range0 <= value

Response Body

application/json

curl -X GET "https://example.com/api/v1/auth/orgs"
{  "organizations": [    {      "created_at": "2019-08-24T14:15:22Z",      "created_by": "string",      "logo_url": "string",      "member_count": 0,      "metadata": null,      "name": "string",      "org_id": "string",      "slug": "string",      "sso_enforced": true,      "updated_at": "2019-08-24T14:15:22Z"    }  ],  "pagination": {    "has_more": true,    "page": 0,    "page_size": 0,    "total": 0  }}
POST/api/v1/auth/passkey/register/options
POST
/api/v1/auth/passkey/register/options

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Request payload for initiating passkey registration (get challenge options).

Response Body

application/json

curl -X POST "https://example.com/api/v1/auth/passkey/register/options" \  -H "Content-Type: application/json" \  -d '{}'
{  "challenge_id": "string",  "options": null}
POST/api/v1/auth/passkey/register/verify
POST
/api/v1/auth/passkey/register/verify

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Request payload for completing passkey registration (verify challenge response).

Response Body

application/json

curl -X POST "https://example.com/api/v1/auth/passkey/register/verify" \  -H "Content-Type: application/json" \  -d '{    "challenge_id": "string",    "device_name": "string",    "response": null  }'
{  "backed_up": true,  "created_at": "2019-08-24T14:15:22Z",  "device_name": "string",  "last_used_at": "2019-08-24T14:15:22Z",  "passkey_id": "string"}
GET/api/v1/auth/passkeys
GET
/api/v1/auth/passkeys

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Response Body

application/json

curl -X GET "https://example.com/api/v1/auth/passkeys"
{  "passkeys": [    {      "backed_up": true,      "created_at": "2019-08-24T14:15:22Z",      "device_name": "string",      "last_used_at": "2019-08-24T14:15:22Z",      "passkey_id": "string"    }  ]}
PATCH/api/v1/auth/passkeys/{id}
PATCH
/api/v1/auth/passkeys/{id}

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Path Parameters

id*string

Passkey ID

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Request payload for updating a passkey's device name.

Response Body

application/json

curl -X PATCH "https://example.com/api/v1/auth/passkeys/string" \  -H "Content-Type: application/json" \  -d '{    "device_name": "string"  }'
{  "backed_up": true,  "created_at": "2019-08-24T14:15:22Z",  "device_name": "string",  "last_used_at": "2019-08-24T14:15:22Z",  "passkey_id": "string"}
DELETE/api/v1/auth/passkeys/{id}
DELETE
/api/v1/auth/passkeys/{id}

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Path Parameters

id*string

Passkey ID

Response Body

application/json

curl -X DELETE "https://example.com/api/v1/auth/passkeys/string"
{  "message": "string"}
POST/api/v1/auth/password/change
POST
/api/v1/auth/password/change

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Request payload for changing the current user's password (requires current password).

Response Body

application/json

curl -X POST "https://example.com/api/v1/auth/password/change" \  -H "Content-Type: application/json" \  -d '{    "current_password": "string",    "new_password": "string"  }'
{  "message": "string"}
GET/api/v1/auth/providers
GET
/api/v1/auth/providers

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Response Body

application/json

curl -X GET "https://example.com/api/v1/auth/providers"
{  "providers": [    {      "algorithm": "string",      "audience": "string",      "claim_mapping": {        "email_claim": "string",        "email_verified_claim": "string",        "image_claim": "string",        "name_claim": "string",        "org_id_claim": "string",        "role_claim": "string",        "user_id_claim": "string"      },      "created_at": "2019-08-24T14:15:22Z",      "enabled": true,      "has_webhook_secret": true,      "issuer": "string",      "jwks_url": "string",      "name": "string",      "provider_id": "string",      "updated_at": "2019-08-24T14:15:22Z",      "webhook_signature_header": "string"    }  ]}
POST/api/v1/auth/providers
POST
/api/v1/auth/providers

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Request payload for registering a new external auth provider.

Response Body

application/json

curl -X POST "https://example.com/api/v1/auth/providers" \  -H "Content-Type: application/json" \  -d '{    "algorithm": "string",    "issuer": "string",    "name": "string",    "provider_id": "string"  }'
{  "algorithm": "string",  "audience": "string",  "claim_mapping": {    "email_claim": "string",    "email_verified_claim": "string",    "image_claim": "string",    "name_claim": "string",    "org_id_claim": "string",    "role_claim": "string",    "user_id_claim": "string"  },  "created_at": "2019-08-24T14:15:22Z",  "enabled": true,  "has_webhook_secret": true,  "issuer": "string",  "jwks_url": "string",  "name": "string",  "provider_id": "string",  "updated_at": "2019-08-24T14:15:22Z",  "webhook_signature_header": "string"}
GET/api/v1/auth/providers/{provider_id}
GET
/api/v1/auth/providers/{provider_id}

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Path Parameters

provider_id*string

External provider ID

Response Body

application/json

curl -X GET "https://example.com/api/v1/auth/providers/string"
{  "algorithm": "string",  "audience": "string",  "claim_mapping": {    "email_claim": "string",    "email_verified_claim": "string",    "image_claim": "string",    "name_claim": "string",    "org_id_claim": "string",    "role_claim": "string",    "user_id_claim": "string"  },  "created_at": "2019-08-24T14:15:22Z",  "enabled": true,  "has_webhook_secret": true,  "issuer": "string",  "jwks_url": "string",  "name": "string",  "provider_id": "string",  "updated_at": "2019-08-24T14:15:22Z",  "webhook_signature_header": "string"}
PATCH/api/v1/auth/providers/{provider_id}
PATCH
/api/v1/auth/providers/{provider_id}

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Path Parameters

provider_id*string

External provider ID

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Request payload for updating an existing external auth provider.

Response Body

application/json

curl -X PATCH "https://example.com/api/v1/auth/providers/string" \  -H "Content-Type: application/json" \  -d '{}'
{  "algorithm": "string",  "audience": "string",  "claim_mapping": {    "email_claim": "string",    "email_verified_claim": "string",    "image_claim": "string",    "name_claim": "string",    "org_id_claim": "string",    "role_claim": "string",    "user_id_claim": "string"  },  "created_at": "2019-08-24T14:15:22Z",  "enabled": true,  "has_webhook_secret": true,  "issuer": "string",  "jwks_url": "string",  "name": "string",  "provider_id": "string",  "updated_at": "2019-08-24T14:15:22Z",  "webhook_signature_header": "string"}
DELETE/api/v1/auth/providers/{provider_id}
DELETE
/api/v1/auth/providers/{provider_id}

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Path Parameters

provider_id*string

External provider ID

Response Body

curl -X DELETE "https://example.com/api/v1/auth/providers/string"
Empty
GET/api/v1/auth/session
GET
/api/v1/auth/session

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Response Body

application/json

curl -X GET "https://example.com/api/v1/auth/session"
{  "active": true,  "created_at": "2019-08-24T14:15:22Z",  "expires_at": "2019-08-24T14:15:22Z",  "id": "string",  "ip_address": "string",  "updated_at": "2019-08-24T14:15:22Z",  "user_agent": "string",  "user_id": "string"}
GET/api/v1/auth/sessions
GET
/api/v1/auth/sessions

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Query Parameters

page?integer

1-indexed page number

Formatint64
Range0 <= value
page_size?integer

Page size (max 100)

Formatint64
Range0 <= value

Response Body

application/json

curl -X GET "https://example.com/api/v1/auth/sessions"
{  "pagination": {    "has_more": true,    "page": 0,    "page_size": 0,    "total": 0  },  "sessions": [    {      "active": true,      "created_at": "2019-08-24T14:15:22Z",      "expires_at": "2019-08-24T14:15:22Z",      "id": "string",      "ip_address": "string",      "updated_at": "2019-08-24T14:15:22Z",      "user_agent": "string",      "user_id": "string"    }  ]}
DELETE/api/v1/auth/sessions/{session_id}
DELETE
/api/v1/auth/sessions/{session_id}

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Path Parameters

session_id*string

ID of the session to revoke

Response Body

curl -X DELETE "https://example.com/api/v1/auth/sessions/string"
Empty
POST/api/v1/auth/signout
POST
/api/v1/auth/signout

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Response Body

curl -X POST "https://example.com/api/v1/auth/signout"
Empty
POST/api/v1/auth/users/batch
POST
/api/v1/auth/users/batch

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Admin bulk-onboarding payload: create many users at once. Each user is created without a verification email or session (admin-only); the server enforces a per-batch cap.

Response Body

application/json

curl -X POST "https://example.com/api/v1/auth/users/batch" \  -H "Content-Type: application/json" \  -d '{    "users": [      {        "email": "string",        "password": "string"      }    ]  }'
{  "count": 0,  "user_ids": [    "string"  ]}
GET/api/v1/users/{id}
GET
/api/v1/users/{id}

Authorization

bearer_token
AuthorizationBearer <token>

In: header

Path Parameters

id*string

User ID

Query Parameters

include?string

Response Body

application/json

curl -X GET "https://example.com/api/v1/users/string"
{  "created_at": "2019-08-24T14:15:22Z",  "display_name": "string",  "email": "string",  "email_verified": true,  "id": "string",  "image_url": "string",  "role": "user",  "two_factor_enabled": true,  "updated_at": "2019-08-24T14:15:22Z",  "username": "string",  "_includes": {},  "_relations": {    "property1": {      "has_more": true,      "returned": 0,      "total": 0    },    "property2": {      "has_more": true,      "returned": 0,      "total": 0    }  }}
POST/auth/2fa/backup/verify
POST
/auth/2fa/backup/verify

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Request payload for using a backup code during the login flow.

Response Body

application/json

curl -X POST "https://example.com/auth/2fa/backup/verify" \  -H "Content-Type: application/json" \  -d '{    "backup_code": "string",    "two_factor_token": "string"  }'
{  "access_token": "string",  "expires_in": 0,  "refresh_token": "string",  "requires_2fa": true,  "token_type": "string",  "two_factor_token": "string",  "user": null}
POST/auth/2fa/verify
POST
/auth/2fa/verify

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Request payload for verifying TOTP during the login flow (uses two_factor_token from Redis).

Response Body

application/json

curl -X POST "https://example.com/auth/2fa/verify" \  -H "Content-Type: application/json" \  -d '{    "code": "string",    "two_factor_token": "string"  }'
{  "access_token": "string",  "expires_in": 0,  "refresh_token": "string",  "requires_2fa": true,  "token_type": "string",  "two_factor_token": "string",  "user": null}
GET/auth/accept-invite
GET
/auth/accept-invite

The link this API emails points here. Accepting needs the invitee's own session, so this page carries the invitation id and asks for one rather than acting on its own.

Response Body

curl -X GET "https://example.com/auth/accept-invite"
Empty
POST/auth/cli/session
POST
/auth/cli/session

Response Body

application/json

curl -X POST "https://example.com/auth/cli/session"
{  "expires_in": 0,  "login_url": "string",  "poll_secret": "string",  "session_id": "string"}
GET/auth/cli/session/{id}/poll
GET
/auth/cli/session/{id}/poll

Path Parameters

id*string

CLI session ID

Query Parameters

secret*string

Poll secret issued when the session was created

Response Body

application/json

curl -X GET "https://example.com/auth/cli/session/string/poll?secret=string"
{  "status": "string",  "tokens": null}
POST/auth/email/verify
POST
/auth/email/verify

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Request payload for verifying an email or magic-link token.

Response Body

application/json

curl -X POST "https://example.com/auth/email/verify" \  -H "Content-Type: application/json" \  -d '{    "token": "string"  }'
{  "message": "string"}
GET/auth/magic-link
GET
/auth/magic-link

The link this API emails points here, so without it a default deployment mails a dead URL: nothing else redeems the token from a browser, and magic-link sign-in is on by default.

Response Body

curl -X GET "https://example.com/auth/magic-link"
Empty
POST/auth/magic-link/verify
POST
/auth/magic-link/verify

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Request payload for verifying an email or magic-link token.

Response Body

application/json

curl -X POST "https://example.com/auth/magic-link/verify" \  -H "Content-Type: application/json" \  -d '{    "token": "string"  }'
{  "access_token": "string",  "expires_in": 0,  "refresh_token": "string",  "requires_2fa": true,  "token_type": "string",  "two_factor_token": "string",  "user": null}
GET/auth/oauth/callback/{provider}
GET
/auth/oauth/callback/{provider}

Path Parameters

provider*string

OAuth provider ID

Query Parameters

code*string

The authorization code returned by the OAuth provider.

state*string

The state token used to prevent CSRF attacks.

Response Body

curl -X GET "https://example.com/auth/oauth/callback/string?code=string&state=string"
Empty
GET/auth/oauth/providers
GET
/auth/oauth/providers

Platform providers only. This route is unauthenticated, so including organization-owned providers would turn it into a customer directory.

Response Body

curl -X GET "https://example.com/auth/oauth/providers"
Empty
POST/auth/passkey/authenticate/options
POST
/auth/passkey/authenticate/options

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Request payload for initiating passkey authentication (get challenge options).

Response Body

application/json

curl -X POST "https://example.com/auth/passkey/authenticate/options" \  -H "Content-Type: application/json" \  -d '{}'
{  "challenge_id": "string",  "options": null}
POST/auth/passkey/authenticate/verify
POST
/auth/passkey/authenticate/verify

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Request payload for completing passkey authentication (verify challenge response).

Response Body

application/json

curl -X POST "https://example.com/auth/passkey/authenticate/verify" \  -H "Content-Type: application/json" \  -d '{    "challenge_id": "string",    "response": null  }'
{  "access_token": "string",  "expires_in": 0,  "refresh_token": "string",  "requires_2fa": true,  "token_type": "string",  "two_factor_token": "string",  "user": null}
POST/auth/password/forgot
POST
/auth/password/forgot

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Request payload for the forgot-password flow (sends a reset email).

Response Body

application/json

curl -X POST "https://example.com/auth/password/forgot" \  -H "Content-Type: application/json" \  -d '{    "email": "string"  }'
{  "message": "string"}
POST/auth/password/reset
POST
/auth/password/reset

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Request payload for resetting a password using a token from the reset email.

Response Body

application/json

curl -X POST "https://example.com/auth/password/reset" \  -H "Content-Type: application/json" \  -d '{    "new_password": "string",    "token": "string"  }'
{  "message": "string"}
POST/auth/signin/email
POST
/auth/signin/email

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Request payload for signing in with email and password.

Response Body

application/json

curl -X POST "https://example.com/auth/signin/email" \  -H "Content-Type: application/json" \  -d '{    "email": "string",    "password": "string"  }'
{  "access_token": "string",  "expires_in": 0,  "refresh_token": "string",  "requires_2fa": true,  "token_type": "string",  "two_factor_token": "string",  "user": null}
POST/auth/signin/magic-link
POST
/auth/signin/magic-link

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Request payload for requesting a magic-link sign-in email.

Response Body

application/json

curl -X POST "https://example.com/auth/signin/magic-link" \  -H "Content-Type: application/json" \  -d '{    "email": "string"  }'
{  "message": "string"}
POST/auth/signin/oauth
POST
/auth/signin/oauth

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Request payload for initiating an OAuth sign-in flow.

Response Body

application/json

curl -X POST "https://example.com/auth/signin/oauth" \  -H "Content-Type: application/json" \  -d '{    "provider": "string",    "redirect_uri": "string"  }'
{  "redirect_url": "string",  "state": "string"}
POST/auth/signup
POST
/auth/signup

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Request payload for signing up a new user with email and password.

Response Body

application/json

curl -X POST "https://example.com/auth/signup" \  -H "Content-Type: application/json" \  -d '{    "email": "string",    "password": "string"  }'
{  "access_token": "string",  "expires_in": 0,  "refresh_token": "string",  "requires_2fa": true,  "token_type": "string",  "two_factor_token": "string",  "user": null}
GET/auth/sso/complete
curl -X GET "https://example.com/auth/sso/complete"
Empty
POST/auth/sso/discover
POST
/auth/sso/discover

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Request payload for asking which identity provider serves an email address.

Response Body

application/json

curl -X POST "https://example.com/auth/sso/discover" \  -H "Content-Type: application/json" \  -d '{    "email": "string"  }'
{  "provider_id": "string",  "provider_name": "string",  "sso_required": true}
POST/auth/sso/exchange
POST
/auth/sso/exchange

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Request payload for redeeming a single-use SSO handoff code.

Response Body

application/json

curl -X POST "https://example.com/auth/sso/exchange" \  -H "Content-Type: application/json" \  -d '{    "code": "string"  }'
{  "access_token": "string",  "expires_in": 0,  "refresh_token": "string",  "requires_2fa": true,  "token_type": "string",  "two_factor_token": "string",  "user": null}
GET/auth/sso/idp-initiated/{provider}
GET
/auth/sso/idp-initiated/{provider}

Path Parameters

provider*string

Identity provider ID

Response Body

curl -X GET "https://example.com/auth/sso/idp-initiated/string"
Empty
POST/auth/token/refresh
POST
/auth/token/refresh

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Request payload for refreshing an access token.

Response Body

application/json

curl -X POST "https://example.com/auth/token/refresh" \  -H "Content-Type: application/json" \  -d '{    "refresh_token": "string"  }'
{  "access_token": "string",  "expires_in": 0,  "refresh_token": "string",  "requires_2fa": true,  "token_type": "string",  "two_factor_token": "string",  "user": null}
GET/auth/verify-email
GET
/auth/verify-email

Query Parameters

token*string

Email verification token from the link

Response Body

curl -X GET "https://example.com/auth/verify-email?token=string"
Empty
POST/auth/webhooks/{provider}
POST
/auth/webhooks/{provider}

Path Parameters

provider*string

External provider ID

Request Body

text/plain

Raw webhook body from provider

TypeScript Definitions

Use the request body type in TypeScript.

body*string

Response Body

application/json

curl -X POST "https://example.com/auth/webhooks/string" \  -H "Content-Type: text/plain" \  -d 'string'
{  "message": "string"}

On this page

Admin_set_org_sso_policyAdmin_list_sessionsAdmin_revoke_sessionAdmin_list_usersAdmin_get_userAdmin_update_userAdmin_delete_userAdmin_ban_userAdmin_impersonateAdmin_unban_userRegenerate_backup_codesGet_2fa_statusDisable_totpSetup_totpVerify_totp_setupLink_oauth_accountUnlink_oauth_accountList_linked_accountsList_api_keysCreate_api_keyGet_api_keyUpdate_api_keyRevoke_api_keyCli_complete_sessionSend_verification_emailList_invitationsGet_meCreate_organizationAccept_invitationCheck_slugClear_active_orgDecline_invitationGet_organizationUpdate_organizationDelete_organizationList_org_invitationsInvite_memberList_membersRemove_memberChange_member_roleList_org_providersCreate_org_providerGet_org_providerUpdate_org_providerDelete_org_providerList_org_provider_domainsAdd_org_provider_domainRemove_org_provider_domainVerify_org_provider_domainOrg_provisioning_driftSet_active_orgList_organizationsPasskey_register_optionsPasskey_register_verifyList_passkeysUpdate_passkeyDelete_passkeyChange_passwordList_external_providersCreate_external_providerGet_external_providerUpdate_external_providerDelete_external_providerGet_sessionList_sessionsRevoke_sessionSignoutAdmin bulk-onboarding: create many users with no verification emails or sessionsGet_user_profileVerify_backup_code_loginVerify_2fa_loginBrowser landing for an organization invitation.Cli_create_sessionCli_poll_sessionVerify_emailBrowser landing for a magic link.Verify_magic_linkOauth_callbackReturns the list of enabled platform provider IDs (public, no auth required).Passkey_authenticate_optionsPasskey_authenticate_verifyForgot_passwordReset_passwordSignin_emailRequest_magic_linkInitiate_oauthSignupLanding page for a federated login that did not name an application destination.Discover_ssoExchange_sso_codeIdp_initiated_loginRefresh_tokenBrowser-friendly email verification — user clicks link in email, server verifies and shows a simple HTML success/failure page.Receive_webhook