Skip to main content
Recommended for all new integrations.

What is the Users API?

Version 3 of Clara’s Users API lets you manage user accounts securely, with support for:
  • Role and location handling
  • Advance filtering through query parameters
  • User lifecycle operations support (onboarding, status tracking, updating, and deletion)
All operations are secured via Mutual TLS and OAuth 2 authentication protocols.

Authentication

To use the API:
  1. Obtain your client certificate and credentials via the Clara platform.
  2. Request an access token via POST /oauth/token with your client_id and client_secret.
  3. Use the access token in the Authorization header for all subsequent API requests.

Core Use Cases

List Users

Retrieve a list of users with optional filters like status, role, or name.
  • **GET /api/v3/users **- with filters for status, role, name.
  • Successful Response HTTP Status:
    200 OK : List of users successfully returned
  • Query Parameters:
  • Example Request:
  • Example Response:

Create User

  • POST /api/v3/users - add a new user to your organization.
  • Successful Response HTTP Status:
    201 Created: User successfully created
  • Request Body Parameters:
  • Example Request:
  • Example Response:

Retrieve a User by UUID

  • GET /api/v3/users/{uuid} - fetch details of a single user using their UUID
  • Successful Response HTTP Status:
    200 OK: User successfully retrieved
  • Path Parameter:
  • Example Request:
  • Example Response:

Update User

  • PATCH /api/v3/users/{uuid} - modify the details of an existing user.
  • Successful Response HTTP Status:
    200 OK: User successfully updated
  • Path Parameter:
  • Request Body Parameters:
  • Example Request:

Group Management Fields

The following fields enhance how a user’s group memberships are updated:
  • groupsToAdd: Adds the user to one or more groups. Must not duplicate existing memberships.
  • groupsToRemove: Removes the user from specified groups. Must already be a member of those groups.
  • cleanGroups: If true, removes all existing groups before adding new ones from groupsToAdd.
⚠️ When cleanGroups is true, groupsToAdd must include at least one group. The user must always remain in at least one group.
  • Example Response:

Delete User

  • DELETE /api/v3/users/{uuid} - delete a user using their UUID.
  • Successful Response HTTP Status:
    204 No Content: User successfully deleted
  • Path Parameter:
  • Example Request:
  • Example Response:

User Lifecycle Status

  • ONBOARDING_CANDIDATE: User has been created but not fully onboarded.
  • WAITING: User is awaiting some verification or action.
  • DELETED: User account has been marked for deletion.
  • ACTIVE: User is active and can use the system.
  • LOCKED: User account is locked.
  • INACTIVE: User is not currently active but may be reactivated.
  • PENDING: User creation is pending.
  • MASTER_LOCKED: User is locked at the highest permission level.
  • CLARA_BLOCKED: User is blocked by the system administrator.

Lifecycle Flow

  1. Creation: A user is created via the POST /api/v3/users endpoint. Initially, they may be in a status such as ONBOARDING_CANDIDATE or PENDING.
  2. Activation: After onboarding steps are completed, the user transitions to ACTIVE.
  3. Usage: The user actively participates in the platform’s operations.
  4. Locking/Blocking: If needed, the user may be LOCKED, MASTER_LOCKED, or CLARA_BLOCKED due to policy violations or security issues.
  5. Deactivation: Users can be set to INACTIVE if no longer participating but still retained in the system.
  6. Deletion: Finally, the user can be marked as DELETED via the DELETE /api/v3/users/{uuid} endpoint.

Endpoint Reference

GET /api/v3/users

List all users (v3)Parameters:Response Schema (UserPageV3):

POST /api/v3/users

Create user (v3)Request Body (CreateUserRequestV3):

GET /api/v3/users/{uuid}

Get user by UUID (v3)Parameters:Response Schema (UserV3):

PATCH /api/v3/users/{uuid}

Update user (v3)Parameters:Request Body (UpdateUserRequestV3):

DELETE /api/v3/users/{uuid}

Delete user (v3)Parameters: