Discover and explore top open-source AI tools and projects—updated daily.
AmazingAngClaude API proxy for OpenAI clients
New!
Top 87.2% on SourcePulse
This project provides a lightweight, single-account proxy that bridges Claude's OAuth authentication with an OpenAI-compatible API endpoint. It is designed for developers and power users seeking to integrate Claude models into existing applications or workflows that rely on the OpenAI API specification, offering a simple, understandable, and easily modifiable solution. The primary benefit is enabling seamless use of Claude's capabilities through familiar API patterns without complex setup.
How It Works
auth2api functions as a reverse proxy, intercepting requests intended for OpenAI-compatible APIs and translating them into calls to the Anthropic Claude API. It handles the OAuth flow for a single Claude account, managing token refresh and cooldown periods. The proxy exposes standard OpenAI endpoints like /v1/chat/completions and /v1/models, while also supporting Claude's native /v1/messages endpoint for direct interaction, including features like streaming, tool use, and image input. Its design prioritizes a minimal codebase and a straightforward, single-account architecture for ease of deployment and customization.
Quick Start & Requirements
npm install && npm run build.node dist/index.js. The server defaults to http://127.0.0.1:8317.node dist/index.js --login for automatic browser-based authorization or node dist/index.js --login --manual for remote servers, requiring manual URL pasting.config.example.yaml to config.yaml and adjust settings for host, port, API keys, body limits, and timeouts.docker build -t auth2api . and run using provided docker run or docker-compose examples, mounting configuration and token directories.Highlighted Details
/v1/chat/completions, /v1/responses, /v1/models./v1/messages, /v1/messages/count_tokens./admin/accounts status endpoint.Maintenance & Community
No specific details regarding maintainers, community channels (e.g., Discord, Slack), or project roadmaps are provided in the README.
Licensing & Compatibility
The project is released under the MIT License, which is permissive and generally compatible with commercial use and linking within closed-source applications.
Limitations & Caveats
The proxy is strictly designed for a single Claude OAuth account per instance. Attempting to add a second account requires manual removal of the existing token file. It is not intended as a multi-provider gateway or a complex routing platform.
2 days ago
Inactive