Your Claude subscription. Anywhere.
Connect once. Call it from any app.
A self-hosted proxy that turns your Claude subscription into a simple, secret-protected HTTP API — with automatic token refresh, prompt caching, tool use, streaming and per-response cost accounting.
- Self-hosted on your Cloudflare account
- Fails closed — no keyless access
- Auto-refreshing OAuth token
From Claude to your app in four steps.
No SDK lock-in, no extra backend. One Worker in your account, one secret, one HTTP endpoint.
Deploy
Deploy the Worker to your Cloudflare account.
Connect
Authorize Claude once via OAuth.
Call
Send requests through your private HTTP endpoint.
Track
Every response returns tokens and cost.
One Worker. A small API surface.
Eight routes, all behind one shared secret. Everything returns tokens and cost so you always know what a call did.
Health & Status
/healthLiveness and token status. Public, exposes no Claude access.
OAuth Setup
/setupGenerate a PKCE authorization link, then post CODE#STATE back.
Token Import
/admin/tokensBring an existing access/refresh token set. The Worker refreshes from there.
Single Message
/api/messagesSystem + user prompt, tier selection, JSON mode, thinking budget.
Conversation + Tools
/api/conversationMulti-turn messages with tool definitions and tool_choice.
SDK Passthrough
/proxy/v1/messagesRaw Anthropic Messages API. Point any SDK at /proxy — SSE when stream:true.
One curl away from your first response.
Every app that can make an HTTP request can use ClaudeOauth. Pass your secret as a Bearer token, pick a tier, get text and cost back.
- Token refresh is not your problem
The Worker holds the OAuth token in a Durable Object and rotates it ~1 hour before expiry — even with zero traffic.
- Cost on every response
Prompt, completion and cache tokens plus a USD figure come back with each call. No separate billing export.
- Streaming through /proxy
Point the Anthropic SDK at your Worker's /proxy path and keep streaming, tools and the rest of the Messages API.
$SECRETYour Worker. Your secret. Your infrastructure.
ClaudeOauth never sees your traffic. The dashboard talks to your Worker directly from the browser; the Worker talks to Claude.
Fail Closed
Every functional route requires your secret. If the secret is unset, the Worker returns 403 — there is no keyless path.
Self Hosted
Runs in your own Cloudflare account. The token lives in your Durable Object, not on a third-party server.
Optional IP Allowlist
Restrict requests at the Worker with ALLOWED_IPS. A leaked secret is useless from any other address.
OAuth Refresh
Tokens refresh automatically before expiry. Your apps only ever carry the shared secret.
Two hops. One secret.
Apps hold only the shared secret. The Worker exchanges it for the OAuth Bearer it manages for you.
Point your apps at your Worker.
Unlock the dashboard with your Worker URL and secret. Credentials stay in this browser and go straight to your Worker.