Rate limits

Requests per minute, the 429 answer, the Retry-After header and call guards.

Limit per key

Each API key can send 120 requests per 60-second window. Beyond that, the API answers 429 with the code rate_limited and a Retry-After header holding the number of seconds to wait.

async function call(url, init, attempts = 5) {
  for (let i = 0; i < attempts; i++) {
    const res = await fetch(url, init);
    if (res.status !== 429) return res;
    const wait = Number(res.headers.get("Retry-After") ?? 1);
    await new Promise((r) => setTimeout(r, wait * 1000));
  }
  throw new Error("rate_limited");
}

Call guards

Placing calls has its own guards, shared with the dashboard: concurrent calls, calls per hour and pending scheduled calls. They also answer 429, with the codes concurrent_limit, hourly_limit and pending_limit. Other refusals are not rate limits: outside_hours (422), do_not_call and country_not_allowed (403).

Good practice

  • Honor Retry-After instead of retrying immediately.
  • Add jitter to your backoff when several workers share a key.
  • Spread bulk work over time, or use separate keys for separate systems so that one cannot starve the other.
  • Webhook deliveries do not count against the limit.