Building a partner app that acts on behalf of individual Yotel
users (Salesforce, HubSpot, etc.)? You want OAuth 2.0,
not an API key. API keys are for your own tenant’s automation.
Headers
Every request to/api/v1/* must send:
| Header | Required | Purpose |
|---|---|---|
Content-Type: application/json | on writes | request body type |
Idempotency-Key: <uuid> | recommended on writes | dedup on retry (see Idempotency) |
Environments
| Prefix | Behavior |
|---|---|
yt_live_… | Real dialing, real PSTN charges, real webhooks to your production URL. |
yt_test_… | Sandbox: DB writes happen, webhooks fire, but no PSTN originate. Use during development + CI. |
Rate limits
Every key has arate_limit_per_min — default 600, configurable up
to 100,000 for enterprise plans. The algorithm is a fixed per-minute
window:
Retry-After is seconds until the next minute boundary. Well-behaved
clients sleep for that duration and retry.
Burst behavior
At the minute boundary, 2× the limit can pass in a single second (last second of minute A + first second of minute B). This is a known property of fixed-window counters; if you need exact 600/min smoothing, throttle on your side with a client-side token bucket.Redis outage fallback
If our rate-limit backend is unreachable, we fail open — your request isn’t rate-limited. This is deliberate: a DoS control shouldn’t block paying customers during our own outages. We still log the failure and rate-limit at the LB in emergencies.Scopes
Reserved for v1.1 — thescopes field on a key is accepted but not
enforced per-route yet. Safe to leave empty during v1. When scope
enforcement lands, existing keys with empty scopes will be grandfathered
into “all scopes granted.”
Rotating keys
Keys don’t expire. To rotate:Deploy it to your backend
Roll the env var, restart services, verify traffic on the new key
via dashboard → Usage → filter by key prefix.
Auth errors
401 Malformed key
Authorization value doesn’t parse as yt_<env>_…. Common cause:
copy-paste lost the Bearer prefix.
401 Invalid key
403 Scope denied (v1.1)
429 Rate limited