rate_limit_exceeded

HTTP 429

Too many requests

Type URL

https://developer.hostup.se/errors/rate_limit_exceeded

Example response

{
  "type": "https://developer.hostup.se/errors/rate_limit_exceeded",
  "title": "Too many requests",
  "status": 429,
  "detail": "Too many requests.",
  "code": "rate_limit_exceeded",
  "instance": "/api/v2/...",
  "requestId": "req_abc123",
  "timestamp": "2026-04-27T12:00:00.000Z"
}

Rate limit headers

HTTP 429 responses include headers for retry behavior. Use Retry-After as seconds to wait before retrying.

Retry-After Seconds to wait before retrying the request.
X-RateLimit-Limit Maximum requests allowed in the active window.
X-RateLimit-Remaining Requests remaining in the active window, usually 0 on 429.
X-RateLimit-Reset ISO timestamp when the active window resets.

Handling this error

const response = await fetch(url, options);

if (!response.ok) {
  const problem = await response.json();
  const retryAfterSeconds = response.headers.get("Retry-After");
  const rateLimitReset = response.headers.get("X-RateLimit-Reset");

  if (problem.code === "rate_limit_exceeded") {
    // Handle: Too many requests
    console.error(problem.detail);

    if (retryAfterSeconds) {
      // Back off for this many seconds before retrying.
      console.log(`Retry after ${retryAfterSeconds}s`);
    } else if (rateLimitReset) {
      console.log(`Rate limit resets at ${rateLimitReset}`);
    }
  }
}