Ledger Enterprise
API Documentation V2
API Documentation V2
  • Introduction
    • Getting Started
    • Overview
  • Guides
    • Authentication
    • Balance Reporting Bot
      • 1. Project setup
      • 2. Connect to revault-api
      • 3. Fetch accounts balances
      • 4. Conclusion
  • reference
    • API reference
      • Users
      • Accounts
        • Transactions
      • Groups
      • Whitelists
      • Policies
      • Entities
      • Requests
        • Generate registration challenge
        • Confirm registration challenge
        • Challenge
        • Approve
        • Reject
      • Auth
        • Token
          • Refresh
      • Permissions
        • Allowed actions
        • Resources
      • Assets
        • Currencies
        • Tokens
      • Tradelink
        • Network
          • Blueprint
    • Specification
Powered by GitBook
On this page
  1. reference
  2. API reference

Users

PreviousAPI referenceNextAccounts

Last updated 23 days ago

List users

get

List users in the same workspace. Administrators & operators with legacyViewAll set to true can see the full list, other users can only see themselves.

Authorizations
Query parameters
pageany ofOptional

Which page to fetch

Default: 1
notOptional
or
integer · min: 1Optional
pageSizeany ofOptional

Page size to use

Default: 30
notOptional
or
integer · min: 1 · max: 30Optional
rolestring · enumOptional

User role

Possible values:
statusstring · enumOptional

User status

Possible values:
sortBystring · enumOptional

Sort by attribute

Default: createdAtPossible values:
sortOrderstring · enumOptional

Sort order

Default: ascPossible values:
Responses
200
Successful response
application/json
default
Error response
application/json
get
GET /rest/users HTTP/1.1
Host: 
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*
{
  "page": 1,
  "next": 1,
  "prev": 1,
  "pageSize": 1,
  "total": 1,
  "results": [
    {
      "id": "text",
      "legacyId": 1,
      "legacyViewAll": true,
      "workspaceName": "text",
      "name": "text",
      "deviceUserId": "text",
      "role": "ADMIN",
      "status": "ACTIVE",
      "createdAt": "2025-05-31T02:42:05.909Z",
      "updatedAt": "2025-05-31T02:42:05.909Z"
    }
  ]
}

Get a single user

get

Find a user by its ID. Use me to fetch current user. Operators can only see themselves (unless they have legacyViewAll set to true), fetching other users will yield Not Found error.

Authorizations
Path parameters
idstringRequired

Id of the target user

Responses
200
Successful response
application/json
default
Error response
application/json
get
GET /rest/users/{id} HTTP/1.1
Host: 
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*
{
  "id": "text",
  "legacyId": 1,
  "legacyViewAll": true,
  "workspaceName": "text",
  "name": "text",
  "deviceUserId": "text",
  "role": "ADMIN",
  "status": "ACTIVE",
  "createdAt": "2025-05-31T02:42:05.909Z",
  "updatedAt": "2025-05-31T02:42:05.909Z"
}
  • POSTAuthenticate
  • POSTRefresh token
  • GETList users
  • GETGet a single user

Authenticate

post

Exchange API Key credentials for JWT tokens

Authorizations
Body
workspacestringRequired

Target workspace

apiKeyIdstringRequired

API Key id

apiKeySecretstringRequired

API Key secret

Responses
200
Successful response
application/json
400
Invalid input data
application/json
401
Authorization not provided
application/json
403
Insufficient access
application/json
500
Internal server error
application/json
post
POST /rest/auth/token HTTP/1.1
Host: 
Authorization: Bearer YOUR_SECRET_TOKEN
Content-Type: application/json
Accept: */*
Content-Length: 60

{
  "workspace": "text",
  "apiKeyId": "text",
  "apiKeySecret": "text"
}
{
  "accessToken": "text",
  "expiresInSeconds": 1,
  "refreshToken": "text",
  "refreshExpiresInSeconds": 1
}

Refresh token

post

Exchange refreshToken for JWT tokens

Authorizations
Body
workspacestringRequired

Target workspace

refreshTokenstringRequired

Refresh token

Responses
200
Successful response
application/json
400
Invalid input data
application/json
401
Authorization not provided
application/json
403
Insufficient access
application/json
500
Internal server error
application/json
post
POST /rest/auth/token/refresh HTTP/1.1
Host: 
Authorization: Bearer YOUR_SECRET_TOKEN
Content-Type: application/json
Accept: */*
Content-Length: 42

{
  "workspace": "text",
  "refreshToken": "text"
}
{
  "accessToken": "text",
  "expiresInSeconds": 1,
  "refreshToken": "text",
  "refreshExpiresInSeconds": 1
}