openrouter-rate-limits
Skill by jeremylongshore
Explains and handles OpenRouter API rate limits. Covers 429 errors, SDK retry settings, client-side throttling and batch requests. Built for developers running high-throughput systems.
Install openrouter-rate-limits
Built from the published package, never by AI.
git clone --depth 1 https://github.com/jeremylongshore/tons-of-skills-marketplace /tmp/tons-of-skills-marketplace && mkdir -p ~/.claude/skills && cp -r /tmp/tons-of-skills-marketplace/skills/.curated/openrouter-rate-limits ~/.claude/skills/openrouter-rate-limitsRun in your terminal. Claude Code loads skills from ~/.claude/skills automatically.
git clone --depth 1 https://github.com/jeremylongshore/tons-of-skills-marketplace /tmp/tons-of-skills-marketplace && mkdir -p ~/.gemini/antigravity-cli/skills && cp -r /tmp/tons-of-skills-marketplace/skills/.curated/openrouter-rate-limits ~/.gemini/antigravity-cli/skills/openrouter-rate-limitsAntigravity CLI loads skills from ~/.gemini/antigravity-cli/skills, or .agents/skills for one project.
Step-by-step: install openrouter-rate-limits in Antigravity CLI
Skills can run scripts on your machine. Some need an API key: check the README.
About
The openrouter-rate-limits skill is a guide for handling rate limits on the OpenRouter API. It states that limits are per key, not per account, and that free keys get lower limits than paid keys. It shows how to query a key's limits from GET /api/v1/auth/key, read the x-ratelimit and retry-after headers, and set retries on the OpenAI SDK with max_retries and timeout.
The skill also includes a Python TokenBucket class for client-side limiting and a batch helper that staggers request starts and caps concurrency with a semaphore. It notes that free models have separate daily caps of 50 requests per day, or 1000 with $10 or more in credits. It is aimed at developers who hit 429 errors, build high-throughput systems, or implement retry logic.
Written from the project's SKILL.md and checked against it.
What it can do
- Check key limitsQueries GET /api/v1/auth/key to show the key's request limit and interval.
- Read rate limit headerscheck_rate_headers() returns x-ratelimit values and retry-after from a request.
- Configure SDK retriesSets max_retries and timeout on the OpenAI SDK so 429 responses are retried with backoff.
- Client-side rate limiterTokenBucket blocks until a request slot is free, staying under the server limit.
- Batch processingbatch_with_rate_limit() staggers request starts and caps concurrency for bulk jobs.
- Error handling guideLists causes and fixes for 429 errors, retry storms, silent throttling and free tier limits.
What you need
- OpenRouter API key exported as OPENROUTER_API_KEY
- curl and jq
- Python 3.8 or later
- OpenAI SDK and the requests package
Try asking
- Check my OpenRouter key's rate limit and tell me the interval.
- Add retry logic with max_retries to my OpenRouter client.
- Write a batch job that sends prompts to OpenRouter with capped concurrency.
Good to know
- Rate limits apply per key, not per account.
- Free models have daily caps of 50 requests per day, or 1000 with $10 or more in credits.
- Paid tier limits vary and depend on credit balance.
Security check
B- Allowed to use Write, Edit without limitsIn
SKILL.md
Checked automatically: skills/.curated/openrouter-rate-limits/SKILL.md. This looks for known risky patterns and is not a full audit. How grades work
Inside the skill
Allowed tools: ReadWriteEditGrepBash(python3:*)Bash(curl:*)Bash(jq:*)
Alternatives to openrouter-rate-limits
All alternatives →Runs a 7-stage workflow for auditing, cleaning up and reviewing GitHub repositories, plus competitor analysis. Written for developers who want a repo checked for secrets, junk files and documentation gaps.
Teaches an AI assistant to build, debug and explain Gradio web UIs and ML demos in Python. It covers the core API, components, event listeners, layouts and the MCP server option. Aimed at Python developers who work with Gradio.
Recommends menus, buttons, toolbars and disclosure controls for Apple platforms using Human Interface Guidelines conventions. Built for developers and designers making iOS, iPadOS, macOS or visionOS interfaces. Checks existing project design context before asking questions.
Creates production-ready FastAPI project structures with async patterns, dependency injection, and error handling. It is for developers starting new FastAPI applications or backend API projects.
Analyzes Android apps to find user workflows to expose as AppFunctions, so AI agents and system shortcuts can run them without opening the app UI. Generates Kotlin code and refines KDoc for Android developers.
Creates, edits, validates and runs Agent QA tests, suites and hooks through MCP or CLI. It keeps canonical IDs and schema contracts intact, for developers and QA teams using Agent QA.
Compare with openclaw-github-repo-commander, gradio or hig-components-menus
openrouter-rate-limits: common questions
What causes OpenRouter 429 errors?
The source says 429 errors occur when a key exceeds its requests per interval. The OpenAI SDK retries these automatically if max_retries is set.
Are OpenRouter rate limits per account or per key?
They are per key. The source says that using multiple keys can increase effective throughput.
How do I check my current OpenRouter rate limit?
Call GET /api/v1/auth/key with your API key and read the rate_limit field in the response.
How do I install openrouter-rate-limits?
Run the command above to copy the skill into ~/.claude/skills/. Claude Code picks it up automatically.
Is openrouter-rate-limits free?
The code is published under the MIT licence. The service it connects to may have its own pricing.
Is openrouter-rate-limits safe to use?
It scores 76 of 100. Grades: maintenance A, licence A, quality A. Security check: grade B (allowed to use write, edit without limits). Review the code before you install. How grades work.
What are alternatives to openrouter-rate-limits?
Similar skills: openclaw-github-repo-commander, gradio, hig-components-menus, fastapi-templates.
