QCode Documentation
Browse the full Claude Code & Codex documentation by category and find what you need fast
Connect in 60 seconds
-
Choose a plan and get an API keyPick the plan that suits you in "How to choose a plan", then create a key in the QCode console — one key works on all four endpoints.How to choose a plan → Open console →
-
Set the right BASE_URLOne command writes the config for you, or check the endpoint table to fill it in yourself (which tools need /v1).One-command setup → Endpoints & API formats →
-
Connect your toolStep-by-step per tool: what to install, which file to edit, how to verify.
What are you trying to do?
4 common tasks
Start here
🚀
Get running in 5 minutes
First time? Start here
🧭
Pick the right tool & IDE
Claude Code or Codex? Which IDE fits?
💰
Spend less, run longer
Choose models, control context, watch billing
🛠️
Troubleshoot & level up
Diagnose errors, then go further
Full documentation index
88 docs
Getting Started
Get your key, set the right BASE_URL, make your first request
12 docs
Introduction to Claude Code
Learn what Claude Code is, how it compares to competitors, and how to use it through QCode.cc
How to Choose a Plan
How the four plans differ in quota, validity, concurrency and resale, plus three questions to pick one: personal plan, packs, or other paths for teams.
Cloud Servers: Picking, Buying and Using
Your first cloud server: a dedicated IPv4, full root access, lines in five countries, how to pick a line, the 1-day trial and how delivery works.
QCode for Users Outside Mainland China
Signing up, paying in USD, choosing the right access domain and switching the documentation language for developers outside mainland China
One-Click Setup Script
One command to fully configure Claude Code / Codex: latency-based endpoint selection, config writing, CLI installation and connectivity verification — no sudo / admin rights required
Endpoints & API Paths
QCode.cc's Anthropic and OpenAI API protocols (the Gemini path is currently unavailable), three access domains, and how to fill in BASE_URL
Installation
Install and configure Claude Code on Windows, macOS, and Linux
Claude Code Environment Variables (2026)
Set ANTHROPIC_BASE_URL and ANTHROPIC_AUTH_TOKEN for Claude Code on QCode.cc, see how ANTHROPIC_API_KEY differs, plus per-tool settings and verification.
Quick Start
Learn Claude Code essentials in 5 minutes
Codex CLI Quick Start (2026): Setup in 5 Min
Install Codex CLI and connect it to QCode.cc in about 5 minutes: one-click script or manual config.toml + auth.json, then a first task. Same key as Claude Code.
Claude Code Tutorial: Install & Run (2026)
The shortest path from install to first run: one command sets up Claude Code with QCode, then add your cr_ key and start. Full tutorial for 2026.
Codex vs Claude Code 2026: When to Use Each
Codex CLI vs Claude Code in 2026: autonomous sandboxed agent vs interactive pair programming across 15+ dimensions, when to pick each, and how to combine them.
Connect Your Tool
Step-by-step setup and a compatibility overview for IDEs, CLIs, desktop apps and chat clients
33 docs
Tool Compatibility Overview
The compatibility matrix behind every integration page on this site: which protocol each tool speaks, whether Claude models work with it, where its configuration lives, and when each page was last verified
CC Switch Download: Latest v4.0.21 & Setup
CC Switch v4.0.21 (2026-10-26): ccswitch.io is the only official website. Download from GitHub Releases, then add QCode.cc to Claude Code or Codex CLI.
magpie Setup with QCode: Claude Code & Codex
Point magpie at QCode: fill the anthropic, chat and responses addresses, add the provider with an import link or one command, then pick models.
Codex CLI 0.164.0: Install & config.toml
Codex CLI 0.164.0 (2026-10-23): install it, connect QCode.cc through ~/.codex/config.toml and auth.json, then use AGENTS.md, approvals, profiles and MCP.
Claude Desktop Third-Party API Setup (2026)
Claude Desktop without signing in: enable Developer Mode, open Configure Third-Party Inference and add QCode.cc as the gateway; one quota shared with your CLIs.
OpenCode 2.1.4 Setup: Claude & GPT (2026)
OpenCode 2.1.4 (2026-10-23): connect QCode.cc in opencode.json with anthropic and openai baseURL entries, then save the key through /connect.
OpenClaw Integration
Configure QCode.cc as model providers for OpenClaw: the models.providers block in openclaw.json, the Custom Provider onboarding wizard, and how to verify the connection
Hermes Agent Integration
Point Hermes Agent (Nous Research) at QCode.cc through custom providers in config.yaml: the three transport values, keys in .env, and switching models mid-session
WorkBuddy API Setup with QCode
2026: Add QCode.cc to Tencent WorkBuddy as a custom OpenAI Chat model: base URL, cr_ key and a live model id; then verify with a ping.
Antigravity CLI (agy): API-Key Setup (2026)
Configure Google Antigravity CLI (agy) with a QCode.cc key: set modelProvider in settings.json, then point GEMINI_API_KEY and GOOGLE_GEMINI_BASE_URL at QCode's Gemini endpoint
DeepSeek-TUI (CodeWhale 0.10.2) Setup 2026
CodeWhale v0.10.2 (2026-10-24), formerly DeepSeek-TUI: binary codewhale, config ~/.codewhale/config.toml. Connect QCode.cc on the anthropic or openai provider.
Zed + Claude Code ACP Setup (v1.25.3)
Zed 1.25.3 (2026-10-23): run Claude Code in the agent panel over ACP, or add QCode.cc as an anthropic_compatible / openai_compatible provider in settings.json.
ACP Overview
Agent Client Protocol: one setup that works across Zed, Devin Desktop and JetBrains — run Claude Code as an ACP agent with its environment pointed at QCode
VS Code Integration
Use the Claude Code extension and GitHub Copilot custom endpoints in VS Code: installing the extension, the primaryApiKey config, and connecting QCode through chatLanguageModels.json
GitHub Copilot Integration
Use QCode.cc through GitHub Copilot's custom endpoints: chatLanguageModels.json in VS Code 1.122+ with the three apiType values (messages / chat-completions / responses), Copilot CLI BYOK variables, and JetBrains support scope
Trae Claude Code Extension Setup
2026: install the Claude Code extension in Trae IDE, set primaryApiKey in ~/.claude/config.json and connect QCode.cc; covers the offline .vsix path for Trae CN.
Cursor Custom Base URL & API Key Setup
Connect QCode to Cursor with a custom OpenAI or Anthropic Base URL and API key: setup, model IDs, and the features that stay on Cursor's built-in models.
Cline Integration
Use QCode.cc API with the Cline extension in VS Code
Cherry Studio Integration
Add QCode.cc as a custom provider in Cherry Studio: the Settings-to-Model-Services path, what URL each of the four provider types needs, and why the Agent feature wants an Anthropic-type endpoint
JetBrains IDE Integration
Use Claude Code through QCode in IntelliJ IDEA, WebStorm, PyCharm, GoLand, and other JetBrains IDEs
Devin Desktop (formerly Windsurf) Setup
Windsurf is now Devin Desktop and is built around ACP: attach Claude Code as an ACP agent with its environment pointed at QCode
Gemini CLI Integration Guide
Configure the Google Gemini CLI with a QCode.cc API key — enterprise paid keys; Pro / consumer tiers were retired on 2026-06-18 (QCode does not offer Gemini for now; reference only)
Kilo Code Setup
Connect QCode.cc in the Kilo Code VS Code extension: Settings -> Providers -> Custom provider, with Provider API set to Anthropic Messages for Claude
Crush Setup
Add QCode.cc as a custom provider in Charm Crush: type=anthropic plus base_url in crush.json, and use Claude from the terminal
Droid (Factory) Setup
Add QCode.cc as a BYOK custom model in Factory's Droid CLI: provider=anthropic plus baseUrl in ~/.factory/settings.json
Aider Integration
Configure Aider with QCode.cc: Claude over the Anthropic endpoint (anthropic/ prefix), GPT and Chinese models over the OpenAI-compatible endpoint
SillyTavern Custom API Setup (Claude, GPT)
Connect QCode to SillyTavern via the Claude reverse proxy or a custom OpenAI-compatible endpoint: field names, models, and image-generation limits (2026).
Roo Code Setup
Use QCode.cc from the Roo Code VS Code extension: pick the Anthropic provider, tick the custom base URL, and Claude works
Qwen Code Setup
Connect QCode to the Qwen Code CLI with modelProviders in ~/.qwen/settings.json: Anthropic and OpenAI-compatible base URLs, /model, /doctor
Kimi Code CLI Setup
Connect QCode.cc to Kimi Code CLI in ~/.kimi-code/config.toml: type anthropic for Claude, type openai for GPT and Chinese models
Goose Provider Setup
Point goose's Anthropic and OpenAI-compatible providers at QCode: which HOST field takes which URL, and what goose configure cannot do
LobeChat Setup
Connect QCode.cc in LobeChat / LobeHub: the Anthropic and OpenAI provider entries, the Proxy URL field, and the self-hosted variables.
Open WebUI Integration
Connect QCode.cc to Open WebUI as an OpenAI-compatible connection: the admin Connections page, the Model IDs allowlist, and why Claude is not available
Usage Tips
After it works: choose models, cut costs, manage context, write config files
18 docs
Claude Code Model Selection Guide
Choose a Claude model for Claude Code by task, plus GPT models via Codex CLI: callable model IDs, /model switching, scenarios; see qcode.cc/models (2026).
Cost Optimization Guide
Master Claude Code's cost control techniques to accomplish more with fewer tokens
Context Management
Understanding and managing Claude Code's context window, and effectively using commands like /compact and /clear
CLAUDE.md Configuration Guide
Using CLAUDE.md to provide Claude Code with project context and coding conventions
AGENTS.md Guide: Setup & CLAUDE.md
AGENTS.md is the open instruction format for Codex and other coding agents: file locations, override rules, CLAUDE.md differences, and migration steps (2026).
Language Settings: Making Claude Code and Codex Reply in Your Language
Set the response language for Claude Code and Codex with CLAUDE.md and AGENTS.md, write non-English prompts without breaking code, and handle UTF-8 files, accented characters and CJK paths
CLI Tips
34 practical Claude Code CLI tips to boost your development efficiency
Best Practices
Best practices for efficient Claude Code usage, a comprehensive guide from project initialization to team collaboration
Workflow Tips
Efficient Claude Code development workflows to boost team productivity
Dynamic Workflows
Use Claude Code's Dynamic Workflows to orchestrate dozens to hundreds of background sub-agents for repo-wide review, migration, and research — works through QCode
Claude Code Output Format: JSON & Stream
Use claude -p --output-format with json, stream-json, and text in scripts and CI: one JSON object, NDJSON events, --json-schema, and jq recipes (2026).
Permission Configuration
Configure Claude Code's permission modes to control which operations require human confirmation
Claude Adaptive Thinking vs budget_tokens
Adaptive thinking vs budget_tokens on Claude 4.6 / 4.7 / 4.8: set thinking to adaptive, tune effort, and why Opus 4.8 returns a 400 error for budget_tokens.
Chinese Models
Call GLM / Kimi / DeepSeek / Qwen with the same QCode.cc cr_ key: current ids on sale, protocol paths, a curl self-test, and pairing with the Claude 5 family
Image Input (Vision)
Give Claude Code images by paste, drag-and-drop or file path to read screenshots, mockups, diagrams and charts — one QCode.cc API key works on every endpoint.
gpt-image-2 Image Generation and Editing
OpenAI-compatible gpt-image-2 text-to-image + image-edit API: drop in by switching base_url, multi-region endpoints, unified billing with your QCode key
Use QCode with 9router
Add QCode.cc as a custom provider in 9router, a local multi-provider router, for cross-provider fallback and unified management
Run Agents on a Cloud Server
Run Claude Code or Codex on a cloud server: install the tools, set the key and endpoint, keep tasks alive with tmux, and switch to key-based SSH safely.
Advanced
Hooks, MCP, subagents, headless automation and the SDK
9 docs
Claude Code Skills Guide (SKILL.md)
Create and use Claude Code skills: SKILL.md structure, frontmatter fields, load locations, automatic and /skill-name invocation, and bundled skills (2026).
Plan Mode Deep Dive
Mastering Claude Code's Plan Mode — Plan First, Then Execute for More Controllable and Efficient AI Programming
Hooks System
Master Claude Code Hooks — 17 lifecycle events, 3 handler types, 10+ practical recipes and enterprise configuration
MCP Servers
Extend Claude Code capabilities with Model Context Protocol to connect external tools and services
Sub-agent Collaboration Mode
Understanding and using Claude Code's sub-agents — parallel exploration, background tasks, isolated execution
Plugin System
Use Claude Code plugin system to create custom commands, agents, and workflows
Automation & CI/CD
Master Claude Code headless mode — full flag reference, five CI/CD recipes, Docker isolation, session resumption and a Codex comparison
Claude Agent SDK: Python & TypeScript
Build agents with the Claude Agent SDK in Python and TypeScript: official package names, query(), ClaudeSDKClient, and running through QCode (2026).
Security Best Practices
Fully mastering Claude Code's security mechanisms — permission control, sensitive file protection, command interception, API key management
Reference
Cheatsheet, error codes, troubleshooting, billing, enterprise and availability
16 docs
Claude Code Cheatsheet
Claude Code one-page cheatsheet — keyboard shortcuts, slash commands, CLI flags, env vars, MCP, Skills, Agents, CLAUDE.md reference
FAQ
Frequently asked questions about Claude Code and QCode.cc
Subscriptions vs API Keys vs QCode Keys
What a Claude Pro / ChatGPT Plus subscription, an official API key, and a QCode cr_ key actually are, how each is billed, and where each works — three independent things that can coexist
Dashboard Guide
Using the QCode.cc console: the API access address, creating and copying API keys, usage statistics, top-up, plan purchase, team sub-keys and the Open API access token
Why Claude Sonnet 5 Appears in Your Usage
Picked Sonnet 5.5 but see claude-sonnet-5 in your usage? Claude Code's auto permission mode sends safety checks to Sonnet 5. Why, how to check, how to reduce.
Claude Code Classifier Billing Notice
Claude Code says this session isn't eligible and your endpoint isn't compatible? What the notice means, how it affects usage and cost, and how to remove it.
Error Code Reference
Reference for QCode.cc API error codes: 400/401/402/403/429/500/502/503/529 semantics, typical causes and proven fixes, including INSUFFICIENT_BALANCE
Troubleshooting Guide
Diagnosis and solutions for common Claude Code problems, helping you quickly locate and fix issues
Billing Description
Understanding QCode.cc's billing methods, pricing data sources, and fee calculation logic
Pay-as-you-go Packs: Prices and Renewal
Prices, quota and validity of the four packs, how renewal adds quota and sets the expiry date, recovery after expiry, 402 and 401 errors, and no refunds.
Cloud Server Billing and Rules
Terms and price, automatic renewal, the 1-day trial, refund rules, the acceptable use policy, payment and balance, and changing the line or size.
Payment Methods Overview
Every payment method the QCode.cc top-up page offers, which currency each one runs in, what it costs in fees, who it suits, and how corporate bank transfer fits in
Enterprise Team Guide
The complete guide to the QCode Enterprise Team plan — dedicated domain, sub-key management, ban protection, multi-tool support, team deployment and security
Crypto Payment Guide
Top up QCode.cc with USDT / USDC / BTC and 6 more coins: picking the network, memos, minimum deposits, and what to do when funds do not arrive
Claude Code Feature Availability
Which Claude Code features work with a QCode API key and which do not — each row labelled as measured or inferred
Partner Open API Guide
Once you are an approved QCode partner, manage your reseller account programmatically with an access token: check balance and usage, create and toggle the sub API Keys you resell. Covers the prerequisite, how to apply, auth, endpoint reference, rate limits and security.
🔥 Trending this week (last 7 days)
🆕 Recently updated
💬 Still stuck?
Answers Claude Code & Codex questions based on the QCode docs
- How do I install Claude Code?
- How to configure environment variables?
- How do I choose between Pay-as-you-go Packs and a personal plan?