- Returns permissions per user and resource. Temporary permissions include an
expiresAt(Unix seconds) value. - See the Access Control overview for concepts and detailed guidance.
Endpoint
POST https://api.velt.dev/v2/auth/permissions/get
Headers
Your API key.
Your Auth Token.
Body
Example Request
- JSON
- cURL
Response
Error responses include an
errorCode field with structured error codes from the UserPermissionAccessRoleResult enum. This helps you handle permission resolution failures programmatically.Response Schema
The response returns a nested structure with permissions per user and resource type. Each resource permission can include:| Field | Type | Description |
|---|---|---|
accessRole | string | The user’s access role ("editor" or "viewer") |
expiresAt | number | Unix timestamp (seconds) when temporary access expires |
error | string | Human-readable error message if permission resolution failed |
errorCode | string | Error code from UserPermissionAccessRoleResult enum (v4.5.4+) |
Success Response
Permission Denied
Error Response Examples
When a resource does not exist, is denied, or encounters an error, the response includes both anerror message and an errorCode:
Resource Not Found:

