api-rate-limit-handler

api-rate-limit-handler is a skill for Claude Code from iradoweck/antigravity-awesome-skills. It costs 32 tokens per session (2,309 once invoked), scanned A, a copy of api-rate-limit-handler, MIT.

An API request-handling guide for limiting calls, waiting between retries, and safely repeating requests after temporary failures. It covers 429 rate-limit responses and temporary 5xx server errors.

In plain words
What is it for?
Use it when connecting to services such as OpenAI, Stripe, or GitHub, especially when handling Retry-After headers or requests sent to several API providers.
Why use it?
It helps applications respect external service quotas and recover from temporary problems without sending too many repeated requests or causing wider failures.

Skill for Claude Code

Written for Claude Code: shipped in a Claude Code plugin. Also seen: mentions Codex.

Part of the agentic-awesome-skills plugin — 196 skills shipped together

Good fit Use it when connecting to services such as OpenAI, Stripe, or GitHub, especially when handling Retry-After headers or requests sent to several API providers.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/iradoweck/antigravity-awesome-skills/api-rate-limit-handler
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add iradoweck/antigravity-awesome-skills --skill api-rate-limit-handler
Clone the repo
git clone --depth 1 https://github.com/iradoweck/antigravity-awesome-skills

Made for: Claude Code.

Or install agentic-awesome-skills, the plugin that ships this one along with the rest of its 196 skills.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for api-rate-limit-handler

README.md
[![agentmods](https://agentmods.dev/badge/skills/iradoweck/antigravity-awesome-skills/api-rate-limit-handler/github.svg)](https://agentmods.dev/skills/iradoweck/antigravity-awesome-skills/api-rate-limit-handler)
Your own site
<a href="https://agentmods.dev/skills/iradoweck/antigravity-awesome-skills/api-rate-limit-handler"><img src="https://agentmods.dev/badge/skills/iradoweck/antigravity-awesome-skills/api-rate-limit-handler/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for api-rate-limit-handler

Your own site · 80×15
<a href="https://agentmods.dev/skills/iradoweck/antigravity-awesome-skills/api-rate-limit-handler"><img src="https://agentmods.dev/badge/skills/iradoweck/antigravity-awesome-skills/api-rate-limit-handler.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 32 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 2,309 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 1 finding. A grade says what 26 rules found in the file — not that it is safe.
Origin 100% copy Near-identical to another mod in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00032 $0.02309
Opus 5 $0.00016 $0.01154
Sonnet 5 $0.00006 $0.00462
Haiku 4.5 $0.00003 $0.00231

Measured 5d ago against content hash 05f166646882, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-09, from the pricing page.

Security

Grade A, and why

api-rate-limit-handler scanned grade A with 1 finding against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 5d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Makes network callslowCapability

Not a fault in itself. Listed so you know the mod talks to something, and to what.

const response = await fetch(url, options);
Origin

This is a copy

100% identical to api-rate-limit-handler — 0 lines differ, which has more behind it and is treated as the original. This page carries a canonical link to it rather than competing with it.

plugins/agentic-awesome-skills-claude/skills/api-rate-limit-handler/SKILL.md · 283 lines

How it starts

The opening of the file, as written. The whole thing — 283 lines — stays where its author put it; the contents beside it link to each section on GitHub.

API Rate Limit Handler

Overview

A skill for implementing production-grade rate limiting, exponential backoff, and retry strategies when integrating with external APIs. Prevents cascading failures, respects upstream quotas, and keeps your application resilient under load.

When to Use This Skill

  • Use when calling external APIs that enforce rate limits (OpenAI, Stripe, GitHub, etc.)
  • Use when you receive 429 Too Many Requests or 5xx errors and need graceful recovery
  • Use when building a client that must respect Retry-After headers
  • Use when designing a system that fans out to multiple API providers
  • Use when the user says "handle rate limits", "add retry logic", "backoff strategy", or "don't get throttled"

How It Works

Step 1: Classify the response

Determine whether a failed request is retryable or terminal.

Status Classification Action
200-299 Success Return response
400, 401, 403, 404 Terminal client error Do not retry — fix the request
408, 429 Retryable (rate limit / timeout) Retry with backoff
500, 502, 503, 504 Retryable (server error) Retry with backoff

Step 2: Parse rate limit headers

Always check upstream hints before computing your own delay.

function getRetryDelay(
  response: Response,
  attempt: number,
  maxDelayMs = 60_000
): number {
  // Prefer upstream hints
  const retryAfter = response.headers.get("Retry-After");
  if (retryAfter) {
    const seconds = Number(retryAfter);
    if (Number.isFinite(seconds) && seconds >= 0) {
      return Math.min(seconds * 1000, maxDelayMs);
    }
    // HTTP-date format
    const date = new Date(retryAfter).getTime();
    if (Number.isFinite(date)) {
      return Math.min(Math.max(0, date - Date.now()), maxDelayMs);
    }
  }

  // GitHub documents x-ratelimit-reset as Unix epoch seconds.
  const githubReset = Number(response.headers.get("x-ratelimit-reset"));
  if (Number.isFinite(githubReset)) {
    return Math.min(
      Math.max(0, githubReset * 1000 - Date.now()),
      maxDelayMs
    );
  }

  // Fallback: capped exponential backoff with full jitter.
  const cap = Math.min(1000 * 2 ** attempt, maxDelayMs);
  return Math.floor(Math.random() * cap);
}

Read the full file on GitHub · 283 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 5d ago First seen · 283 lines · 32 tokens per session scan A 05f166646882

Subscribe to this mod's changes

api-rate-limit-handler is a skill published in the GitHub repository iradoweck/antigravity-awesome-skills (30 stars, last pushed 9d ago), licensed MIT. It adds 32 tokens to every session and 2,309 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 1 finding (makes network calls). It is 100% identical to api-rate-limit-handler, differing in 0 lines, and is treated as a copy.

Related

Other skills, from other repositories

api-rate-limit-handler

Implement bounded, idempotency-aware API throttling, backoff, and retry handling for 429 and transient 5xx responses.

sickn33/agentic-awesome-skills · 32 tokens

distributed-systems

Distributed systems patterns for locking, resilience, idempotency, and rate limiting. Use when implementing distributed locks, circuit breakers, retry policies, idempotency keys, token bucket rate limiters, or fault tolerance patterns.

yonatangross/orchestkit · 48 tokens

API Rate Limiting Testing

Testing API rate limiting implementations including throttling behavior, burst handling, rate limit headers, and distributed rate limiting patterns.

PramodDutta/qaskills · 29 tokens

a0-development

Development guide for extending Agent Zero from current source and DOX. Use for framework architecture, tools, extensions, API/WebUI handlers, agent profiles, prompts, skills, projects, runtime boundaries, and contribution workflow. Load the focused reference files before giving implementation guidance.

agent0ai/agent-zero · 57 tokens

api-connector-builder

Use when writing a client for someone else's REST or GraphQL API: auth flow choice and token refresh, pagination to exhaustion, retry-with-jitter on transient failures only, rate-limit-aware throttling. NOT inbound callbacks (that is webhooks), NOT chaining services (that is automation-flows), NOT designing your own…

ericrisco/rsc-harness · 80 tokens

error-handling

Use when designing the reaction to a class of failures — typed error taxonomies, retry/backoff/timeout policy, circuit breakers, React/Next error boundaries, and the user-message vs operator-log split. NOT diagnosing one specific crash (that is debug), NOT logs/metrics/traces (that is observability), NOT the wire…

ericrisco/rsc-harness · 78 tokens