@ai_super_niko: https://x.com/ai_super_niko/status/2077612167634030853

X AI KOLs Timeline Tools

Summary

CLIProxyAPI is a 42k-star open-source tool that converts AI subscriptions like Claude and ChatGPT into local API endpoints via OAuth login. It allows tools that only support API keys (such as ByteDance Trae, Tencent WorkBuddy) to share the same subscription, solving the pain point of reusing subscriptions across multiple tools.

https://t.co/9o93xFSnEE
Original Article
View Cached Full Text

Cached at: 07/16/26, 12:16 PM

CLIProxyAPI with 42k stars: One subscription feeds all AI tools

You bought Claude Pro, and want to use it in ByteDance Trae or the recently popular Tencent WorkBuddy — what do you do?

Today let’s talk about an open-source tool with 42k stars: CLIProxyAPI. It turns your AI subscriptions (Claude, ChatGPT, Gemini, Grok) into local API endpoints.

Why you need this

Many tools only accept API keys, not OAuth login:

Domestic agent tools: ByteDance Trae, Alibaba CoderWork, Tencent WorkBuddy, etc. To use Claude or GPT, you must fill in an API key.

Open-source agents: Plugins like Opencode, Cline have the same limitation.

Core pain point: You bought a Claude Pro subscription and want to try coding in Trae, fixing bugs in Cursor, and refactoring in Continue — all three tools using the same subscription. How?

CLIProxyAPI does exactly that: turns your subscription account into an API endpoint, allowing one subscription to serve multiple tools.

What it is

A relay running on your computer.

