Skip to content
Rapid Router
← API reference

Provisioning API

Part of the Rapid Router API reference. One OpenAI-compatible endpoint, https://rapidrouter.ai/api/v1, in front of every model in the catalog.

27Provisioning API

Manage runtime API keys programmatically: issue a key per customer, rotate keys on a schedule, disable a key the moment a customer churns. It is driven by a management key (sk-rr-mgmt-...), created in the dashboard under Keys, which authenticates /provisioning/* and nothing else: a management key is rejected by every inference endpoint, and a runtime key is rejected by the provisioning endpoints. You can hold up to 5 active management keys.

curl https://rapidrouter.ai/api/v1/provisioning/keys \
  -H "Authorization: Bearer sk-rr-mgmt-..." \
  -H "Content-Type: application/json" \
  -d '{
    "name": "customer-42",
    "limit_usd": 10,
    "limit_reset": "monthly",
    "allowed_models": ["google/*"]
  }'

# -> { "id": "key_...", "secret": "sk-rr-v1-...", "limit_usd": 10, ... }
# The secret is returned exactly once and never stored.

GET /provisioning/keys lists the account's runtime keys (hashes are never returned), GET /provisioning/keys/:id returns one with its live limit state (limit_spent_usd, limit_remaining_usd, limit_resets_at), and PATCH accepts the same fields as the dashboard editor: name, limit_usd, limit_reset, monthly_cap_usd, allowed_models, plus disabled. Keys created here are ordinary runtime keys: they show up in the dashboard, spend the same credit balance and obey the same limits.