{"record":{"id":"e8fbd7f9b70777b1","repo":"openai/codex","slug":"failed-to-send-openai-file-request-to-url-sour","errorCode":null,"errorMessage":"failed to send OpenAI file request to {url}: {source}","messagePattern":"failed to send OpenAI file request to (.+?): (.+?)","errorType":"exception","errorClass":"OpenAiFileError","httpStatus":null,"severity":"error","filePath":"codex-rs/codex-api/src/files.rs","lineNumber":52,"sourceCode":"    pub file_id: String,\n    pub uri: String,\n    pub download_url: String,\n    pub file_name: String,\n    pub file_size_bytes: u64,\n    pub mime_type: Option<String>,\n}\n\n#[derive(Debug, thiserror::Error)]\npub enum OpenAiFileError {\n    #[error(\n        \"file `{file_name}` is too large: {size_bytes} bytes exceeds the limit of {limit_bytes} bytes\"\n    )]\n    FileTooLarge {\n        file_name: String,\n        size_bytes: u64,\n        limit_bytes: u64,\n    },\n    #[error(\"failed to send OpenAI file request to {url}: {source}\")]\n    Request {\n        url: String,\n        #[source]\n        source: RouteAwareRequestError,\n    },\n    #[error(\n        \"OpenAI file blob upload to {host} failed after {elapsed_ms} ms ({error_kind}, azure_client_request_id={azure_client_request_id}): {source}\"\n    )]\n    BlobUploadRequest {\n        host: String,\n        elapsed_ms: u128,\n        error_kind: &'static str,\n        azure_client_request_id: String,\n        #[source]\n        source: RouteAwareRequestError,\n    },\n    #[error(\n        \"OpenAI file blob upload to {host} failed with status {status} (azure_client_request_id={azure_client_request_id}, azure_request_id={azure_request_id}, azure_error_code={azure_error_code})\"","sourceCodeStart":34,"sourceCodeEnd":70,"githubUrl":"https://github.com/openai/codex/blob/339751715c64496cb86246bfb3935f40e309dd3d/codex-rs/codex-api/src/files.rs#L34-L70","documentation":"Error \"failed to send OpenAI file request to {url}: {source}\" thrown in openai/codex.","triggerScenarios":"Thrown at codex-rs/codex-api/src/files.rs:52 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":[],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"339751715c64496cb86246bfb3935f40e309dd3d","analyzedAt":"2026-08-25T05:35:09.876Z","schemaVersion":2},"datasetVersion":"2026-08-25T06:17:31.827Z"}