Skip to main content
529Retryable

Anthropic 529 Overloaded

Anthropic's API is under heavy load and is shedding traffic. Your request was valid; capacity wasn't there. This is the most Anthropic-specific status code.

Most likely causes

  1. 1.Provider-wide demand spike (common at US working-hours peaks)
  2. 2.Burst of parallel requests from your side landing in a congested window
  3. 3.Large-context requests during constrained capacity

Fix checklist

  • Retry with exponential backoff and jitter — most 529s clear in seconds
  • Reduce parallelism temporarily (halve concurrent agents on first 529)
  • Use the Batch API for non-interactive work; it queues instead of failing
  • Consider a fallback model/provider path for hard availability requirements

Retry guidance

Exponential backoff with full jitter: base 1s, ×2 per attempt, cap 32s, up to 6 attempts. Do not hammer — synchronized retries extend the overload.

// Retry 529 with exponential backoff + full jitter.
async function callWithBackoff(payload: unknown, maxAttempts = 5) {
  for (let attempt = 0; attempt < maxAttempts; attempt++) {
    const res = await fetch("https://api.anthropic.com/v1/messages", {
      method: "POST",
      headers: {
        "content-type": "application/json",
        "x-api-key": process.env.ANTHROPIC_API_KEY!,
      "anthropic-version": "2023-06-01",
      },
      body: JSON.stringify(payload),
    });
    if (res.status !== 529) return res;
    // Honor Retry-After when present; otherwise exponential backoff, capped at 32s.
    const retryAfter = Number(res.headers.get("retry-after"));
    const base = Number.isFinite(retryAfter) && retryAfter > 0
      ? retryAfter * 1000
      : Math.min(1000 * 2 ** attempt, 32_000);
    await new Promise((r) => setTimeout(r, base * (0.5 + Math.random() * 0.5)));
  }
  throw new Error("Anthropic 529: still failing after backoff — check https://status.anthropic.com");
}

Provider status page: status.anthropic.com