Skip to content

Principals

Principals: 30 operations, tagged principals in the OpenAPI document.

Method Path Summary
GET /api/principals List principals
POST /api/principals Create a principal
POST /api/principals/bulk-import Bulk-import CLIENT users for a client (CSV onboarding)
GET /api/principals/check-email-domain Resolve auth-method for an email’s domain
GET /api/principals/developer-users List USER principals holding the developer role
POST /api/principals/match-emails Match a pasted list of email addresses against the users the caller can see
POST /api/principals/sync Sync users (declarative upsert by email; no application scope)
POST /api/principals/users Create a user principal (scope optional, default CLIENT; ANCHOR/PARTNER must be backed by the email domain’s setup)
GET /api/principals/{id} Get a principal by id
PUT /api/principals/{id} Update a principal
DELETE /api/principals/{id} Delete a principal
POST /api/principals/{id}/activate Activate a principal
GET /api/principals/{id}/application-access List application IDs the principal can access
PUT /api/principals/{id}/application-access Assign application access to a principal
GET /api/principals/{id}/available-applications List applications a principal can be granted access to
GET /api/principals/{id}/client-access List client-access grants for a principal
POST /api/principals/{id}/client-access Grant a client-access for a principal
DELETE /api/principals/{id}/client-access/{clientId} Revoke a client-access grant
PUT /api/principals/{id}/client-association Change a principal’s scope/client association (anchor-gated)
POST /api/principals/{id}/deactivate Deactivate a principal
POST /api/principals/{id}/developer-credential Create or rotate a principal’s self-service developer API credential
DELETE /api/principals/{id}/developer-credential Revoke a principal’s self-service developer API credential
POST /api/principals/{id}/reset-2fa Clear a user’s two-factor methods (forces re-enrollment)
POST /api/principals/{id}/reset-password Reset a user’s password
GET /api/principals/{id}/roles List a principal’s assigned roles
POST /api/principals/{id}/roles Add a single role to a principal
PUT /api/principals/{id}/roles Assign roles to a principal (replaces full set)
DELETE /api/principals/{id}/roles/{role} Remove a single role from a principal
POST /api/principals/{id}/send-password-reset Send a password-reset email to a user
GET /api/principals/{id}/version Get when a principal (or a role it holds) last changed — used by SDKs to detect a revoked/changed session

List principals

Operation ID: listPrincipals

Parameters

Name In Type Required Description
type query string no Filter by principal type (USER or SERVICE)
clientId query string no Filter to principals homed at, or granted access to, this client
active query string no Filter by active status (true/false); absent = both
q query string no Case-insensitive substring search across name and email
roles query string no CSV of role names; matches principals holding any of them
page query integer (int64) no 0-based page index (default 0)
pageSize query integer (int64) no Page size; <=0 returns all matches (default: all)
sortField query string no Sort key: name | email | createdAt (default createdAt)
sortOrder query string no Sort direction: asc | desc (default asc)

Responses

Status Description Body
200 OK application/json PrincipalListResponse
default Error application/json ErrorModel

Create a principal

Operation ID: createPrincipal

Request body (required)

Content type Schema
application/json CreatePrincipalRequest

Responses

Status Description Body
201 Created application/json CreatePrincipalResponse
default Error application/json ErrorModel

Bulk-import CLIENT users for a client (CSV onboarding)

Operation ID: bulkImportUsers

Request body (required)

Content type Schema
application/json BulkImportRequest

Responses

Status Description Body
200 OK application/json BulkImportResponse
default Error application/json ErrorModel

Resolve auth-method for an email’s domain

Operation ID: checkPrincipalEmailDomain

Parameters

Name In Type Required Description
email query string no

Responses

Status Description Body
200 OK application/json CheckEmailDomainResponse
default Error application/json ErrorModel

List USER principals holding the developer role

Operation ID: listDeveloperUsers

Responses

Status Description Body
200 OK application/json DeveloperUserListResponse
default Error application/json ErrorModel

Match a pasted list of email addresses against the users the caller can see

Operation ID: matchPrincipalEmails

Request body (required)

