OpenAI-compatible + native Anthropic API proxy backed by a Claude Max subscription (OAuth).
| Method | Path | Description |
|---|---|---|
| GET | /health | Liveness |
| GET | /v1/models | Model list |
| POST | /v1/chat/completions | OpenAI-compat (Claude CLI subprocess) |
| POST | /v1/messages | Anthropic Messages API (OAuth passthrough) |
| GET | /auth/login | Auth UI — browser login page |
| GET | /auth/status | JSON auth status |
| POST | /auth/start | Begin PKCE login → returns {url, state} |
| POST | /auth/callback | Complete login with {code, state} |
When the token expires, browse to /auth/login:
- Click Generate Login URL — opens
claude.comOAuth - Log in and authorise Claude Code
- Anthropic redirects to
platform.claude.com/oauth/code/callbackwhich shows a one-time code - Paste that code into the proxy UI → tokens written, cache busted, ready immediately
services:
claude-max-proxy:
build: .
volumes:
- /home/joao/.claude:/root/.claude # OAuth credentials
ports:
- "8318:8318"