https://api.omnirelay.ai/v1/manage/.
Management keys
The Management API accepts a management key (or-mgmt-…), never an API key. The two are separate on purpose: a key that calls models can never provision keys, and a management key can never call a model.
After verified activation, create one on the API Keys page under Management keys. Creation is disabled before activation. It is shown once and only its hash is stored. Each key has a scope:
A read key that attempts a write gets
403 insufficient_scope. A management key acts as you: it changes your API keys; usage visibility follows your account permissions, and every change it makes appears in the audit log as you@example.com via management key <name>. Revoking it, suspending your account or deleting your account stops it on the next call. You can hold up to 10 active management keys.
Endpoints
Every request sendsAuthorization: Bearer $OMNIRELAY_MANAGEMENT_KEY. Bodies are JSON. Limited to 120 requests per minute per management key.
Anything else under
/v1/manage/ returns 404. There is no way to reach billing, account or admin routes with a management key.
Create a key for a customer
The owner’s workspace must currently have verified service readiness. OtherwisePOST /v1/manage/keys returns 403 activation_required and creates no key. Check Overview → Live model service and complete activation before retrying. Existing key rotation and revocation remain separate operations.
budget is in micro-USD (50,000,000 is $50). defaultTags follow the Tags and allowedModels the model limits. Store the returned key right away; it is not shown again.
Read usage
The response holds
totals, previous (the period before, for comparison), series, and groups by model, provider, key and status. Amounts are micro-USD and times are UTC.
GET /v1/manage/requests takes the same filters plus limit (up to 1,000) and before (the next cursor from the previous page).
Calling order and fields
Create a management key in the console first. read and write scopes control management operations and do not activate models. Query List models with an inference key to confirm access. Creation returns 201; other successful operations return 200. Response examples use placeholder IDs and credentials. Creation and rotation return the full key once.
PATCH preserves omitted fields. Changing budget does not refill remaining; explicitly set remaining to refill. Periodic budgets must be positive. Clear a budget with budget=null, remaining=null and resetPeriod=none together. Set expiry using the key update endpoint, not the budget endpoint.
Each owner can have 20 active API keys. Rotation preserves ID, expiry, restrictions, tags and spending counters; the old credential stops working immediately. Limited to 10 rotations per owner per hour. Creation and rotation are not idempotent: check current state before retrying an ambiguous result.
List keys and budgets
{ "keys": [...] }, including revoked entries, without full credentials. Response fields use expires_at, default_tags and allowed_models; write parameters use expiresAt, defaultTags and allowedModels.
Budget response example:
Update a key and its budget
Set KEY_ID to the ID from creation or listing, not the full credential.{ "ok": true }. After 409 key_changed, fetch current state before deciding to update again.
Rotate and revoke a key
{ "id": "example-key-id", "key": "or-live-…" }; store it securely and update your service. Revocation returns { "ok": true } and preserves historical usage.
Request records and pagination
Errors
Validation errors from key changes (
invalid_input, invalid_tags, invalid_model_rules, invalid_key_policy, invalid_key_expiry) are the same as in the console.