Rate limits
Servor API rate limits — 3 requests per second and 5000 per hour per token, plus how to handle a 429 with the retry-after header.
The Servor API enforces a rate limit per token so one integration can't starve the
others. This page explains the exact limits, what a 429 response looks like, and
how to handle it cleanly with the retry-after header.
The limits
Limits are applied per API token, not per team or per IP. Each token gets its own budget:
| Window | Limit |
|---|---|
| Per second | 3 requests |
| Per hour | 5000 requests |
If you run several integrations, give each its own token — separate tokens get separate budgets, and you can revoke one without touching the rest. Manage your tokens in Servor.
When you hit the limit
Exceeding either window returns HTTP 429 Too Many Requests with a retry-after
header telling you how many seconds to wait before retrying:
HTTP/1.1 429 Too Many Requests
retry-after: 2
{ "error": "Rate limit exceeded", "code": "rate_limited" }Always read retry-after
Don't guess the wait — read the retry-after value and sleep for exactly that
many seconds before retrying. It's the reliable way to get back under the limit.
Handling 429 in your code
The pattern is simple: on a 429, wait for retry-after seconds, then retry.
Cap the number of retries so a persistent limit doesn't loop forever.
async function apiGet(path: string, token: string, tries = 5): Promise<Response> {
const res = await fetch(`https://api.servor.app/v1${path}`, {
headers: { Authorization: `Bearer ${token}` },
});
if (res.status === 429 && tries > 0) {
const wait = Number(res.headers.get("retry-after") ?? "1");
await new Promise((r) => setTimeout(r, wait * 1000));
return apiGet(path, token, tries - 1);
}
return res;
}# curl: retry automatically, honoring retry-after
curl --retry 5 --retry-delay 0 \
https://api.servor.app/v1/monitors \
-H "Authorization: Bearer sv_live_xxxxxxxxxxxx"Staying under the limit
- Throttle your requests. Keep steady-state traffic under 3 requests/second per token rather than bursting.
- Poll on a sensible interval. For status mirrors and dashboards, poll every 30–60 seconds, not every second — you'll stay far under 5000/hour.
- Cache what rarely changes. Server and status-page metadata don't need to be re-fetched on every loop.
- Spread load across tokens. Independent workloads deserve independent tokens and independent budgets.
- Back off on 429. Treat it as normal flow control, not an error to log and ignore.
Limits vs. plan limits
These are per-request rate limits. They're separate from the resource limits (servers, monitors, status pages) on your plan — see plans and limits. Access to the public API itself requires the AI plan.