rate-limit-abuse-prevention

rate-limit-abuse-prevention is a skill for Claude Code, Codex from roedyrustam/vibes-plug. It costs 63 tokens per session (3,112 once invoked), scanned B, original, MIT.

A guide to protecting APIs and web applications from excessive use, automated bots, denial-of-service attacks, and repeated login guesses.

In plain words
What is it for?
Use it to add request limits, bot checks, DDoS protection, login-attempt protection, API-key quotas, and subscription-based limits.
Why use it?
It helps prevent attackers or heavy users from overwhelming services, abusing accounts, or consuming more API access than allowed.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Use it to add request limits, bot checks, DDoS protection, login-attempt protection, API-key quotas, and subscription-based limits.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/roedyrustam/vibes-plug/rate-limit-abuse-prevention
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 roedyrustam/vibes-plug --skill rate-limit-abuse-prevention
Clone the repo
git clone --depth 1 https://github.com/roedyrustam/vibes-plug

Made for: Claude Code, Codex.

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 rate-limit-abuse-prevention

README.md
[![agentmods](https://agentmods.dev/badge/skills/roedyrustam/vibes-plug/rate-limit-abuse-prevention/github.svg)](https://agentmods.dev/skills/roedyrustam/vibes-plug/rate-limit-abuse-prevention)
Your own site
<a href="https://agentmods.dev/skills/roedyrustam/vibes-plug/rate-limit-abuse-prevention"><img src="https://agentmods.dev/badge/skills/roedyrustam/vibes-plug/rate-limit-abuse-prevention/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 rate-limit-abuse-prevention

Your own site · 80×15
<a href="https://agentmods.dev/skills/roedyrustam/vibes-plug/rate-limit-abuse-prevention"><img src="https://agentmods.dev/badge/skills/roedyrustam/vibes-plug/rate-limit-abuse-prevention.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 63 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 3,112 The whole file, excluding the scripts and references it only reads on demand.
Security scan B 1 finding. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector warn 7 Sept 2026
SkillSpector: 1 finding, up to medium

These are SkillSpector’s own severities. On a checked sample its high-severity flags on skills were ~96% false positives — a documented command, a public API, a “never do X” rule — so we show them as a caution to read, not a verdict. Why →

  • medium Data Exfiltration · line 209
    Data is being sent to an external URL. This could be legitimate telemetry or data exfiltration. Manual review is recommended.
    Fix: Verify the destination URL is trusted and necessary. Remove or replace with documented APIs. Ensure no secrets, tokens, or PII are transmitted.
How audits are shown
Origin original No closer match found 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.00063 $0.03112
Opus 5 $0.00032 $0.01556
Sonnet 5 $0.00013 $0.00622
Haiku 4.5 $0.00006 $0.00311

Measured 7d ago against content hash 0d04004419ac, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-11, from the pricing page.

Security

Grade B, and why

rate-limit-abuse-prevention scanned grade B 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 7d 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.

Sends data to an external URLmediumData exfiltration

A POST to an outside endpoint may be telemetry or may be exfiltration; either way the mod talks to somewhere, and you should know where.

const response = await fetch('https://challenges.cloudflare.com/turnstile/v0/siteverify', { method: 'POST',
skills/rate-limit-abuse-prevention/SKILL.md · 378 lines

How it starts

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

Rate Limit & Abuse Prevention (2026 Edition)

English | Bahasa Indonesia


English

Orchestration & Integration

Connects and orchestrates with relevant domain skills like brainstorming, zero-to-prod-orchestrator, and project-context-mapper to ensure cohesive execution.

Description

Production-grade guide for protecting APIs and web applications from abuse, overuse, and attacks. Covers rate limiting algorithms (Token Bucket, Sliding Window), Upstash Ratelimit, bot protection (Cloudflare Turnstile, hCaptcha), DDoS mitigation at edge, brute-force login prevention, API key management & usage quotas, and response headers (X-RateLimit, Retry-After).

Trigger Conditions

Activate this skill when:

  • Implementing API rate limiting for public or authenticated endpoints.
  • Adding bot protection (CAPTCHA) to forms (login, signup, contact).
  • Setting up DDoS protection at the edge (Cloudflare, Vercel).
  • Preventing brute-force attacks on authentication endpoints.
  • Implementing API key issuance and usage quotas for SaaS.
  • Building tiered rate limits based on subscription plans.

Rate Limiting Algorithm Comparison

Algorithm Behavior Best For Burst Handling
Fixed Window Resets counter at interval boundary Simple endpoints Allows double burst at window edge
Sliding Window Rolling window, smooth distribution API endpoints Smooth, no edge burst
Token Bucket Tokens refill at fixed rate High-throughput APIs Allows controlled bursts
Leaky Bucket Processes at fixed rate, queues excess Stream processing No bursts, constant rate

Recommendation: Use Sliding Window for most API endpoints. Use Token Bucket for endpoints that should allow burst traffic.


1. Upstash Ratelimit (Edge-Compatible)

// lib/ratelimit.ts
import { Ratelimit } from '@upstash/ratelimit';
import { Redis } from '@upstash/redis';

const redis = Redis.fromEnv();

// Different rate limiters for different tiers
export const rateLimiters = {
  /** Public API: 10 requests per 10 seconds */
  public: new Ratelimit({
    redis,
    limiter: Ratelimit.slidingWindow(10, '10s'),
    prefix: 'rl:public',
    analytics: true,
  }),

  /** Authenticated API: 100 requests per minute */
  authenticated: new Ratelimit({
    redis,
    limiter: Ratelimit.slidingWindow(100, '1m'),
    prefix: 'rl:auth',
    analytics: true,
  }),

  /** Pro tier: 1000 requests per minute */
  pro: new Ratelimit({
    redis,
    limiter: Ratelimit.slidingWindow(1000, '1m'),
    prefix: 'rl:pro',
    analytics: true,
  }),

  /** Login endpoint: 5 attempts per 15 minutes */
  login: new Ratelimit({
    redis,
    limiter: Ratelimit.slidingWindow(5, '15m'),
    prefix: 'rl:login',
  }),

  /** Password reset: 3 per hour */
  passwordReset: new Ratelimit({
    redis,
    limiter: Ratelimit.slidingWindow(3, '1h'),
    prefix: 'rl:pwreset',
  }),
};

Read the full file on GitHub · 378 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. 7d ago First seen · 378 lines · 63 tokens per session scan B 0d04004419ac

Subscribe to this mod's changes

rate-limit-abuse-prevention is a skill published in the GitHub repository roedyrustam/vibes-plug (50 stars, last pushed today), licensed MIT. It adds 63 tokens to every session and 3,112 once invoked, about $0.0003 per session on Opus 5. A static security scan graded it B with 1 finding (sends data to an external url). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.

Related

Other skills, from other repositories

api-and-interface-design

Guides stable API and interface design. Use when designing APIs, module boundaries, or any public interface. Use when creating REST or GraphQL endpoints, defining type contracts between modules, or establishing boundaries between frontend and backend.

addyosmani/agent-skills · 49 tokens

evolutionary-modular-architecture

Guides design and implementation of evolutionary modular-monolith platforms with DDD (strategic + tactical), flat-by-aggregate organization, an Anti-Corruption Layer for vendor independence, a transactional outbox for events, smart resilience (backoff with jitter, circuit breakers, idempotency), and a polished…

tech-leads-club/agent-skills · 208 tokens

nestjs-modular-monolith

Specialist in designing and implementing scalable modular monolith architectures using NestJS with DDD, Clean Architecture, and CQRS patterns. Use when building modular monolith backends, designing bounded contexts, creating domain modules, implementing event-driven module communication, or when user mentions "modular…

tech-leads-club/agent-skills · 131 tokens

component-identification-sizing

Maps architectural components in a codebase and measures their size to identify what should be extracted first. Use when asking "how big is each module?", "what components do I have?", "which service is too large?", "analyze codebase structure", "size my monolith", or planning where to start decomposing. Do NOT use…

tech-leads-club/agent-skills · 81 tokens

rails-dev

Opinionated Rails conventions: rich models, concerns, CRUD-everything, state-as-records, minimal dependencies, Minitest with fixtures. Load this skill BEFORE any code-level thinking, not only before editing a file. It is required the moment a task touches Rails code in ANY way: designing or even just discussing a data…

tech-leads-club/agent-skills · 199 tokens

modular-decomposition

Runs a sequenced monolith-to-modular pipeline that sizes and inventories components, finds shared domain duplication, addresses flattening and hierarchy issues, analyzes coupling, then groups components into candidate domain-aligned units, with optional embedded DDD strategic analysis for bounded contexts. Use when…

tech-leads-club/agent-skills · 158 tokens