More screenshots

    Works with the AI Agents you already use

    Claude CodeClaude CodeCursorCursorCodex CLICodex CLIDeepSeekDeepSeekMuseMuse+22 more

    Repair Rate Limit Window Drift

    1

    Repair rate-limit window drift where counters reset inconsistently, retries double-charge, distributed nodes disagree, or Retry-After and remaining-quota metadata diverge from enforcement.

    $1

    Secure checkout via Stripe

    Money-back guarantee

    Converts to your local currency at checkout

    Security scanned
    Repair Rate Limit Window Drift

    Repair Rate Limit Window Drift

    Example session with this skill installed

    Two API nodes calculate minute-window boundaries from local wall clocks. Around the reset edge, users can be rejected by one node while another reports remaining quota, and retries may count twice. Repair without changing plan limits.

    • Read your context and instructions
    • Compiled the repair rate limit

    Enforcement and metadata do not share one accounting authority. The repair moves boundary/counter updates to the existing atomic store/time contract, makes retry charging consistent with current request identity, derives Retry-After and remaining quota from the same state, and adds deterministic boundary/concurrency tests.

    Connects securely to your tools. The creator never sees your data.

    About this skill

    The problem

    Rate limiting implementations often drift across distributed systems, leading to inconsistent window accounting, incorrect Retry-After headers, and race conditions in atomic counters. Developers struggle to align trust boundaries, state ownership, and observability without accidentally weakening existing security policies or customer quotas.

    What it does

    • Audits fixed, sliding, and token-bucket implementations to ensure time authority and state ownership are consistent.
    • Patches distributed atomic updates and retry logic to prevent idempotent charging errors and double-billing.
    • Corrects boundary reset behavior and Retry-After calculations in quota response headers.
    • Implements deterministic local fixtures and barriers for testing clock drift and failover scenarios without production side effects.
    • Aligns observability and logging while strictly redacting secrets and customer values.

    Why this beats prompting it yourself

    Manual prompts often overlook the subtle interplay between concurrency and trust boundaries in distributed counters. This skill enforces a canonical contract for state transitions, ensuring that retries and leases are strictly bound to the state that created them while preserving complex burst and exemption policies.

    Use cases

    • Fixing race conditions in Redis-backed sliding window rate limiters.
    • Standardizing rate limit headers and retry logic across multiple microservices.
    • Adding deterministic regression tests for edge cases like clock skew or fail-open scenarios.
    • Refactoring rate-limit middleware to move validation before irreversible mutation dispatch.

    Known limitations

    This skill operates only on repository files and local fixtures. It cannot contact production services, read live secrets, or mutate deployed infrastructure state.

    Find more skills like this on the Claude Skills Marketplace, the Codex Skills Marketplace and the Gemini Skills Marketplace, or browse Claude Skills for Agents & Orchestration.

    Cannot redesign quota values, customer tiers, exemption policy, burst policy, fail-open/fail-closed policy, and public errors; cannot verify production infrastructure or prove every runtime, proxy, network, storage, clock, or scheduler ordering.

    How to use

    1. 1

      Connect your agent to the Agensi MCP

      Copy the prompt and paste it into Claude, ChatGPT, Cursor or any agent that supports MCP. It sets up the connection for you. Manual setup

    2. 2

      Sign in to Agensi

      Your agent shows a sign-in link. Sign in and click Allow.

    3. 3

      Ask for what you need

      Your agent loads this skill and uses it on your task. It always asks before buying a skill.

    Reviews

    No reviews yet

    Be one of the first to try it. Every listed skill goes through the trust checks below.

    Security scanned

    Checked by our 8-point scan before listing

    Fresh listing

    Recently published to Agensi

    Money-back guarantee

    Doesn't do what its page promises? You get your money back.

    Trust & safety

    Security scan

    Security scan passed 2 months ago

    Permissions

    Terminal / Shell
    Read Files
    Write Files

    Run on a clean branch with repository files and disposable local fixtures. Review patches and validation before merge. Keep production services, real credentials, customer payloads, and deployment out of scope.

    Listed2 months ago
    Updated9 days ago

    What's inside

    Frequently Asked Questions

    This skill fixes distributed accounting errors like race conditions in atomic counters, inconsistent Retry-After headers, and double-charging on retries across Redis-backed or local rate limiters.

    The skill is designed to work with most leading AI coding agents that support multi-file editing and repository-wide context, such as GitHub Copilot Workspace, Cursor, or specialized backend engineering agents.

    You receive the logic-driven skill definition, a set of deterministic test fixtures for simulating clock drift, and a standardized integration guide for your specific middleware.

    Yes, the skill is designed to audit and patch various implementations including fixed windows, sliding windows, and token-bucket algorithms while maintaining your existing burst and exemption policies.

    No, the skill operates strictly on your codebase and local testing environments; it does not require access to your production infrastructure, live Redis instances, or secret keys.

    Simply load the skill into your preferred AI agent's environment and point it at your rate-limiting middleware or distributed counter logic to begin the audit and repair process.

    New in Agents & Orchestration