Invitation flow
Send invitations
An
owner or admin calls POST /orgs/:orgId/invitations with a list of email addresses and the desired role IDs for each invitee.Platform sends email
The platform sends an invitation email to each address. The email contains a link directing the user to their CREDEBL account.
Invitee views pending invitations
The invitee logs in and calls
GET /users/invitations to see all pending invitations across all organizations.Accept or reject
The invitee calls
PUT /users/invitations/:invitationId with status: "accepted" or status: "rejected" to act on the invitation.Send invitations
POST /orgs/:orgId/invitations
Sends bulk invitations to one or more users. Each entry in the invitations array specifies an email address and one or more role IDs to assign upon acceptance.
Required roles: owner, super_admin, admin
Path parameters
UUID of the organization.
Request body
Array of invitation objects. Each object targets one email address.
Role IDs (
orgRoleId) are UUIDs, not role name strings. Use GET /orgs/:orgId/roles to look up the UUID for each role name.List invitations
GET /orgs/:orgId/invitations
Returns all invitations (pending, accepted, or rejected) for an organization. Supports pagination and search.
Required roles: owner, super_admin, admin, issuer, verifier, member
Path parameters
UUID of the organization.
Query parameters
Page number to retrieve. Must be 1 or greater.
Number of results per page. Between 1 and 100.
Filter invitations by email address.
Response
Paginated invitation list.
Delete invitation
DELETE /orgs/:orgId/invitations/:invitationId
Cancels a pending invitation. Once deleted, the invitation link in the invitee’s email is no longer valid.
Required roles: owner, admin
Path parameters
UUID of the organization.
UUID of the invitation to cancel. Must be a valid UUID v4.
Update user roles
PUT /orgs/:orgId/user-roles/:userId
Replaces the existing role assignments for a member of the organization. All previously held roles are replaced by the new orgRoleId list.
Required roles: owner, admin
Path parameters
UUID of the organization.
UUID of the user whose roles should be updated. Must be a valid UUID v4.
Request body
Non-empty array of role UUIDs to assign to the user. Replaces all existing role assignments for this user in the organization. Retrieve role IDs from
GET /orgs/:orgId/roles.User-side invitation endpoints
The following endpoints are called by the invited user from their own account to view and respond to invitations.List pending invitations
GET /users/invitations
Returns all pending invitations for the authenticated user across all organizations.
Authentication: JWT bearer token of the invited user.
Query parameters
Page number to retrieve.
Number of results per page. Between 1 and 100.
Filter by organization name.
Accept or reject an invitation
PUT /users/invitations/:invitationId
Accepts or rejects a specific pending invitation. Once accepted, the user becomes a member of the organization with the assigned roles.
Authentication: JWT bearer token of the invited user.
Path parameters
UUID of the invitation to act on.
Request body
Set to
"accepted" to join the organization or "rejected" to decline. Accepted values: accepted, rejected.