Skip to content

REST API endpoints for Organization Invitations

GET /orgs/{orgId}/invitations
<p>List all pending invitations for an organization.</p>
Authentication

Authentication is required.

Requires MEMBER_CREATE permission in the organization.

Learn more about authentication

Path Parameters
orgIdstringRequired
<p>The slug or ID of the organization.</p>
Response Body Content-Type: application/json

This API endpoint returns standard API response format. The following fields are fields of the data object. Learn more

arrayRequired
<p>The array of pending invitations.</p>
idstringRequired
<p>The unique identifier of the user.</p>
namestringRequired
<p>The display name of the user.</p>
usernamestringRequired
<p>The username of the user.</p>
member_rolestringRequired
<p>The role of the user in the organization.</p>
permissionsarrayRequired
<p>The permissions that the user will have in the organization.</p>
acceptedbooleanRequired
<p>Always false for invitations in this endpoint.</p>
POST /orgs/{orgId}/invitations
<p>Invite a user to join an organization.</p>
Authentication

Authentication is required.

Authenticated user must be the owner ora member with MEMBER_CREATE permission in the organization.

Learn more about authentication

Path Parameters
orgIdstringRequired
<p>The slug or ID of the organization.</p>
Request Body Content-Type: application/json
inviteestringRequired
<p>The username or user ID of the user to invite.</p>
rolestring
<p>The role of the user in the organization. Defaults to empty string.</p>
permissionsarray
<p>The permissions that the user will have in the organization. Defaults to empty array.</p>
PATCH /orgs/{orgId}/invitations/{userId}
<p>Accept a pending invitation. Only the invited user can accept their own invitation.</p>
Authentication

Authentication is required.

Must be the invited user.

Learn more about authentication

Path Parameters
orgIdstringRequired
<p>The slug or ID of the organization.</p>
userIdstringRequired
<p>The username or ID of the invited user. Must match the authenticated user.</p>
DELETE /orgs/{orgId}/invitations/{userId}
<p>Cancel a pending invitation (by authorized member) or reject an invitation (by invitee).</p>
Authentication

Authentication is required.

Must be the invited user or a member with MEMBER_CREATE permission.

Learn more about authentication

Path Parameters
orgIdstringRequired
<p>The slug or ID of the organization.</p>
userIdstringRequired
<p>The username or ID of the invited user.</p>