-
Notifications
You must be signed in to change notification settings - Fork 6.4k
Open
Labels
CLIIssues related to the Codex CLIIssues related to the Codex CLIbugSomething isn't workingSomething isn't workingcustom-modelIssues related to custom model providers (including local models)Issues related to custom model providers (including local models)tool-callsIssues related to tool callingIssues related to tool calling
Description
What version of Codex is running?
0.59 to 0.61
What subscription do you have?
plus
Which model were you using?
gpt-5
What platform is your computer?
Darwin 24.6.0 arm64 arm
What issue are you seeing?
Our working environment requires us to access all gpt models through our central internal proxy server, and this server only support chat completion API. Thus, I'm using codex with chat completion mode with our interall proxy API to access the gpt-5 model, after upgrade to version >= 0.59, codex no longer works.
As we ran into error related to tool calls (this error is from 0.61, other version had similar error):
unexpected status 400 Bad Request: {"error":{"code":null,"message":"An assistant message with 'tool_calls' must be followed by tool messages
responding to each 'tool_call_id'. The following tool_call_ids did not have response messages: call_F5k9261v7RiXieQiIKHYARcl","param":"messages.
[5].role","type":"invalid_request_error"}}
Already switched versions between 0.59 to 0.61, but none of it works. Right now the only working version is 0.58.
These are the config file in ~/.codex/config.toml:
[profiles.custom_provider]
model = "gpt-5"
model_provider = "custom provider"
model_reasoning_effort = "high"
forced_login_method = "api"
[model_providers.custom_provider]
name = "Internal LLM Proxy"
base_url = "http://xxxxx:8080/v1"
wire_api = "chat"
env_key = "XXX_OPENAI_API_KEY"
What steps can reproduce the bug?
launch codex (>=0.59) with custom chat completion api
What is the expected behavior?
No response
Additional information
No response
reppy4620, iharryli and 211211jakobjs
Metadata
Metadata
Assignees
Labels
CLIIssues related to the Codex CLIIssues related to the Codex CLIbugSomething isn't workingSomething isn't workingcustom-modelIssues related to custom model providers (including local models)Issues related to custom model providers (including local models)tool-callsIssues related to tool callingIssues related to tool calling