Skip to main content

Crate codex_http_client

Crate codex_http_client 

Source

Structs§

EncodedJsonBody
A JSON request body serialized once into reference-counted bytes.
HttpClient
Reusable HTTP client wrapper with shared tracing and request-diagnostic behavior.
HttpClientBuilder
Configures an HttpClient without exposing the underlying HTTP implementation.
HttpClientFactory
Builds route-specific HTTP clients using one resolved outbound proxy policy.
PreparedRequestBody
Request
RequestBuilder
ReqwestTransport
Response
RouteAwareClientPool
Reuses transport clients by resolved route while selecting a route for every request URL.
RouteAwareRequestBuilder
StreamResponse

Enums§

BuildCustomCaTransportError
Describes why a transport using shared custom CA support could not be constructed.
BuildRouteAwareHttpClientError
Error while building a resolver-aware reqwest client.
ClientRouteClass
Coarse semantic bucket for the HTTP or WebSocket client being constructed.
OutboundProxyPolicy
Resolved outbound proxy behavior for HTTP clients.
OutboundProxyRoute
Resolved proxy route for a concrete outbound destination.
RequestBody
RequestCompression
RouteAwareClientPoolError
Error returned when selecting a route or constructing its pooled HTTP client.
RouteAwareRequestError
Error returned while building, routing, or sending a route-aware request.
RouteFailureClass
Coarse failure class for route selection errors.
StreamError
TransportError

Traits§

HttpTransport

Functions§

build_reqwest_client_with_custom_ca
Builds a reqwest client that honors Codex custom CA environment variables.
build_rustls_client_config_with_custom_ca
Builds a rustls client config using native roots and any configured Codex custom CA bundle.
is_allowed_chatgpt_host
Returns whether host is one of the ChatGPT hosts Codex is allowed to treat as first-party ChatGPT HTTP traffic.
maybe_build_rustls_client_config_with_custom_ca
Builds a rustls client config when a Codex custom CA bundle is configured.
with_chatgpt_cloudflare_cookie_store
Adds the process-local ChatGPT Cloudflare cookie jar used by Codex HTTP clients.

Type Aliases§

ByteStream
HttpError
HttpResponse