Authentication
BASE https://api.rii.link/v1AUTH: BEARER → AUTHENTICATION
One header on every request. Keys are workspace-scoped and shown once at creation — create one yourself in Settings → API keys.
Bearer authentication
Send the key in the Authorization header. Live keys start with rii_live_, test keys with rii_test_ — test-key writes never touch production links. A missing, malformed, or revoked key is always a 401 with the standard envelope.
REQUEST
curl https://api.rii.link/v1/links \
-H "Authorization: Bearer $RII_KEY"
RESPONSE · 401 (REVOKED KEY)
{
"error": {
"code": "invalid_key",
"message": "The API key is missing, malformed, or revoked.",
"doc_url": "https://rii.link/docs/api/errors#invalid_key"
}
}
Rotation without downtime
A workspace holds up to two active keys at once. Create the replacement in Settings → API keys, deploy it, then revoke the old one — revocation is immediate, in-flight requests finish.
THE FULL RUNBOOK LIVES UNDER SELF-SERVE OPS → API KEYS & ROTATION