1. 4. Common Client Configuration
DMC GATEWAY DOCS EN
  • Welcome
  • 1. Quick Start Guide
    • Registration & Login
    • Token Management
    • Account Settings
    • Pricing
    • Quota & Top-up
  • 3. Developer Code Integration
    • Native OpenAI Format
      • Chat Completions Format
      • Responses Format
    • Native Claude Format
      POST
  • 4. Common Client Configuration
    • OpenCode Configuration Guide
    • OpenAI Codex Installation & Configuration Guide
    • AnythingLLM Configuration Guide
    • Claude Code Configuration Guide
    • TypingMind Configuration Guide
    • n8n Configuration Guide
    • OpenClaw Installation & Configuration Guide
    • Hermes Agent Configuration Guide
  • 6. Troubleshooting
    • Common Misconceptions
    • Common Usage FAQ
  1. 4. Common Client Configuration

OpenAI Codex Installation & Configuration Guide

📌
Only response port models can use Codex!!
image.png

Windows Tutorial#

System Requirements#

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

Installation Steps#

Prerequisites!!!
Install Git Bash. Please visit Git - Downloads to download the version for your operating system, then keep clicking "Next" to complete the installation.
1. Install Node.js
Visit Node.js Official Website to download and install the latest LTS version.
2. Install Codex
Open Command Prompt (CMD) or PowerShell and run:
image.png
3. Verify Installation
Open Command Prompt (CMD) or PowerShell and run:
image.png

Configure DMC API Method#

1. Configuration File
1.
Navigate to the .codex folder in the current user's directory, for example: C:\Users\testuser\.codex.
2.
image.png
Note: If you cannot see this directory, you have not enabled "Show hidden items" in Windows File Explorer. Please enable it first.
3.
If there is no .codex folder, manually create it, then create two files: config.toml and auth.json.
4.
image.png
5.
Fill in Configuration (replace sk-xxxxxxxxxxxxxxxxxxxx with your DMC token).
a. Configuration in auth.json:
{"OPENAI_API_KEY": "sk-xxx"}
image.png
b. Configuration in config.toml (paste the following content directly):
model_reasoning_effort optional values are high, medium, low, representing the model's thinking effort level.
model_provider = "Doubao-Seed-2.0-Code"
model = "Doubao-Seed-2.0-Code"
model_reasoning_effort = "high"
disable_response_storage = true

[model_providers.Doubao-Seed-2.0-Code]
name = "DMC"
base_url = "https://dmc.cc/v1"
wire_api = "responses"
image.png

Close the terminal and start Codex again#

Navigate to your project directory:#

Run the following command to start:#


VSCode Extension Codex#

After completing the above configuration, search for and install codex in the VSCode extension store.
After installation, it will appear in the sidebar.

Mac Tutorial#

System Requirements#

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

Installation Steps#

1. Install Codex
Open Terminal and run (may require sudo):
Verify installation: Open Terminal and run:

Configure API#

Configuration File
1.
Create directory and files:
2.
Edit auth.json file:
Press i to enter insert mode, paste the following content (replace sk-xxx with your DMC token), then press ESC, type :wq and press Enter to save and exit.
{"OPENAI_API_KEY": "sk-xxx"}
3.
Edit 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 = "DMC"
model = "deepseek"
model_reasoning_effort = "high"
disable_response_storage = true
preferred_auth_method = "apikey"

[model_providers.DMC]
name = "DMC"
base_url = "https://dmc.cc/v1"
wire_api = "responses"

Restart terminal and start Codex again#

Navigate to your project directory:
Start Codex:

Linux Tutorial#

System Requirements#

Mainstream 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:
Verify installation: Open Terminal and run:

Linux Codex Configure DMC#

Configuration File
1.
Create directory and files:
2.
Edit 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 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 = "DMC"
model = "deepseek"
model_reasoning_effort = "high"
disable_response_storage = true
preferred_auth_method = "apikey"

[model_providers.DMC]
name = "DMC"
base_url = "https://dmc.cc/v1"
wire_api = "responses"

Start Codex#

Restart terminal! Restart terminal! Restart terminal!
Then navigate to your project directory:
Run the following command to start:
修改于 2026-05-14 12:57:21
上一页
OpenCode Configuration Guide
下一页
AnythingLLM Configuration Guide
Built with