Skip to content
Back to skills

Rate Limiting

ASecurity

Protect APIs from abuse and overload with distributed rate limiters, standard headers, keying, and safe degradation

  • 5 stars
  • 0 votes
  • 0 copies
  • 0 views
  • Added November 30, 2026
developmentgoapi

Works with

  • api

Security analysis

A100/100

Scanned November 30, 2026

npx -y skills add AdityaaaTiwari/ANVIL --skill rate-limiting --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Rate Limiting?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Rate Limiting
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/adityaaatiwari-rate-limiting-anvil/badge)](https://www.skillsdirectory.com/skills/adityaaatiwari-rate-limiting-anvil)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: rate-limiting
description: Protect APIs from abuse and overload with distributed rate limiters, standard headers, keying, and safe degradation
---

<!-- Generated by `anvil plugin build` from catalog/. Edit the catalog, not this file. -->

# Rate limiting

Use when adding request throttling to public endpoints, auth flows, webhooks, or expensive AI/compute APIs.

## Strategy and keying
- Apply multi-layer keys: tighter limits on anonymous IP/subnet plus authenticated user/tenant quotas on write and expensive routes.
- Choose token bucket or sliding window algorithms (via atomic Redis Lua/pipeline scripts) to avoid boundary bursts at fixed window edges.
- Exempt health checks cleanly while keeping login, OTP, password reset, and token endpoints strictly throttled.

## Responses and resilience
- Return `HTTP 429` with `Retry-After` and standard `RateLimit-Limit`, `RateLimit-Remaining`, and `RateLimit-Reset` headers.
- Decide fail-open vs fail-closed explicitly per endpoint: fail open for read APIs on Redis outage, fail closed for brute-force/payment endpoints.
- Put rate limiting ahead of DB lookups and model calls so rejected requests stay cheap.

## Verify
Test concurrent burst requests hitting `429`, `Retry-After` header accuracy, key isolation across tenants, and limiter store timeout behavior.

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

View all in development →

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.