[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"project-79046":3},{"id":4,"name":5,"fullName":6,"owner":7,"repo":5,"description":8,"homepage":9,"htmlUrl":9,"language":10,"languages":9,"totalLinesOfCode":9,"stars":11,"forks":12,"watchers":13,"openIssues":14,"contributorsCount":15,"subscribersCount":15,"size":15,"stars1d":16,"stars7d":17,"stars30d":18,"stars90d":15,"forks30d":15,"starsTrendScore":19,"compositeScore":20,"rankGlobal":9,"rankLanguage":9,"license":21,"archived":22,"fork":22,"defaultBranch":23,"hasWiki":24,"hasPages":22,"topics":25,"createdAt":9,"pushedAt":9,"updatedAt":36,"readmeContent":37,"aiSummary":38,"trendingCount":15,"starSnapshotCount":15,"syncStatus":14,"lastSyncTime":39,"discoverSource":40},79046,"backdoor","ajsai47\u002Fbackdoor","ajsai47","Run Claude Code against any AI provider. DeepSeek, Groq, Ollama, OpenRouter — your call.",null,"Python",295,32,71,2,0,16,28,112,59,88.56,"MIT License",false,"main",true,[26,27,28,29,30,31,32,33,34,35],"ai","anthropic","claude","claude-code","deepseek","llm","ollama","openai-compatible","openrouter","proxy","2026-06-12 04:01:24","```\n██████╗  █████╗  ██████╗██╗  ██╗██████╗  ██████╗  ██████╗ ██████╗\n██╔══██╗██╔══██╗██╔════╝██║ ██╔╝██╔══██╗██╔═══██╗██╔═══██╗██╔══██╗\n██████╔╝███████║██║     █████╔╝ ██║  ██║██║   ██║██║   ██║██████╔╝\n██╔══██╗██╔══██║██║     ██╔═██╗ ██║  ██║██║   ██║██║   ██║██╔══██╗\n██████╔╝██║  ██║╚██████╗██║  ██╗██████╔╝╚██████╔╝╚██████╔╝██║  ██║\n╚═════╝ ╚═╝  ╚═╝ ╚═════╝╚═╝  ╚═╝╚═════╝  ╚═════╝  ╚═════╝ ╚═╝  ╚═╝\n```\n\n\u003Cdiv align=\"center\">\n\n### Claude Code is the best coding agent ever built. The model underneath is optional.\n\n**Backdoor lets you run Claude Code against any AI — DeepSeek, Groq, Ollama, OpenRouter, or your own local model. Same UI. Same tools. Same agentic loops. Zero lock-in.**\n\n[![License: MIT](https:\u002F\u002Fimg.shields.io\u002Fbadge\u002FLicense-MIT-green.svg)](LICENSE)\n[![Works with Claude Code](https:\u002F\u002Fimg.shields.io\u002Fbadge\u002Fworks%20with-Claude%20Code-blue)](https:\u002F\u002Fdocs.anthropic.com\u002Fen\u002Fdocs\u002Fclaude-code)\n[![Providers](https:\u002F\u002Fimg.shields.io\u002Fbadge\u002Fproviders-any%20OpenAI--compatible-orange)](README.md)\n\n\u003C\u002Fdiv>\n\n---\n\n## The problem\n\nClaude Code is genuinely in a league of its own as a coding agent. The tool use, the agentic loops, the way it navigates a codebase — nothing else comes close.\n\nBut it's hardwired to Anthropic's API. You pay Anthropic's prices. You use Anthropic's models. You play by Anthropic's rules.\n\nThat's a lot of lock-in for a tool that could theoretically run on anything.\n\n---\n\n## The fix\n\nBackdoor is a lightweight proxy that intercepts Claude Code's API calls and reroutes them to any OpenAI-compatible provider. It translates the request format, streams the response back, handles tool use — everything. Claude Code has no idea anything changed.\n\n```\nBefore:   Claude Code  →  Anthropic API  →  $$$\nAfter:    Claude Code  →  Backdoor  →  literally anything\n```\n\nThree commands to set up. One line to switch providers.\n\n---\n\n## The numbers don't lie\n\nWe ran **500 million tokens** through Claude Code. Same workload. Two different backends.\n\n| | Claude Opus 4.7 | DeepSeek V3 Flash |\n|---|---|---|\n| **500M tokens** | **$9,834** | **$5.34** |\n| Cost per 1M tokens | ~$19.67 | ~$0.01 |\n| **Savings** | — | **99.95% cheaper** |\n\nThat's not a typo. **$9,834 vs $5.34. Nearly 2,000x cheaper at scale.**\n\nIf you're an individual developer, that's the difference between a credit card bill that hurts and one that rounds to zero. If you're a team running Claude Code across multiple engineers, this is the difference between a budget line item that gets cut and one nobody notices.\n\nThe harness is free. The intelligence is cheap. That's the whole point.\n\n---\n\n## What you actually get\n\n🆓 **Run it free.** NVIDIA NIM and Groq both have free tiers with thousands of requests per month. Backdoor works with both out of the box.\n\n💸 **Run it cheap.** DeepSeek costs roughly **95% less** than Claude's API. If you're using Claude Code daily, that's the difference between a coffee and a car payment.\n\n🔒 **Run it private.** Point Backdoor at a local Ollama instance and nothing ever leaves your machine. No API. No logs. No data sent anywhere.\n\n🔀 **Run whatever model you want.** One config change and you're on a completely different AI. Benchmark Llama vs. Mistral vs. DeepSeek against your actual work, using the best coding agent UI ever built as the harness.\n\n🌍 **200+ models, one tool.** Wire up OpenRouter and you have access to every major model on earth — Gemini, Grok, Qwen, Command R, all of them — through a single API key.\n\n---\n\n## Get running in 60 seconds\n\n```bash\ngit clone https:\u002F\u002Fgithub.com\u002Fajsai47\u002Fbackdoor\ncd backdoor\n.\u002Fbackdoor   # animated setup wizard — picks your provider, writes your config, launches Claude Code\n```\n\nThat's it. The wizard handles everything: animated intro, provider selection, API key entry, and launching your first session. If you'd rather skip the wizard and configure manually, copy `.env.example` to `.env`, fill it in, and run `.\u002Frun.sh` directly.\n\n---\n\n## Pick your provider\n\nEdit three lines in `.env` and you're on a different AI:\n\n```bash\nPROVIDER_BASE_URL=https:\u002F\u002Fapi.deepseek.com\u002Fv1\nPROVIDER_API_KEY=your-key\nPROVIDER_MODEL=deepseek-chat\n```\n\n| Provider | Free tier? | Speed | Best for |\n|---|---|---|---|\n| **DeepSeek** | — | Fast | Best value. Insanely cheap. |\n| **Groq** | ✅ | Fastest | When you want responses instantly |\n| **NVIDIA NIM** | ✅ | Fast | Free Llama 3.3 70B |\n| **OpenRouter** | — | Varies | Access to everything, one key |\n| **Ollama** | ✅ (local) | Depends on your machine | Total privacy, no internet needed |\n| **LM Studio** | ✅ (local) | Depends on your machine | Easy local model management |\n\n---\n\n## Why this exists\n\nI'm a huge fan of Anthropic. Genuinely. Their models are some of the most impressive technology I've ever used, and Claude Code is the best coding agent ever built — it's not close.\n\nThis project isn't a knock on them. It's a tribute to how good the harness is.\n\nWhat I believe is simple: the best tools should be accessible to everyone, not just the people who can afford the top-tier API. A student, a solo developer, a builder in a country where $9,000\u002Fmonth in API costs is unthinkable — they deserve to experience what Claude Code can do. Vendor lock-in shouldn't be the thing standing between a great developer and a great tool.\n\nAnthropic built the magic. Backdoor makes sure everyone gets to use it.\n\n**Run Claude Code. Bring your own model. Keep building.**\n\n---\n\n## Open source. No strings.\n\nMIT licensed. Read the code — it's clean, it's simple, it's less than 600 lines. Fork it, change it, build on it.\n\nIf a new AI provider launches tomorrow, you can use it with Backdoor the same day. No waiting for a pull request. Just drop in the URL.\n\n---\n\n## Bonus: control Claude Code from your phone\n\nSet `TELEGRAM_BOT_TOKEN` and `TELEGRAM_ALLOWED_USER_ID` in `.env` and you can trigger Claude Code sessions from Telegram. Send a prompt from your phone, get the output back in chat.\n\n---\n\n## Troubleshooting\n\n**`Proxy failed to start`**\nSomething is already using port 8082. Either stop the other process or change `PORT=8083` in your `.env`.\n\n**`PROVIDER_API_KEY is not set`**\nOpen `.env` and replace `your-api-key-here` with your actual key.\n\n**`Claude Code is not installed`**\nInstall it from [claude.ai\u002Fcode](https:\u002F\u002Fclaude.ai\u002Fcode).\n\n**`Model not found` or `404` from the provider**\nThe model name in `PROVIDER_MODEL` doesn't match what the provider expects. Check the provider's docs for the exact model slug — they vary (e.g. DeepSeek uses `deepseek-chat`, Groq uses `llama-3.3-70b-versatile`).\n\n**Responses feel slow**\nSwitch to Groq — it's the fastest inference available and has a free tier.\n\n**Nothing is logged**\nCheck `proxy.log` in the project directory. If it's empty, the proxy didn't start at all — run `uv run uvicorn server:app` directly to see the error.\n\n---\n\n## How it works under the hood\n\nClaude Code talks to `localhost:8082` thinking it's Anthropic. Backdoor receives the request, translates it from Anthropic's Messages API format to OpenAI's chat completions format, forwards it to your chosen provider, and streams the response back — translated back into Anthropic's SSE format in real time. Tool calls, streaming deltas, token counts — all handled transparently.\n\nA handful of Claude Code's internal housekeeping requests (quota probes, title generation, etc.) are intercepted and short-circuited locally so they don't burn your provider quota.\n\n---\n\n\u003Cdiv align=\"center\">\n\n**Star this if you think the best coding agent should work with any model.**\n\n\u003C\u002Fdiv>\n","Backdoor 项目允许用户将 Claude Code 运行在任何 AI 提供商上，如 DeepSeek、Groq、Ollama 和 OpenRouter 等。其核心功能是通过一个轻量级代理拦截并重定向 Claude Code 的 API 请求，从而实现对不同后端的支持，同时保持相同的用户界面和工具使用体验。该项目采用 Python 编写，具有高度的灵活性和零锁定特性，使得用户可以在不改变工作流程的情况下自由选择成本更低或更适合自身需求的服务提供商。适用于希望降低 Claude Code 使用成本或需要在本地部署 AI 模型的个人开发者及团队。","2026-06-11 03:57:25","CREATED_QUERY"]