Claude Code Nexus
August 20, 2025 Β· View on GitHub
δΈζη | English
π€ A Claude API Proxy Service Platform - Seamlessly Compatible with Any OpenAI API Service for Claude Code CLI
Claude Code Nexus is a high-performance AI proxy service platform deployed on Cloudflare. It's specifically designed for Claude Code CLI, providing a compatibility layer that allows you to seamlessly forward Claude Code requests to any OpenAI-compatible API service, such as OneAPI, Azure OpenAI, local Ollama, or any other LLM service that follows the OpenAI specification.
β¨ Core Value
- π Vendor Unlock: No longer locked to a single AI service provider. You can freely choose the service with the best cost-performance ratio and performance.
- π Seamless Compatibility: Compatible with Claude Messages API, including streaming responses (SSE), tool use (Tool Use), and multimodal input.
- π― Smart Model Mapping: Easily configure model mapping rules on the web (e.g., map
claude-3-haikutogpt-4o-mini), with no changes needed in Claude Code CLI. - π Secure & Reliable: API Keys are encrypted and stored in the database, with strict user data isolation.
- π Global Acceleration: Based on Cloudflare's global network, providing low-latency, high-availability access for your AI applications.
- π Open Source & Controllable: The project is completely open source, allowing you to deploy, modify, and extend it yourself, with complete control over your data and services.
π Quick Start (3 Steps)
1. Login & Get API Key
Visit https://claude.nekro.ai/ and log in with your GitHub account. The system will automatically generate a dedicated API Key for you.
2. Configure Your Backend Service
In the console, configure your OpenAI-compatible API service. You'll need to provide:
- Base URL: Your API service address (e.g.,
https://api.oneapi.com) - API Key: Your API service secret key
3. Use in Claude Code
Set the following environment variables in your terminal:
# 1. Set your dedicated API Key
export ANTHROPIC_API_KEY="ak-your-nexus-key"
# 2. Set the proxy service address
export ANTHROPIC_BASE_URL="https://claude.nekro.ai"
# 3. Use Claude Code normally!
claude
π Done! Now your Claude Code CLI is proxied through Claude Code Nexus, using your own backend service.
π οΈ Tech Stack
- Backend: Hono on Cloudflare Workers - Lightweight, fast edge computing backend.
- Frontend: React + Vite on Cloudflare Pages - Modern, efficient frontend development experience.
- Database: Cloudflare D1 + Drizzle ORM - Type-safe serverless SQL database.
- UI: Material-UI - Mature, beautiful React component library.
- Authentication: GitHub OAuth.
π Documentation
We provide comprehensive project requirements and implementation details:
- Project Requirements Document (PRD) - Deep dive into the project's design philosophy, functional architecture, and technical implementation details.
π Related Projects
If you're looking for a highly extensible AI Agent framework, we recommend checking out our other project:
Nekro Agent - A multi-platform chat robot framework that combines code execution capabilities with high extensibility. Features sandbox-driven execution, visual interface, highly extensible plugin system, and native support for QQ, Discord, Minecraft, Bilibili Live, and other platforms. If you need to build intelligent chatbots or automated Agent systems, Nekro Agent will be your ideal choice.
π€ Contributing
Welcome to participate in the project through the following ways:
- π Report Issues: Submit bugs in GitHub Issues
- π‘ Suggest Ideas: Share your thoughts in GitHub Discussions
- β If you find this project helpful, please give it a Star!
π License
This project is licensed under the MIT License.