Content type Schema
application/json MatchEmailsRequest

Responses

Status Description Body
200 OK application/json MatchEmailsResponse
default Error application/json ErrorModel

Sync users (declarative upsert by email; no application scope)

Operation ID: syncUsers

Request body (required)

Content type Schema
application/json SyncUsersRequest

Responses

Status Description Body
200 OK application/json SyncUsersResponse
default Error application/json ErrorModel

Create a user principal (scope optional, default CLIENT; ANCHOR/PARTNER must be backed by the email domain’s setup)

Operation ID: createUser

Request body (required)

Content type Schema
application/json CreateUserRequest

Responses

Status Description Body
200 OK application/json PrincipalResponse
default Error application/json ErrorModel

Get a principal by id

Operation ID: getPrincipal

Parameters

Name In Type Required Description
id path string yes

Responses

Status Description Body
200 OK application/json PrincipalResponse
default Error application/json ErrorModel

Update a principal

Operation ID: updatePrincipal

Parameters

Name In Type Required Description
id path string yes

Request body (required)

Content type Schema
application/json UpdatePrincipalRequest

Responses

Status Description Body
200 OK application/json PrincipalResponse
default Error application/json ErrorModel

Delete a principal

Operation ID: deletePrincipal

Parameters

Name In Type Required Description
id path string yes

Responses

Status Description Body
204 No Content none
default Error application/json ErrorModel

Activate a principal

Operation ID: activatePrincipal

Parameters

Name In Type Required Description
id path string yes

Responses

Status Description Body
200 OK application/json StatusChangeResponse
default Error application/json ErrorModel

GET /api/principals/{id}/application-access

Section titled “GET /api/principals/{id}/application-access”

List application IDs the principal can access

Operation ID: listPrincipalApplicationAccess

Parameters

Name In Type Required Description
id path string yes

Responses

Status Description Body
200 OK application/json ApplicationAccessListResponse
default Error application/json ErrorModel

PUT /api/principals/{id}/application-access

Section titled “PUT /api/principals/{id}/application-access”

Assign application access to a principal

Operation ID: assignPrincipalApplicationAccess

Parameters

Name In Type Required Description
id path string yes

Request body (required)

Content type Schema
application/json AssignApplicationAccessRequest

Responses

Status Description Body
200 OK application/json SetApplicationAccessResponse
default Error application/json ErrorModel

GET /api/principals/{id}/available-applications

Section titled “GET /api/principals/{id}/available-applications”

List applications a principal can be granted access to

Operation ID: listPrincipalAvailableApplications

Parameters

Name In Type Required Description
id path string yes

Responses

Status Description Body
200 OK application/json PrincipalAvailableApplicationsResponse
default Error application/json ErrorModel

List client-access grants for a principal

Operation ID: listPrincipalClientAccess

Parameters

Name In Type Required Description
id path string yes

Responses

Status Description Body
200 OK application/json ClientAccessGrantListResponse
default Error application/json ErrorModel

Grant a client-access for a principal

Operation ID: grantPrincipalClientAccess

Parameters

Name In Type Required Description
id path string yes

Request body (required)

Content type Schema
application/json GrantClientAccessRequest

Responses

Status Description Body
200 OK application/json ClientAccessGrantResponse
default Error application/json ErrorModel

DELETE /api/principals/{id}/client-access/{clientId}

Section titled “DELETE /api/principals/{id}/client-access/{clientId}”

Revoke a client-access grant

Operation ID: revokePrincipalClientAccess

Parameters

Name In Type Required Description
id path string yes
clientId path string yes

Responses

Status Description Body
204 No Content none
default Error application/json ErrorModel

PUT /api/principals/{id}/client-association

Section titled “PUT /api/principals/{id}/client-association”

Change a principal’s scope/client association (anchor-gated)

Operation ID: setPrincipalClientAssociation

Parameters

Name In Type Required Description
id path string yes

Request body (required)

Content type Schema
application/json ClientAssociationRequest

Responses

Status Description Body
200 OK application/json PrincipalResponse
default Error application/json ErrorModel

