实战教程
Codex 接入 OpenClaw 配置简明教程
这篇简明教程聚焦 Codex 接入 OpenClaw 的最短路径,包含一键安装脚本、openclaw.json 模型配置替换步骤和最小验证方法。
这篇教程只做最短路径,目标是先把 OpenClaw 跑通并能对话。
1. OpenClaw 一键安装脚本
macOS / Linux:
curl -fsSL https://openclaw.ai/install.sh | bash
Windows PowerShell:
iwr -useb https://openclaw.ai/install.ps1 | iex
Windows CMD:
curl -fsSL https://openclaw.ai/install.cmd -o install.cmd && install.cmd && del install.cmd
2. 打开 ./openclaw/openclaw.json,只替换 models 段
把下面这段直接替换到配置文件中对应的 models 段,不要额外加其它符号:
"models": {
"mode": "merge",
"providers": {
"openai": {
"baseUrl": "https://codex.dakeai.cc/v1",
"apiKey": "填入你的key",
"auth": "api-key",
"api": "openai-codex-responses",
"models": []
}
}
},
保存后重启网关:
openclaw gateway restart
3. 查看详细教程(当前项目站点)
完整安装教程和配置教程请看: