Status: [UNTESTED] Endpoints found: http://localhost:8082/v1/chat/completions http://localhost:8082/v1/models Source: https://github.com/cyberanrhy/claude-web2api # Claude Web2API — OpenAI-Compatible Proxy for Claude.ai > **[Keywords]**: Claude.ai API proxy · OpenAI-compatible · LLM proxy server · ChatGPT alternative · Claude web API wrapper · cookie-based auth · self-hosted Claude API · SSE streaming · Python proxy · Cloudflare bypass · tool calling support OpenAI-compatible proxy for [Claude.ai](https://claude.ai) Web API. Converts standard `/v1/chat/completions` requests to Claude.ai internal API. Works via cookie-based auth — no API key needed. **Use cases**: local development, testing, automation, integrating Claude.ai into OpenAI-compatible tools ## Features - OpenAI-compatible `/v1/chat/completions` - Streaming (SSE) and non-streaming - Model: `claude-3-5-sonnet`, `claude-3-5-haiku`, etc. (matches Claude.ai models) - Automatic TLS retry with exponential backoff - Rate-limit handling (429, daily reset) - CORS enabled ## Requirements - **Python 3.10+** - `pip install -r requirements.txt` (uses `curl_cffi` with Chrome impersonation) - **Firefox** with [cookies.txt](https://addons.mozilla.org/en-US/firefox/addon/cookies-txt/) extension - **VPN/proxy** — Claude.ai blocks non-residential IPs (Cloudflare) ## Keywords / SEO `claude-api`, `openai-api`, `proxy-server`, `llm`, `sse-streaming`, `python-proxy`, `claude-web-api`, `cookie-auth`, `cloudflare-bypass`, `function-calling`, `tool-use`, `openai-compatible` --- ## Setup (step by step) ### 1. Clone & install ```bash git clone https://github.com/YOUR_USERNAME/claude-web2api.git cd claude-web2api pip install -r requirements.txt ``` ### 2. Export cookies 1. Open [Claude.ai](https://claude.ai) **in Firefox** and log in 2. Install [cookies.txt](https://addons.mozilla.org/en-US/firefox/addon/cookies-txt/) extension 3. Click the extension icon → **Export** → save as `cookie_claude.txt` 4. Put `cookie_claude.txt` in the project directory > Must be **Netscape format** (tabs). The cookies.txt extension exports this by default. ### 3. Run ```bash