Deactivate a principal

Operation ID: deactivatePrincipal

Parameters

Name In Type Required Description
id path string yes

Responses

Status Description Body
200 OK application/json StatusChangeResponse
default Error application/json ErrorModel

POST /api/principals/{id}/developer-credential

Section titled “POST /api/principals/{id}/developer-credential”

Create or rotate a principal’s self-service developer API credential

Operation ID: setPrincipalDeveloperCredential

Parameters

Name In Type Required Description
id path string yes

Responses

Status Description Body
200 OK application/json SetDeveloperCredentialResponse
default Error application/json ErrorModel

DELETE /api/principals/{id}/developer-credential

Section titled “DELETE /api/principals/{id}/developer-credential”

Revoke a principal’s self-service developer API credential

Operation ID: revokePrincipalDeveloperCredential

Parameters

Name In Type Required Description
id path string yes

Responses

Status Description Body
204 No Content none
default Error application/json ErrorModel

Clear a user’s two-factor methods (forces re-enrollment)

Operation ID: resetPrincipalTwoFactor

Parameters

Name In Type Required Description
id path string yes

Responses

Status Description Body
200 OK application/json StatusChangeResponse
default Error application/json ErrorModel

Reset a user’s password

Operation ID: resetPrincipalPassword

Parameters

Name In Type Required Description
id path string yes

Request body (required)

Content type Schema
application/json ResetPasswordRequest

Responses

Status Description Body
200 OK application/json StatusChangeResponse
default Error application/json ErrorModel

List a principal’s assigned roles

Operation ID: listPrincipalRoles

Parameters

Name In Type Required Description
id path string yes

Responses

Status Description Body
200 OK application/json PrincipalRoleListResponse
default Error application/json ErrorModel

Add a single role to a principal

Operation ID: addPrincipalRole

Parameters

Name In Type Required Description
id path string yes

Request body (required)

Content type Schema
application/json AddRoleRequest

Responses

Status Description Body
200 OK application/json PrincipalResponse
default Error application/json ErrorModel

Assign roles to a principal (replaces full set)

Operation ID: assignPrincipalRoles

Parameters

Name In Type Required Description
id path string yes

Request body (required)

Content type Schema
application/json AssignPrincipalRolesRequest

Responses

Status Description Body
200 OK application/json RolesAssignedResponse
default Error application/json ErrorModel

Remove a single role from a principal

Operation ID: removePrincipalRole

Parameters

Name In Type Required Description
id path string yes
role path string yes

Responses

Status Description Body
200 OK application/json PrincipalResponse
default Error application/json ErrorModel

POST /api/principals/{id}/send-password-reset

Section titled “POST /api/principals/{id}/send-password-reset”

Send a password-reset email to a user

Operation ID: sendPrincipalPasswordReset

Parameters

Name In Type Required Description
id path string yes

Request body

Content type Schema
application/json SendPasswordResetInputBody

Responses

Status Description Body
200 OK application/json StatusChangeResponse
default Error application/json ErrorModel

Get when a principal (or a role it holds) last changed — used by SDKs to detect a revoked/changed session

Operation ID: getPrincipalVersion

Parameters

Name In Type Required Description
id path string yes

Responses

