REST API
-
:material-api:{ .lg .middle } Admin API
Role-based endpoints for system management and plugin operations
-
:material-account-box:{ .lg .middle } User & Role Management
CRUD for users, roles, and assignments
-
:material-cloud-upload:{ .lg .middle } Plugin & Config API
Register plugins, query audits, and manage configuration via API
!!! tip 'Use role-scoped tokens' Create service tokens with minimal scopes for automation and integrations.
!!! note 'Rate limits' Admin API enforces per-client rate-limits managed via the gateway configuration.
!!! warning 'Audit queries may be large' Use pagination and filters when querying audit logs to avoid long-running requests.
Common endpoints
| Endpoint | Purpose | Method | Auth |
|---|---|---|---|
| /api/users | Manage users | GET/POST/PUT/DELETE | admin |
| /api/plugins | Register/list plugins | GET/POST | admin |
| /api/config | Read/update config | GET/PUT | admin |
| /api/audit | Query audit logs | GET | admin/audit |
Example: Create a user
- Use scoped tokens and role assertions; avoid admin tokens in automation when possible
mermaid graph LR AdminUI -->|API Calls| API API --> AuthService API --> Storage API --> Plugins API --> Audit
Audit API: filtering
| Filter | Description | Example |
|---|---|---|
| actor | Who performed action | actor=system or user id |
| action | Action type | create,user.update |
| since | ISO datetime | 2024-01-01T00:00:00Z |
!!! note 'Pagination' The Admin API uses cursor-based pagination for large datasets. Check response for ++next_cursor++ field.
??? note 'Advanced: webhook integrations' The Admin API supports webhook delivery for events. Use signed payloads and retry policies.
-
API access is audited and role-checked. Ensure service accounts are limited in scope and rotated regularly. ↩