Files
codex/codex-rs/http-client/Cargo.toml
T
Adam Perry @ OpenAI 55ea9a4620 Standardize response request IDs across Codex clients (#65135)
## Why

Different response paths recognize different request ID headers, so
diagnostics can lose the ID needed to correlate a failed request. For
example, an Azure response may carry only `x-ms-request-id`.

## What changed

Use `CodexHeaderMap` to share response header parsing across API clients,
OAuth errors, and response debug context. When a caller needs one
request ID, fall back to the next supported header if the preferred
value is missing, empty, or unreadable.

Preserve recognized request ID headers on Responses WebSocket
handshakes. Use a shared summary for remote control errors and tracing,
omitting sensitive, empty, unreadable, and unrelated values.

## Testing

Cover fallback from an empty or unreadable primary ID, Azure-only debug
context, filtering in diagnostic summaries, and preservation of request
IDs in WebSocket handshakes and remote control pairing errors.

GitOrigin-RevId: f728a4a867f4705b784916b331f413e560f8626b
2026-12-02 01:44:46 +00:00

61 lines
1.8 KiB
TOML

[package]
edition.workspace = true
license.workspace = true
name = "codex-http-client"
version.workspace = true
[dependencies]
bytes = { workspace = true }
codex-utils-rustls-provider = { workspace = true }
futures = { workspace = true }
http = { workspace = true }
http-body = "1.0.1"
httpdate = { workspace = true }
native-tls = "0.2"
opentelemetry = { workspace = true }
ref-cast = "1.0.25"
reqwest = { workspace = true, features = ["gzip", "json", "rustls-tls", "rustls-tls-native-roots", "stream", "zstd"] }
rustls = { workspace = true }
rustls-native-certs = { workspace = true }
rustls-pki-types = { workspace = true }
serde = { workspace = true, features = ["derive"] }
serde_json = { workspace = true }
serde_urlencoded = "0.7"
sha2 = { workspace = true }
thiserror = { workspace = true }
tokio = { workspace = true, features = ["macros", "rt", "time", "sync"] }
tracing = { workspace = true }
tracing-opentelemetry = { workspace = true }
url = { workspace = true }
zstd = { workspace = true }
[target.'cfg(target_os = "macos")'.dependencies]
system-configuration = { workspace = true }
[target.'cfg(target_os = "windows")'.dependencies]
curl = { version = "0.4.50", features = ["static-curl", "ntlm"] }
rustls-platform-verifier = "0.7.0"
socket2 = "0.6"
tokio = { workspace = true, features = ["io-util", "net"] }
tokio-rustls = { workspace = true }
url = { workspace = true }
windows-sys = { workspace = true, features = [
"Win32_Foundation",
"Win32_Networking_WinHttp",
] }
[lints]
workspace = true
[dev-dependencies]
codex-utils-cargo-bin = { workspace = true }
opentelemetry_sdk = { workspace = true }
pretty_assertions = { workspace = true }
rcgen = { workspace = true }
tempfile = { workspace = true }
tokio = { workspace = true, features = ["test-util"] }
tracing-subscriber = { workspace = true }
[lib]
doctest = false