Self-serve API keys in the dashboard
Sign up at dashboard.closedrouter.app, create an organization, connect an account, and generate scoped cr-sk- keys under API keys. Test live in the built-in Playground.
Call OpenAI, Anthropic, and Gemini compatible endpoints with one scoped cr-sk- key, launch coding tools through @closedrouter/cli, or connect autonomous agents over Streamable HTTP MCP and OAuth 2.1.
Specs: openapi.json · llms.txt · llms-full.txt · mcp.json | Self-hosting (Vault & Kubernetes)
# 1. Install the official CLI from npm
$ npm install -g @closedrouter/cli
# 2. Sign in and import accounts
$ cr login
$ cr import
# 3. Launch Claude Code or test the API
$ cr start claude
$ curl https://api.closedrouter.app/v1/models \
-H "Authorization: Bearer cr-sk-..."
Use https://api.closedrouter.app directly for lowest latency, SSE streaming, WebSockets, and MCP. HTTP routes are also proxied on https://closedrouter.app.
Free to start with your own provider seats or keys. No sales calls or manual approvals required.
Sign up at dashboard.closedrouter.app, create an organization, connect an account, and generate scoped cr-sk- keys under API keys. Test live in the built-in Playground.
Run claude mcp add --transport http closedrouter https://api.closedrouter.app/mcp. Discovery lives at /.well-known/oauth-authorization-server and /.well-known/oauth-protected-resource.
Start at POST https://api.closedrouter.app/oauth/device_authorization. A teammate approves the one-time code at https://dashboard.closedrouter.app/agent-connect.
Agents without a human account can call POST https://api.closedrouter.app/api/v1/agent/signup with {"name":"agent"} to create an isolated workspace, obtain a cr-sk- key immediately, and receive a one-time claim_url.
Restrict any cr-sk- key or OAuth grant to exact endpoint families, models, RPM, and token ceilings.
Every API failure returns JSON with error.code, error.type, and error.message (never HTML). Nonexistent docs routes return HTTP 404 with Markdown when Accept: text/markdown is sent.
Gateway responses advertise RateLimit-Policy. When a pool window or member cap is hit, responses return HTTP 429 with Retry-After (seconds until earliest reset) and X-ClosedRouter-Cap.
Inference endpoints are versioned by path (/v1, /v1beta) and advertise X-API-Version. Breaking changes ship under a new version prefix. Deprecated endpoints emit RFC 8594 Deprecation and Sunset headers with at least 90 days notice.
Install @closedrouter/cli via npm install -g @closedrouter/cli. Run cr verify to test streamed tool calls end to end across protocols, or run cr gateway to bridge local Claude Code seats.