Status Description Body
200 OK application/json PrincipalVersionResponse
default Error application/json ErrorModel
Field Type Required Description
role string yes
Field Type Required Description
allApplications boolean yes
applications ApplicationAccessResponse[] yes
total integer (int64) yes
Field Type Required Description
applicationCode string yes
applicationId string yes
applicationName string yes
Field Type Required Description
allApplications boolean no
applicationIds string[] yes
confirmSelfRestriction boolean no
Field Type Required Description
roles string[] yes
Field Type Required Description
clientId string yes Client all imported users are created under
users BulkImportUser[] yes
Field Type Required Description
created integer (int64) yes
failed integer (int64) yes
results BulkImportResult[] yes
skipped integer (int64) yes
Field Type Required Description
email string yes
message string no
row integer (int64) yes
status string yes created | exists | dropped | error
Field Type Required Description
email string yes
name string yes
roles string[] no Role names to assign (pipe-separated in the CSV)
Field Type Required Description
allowedClientIds string[] yes
authMethod string yes
authProvider string yes
derivedScope string yes
domain string yes
emailExists boolean yes
hasIdpConfig boolean yes
idpIssuer string no
info string | null yes
isAnchorDomain boolean yes
loginUrl string no
requiresClientId boolean yes
warning string | null yes
Field Type Required Description
grants ClientAccessGrantResponse[] yes
Field Type Required Description
clientId string yes
expiresAt string (date-time) no
grantedAt string (date-time) yes
id string yes
Field Type Required Description
clientId string yes Target client id, or “*” for anchor (all-client) access
mode string no CHANGE_CLIENT | TO_PARTNER — required for a specific clientId, ignored for “*”
Field Type Required Description
clientId string no
email string yes
idpType string no
inviteRedirectUri string no
name string no
password string no
returnInviteLink boolean no
scope string yes Principal scope (ANCHOR, PARTNER, CLIENT)
sendInvitation boolean no
Field Type Required Description
id string yes
inviteLink string no
Field Type Required Description
clientId string no
email string yes
enforcePasswordComplexity boolean no
inviteRedirectUri string no
name string yes
password string no
returnInviteLink boolean no
scope string no One of: ANCHOR, PARTNER, CLIENT.
sendInvitation boolean no
Field Type Required Description
principals PrincipalResponse[] yes
total integer (int64) yes
Field Type Required Description
clientId string yes
Field Type Required Description
emails string[] no Addresses (each entry is parsed like text)
text string no Pasted address list: commas, semicolons, whitespace or ‘Name <addr>’ entries
Field Type Required Description
invalid string[] yes
matches PrincipalResponse[] yes
unmatched string[] yes
Field Type Required Description
code string yes
id string yes
name string yes
Field Type Required Description
applications PrincipalAvailableApplication[] yes
Field Type Required Description
principals PrincipalResponse[] yes
total integer (int64) yes
Field Type Required Description
active boolean yes
clientId string no
createdAt string (date-time) yes
developerCredentialUpdatedAt string (date-time) no
email string no
grantedClientIds string[] yes
hasDeveloperCredential boolean yes
id string yes
idpType string no
inviteLink string no
isAnchorUser boolean yes
name string yes
roles string[] yes
scope string yes
serviceAccountId string no
twoFactorMethods string[] no
type string yes
updatedAt string (date-time) yes
Field Type Required Description
assignedAt string (date-time) yes
assignmentSource string yes
id string yes
roleName string yes
Field Type Required Description
roles PrincipalRoleAssignmentDTO[] yes
Field Type Required Description
updatedAt string (date-time) yes
Field Type Required Description
enforcePasswordComplexity boolean no
newPassword string yes
Field Type Required Description
added string[] yes
removed string[] yes
roles PrincipalRoleAssignmentDTO[] yes
Field Type Required Description
reset2fa boolean no
Field Type Required Description
added integer (int64) yes
allApplications boolean yes
applications ApplicationAccessResponse[] yes
removed integer (int64) yes
Field Type Required Description
clientSecret string no
id string yes
Field Type Required Description
message string yes
Field Type Required Description
active boolean no Whether the user is active (default true)
email string yes User’s email address (unique identifier for matching)
name string yes Display name
passwordHash string no Pre-hashed password (bcrypt/argon2i/argon2id), stored verbatim on a user the sync creates; migrated on first login. Never applied to an existing user (reported in passwordHashIgnored).
roles string[] no Role names to assign (SDK_SYNC source; replaces this source’s prior set)
Field Type Required Description
principals SyncUserInput[] yes
Field Type Required Description
created integer (int32) yes Minimum 0.
deleted integer (int32) yes Minimum 0.
passwordHashIgnored string[] no Emails whose passwordHash was ignored because the user already exists (omitted when none)
syncedEmails string[] yes
updated integer (int32) yes Minimum 0.
Field Type Required Description
active boolean no
email string no Optional; asserted against the stored email — a different value is rejected, not treated as a rename
name string no