Crazyrouter API Document
🇺🇸 English
  • 中文
  • 🇺🇸 English
🇺🇸 English
  • 中文
  • 🇺🇸 English
🇺🇸 English
  • 中文
  • 🇺🇸 English
API 参考快速开始接入教程
官网模型与价格控制台
API 参考快速开始接入教程
官网模型与价格控制台
  1. 接入教程
  • Codex
  • N8N
  • Gemini CLI
  • Claude Code Installation and Usage Guide
  • CherryStudio Configuration Guide
  • dify Configuration Guide
  • cline
  • aider
  • Cursor
  • lobechat
  • ChatBox
  • gpt_academic
  • nextchat
  • zotero gpt
  • CLAUDE DEV
  • ChatGPT Sidebar
  • chatgpt-on-wechat
  • chatgpt GPT Academic
  • RikkaHub
  • Coze Workflow Configuration Guide
  1. 接入教程

Codex

Codex Installation and Configuration Guide#


Windows Tutorial#

System Requirements#

Windows 10 or Windows 11
Node.js 22+
npm 10+
Network connection

Installation Steps#

Prerequisites!!!
Install Git Bash by visiting Git - Downloads to download the version for your system, then click "Next" through the installation process.
1. Install Node.js
Visit the Node.js Official Website to download and install the latest LTS version.
2. Install codex
Open Command Prompt (CMD) or PowerShell, and run:
3. Verify Installation
Open Command Prompt (CMD) or PowerShell, and run:

Configure API#

1. Obtain Auth Token
Visit the Crazyrouter website and perform the following:
Click Console → API Tokens page
Click Add Token
Token group
Token name: Any name you prefer
Quota recommendation: Set to Unlimited
Keep other options as default
image.png
2. Configuration Files
Important: Replace sk-xxx below with your actual API key generated from Crazyrouter!
Important: Replace sk-xxx below with your actual API key generated from Crazyrouter!
Important: Replace sk-xxx below with your actual API key generated from Crazyrouter!
1.
Navigate to the .codex folder in your user directory, e.g., C:\Users\testuser\.codex.
(Note: If you cannot see this directory, you haven't enabled "Show hidden items" in Windows. Please enable it in File Explorer first.)
image.png
2.
If the .codex folder doesn't exist, manually create it, then create two files inside: config.toml and auth.json.
image.png
3. Fill in the configuration (replace sk-xxx with your actual SK).
a. Configuration in auth.json:
{"OPENAI_API_KEY": "sk-xxx"}
b. Configuration in config.toml (just paste the content below):
model_reasoning_effort options are high, medium, low, representing the model's thinking effort level.
model_provider = "api111"
model = "gpt-5-codex"
model_reasoning_effort = "high"
disable_response_storage = true
preferred_auth_method = "apikey"

[model_providers.api111]
name = "api111"
base_url = "https://api.crazyrouter.com/v1"
wire_api = "responses"

Launch codex#

Restart your terminal! Restart your terminal! Restart your terminal!
Then navigate to your project directory:
Run the following command to start:
image.png

VSCode codex Extension#

After completing the above configuration, search for and install codex in the VSCode Extension Marketplace.
image.png
Once installed, it will appear in the sidebar.

image.png#

Mac Tutorial#

System Requirements#

macOS 12 or higher
Node.js 22+
npm 10+
Network connection

Installation Steps#

1. Install Node.js
Option 1: Visit the Node.js Official Website to download and install the latest LTS version.
Option 2: Use Homebrew (Recommended)
2. Install codex
Open Terminal and run (may require sudo):
3. Verify Installation
Open Terminal and run:

Configure API#

1. Obtain Auth Token
Visit the Crazyrouter website and perform the following:
Click Console → API Tokens page
Click Add Token
Token group: Select codex-special (you must select this group, otherwise it won't work)
Token name: Any name you prefer
Quota recommendation: Set to Unlimited
Keep other options as default
image.png
2. Configuration Files
Important: Replace sk-xxx below with your actual API key generated from Crazyrouter!
Important: Replace sk-xxx below with your actual API key generated from Crazyrouter!
Important: Replace sk-xxx below with your actual API key generated from Crazyrouter!
1.
Create directory and files:
2.
Edit the auth.json file:
Press i to enter insert mode, paste the following content (replace sk-xxx with your key), then press ESC, type :wq and press Enter to save and exit.
{"OPENAI_API_KEY": "sk-xxx"}
3.
Edit the config.toml file:
Press i to enter insert mode, paste the following content, then press ESC, type :wq and press Enter to save and exit.
model_provider = "api111"
model = "gpt-5-codex"
model_reasoning_effort = "high"
disable_response_storage = true
preferred_auth_method = "apikey"

[model_providers.api111]
name = "api111"
base_url = "https://api.crazyrouter.com/v1"
wire_api = "responses"

Launch codex#

Restart your terminal! Restart your terminal! Restart your terminal!
Then navigate to your project directory:
Run the following command to start:
[Image]

VSCode codex Extension#

After completing the above configuration, search for and install codex in the VSCode Extension Marketplace.
[Image]
Once installed, it will appear in the sidebar.
[Image]

Linux Tutorial#

System Requirements#

Major Linux distributions (Ubuntu 20.04+, Debian 10+, CentOS 7+, etc.)
Node.js 22+
npm 10+
Network connection

Installation Steps#

1. Install Node.js
Ubuntu/Debian
CentOS/RHEL/Fedora
Arch Linux
2. Install codex
Open Terminal and run:
3. Verify Installation
Open Terminal and run:

Configure API#

1. Obtain Auth Token
Visit the Crazyrouter website and perform the following:
Click Console → API Tokens page
Click Add Token
Token group: Select codex-channel-gpt (you must select this group, otherwise it won't work)
Token name: Any name you prefer
Quota recommendation: Set to Unlimited
Keep other options as default
[Image]
2. Configuration Files
Important: Replace sk-xxx below with your actual API key generated from Crazyrouter!
Important: Replace sk-xxx below with your actual API key generated from Crazyrouter!
Important: Replace sk-xxx below with your actual API key generated from Crazyrouter!
1.
Create directory and files:
2.
Edit the auth.json file:
Press i to enter insert mode, paste the following content (replace sk-xxx with your key), then press ESC, type :wq and press Enter to save and exit.
{"OPENAI_API_KEY": "sk-xxx"}
3.
Edit the config.toml file:
Press i to enter insert mode, paste the following content, then press ESC, type :wq and press Enter to save and exit.
model_provider = "api111"
model = "gpt-5-codex"
model_reasoning_effort = "high"
disable_response_storage = true
preferred_auth_method = "apikey"

[model_providers.api111]
name = "api111"
base_url = "https://api.crazyrouter.com/v1"
wire_api = "responses"

Launch codex#

Restart your terminal! Restart your terminal! Restart your terminal!
Then navigate to your project directory:
Run the following command to start:
image.png

VSCode codex Extension#

After completing the above configuration, search for and install codex in the VSCode Extension Marketplace.
image.png
Once installed, it will appear in the sidebar.

image.png#

FAQ#

If you encounter errors, troubleshoot with the following steps:
1.
Confirm the API Key was created correctly: Set quota to Unlimited, don't restrict models, and select codex-channel-gpt as the group.
For more codex configuration and usage details, please refer to the official codex tutorial.

Last verified/modified: 2026-09-28 (API base URL unified to https://api.crazyrouter.com, 3 occurrence(s); account/console stays https://crazyrouter.com)
Modified at 2026-09-28 12:50:39
Next
N8N
Built with