It logs into your subscription account (Claude Code, Codex, Gemini, Grok) via OAuth, then wraps these subscriptions into a standard API address (http://localhost:8317).

Any other tool that supports a custom base_url can use this local address.

You don’t need to understand “reverse proxy” or “protocol conversion”. Three steps: install a small program, log into your subscription account, fill in the local address in your tool.

How it works:

Subscription account (OAuth login) ↓ Local proxy (CLIProxyAPI, listening on port 8317) ↓ API endpoint (http://localhost:8317) ↓ Any tool that supports custom base_url

Why it’s worth recommending

One subscription, use everywhere

Buy one Claude Pro, use it in multiple tools.

Scenarios:

  • Daily development: Cursor for requirements, bug fixes — use Claude Pro
  • Experimentation and content creation: Access WorkBuddy or Trae — still use the same subscription

All three tools point to http://localhost:8317, and under the hood they all use the quota of your single subscription.

Especially useful for domestic tools, which mostly only support API keys:

  • ByteDance Trae, Alibaba CoderWork, Tencent WorkBuddy

If you want to use Claude or GPT in these tools, you either pay for API keys or can’t use them. With CLIProxyAPI, you convert your subscription into a key and connect.

Tools like Cursor, Windsurf with custom model support also work — just fill in the base_url.

Mix and match across vendors

Not just Claude — you can connect Claude, GPT, Gemini, and Grok all at once, switching between them at a single entry point.

For example:

  • Use Claude Opus for coding
  • Use GPT-Image-2 for image generation
  • Use Gemini Flash for quick queries

All called from http://localhost:8317, just change the model name.

You can also alias model names. If gpt-5.5 is too long, rename it to codex-latest in the config file, and just write codex-latest when calling.

OpenRouter and similar aggregation platforms can also be connected — add an openai-compatibility section in the config file, fill in OpenRouter’s API address and key, and hundreds of models become available through the local proxy.

How is it different from direct OAuth?

Many people ask: Cursor and Claude Code already support OAuth login natively — why add a proxy layer?

Different use cases.

Comparison DimensionDirect OAuthCLIProxyAPI Reverse Proxy
How it worksTool → Vendor directlyTool → Local proxy → Vendor
Account bindingSingle account locked to one toolOne account serves multiple tools
Tool restrictionOnly works with tools that natively support that vendor (e.g., Cursor OAuth can only log into Claude/OpenAI)Works with any tool that supports custom base_url
Cross-vendorNot supportedSupported (Claude, GPT, Gemini mixed)
Applicable scenariosVendors natively integrated by the toolVendors not supported via OAuth, or want to reuse subscription across tools

Key difference: OAuth makes the tool recognize the account; reverse proxy makes the tool recognize the endpoint, and the endpoint recognizes the account.

Examples:

  • Cursor natively supports OAuth login for Claude — just log in within Cursor
  • ByteDance Trae does not support OAuth for Claude, only accepts API keys — that’s where CLIProxyAPI is needed to convert the subscription into a key

Cross-tool reuse: A single Claude Pro subscription used in Trae, Cursor, and Continue — OAuth direct login can’t do it (each tool logs in separately, quotas count independently), but reverse proxy can (all three tools point to the same local interface, all use the same subscription).

Step-by-step: Getting started in three steps

Step 1: Install the proxy

macOS with Homebrew:

brew install cliproxyapi brew services start cliproxyapi

Docker one-liner:

docker run -p 8317:8317
-v /path/to/config.yaml:/CLIProxyAPI/config.yaml
-v /path/to/auth-dir:/root/.cli-proxy-api
eceasy/cli-proxy-api:latest

After starting, the proxy listens on port 8317. Open http://localhost:8317 in your browser. If you see a status page, it’s running.

Step 2: Log into your subscription

CLIProxyAPI logs into your subscription account via OAuth — no API key needed.

Run the login command in terminal (choose based on your subscription):

Claude Code subscription

./cli-proxy-api –claude-login

Codex subscription

./cli-proxy-api –codex-login

Grok Build subscription

./cli-proxy-api –xai-login

After running, the browser will open automatically for login. Log in and authorize. If you’re on a remote server, add --no-browser to print the login URL, which you can open on your local browser.

After login, set api-keys in the config file (define a string yourself, e.g., “my-secret-key”). This key will later be filled into your tools.

Config file path:

  • Homebrew install: $(brew --prefix)/etc/cliproxyapi.conf (common for Apple Silicon: /opt/homebrew/etc/cliproxyapi.conf, for Intel Mac: /usr/local/etc/cliproxyapi.conf)
  • Docker: the config.yaml you mounted

Open the config file, find api-keys:

api-keys:

  • “my-secret-key”

Fill in a key you’ll remember.

Step 3: Fill in the address in your target tool

Proxy is running, subscription is logged in. Last step: connect your other tools.

All tools that support custom models use the same method:

  • base_url: http://localhost:8317 or http://localhost:8317/v1 (some tools require the /v1 suffix)
  • api-key: the key you set in the config file (e.g., my-secret-key)
  • Model name: copy the model ID you want to use, e.g., claude-opus-4-20250514, gpt-5-codex, gemini-2.5-flash

Domestic tools (Trae, CoderWork, Workbuddy), Cursor, Continue, Cline — all filled the same way.

After filling, the tool sends requests to http://localhost:8317. The proxy receives the request, uses your logged-in subscription to call the model, and returns the result to the tool.

Caveats and reminders

Compliance risk

This approach treads on the edge of each vendor’s terms of service.

Essentially, you’re turning a subscription quota into API usage. Vendors may detect abnormal traffic patterns (e.g., the same account calling from multiple IPs and multiple tools simultaneously within a short time), deem it abuse, and risk account suspension.

My stance: This is a tool. Whether to use it and how is your own risk assessment. I’m just explaining it clearly.

Requires basic command-line skills

Installing the proxy and editing config files requires using the terminal. If you never touch the command line, there’s a learning curve.

Good news: there are desktop GUI versions in the ecosystem (recommended in the README), so you can manage the proxy without typing commands.

Depends on open-source project maintenance

Vendors’ risk control policies change. CLIProxyAPI needs to keep up. If Claude or OpenAI changes their protocol one day, the proxy may stop working until the project updates.

Fortunately, this project has 42k stars and is actively maintained.

Not a silver bullet

Only works in tools that support custom base_url. Some online platforms (e.g., certain web IDEs) don’t support custom endpoints, so it can’t connect.

One-sentence summary

If you have an AI subscription and want to use it across multiple tools (especially domestic tools or open-source agents that only accept API keys), this 42k-star tool is worth trying.

Hi, I’m Niko, a lifelong learner. A programmer with 17 years of experience, now using AI daily to write code and create content. Here I share my learning and experience with AI, technical thoughts, pitfalls I’ve encountered, practical tools, and skills. Follow me, learn together.

Similar Articles

@cloudi66: https://x.com/cloudi66/status/2090294715665293335

X AI KOLs Following

Introduces an open-source plugin named dsh that converts web subscriptions like ChatGPT, Claude, and Grok into standard AI model APIs, allowing users to fully utilize their existing subscriptions without additional API fees, and includes features such as real-time search, image generation, and video generation.

@laozhang2579: Reverse proxies, gray-market services, and middleman relays are likely all here. I. Comprehensive Multi-Protocol Gateways: CLIProxyAPI is the benchmark in this track, wrapping Gemini CLI, Antigravity, ChatGPT Codex, Claude Code, Qwen Code, and iFlow into…

X AI KOLs Timeline

A comprehensive guide reviewing various open-source tools for creating AI proxies and reverse-engineering APIs for services like Claude, ChatGPT, Gemini, and Copilot. It categorizes tools by supported service, highlighting technical approaches such as OAuth integration, cookie extraction, and protocol conversion.

@10xmylife: 这个工具好

X AI KOLs Following

KIGI CLI 0.1.5版本更新,新增支持5个OAuth提供商和24个基于API的提供商,包括Kimi Coding、ChatGPT、Grok xAI、Claude、GitHub Copilot。这是一个完全开源的支持图工程的CLI工具。

@sunmer575399: After searching for a long time, I finally dug up free-claude-code with 43.8k stars. You can run Claude Code and Codex without an API key, chatting right in the terminal. In testing, writing a crawler, it fixed bugs on its own. The free quota is genuinely enough for daily development. Mobile, IDE, terminal all...

X AI KOLs Timeline

free-claude-code is an open-source proxy tool that runs Claude Code, Codex, and Pi through its own provider without requiring an API key. It supports 31 cloud and local models, as well as multiple access methods such as terminal, IDE, and mobile. It has currently gained 43.8k stars on GitHub.