Skip to content

fix(responses): preserve Codex client metadata - #584

Open
Jeadie wants to merge 1 commit into
64bit:mainfrom
spiceai:fix/codex-client-metadata
Open

fix(responses): preserve Codex client metadata#584
Jeadie wants to merge 1 commit into
64bit:mainfrom
spiceai:fix/codex-client-metadata

Conversation

@Jeadie

@Jeadie Jeadie commented Aug 13, 2026

Copy link
Copy Markdown

OpenAI Codex includes request metadata in v1/responses under client_metadata.

For example:

{
  "client_metadata": {
    "x-codex-installation-id": "...",
    "thread_id": "...",
    "session_id": "...",
    "x-codex-window-id": "...",
    "turn_id": "...",
    "x-codex-turn-metadata": "..."
  }
}

Preserve this metadata in the typed Responses request so gateways can forward it. Add a serde roundtrip test covering all Codex metadata fields.

This is backwards compatible: the field is optional, and requests that do not include Codex metadata are unchanged.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant