{"command":{"effect":"write","timeoutSeconds":120,"inputSchema":{"type":"object","description":"Compact a conversation. Returns a compacted response object.\n\nLearn when and how to compact long-running conversations in the [conversation state guide](https://developers.openai.com/api/docs/guides/conversation-state#managing-the-context-window). For ZDR-compatible compaction details, see [Compaction (advanced)](https://developers.openai.com/api/docs/guides/conversation-state#compaction-advanced).","properties":{"body":{"$ref":"#/definitions/CompactResponseMethodPublicBody"}},"required":[],"additionalProperties":false,"definitions":{"CompactResponseMethodPublicBody":{"properties":{"model":{"$ref":"#/definitions/ModelIdsCompaction"},"input":{"anyOf":[{"oneOf":[{"type":"string","maxLength":10485760,"description":"A text input to the model, equivalent to a text input with the `user` role."},{"items":{"$ref":"#/definitions/InputItem"},"type":"array","maxItems":131072,"description":"A list of one or many input items to the model, containing different content types."}],"description":"Text, image, or file inputs to the model, used to generate a response"},{"type":"null"}]},"previous_response_id":{"anyOf":[{"type":"string","description":"The unique ID of the previous response to the model. Use this to create multi-turn conversations. Learn more about [conversation state](https://developers.openai.com/api/docs/guides/conversation-state). Cannot be used in conjunction with `conversation`.","examples":["resp_123"]},{"type":"null"}]},"instructions":{"anyOf":[{"type":"string","description":"A system (or developer) message inserted into the model's context.\nWhen used along with `previous_response_id`, the instructions from a previous response will not be carried over to the next response. This makes it simple to swap out system (or developer) messages in new responses."},{"type":"null"}]},"prompt_cache_key":{"anyOf":[{"type":"string","maxLength":64,"description":"A key to use when reading from or writing to the prompt cache."},{"type":"null"}]},"prompt_cache_retention":{"anyOf":[{"allOf":[{"$ref":"#/definitions/PromptCacheRetentionEnum"},{}]},{"type":"null"}]},"prompt_cache_options":{"anyOf":[{"$ref":"#/definitions/PromptCacheOptionsParam"},{"type":"null"}]},"service_tier":{"anyOf":[{"$ref":"#/definitions/ServiceTierEnum"},{"type":"null"}]}},"type":"object","required":["model"]},"ModelIdsCompaction":{"anyOf":[{"$ref":"#/definitions/ModelIdsResponses"},{"type":"string"},{"type":"null"}],"description":"Model ID used to generate the response, like `gpt-6-astra`. OpenAI offers a wide range of models with different capabilities, performance characteristics, and price points. Refer to the [model guide](https://developers.openai.com/api/docs/models) to browse and compare available models."},"InputItem":{"oneOf":[{"$ref":"#/definitions/EasyInputMessage"},{"allOf":[{"$ref":"#/definitions/Item"},{"type":"object","title":"Item"}]},{"$ref":"#/definitions/CompactionTriggerItemParam"},{"$ref":"#/definitions/ItemReferenceParam"},{"$ref":"#/definitions/ProgramItemParam"},{"$ref":"#/definitions/ProgramOutputItemParam"}]},"PromptCacheRetentionEnum":{"type":"string","enum":["in_memory","24h"]},"PromptCacheOptionsParam":{"properties":{"ttl":{"$ref":"#/definitions/PromptCacheTTLEnum"},"mode":{"$ref":"#/definitions/PromptCacheModeEnum"}},"type":"object","required":[],"title":"Prompt cache options","description":"Options for prompt caching. Supported for `gpt-5.6` and later models. By default, OpenAI automatically chooses one implicit cache breakpoint. You can add explicit breakpoints to content blocks with `prompt_cache_breakpoint`. Each request can write up to four breakpoints. For cache matching, OpenAI considers up to the latest 80 breakpoints in the conversation, without a content-block lookback limit. Set `mode` to `explicit` to disable the implicit breakpoint. The `ttl` defaults to `30m`, which is currently the only supported value. See the [prompt caching guide](https://developers.openai.com/api/docs/guides/prompt-caching) for current details."},"ServiceTierEnum":{"type":"string","enum":["auto","default","fast","flex","priority"]},"ModelIdsResponses":{"anyOf":[{"$ref":"#/definitions/ModelIdsShared"},{"type":"string","title":"ResponsesOnlyModel","enum":["o1-pro","o1-pro-2025-03-19","o3-pro","o3-pro-2025-06-10","o3-deep-research","o3-deep-research-2025-06-26","o4-mini-deep-research","o4-mini-deep-research-2025-06-26","computer-use-preview","computer-use-preview-2025-03-11","gpt-5.5-pro","gpt-5.5-pro-2026-04-23","gpt-5-codex","gpt-5-pro","gpt-5-pro-2025-10-06","gpt-5.1-codex-max","gpt-daybreak-blue-latest","gpt-daybreak-red-latest","gpt-5.6-cyber","gpt-rosalind-research"]}],"examples":["gpt-6-astra"]},"EasyInputMessage":{"type":"object","title":"Input message","description":"A message input to the model with a role indicating instruction following\nhierarchy. Instructions given with the `developer` or `system` role take\nprecedence over instructions given with the `user` role. Messages with the\n`assistant` role are presumed to have been generated by the model in previous\ninteractions.\n","properties":{"role":{"type":"string","description":"The role of the message input. One of `user`, `assistant`, `system`, or\n`developer`.\n","enum":["user","assistant","system","developer"]},"content":{"description":"Text, image, or audio input to the model, used to generate a response.\nCan also contain previous assistant responses.\n","oneOf":[{"type":"string","title":"Text input","description":"A text input to the model.\n"},{"$ref":"#/definitions/InputMessageContentList"}]},"phase":{"anyOf":[{"$ref":"#/definitions/MessagePhase"},{"type":"null"}]},"type":{"type":"string","description":"The type of the message input. Always `message`.\n","enum":["message"]}},"required":["role","content"]},"Item":{"type":"object","description":"Content item used to generate a response.\n","oneOf":[{"$ref":"#/definitions/InputMessage"},{"$ref":"#/definitions/OutputMessage"},{"$ref":"#/definitions/FileSearchToolCall"},{"$ref":"#/definitions/ComputerToolCall"},{"$ref":"#/definitions/ComputerCallOutputItemParam"},{"$ref":"#/definitions/WebSearchToolCall"},{"$ref":"#/definitions/FunctionToolCall"},{"$ref":"#/definitions/FunctionCallOutputItemParam"},{"$ref":"#/definitions/ToolSearchCallItemParam"},{"$ref":"#/definitions/ToolSearchOutputItemParam"},{"$ref":"#/definitions/AdditionalToolsItemParam"},{"$ref":"#/definitions/ResponseConfigurationUpdateItemParam"},{"$ref":"#/definitions/ReasoningItem"},{"$ref":"#/definitions/CompactionSummaryItemParam"},{"$ref":"#/definitions/ImageGenToolCall"},{"$ref":"#/definitions/CodeInterpreterToolCall"},{"$ref":"#/definitions/LocalShellToolCall"},{"$ref":"#/definitions/LocalShellToolCallOutput"},{"$ref":"#/definitions/FunctionShellCallItemParam"},{"$ref":"#/definitions/FunctionShellCallOutputItemParam"},{"$ref":"#/definitions/ApplyPatchToolCallItemParam"},{"$ref":"#/definitions/ApplyPatchToolCallOutputItemParam"},{"$ref":"#/definitions/MCPListTools"},{"$ref":"#/definitions/MCPApprovalRequest"},{"$ref":"#/definitions/MCPApprovalResponse"},{"$ref":"#/definitions/MCPToolCall"},{"$ref":"#/definitions/CustomToolCallOutput"},{"$ref":"#/definitions/CustomToolCall"}]},"CompactionTriggerItemParam":{"properties":{"id":{"anyOf":[{"type":"string","description":"The unique ID of this compaction trigger.","examples":["msg_123"]},{"type":"null"}]},"type":{"type":"string","enum":["compaction_trigger"],"description":"The type of the item. Always `compaction_trigger`.","default":"compaction_trigger"}},"type":"object","required":["type"],"title":"Compaction trigger","description":"Compacts the current context. Must be the final input item."},"ItemReferenceParam":{"properties":{"type":{"anyOf":[{"type":"string","enum":["item_reference"],"description":"The type of item to reference. Always `item_reference`.","default":"item_reference"},{"type":"null"}]},"id":{"type":"string","description":"The ID of the item to reference."}},"type":"object","required":["id"],"title":"Item reference","description":"An internal identifier for an item to reference."},"ProgramItemParam":{"properties":{"id":{"type":"string","description":"The unique ID of this program item.","examples":["cm_123"]},"type":{"type":"string","enum":["program"],"description":"The item type. Always `program`.","default":"program"},"call_id":{"type":"string","maxLength":64,"minLength":1,"description":"The stable call ID of the program item."},"code":{"type":"string","maxLength":10485760,"description":"The JavaScript source executed by programmatic tool calling."},"fingerprint":{"type":"string","maxLength":10485760,"description":"Opaque program replay fingerprint that must be round-tripped."}},"type":"object","required":["id","type","call_id","code","fingerprint"]},"ProgramOutputItemParam":{"properties":{"id":{"type":"string","description":"The unique ID of this program output item.","examples":["cmo_123"]},"type":{"type":"string","enum":["program_output"],"description":"The item type. Always `program_output`.","default":"program_output"},"call_id":{"type":"string","maxLength":64,"minLength":1,"description":"The call ID of the program item."},"result":{"type":"string","maxLength":10485760,"description":"The result produced by the program item."},"status":{"$ref":"#/definitions/ProgramOutputItemStatus"}},"type":"object","required":["id","type","call_id","result","status"]},"PromptCacheTTLEnum":{"type":"string","enum":["30m"]},"PromptCacheModeEnum":{"type":"string","enum":["implicit","explicit"]},"ModelIdsShared":{"anyOf":[{"type":"string"},{"type":"string","enum":["gpt-6-astra","gpt-6.1-sol","gpt-6.1-terra","gpt-6-sol","gpt-6-luna","gpt-5.6-sol","gpt-5.6-terra","gpt-5.6-luna","gpt-5.5","gpt-5.5-2026-04-23","gpt-5.4","gpt-5.4-mini","gpt-5.4-nano","gpt-5.4-mini-2026-03-17","gpt-5.4-nano-2026-03-17","gpt-5.3-chat-latest","gpt-5.2","gpt-5.2-2025-12-11","gpt-5.2-chat-latest","gpt-5.2-pro","gpt-5.2-pro-2025-12-11","gpt-5.1","gpt-5.1-2025-11-13","gpt-5.1-codex","gpt-5.1-mini","gpt-5.1-chat-latest","gpt-5","gpt-5-mini","gpt-5-nano","gpt-5-2025-08-07","gpt-5-mini-2025-08-07","gpt-5-nano-2025-08-07","gpt-5-chat-latest","gpt-4.1","gpt-4.1-mini","gpt-4.1-nano","gpt-4.1-2025-04-14","gpt-4.1-mini-2025-04-14","gpt-4.1-nano-2025-04-14","o4-mini","o4-mini-2025-04-16","o3","o3-2025-04-16","o3-mini","o3-mini-2025-01-31","o1","o1-2024-12-17","o1-preview","o1-preview-2024-09-12","o1-mini","o1-mini-2024-09-12","gpt-4o","gpt-4o-2024-11-20","gpt-4o-2024-08-06","gpt-4o-2024-05-13","gpt-audio-mini","gpt-audio-mini-2025-12-15","gpt-4o-audio-preview","gpt-4o-audio-preview-2024-10-01","gpt-4o-audio-preview-2024-12-17","gpt-4o-audio-preview-2025-06-03","gpt-4o-mini-audio-preview","gpt-4o-mini-audio-preview-2024-12-17","gpt-4o-search-preview","gpt-4o-mini-search-preview","gpt-4o-search-preview-2025-03-11","gpt-4o-mini-search-preview-2025-03-11","chatgpt-4o-latest","codex-mini-latest","gpt-4o-mini","gpt-4o-mini-2024-07-18","gpt-4-turbo","gpt-4-turbo-2024-04-09","gpt-4-0125-preview","gpt-4-turbo-preview","gpt-4-1106-preview","gpt-4-vision-preview","gpt-4","gpt-4-0314","gpt-4-0613","gpt-4-32k","gpt-4-32k-0314","gpt-4-32k-0613","gpt-3.5-turbo","gpt-3.5-turbo-16k","gpt-3.5-turbo-0301","gpt-3.5-turbo-0613","gpt-3.5-turbo-1106","gpt-3.5-turbo-0125","gpt-3.5-turbo-16k-0613"]}],"examples":["gpt-6-astra"]},"InputMessageContentList":{"type":"array","title":"Input item content list","description":"A list of one or many input items to the model, containing different content \ntypes.\n","items":{"$ref":"#/definitions/InputContent"}},"MessagePhase":{"type":"string","description":"Labels an `assistant` message as intermediate commentary (`commentary`) or the final answer (`final_answer`).\nFor models like `gpt-5.3-codex` and beyond, when sending follow-up requests, preserve and resend\nphase on all assistant messages — dropping it can degrade performance. Not used for user messages.\n","enum":["commentary","final_answer"]},"InputMessage":{"type":"object","title":"Input message","description":"A message input to the model with a role indicating instruction following\nhierarchy. Instructions given with the `developer` or `system` role take\nprecedence over instructions given with the `user` role.\n","properties":{"type":{"type":"string","description":"The type of the message input. Always set to `message`.\n","enum":["message"]},"role":{"type":"string","description":"The role of the message input. One of `user`, `system`, or `developer`.\n","enum":["user","system","developer"]},"status":{"type":"string","description":"The status of item. One of `in_progress`, `completed`, or\n`incomplete`. Populated when items are returned via API.\n","enum":["in_progress","completed","incomplete"]},"content":{"$ref":"#/definitions/InputMessageContentList"}},"required":["role","content"]},"OutputMessage":{"type":"object","title":"Output message","description":"An output message from the model.\n","properties":{"id":{"type":"string","description":"The unique ID of the output message.\n"},"type":{"type":"string","description":"The type of the output message. Always `message`.\n","enum":["message"]},"role":{"type":"string","description":"The role of the output message. Always `assistant`.\n","enum":["assistant"]},"content":{"type":"array","description":"The content of the output message.\n","items":{"$ref":"#/definitions/OutputMessageContent"}},"phase":{"anyOf":[{"$ref":"#/definitions/MessagePhase"},{"type":"null"}]},"status":{"type":"string","description":"The status of the message input. One of `in_progress`, `completed`, or\n`incomplete`. Populated when input items are returned via API.\n","enum":["in_progress","completed","incomplete"]}},"required":["id","type","role","content","status"]},"FileSearchToolCall":{"type":"object","title":"File search tool call","description":"The results of a file search tool call. See the\n[file search guide](https://developers.openai.com/api/docs/guides/tools-file-search) for more information.\n","properties":{"id":{"type":"string","description":"The unique ID of the file search tool call.\n"},"type":{"type":"string","enum":["file_search_call"],"description":"The type of the file search tool call. Always `file_search_call`.\n"},"status":{"type":"string","description":"The status of the file search tool call. One of `in_progress`,\n`searching`, `incomplete` or `failed`,\n","enum":["in_progress","searching","completed","incomplete","failed"]},"queries":{"type":"array","items":{"type":"string"},"description":"The queries used to search for files.\n"},"results":{"anyOf":[{"type":"array","description":"The results of the file search tool call.\n","items":{"type":"object","properties":{"file_id":{"type":"string","description":"The unique ID of the file.\n"},"text":{"type":"string","description":"The text that was retrieved from the file.\n"},"filename":{"type":"string","description":"The name of the file.\n"},"attributes":{"$ref":"#/definitions/VectorStoreFileAttributes"},"score":{"type":"number","description":"The relevance score of the file - a value between 0 and 1.\n"}}}},{"type":"null"}]}},"required":["id","type","status","queries"]},"ComputerToolCall":{"type":"object","title":"Computer tool call","description":"A tool call to a computer use tool. See the\n[computer use guide](https://developers.openai.com/api/docs/guides/tools-computer-use) for more information.\n","properties":{"type":{"type":"string","description":"The type of the computer call. Always `computer_call`.","enum":["computer_call"],"default":"computer_call"},"id":{"type":"string","description":"The unique ID of the computer call."},"call_id":{"type":"string","description":"An identifier used when responding to the tool call with output.\n"},"action":{"$ref":"#/definitions/ComputerAction"},"actions":{"$ref":"#/definitions/ComputerActionList"},"pending_safety_checks":{"type":"array","items":{"$ref":"#/definitions/ComputerCallSafetyCheckParam"},"description":"The pending safety checks for the computer call.\n"},"status":{"type":"string","description":"The status of the item. One of `in_progress`, `completed`, or\n`incomplete`. Populated when items are returned via API.\n","enum":["in_progress","completed","incomplete"]}},"required":["type","id","call_id","pending_safety_checks","status"]},"ComputerCallOutputItemParam":{"properties":{"id":{"anyOf":[{"type":"string","description":"The ID of the computer tool call output.","examples":["cuo_123"]},{"type":"null"}]},"call_id":{"type":"string","maxLength":64,"minLength":1,"description":"The ID of the computer tool call that produced the output."},"type":{"type":"string","enum":["computer_call_output"],"description":"The type of the computer tool call output. Always `computer_call_output`.","default":"computer_call_output"},"output":{"$ref":"#/definitions/ComputerScreenshotImage"},"acknowledged_safety_checks":{"anyOf":[{"items":{"$ref":"#/definitions/ComputerCallSafetyCheckParam"},"type":"array","description":"The safety checks reported by the API that have been acknowledged by the developer."},{"type":"null"}]},"status":{"anyOf":[{"$ref":"#/definitions/FunctionCallItemStatus"},{"type":"null"}]}},"type":"object","required":["call_id","type","output"],"title":"Computer tool call output","description":"The output of a computer tool call."},"WebSearchToolCall":{"type":"object","title":"Web search tool call","description":"The results of a web search tool call. See the\n[web search guide](https://developers.openai.com/api/docs/guides/tools-web-search) for more information.\n","properties":{"id":{"type":"string","description":"The unique ID of the web search tool call.\n"},"type":{"type":"string","enum":["web_search_call"],"description":"The type of the web search tool call. Always `web_search_call`.\n"},"status":{"$ref":"#/definitions/WebSearchCallStatus"},"action":{"type":"object","description":"An object describing the specific action taken in this web search call.\nIncludes details on how the model used the web (search, open_page, find_in_page).\n","oneOf":[{"$ref":"#/definitions/WebSearchActionSearch"},{"$ref":"#/definitions/WebSearchActionOpenPage"},{"$ref":"#/definitions/WebSearchActionFind"}]}},"required":["id","type","status"]},"FunctionToolCall":{"type":"object","title":"Function tool call","description":"A tool call to run a function. See the\n[function calling guide](https://developers.openai.com/api/docs/guides/function-calling) for more information.\n","properties":{"id":{"type":"string","description":"The unique ID of the function tool call.\n"},"type":{"type":"string","enum":["function_call"],"description":"The type of the function tool call. Always `function_call`.\n"},"call_id":{"type":"string","description":"The unique ID of the function tool call generated by the model.\n"},"caller":{"anyOf":[{"$ref":"#/definitions/ToolCallCaller"},{"type":"null"}]},"namespace":{"type":"string","description":"The namespace of the function to run.\n"},"name":{"type":"string","description":"The name of the function to run.\n"},"arguments":{"type":"string","description":"A JSON string of the arguments to pass to the function.\n"},"status":{"type":"string","description":"The status of the item. One of `in_progress`, `completed`, or\n`incomplete`. Populated when items are returned via API.\n","enum":["in_progress","completed","incomplete"]},"async":{"type":"boolean","description":"Whether the function tool call runs asynchronously.\n"}},"required":["type","call_id","name","arguments"]},"FunctionCallOutputItemParam":{"properties":{"id":{"anyOf":[{"type":"string","description":"The unique ID of the function tool call output. Populated when this item is returned via API.","examples":["fc_123"]},{"type":"null"}]},"call_id":{"anyOf":[{"type":"string","maxLength":64,"minLength":1,"description":"The unique ID of the function tool call generated by the model."},{"type":"null"}]},"type":{"type":"string","enum":["function_call_output"],"description":"The type of the function tool call output. Always `function_call_output`.","default":"function_call_output"},"output":{"oneOf":[{"type":"string","maxLength":10485760,"description":"A JSON string of the output of the function tool call."},{"items":{"oneOf":[{"$ref":"#/definitions/InputTextContentParam"},{"$ref":"#/definitions/InputImageContentParamAutoParam"},{"$ref":"#/definitions/InputFileContentParam"}],"description":"A piece of message content, such as text, an image, or a file."},"type":"array","description":"An array of content outputs (text, image, file) for the function tool call."}],"description":"Text, image, or file output of the function tool call."},"name":{"anyOf":[{"type":"string","maxLength":128,"minLength":1,"description":"The name of the tool that produced the output."},{"type":"null"}]},"namespace":{"anyOf":[{"type":"string","maxLength":64,"minLength":1,"pattern":"^[a-zA-Z0-9_-]+$","description":"The namespace of the tool that produced the output."},{"type":"null"}]},"caller":{"anyOf":[{"$ref":"#/definitions/ToolCallCallerParam"},{"type":"null"}]},"status":{"anyOf":[{"$ref":"#/definitions/FunctionCallItemStatus"},{"type":"null"}]}},"type":"object","required":["type","output"],"title":"Function tool call output","description":"The output of a function tool call."},"ToolSearchCallItemParam":{"properties":{"id":{"anyOf":[{"type":"string","description":"The unique ID of this tool search call.","examples":["tsc_123"]},{"type":"null"}]},"call_id":{"anyOf":[{"type":"string","maxLength":64,"minLength":1,"description":"The unique ID of the tool search call generated by the model."},{"type":"null"}]},"type":{"type":"string","enum":["tool_search_call"],"description":"The item type. Always `tool_search_call`.","default":"tool_search_call"},"execution":{"$ref":"#/definitions/ToolSearchExecutionType"},"arguments":{"$ref":"#/definitions/EmptyModelParam"},"status":{"anyOf":[{"$ref":"#/definitions/FunctionCallItemStatus"},{"type":"null"}]}},"type":"object","required":["type","arguments"]},"ToolSearchOutputItemParam":{"properties":{"id":{"anyOf":[{"type":"string","description":"The unique ID of this tool search output.","examples":["tso_123"]},{"type":"null"}]},"call_id":{"anyOf":[{"type":"string","maxLength":64,"minLength":1,"description":"The unique ID of the tool search call generated by the model."},{"type":"null"}]},"type":{"type":"string","enum":["tool_search_output"],"description":"The item type. Always `tool_search_output`.","default":"tool_search_output"},"execution":{"$ref":"#/definitions/ToolSearchExecutionType"},"tools":{"items":{"$ref":"#/definitions/ToolSearchOutputTool"},"type":"array","description":"The loaded tool definitions returned by the tool search output."},"status":{"anyOf":[{"$ref":"#/definitions/FunctionCallItemStatus"},{"type":"null"}]}},"type":"object","required":["type","tools"]},"AdditionalToolsItemParam":{"properties":{"id":{"anyOf":[{"type":"string","description":"The unique ID of this additional tools item.","examples":["at_123"]},{"type":"null"}]},"type":{"type":"string","enum":["additional_tools"],"description":"The item type. Always `additional_tools`.","default":"additional_tools"},"role":{"type":"string","enum":["developer"],"description":"The role that provided the additional tools. Only `developer` is supported.","default":"developer"},"tools":{"items":{"$ref":"#/definitions/Tool"},"type":"array","description":"A list of additional tools made available at this item."}},"type":"object","required":["type","role","tools"]},"ResponseConfigurationUpdateItemParam":{"type":"object","description":"An update to the conversation's response configuration. Supply reasoning,\ntext, or both. Each setting stays in effect until a later update replaces it.\n","properties":{"id":{"anyOf":[{"type":"string","description":"The unique ID of the configuration update item.","examples":["cnfu_123"]},{"type":"null"}]},"type":{"type":"string","enum":["configuration_update"],"description":"The item type. Always `configuration_update`.","default":"configuration_update"},"reasoning":{"type":"object","description":"Updates to reasoning configuration. Only effort is supported.","properties":{"effort":{"$ref":"#/definitions/ReasoningEffort"}}},"text":{"type":"object","description":"The text output configuration for subsequent responses.","properties":{"format":{"description":"Use a JSON schema for structured output or text to return to plain text.","oneOf":[{"$ref":"#/definitions/ResponseFormatText"},{"$ref":"#/definitions/TextResponseFormatJsonSchema"}]}},"required":["format"]}},"required":["type"]},"ReasoningItem":{"type":"object","description":"A description of the chain of thought used by a reasoning model while generating\na response. Be sure to include these items in your `input` to the Responses API\nfor subsequent turns of a conversation if you are manually\n[managing context](https://developers.openai.com/api/docs/guides/conversation-state).\n","title":"Reasoning","properties":{"type":{"type":"string","description":"The type of the object. Always `reasoning`.\n","enum":["reasoning"]},"id":{"type":"string","description":"The unique identifier of the reasoning content.\n"},"encrypted_content":{"anyOf":[{"type":"string","description":"The encrypted content of the reasoning item. This is populated by default\nfor reasoning items returned by `POST /v1/responses` and WebSocket\n`response.create` requests.\n\nWhen streaming, use the completed reasoning item and its\n`encrypted_content` from the `response.output_item.done` event in\nsubsequent requests. The `encrypted_content` in\n`response.output_item.added` may be incomplete. This is especially\nimportant when `store` is `false` or when using Zero Data Retention.\n"},{"type":"null"}]},"summary":{"type":"array","description":"Reasoning summary content.\n","items":{"$ref":"#/definitions/SummaryTextContent"}},"content":{"type":"array","description":"Reasoning text content.\n","items":{"$ref":"#/definitions/ReasoningTextContent"}},"status":{"type":"string","description":"The status of the item. One of `in_progress`, `completed`, or\n`incomplete`. Populated when items are returned via API.\n","enum":["in_progress","completed","incomplete"]}},"required":["id","summary","type"]},"CompactionSummaryItemParam":{"properties":{"id":{"anyOf":[{"type":"string","description":"The ID of the compaction item.","examples":["cmp_123"]},{"type":"null"}]},"type":{"type":"string","enum":["compaction"],"description":"The type of the item. Always `compaction`.","default":"compaction"},"encrypted_content":{"type":"string","maxLength":104857600,"description":"The encrypted content of the compaction summary."}},"type":"object","required":["type","encrypted_content"],"title":"Compaction item","description":"A compaction item generated by the [`v1/responses/compact` API](https://developers.openai.com/api/reference/resources/responses/methods/compact)."},"ImageGenToolCall":{"properties":{"type":{"type":"string","enum":["image_generation_call"],"description":"The type of the image generation call. Always `image_generation_call`."},"id":{"type":"string","description":"The unique ID of the image generation call."},"status":{"type":"string","enum":["in_progress","completed","generating","failed"],"description":"The status of the image generation call."},"result":{"anyOf":[{"type":"string","description":"The generated image encoded in base64."},{"type":"null"}]},"error":{"$ref":"#/definitions/ImageGenToolCallError"},"size":{"anyOf":[{"anyOf":[{"type":"string"},{"type":"string","enum":["1024x1024","1024x1536","1536x1024"]}],"description":"The image dimensions as a `WIDTHxHEIGHT` string, for example `1536x864`."},{"type":"null"}]},"quality":{"anyOf":[{"type":"string","enum":["low","medium","high","xhigh","max","auto"],"description":"The quality of the image generated by the image generation tool call. One of `low`, `medium`, `high`, `xhigh`, `max`, or `auto`."},{"type":"null"}]},"action":{"anyOf":[{"$ref":"#/definitions/ImageGenActionEnum"},{"type":"null"}]},"background":{"anyOf":[{"$ref":"#/definitions/ImageBackground"},{"type":"null"}]},"output_format":{"anyOf":[{"$ref":"#/definitions/ImageOutputFormat"},{"type":"null"}]},"revised_prompt":{"anyOf":[{"type":"string","description":"The prompt that was used after any model prompt rewriting."},{"type":"null"}]}},"type":"object","required":["type","id","status","result"],"title":"Image generation call","description":"An image generation request made by the model."},"CodeInterpreterToolCall":{"type":"object","title":"Code interpreter tool call","description":"A tool call to run code.\n","properties":{"type":{"type":"string","enum":["code_interpreter_call"],"default":"code_interpreter_call","description":"The type of the code interpreter tool call. Always `code_interpreter_call`.\n"},"id":{"type":"string","description":"The unique ID of the code interpreter tool call.\n"},"status":{"type":"string","enum":["in_progress","completed","incomplete","interpreting","failed"],"description":"The status of the code interpreter tool call. Valid values are `in_progress`, `completed`, `incomplete`, `interpreting`, and `failed`.\n"},"container_id":{"type":"string","description":"The ID of the container used to run the code.\n"},"code":{"anyOf":[{"type":"string","description":"The code to run, or null if not available.\n"},{"type":"null"}]},"outputs":{"anyOf":[{"type":"array","items":{"oneOf":[{"$ref":"#/definitions/CodeInterpreterOutputLogs"},{"$ref":"#/definitions/CodeInterpreterOutputImage"}]},"description":"The outputs generated by the code interpreter, such as logs or images.\nCan be null if no outputs are available.\n"},{"type":"null"}]}},"required":["type","id","status","container_id","code","outputs"]},"LocalShellToolCall":{"type":"object","title":"Local shell call","description":"A tool call to run a command on the local shell.\n","properties":{"type":{"type":"string","enum":["local_shell_call"],"description":"The type of the local shell call. Always `local_shell_call`.\n"},"id":{"type":"string","description":"The unique ID of the local shell call.\n"},"call_id":{"type":"string","description":"The unique ID of the local shell tool call generated by the model.\n"},"action":{"$ref":"#/definitions/LocalShellExecAction"},"status":{"type":"string","enum":["in_progress","completed","incomplete"],"description":"The status of the local shell call.\n"}},"required":["type","id","call_id","action","status"]},"LocalShellToolCallOutput":{"type":"object","title":"Local shell call output","description":"The output of a local shell tool call.\n","properties":{"type":{"type":"string","enum":["local_shell_call_output"],"description":"The type of the local shell tool call output. Always `local_shell_call_output`.\n"},"id":{"type":"string","description":"The unique ID of the local shell tool call generated by the model.\n"},"output":{"type":"string","description":"A JSON string of the output of the local shell tool call.\n"},"status":{"anyOf":[{"type":"string","enum":["in_progress","completed","incomplete"],"description":"The status of the item. One of `in_progress`, `completed`, or `incomplete`.\n"},{"type":"null"}]}},"required":["id","type","call_id","output"]},"FunctionShellCallItemParam":{"properties":{"id":{"anyOf":[{"type":"string","description":"The unique ID of the shell tool call. Populated when this item is returned via API.","examples":["sh_123"]},{"type":"null"}]},"call_id":{"type":"string","maxLength":64,"minLength":1,"description":"The unique ID of the shell tool call generated by the model."},"caller":{"anyOf":[{"$ref":"#/definitions/ToolCallCallerParam"},{"type":"null"}]},"type":{"type":"string","enum":["shell_call"],"description":"The type of the item. Always `shell_call`.","default":"shell_call"},"action":{"$ref":"#/definitions/FunctionShellActionParam"},"status":{"anyOf":[{"$ref":"#/definitions/FunctionShellCallItemStatus"},{"type":"null"}]},"environment":{"anyOf":[{"oneOf":[{"$ref":"#/definitions/LocalEnvironmentParam"},{"$ref":"#/definitions/ContainerReferenceParam"}],"description":"The environment to execute the shell commands in."},{"type":"null"}]}},"type":"object","required":["call_id","type","action"],"title":"Shell tool call","description":"A tool representing a request to execute one or more shell commands."},"FunctionShellCallOutputItemParam":{"properties":{"id":{"anyOf":[{"type":"string","description":"The unique ID of the shell tool call output. Populated when this item is returned via API.","examples":["sho_123"]},{"type":"null"}]},"call_id":{"type":"string","maxLength":64,"minLength":1,"description":"The unique ID of the shell tool call generated by the model."},"caller":{"anyOf":[{"$ref":"#/definitions/ToolCallCallerParam"},{"type":"null"}]},"type":{"type":"string","enum":["shell_call_output"],"description":"The type of the item. Always `shell_call_output`.","default":"shell_call_output"},"output":{"items":{"$ref":"#/definitions/FunctionShellCallOutputContentParam"},"type":"array","description":"Captured chunks of stdout and stderr output, along with their associated outcomes."},"status":{"anyOf":[{"$ref":"#/definitions/FunctionShellCallItemStatus"},{"type":"null"}]},"max_output_length":{"anyOf":[{"type":"integer","description":"The maximum number of UTF-8 characters captured for this shell call's combined output."},{"type":"null"}]}},"type":"object","required":["call_id","type","output"],"title":"Shell tool call output","description":"The streamed output items emitted by a shell tool call."},"ApplyPatchToolCallItemParam":{"properties":{"type":{"type":"string","enum":["apply_patch_call"],"description":"The type of the item. Always `apply_patch_call`.","default":"apply_patch_call"},"id":{"anyOf":[{"type":"string","description":"The unique ID of the apply patch tool call. Populated when this item is returned via API.","examples":["apc_123"]},{"type":"null"}]},"call_id":{"type":"string","maxLength":64,"minLength":1,"description":"The unique ID of the apply patch tool call generated by the model."},"caller":{"anyOf":[{"$ref":"#/definitions/ToolCallCallerParam"},{"type":"null"}]},"status":{"$ref":"#/definitions/ApplyPatchCallStatusParam"},"operation":{"$ref":"#/definitions/ApplyPatchOperationParam"}},"type":"object","required":["type","call_id","status","operation"],"title":"Apply patch tool call","description":"A tool call representing a request to create, delete, or update files using diff patches."},"ApplyPatchToolCallOutputItemParam":{"properties":{"type":{"type":"string","enum":["apply_patch_call_output"],"description":"The type of the item. Always `apply_patch_call_output`.","default":"apply_patch_call_output"},"id":{"anyOf":[{"type":"string","description":"The unique ID of the apply patch tool call output. Populated when this item is returned via API.","examples":["apco_123"]},{"type":"null"}]},"call_id":{"type":"string","maxLength":64,"minLength":1,"description":"The unique ID of the apply patch tool call generated by the model."},"caller":{"anyOf":[{"$ref":"#/definitions/ToolCallCallerParam"},{"type":"null"}]},"status":{"$ref":"#/definitions/ApplyPatchCallOutputStatusParam"},"output":{"anyOf":[{"type":"string","maxLength":10485760,"description":"Optional human-readable log text from the apply patch tool (e.g., patch results or errors)."},{"type":"null"}]}},"type":"object","required":["type","call_id","status"],"title":"Apply patch tool call output","description":"The streamed output emitted by an apply patch tool call."},"MCPListTools":{"type":"object","title":"MCP list tools","description":"A list of tools available on an MCP server.\n","properties":{"type":{"type":"string","enum":["mcp_list_tools"],"description":"The type of the item. Always `mcp_list_tools`.\n"},"id":{"type":"string","description":"The unique ID of the list.\n"},"server_label":{"type":"string","description":"The label of the MCP server.\n"},"tools":{"type":"array","items":{"$ref":"#/definitions/MCPListToolsTool"},"description":"The tools available on the server.\n"},"error":{"anyOf":[{"type":"string","description":"Error message if the server could not list tools.\n"},{"type":"null"}]}},"required":["type","id","server_label","tools"]},"MCPApprovalRequest":{"type":"object","title":"MCP approval request","description":"A request for human approval of a tool invocation.\n","properties":{"type":{"type":"string","enum":["mcp_approval_request"],"description":"The type of the item. Always `mcp_approval_request`.\n"},"id":{"type":"string","description":"The unique ID of the approval request.\n"},"server_label":{"type":"string","description":"The label of the MCP server making the request.\n"},"name":{"type":"string","description":"The name of the tool to run.\n"},"arguments":{"type":"string","description":"A JSON string of arguments for the tool.\n"}},"required":["type","id","server_label","name","arguments"]},"MCPApprovalResponse":{"type":"object","title":"MCP approval response","description":"A response to an MCP approval request.\n","properties":{"type":{"type":"string","enum":["mcp_approval_response"],"description":"The type of the item. Always `mcp_approval_response`.\n"},"id":{"anyOf":[{"type":"string","description":"The unique ID of the approval response\n"},{"type":"null"}]},"approval_request_id":{"type":"string","description":"The ID of the approval request being answered.\n"},"approve":{"type":"boolean","description":"Whether the request was approved.\n"},"reason":{"anyOf":[{"type":"string","description":"Optional reason for the decision.\n"},{"type":"null"}]}},"required":["type","request_id","approve","approval_request_id"]},"MCPToolCall":{"type":"object","title":"MCP tool call","description":"An invocation of a tool on an MCP server.\n","properties":{"type":{"type":"string","enum":["mcp_call"],"description":"The type of the item. Always `mcp_call`.\n"},"id":{"type":"string","description":"The unique ID of the tool call.\n"},"server_label":{"type":"string","description":"The label of the MCP server running the tool.\n"},"name":{"type":"string","description":"The name of the tool that was run.\n"},"arguments":{"type":"string","description":"A JSON string of the arguments passed to the tool.\n"},"output":{"anyOf":[{"type":"string","description":"The output from the tool call.\n"},{"type":"null"}]},"error":{"description":"The error from the tool call, if any.","anyOf":[{"$ref":"#/definitions/MCPToolCallError"},{"type":"null"}]},"status":{"$ref":"#/definitions/MCPToolCallStatus"},"approval_request_id":{"anyOf":[{"type":"string","description":"Unique identifier for the MCP tool call approval request.\nInclude this value in a subsequent `mcp_approval_response` input to approve or reject the corresponding tool call.\n"},{"type":"null"}]}},"required":["type","id","server_label","name","arguments"]},"CustomToolCallOutput":{"type":"object","title":"Custom tool call output","description":"The output of a custom tool call from your code, being sent back to the model.\n","properties":{"type":{"type":"string","enum":["custom_tool_call_output"],"description":"The type of the custom tool call output. Always `custom_tool_call_output`.\n"},"id":{"type":"string","description":"The unique ID of the custom tool call output in the OpenAI platform.\n"},"call_id":{"type":"string","description":"The call ID, used to map this custom tool call output to a custom tool call.\n"},"caller":{"anyOf":[{"$ref":"#/definitions/ToolCallCallerParam"},{"type":"null"}]},"output":{"description":"The output from the custom tool call generated by your code.\nCan be a string or an list of output content.\n","oneOf":[{"type":"string","description":"A string of the output of the custom tool call.\n","title":"string output"},{"type":"array","items":{"$ref":"#/definitions/FunctionAndCustomToolCallOutput"},"title":"output content list","description":"Text, image, or file output of the custom tool call.\n"}]}},"required":["type","call_id","output"]},"CustomToolCall":{"type":"object","title":"Custom tool call","description":"A call to a custom tool created by the model.\n","properties":{"type":{"type":"string","enum":["custom_tool_call"],"description":"The type of the custom tool call. Always `custom_tool_call`.\n"},"id":{"type":"string","description":"The unique ID of the custom tool call in the OpenAI platform.\n"},"call_id":{"type":"string","description":"An identifier used to map this custom tool call to a tool call output.\n"},"caller":{"anyOf":[{"$ref":"#/definitions/ToolCallCaller"},{"type":"null"}]},"namespace":{"type":"string","description":"The namespace of the custom tool being called.\n"},"name":{"type":"string","description":"The name of the custom tool being called.\n"},"input":{"type":"string","description":"The input for the custom tool call generated by the model.\n"},"async":{"type":"boolean","description":"Whether the custom tool call runs asynchronously.\n"}},"required":["type","call_id","name","input"]},"ProgramOutputItemStatus":{"type":"string","enum":["completed","incomplete"]},"InputContent":{"oneOf":[{"$ref":"#/definitions/InputTextContent"},{"$ref":"#/definitions/InputImageContent"},{"$ref":"#/definitions/InputFileContent"}]},"OutputMessageContent":{"oneOf":[{"$ref":"#/definitions/OutputTextContent"},{"$ref":"#/definitions/RefusalContent"}]},"VectorStoreFileAttributes":{"anyOf":[{"type":"object","description":"Set of 16 key-value pairs that can be attached to an object. This can be\nuseful for storing additional information about the object in a structured\nformat, and querying for objects via API or the dashboard. Keys are strings\nwith a maximum length of 64 characters. Values are strings with a maximum\nlength of 512 characters, booleans, or numbers.\n","maxProperties":16,"propertyNames":{"type":"string","maxLength":64},"additionalProperties":{"oneOf":[{"type":"string","maxLength":512},{"type":"number"},{"type":"boolean"}]}},{"type":"null"}]},"ComputerAction":{"oneOf":[{"$ref":"#/definitions/ClickParam"},{"$ref":"#/definitions/DoubleClickAction"},{"$ref":"#/definitions/DragParam"},{"$ref":"#/definitions/KeyPressAction"},{"$ref":"#/definitions/MoveParam"},{"$ref":"#/definitions/ScreenshotParam"},{"$ref":"#/definitions/ScrollParam"},{"$ref":"#/definitions/TypeParam"},{"$ref":"#/definitions/WaitParam"}]},"ComputerActionList":{"title":"Computer Action List","type":"array","description":"Flattened batched actions for `computer_use`. Each action includes an\n`type` discriminator and action-specific fields.\n","items":{"$ref":"#/definitions/ComputerAction"}},"ComputerCallSafetyCheckParam":{"properties":{"id":{"type":"string","description":"The ID of the pending safety check."},"code":{"anyOf":[{"type":"string","description":"The type of the pending safety check."},{"type":"null"}]},"message":{"anyOf":[{"type":"string","description":"Details about the pending safety check."},{"type":"null"}]}},"type":"object","required":["id"],"description":"A pending safety check for the computer call."},"ComputerScreenshotImage":{"type":"object","description":"A computer screenshot image used with the computer use tool.\n","properties":{"type":{"type":"string","enum":["computer_screenshot"],"default":"computer_screenshot","description":"Specifies the event type. For a computer screenshot, this property is \nalways set to `computer_screenshot`.\n"},"image_url":{"type":"string","format":"uri","description":"The URL of the screenshot image."},"file_id":{"type":"string","description":"The identifier of an uploaded file that contains the screenshot."}},"required":["type"]},"FunctionCallItemStatus":{"type":"string","enum":["in_progress","completed","incomplete"]},"WebSearchCallStatus":{"type":"string","enum":["in_progress","searching","completed","failed","incomplete"]},"WebSearchActionSearch":{"type":"object","title":"Search action","description":"Action type \"search\" - Performs a web search query.\n","properties":{"type":{"type":"string","enum":["search"],"description":"The action type.\n"},"query":{"type":"string","description":"The search query.\n"},"queries":{"type":"array","title":"Search queries","description":"The search queries.\n","items":{"type":"string","description":"A search query.\n"}},"sources":{"type":"array","title":"Web search sources","description":"The sources used in the search.\n","items":{"type":"object","title":"Web search source","description":"A source used in the search.\n","properties":{"type":{"type":"string","enum":["url"],"description":"The type of source. Always `url`.\n"},"url":{"type":"string","format":"uri","description":"The URL of the source.\n"}},"required":["type","url"]}}},"required":["type"]},"WebSearchActionOpenPage":{"type":"object","title":"Open page action","description":"Action type \"open_page\" - Opens a specific URL from search results.\n","properties":{"type":{"type":"string","enum":["open_page"],"description":"The action type.\n"},"url":{"description":"The URL opened by the model.\n","anyOf":[{"type":"string","format":"uri"},{"type":"null"}]}},"required":["type"]},"WebSearchActionFind":{"type":"object","title":"Find action","description":"Action type \"find_in_page\": Searches for a pattern within a loaded page.\n","properties":{"type":{"type":"string","enum":["find_in_page"],"description":"The action type.\n"},"url":{"anyOf":[{"type":"string","format":"uri"},{"type":"null"}],"description":"The URL of the page searched for the pattern, when available.\n"},"pattern":{"type":"string","description":"The pattern or text to search for within the page.\n"}},"required":["type","pattern"]},"ToolCallCaller":{"oneOf":[{"$ref":"#/definitions/DirectToolCallCaller"},{"$ref":"#/definitions/ProgramToolCallCaller"}],"description":"The execution context that produced this tool call."},"InputTextContentParam":{"properties":{"type":{"type":"string","enum":["input_text"],"description":"The type of the input item. Always `input_text`.","default":"input_text"},"text":{"type":"string","maxLength":10485760,"description":"The text input to the model."},"prompt_cache_breakpoint":{"anyOf":[{"$ref":"#/definitions/PromptCacheBreakpointParam"},{"type":"null"}]}},"type":"object","required":["type","text"],"title":"Input text","description":"A text input to the model."},"InputImageContentParamAutoParam":{"properties":{"type":{"type":"string","enum":["input_image"],"description":"The type of the input item. Always `input_image`.","default":"input_image"},"image_url":{"anyOf":[{"type":"string","maxLength":20971520,"format":"uri","description":"The URL of the image to be sent to the model. A fully qualified URL or base64 encoded image in a data URL."},{"type":"null"}]},"file_id":{"anyOf":[{"type":"string","description":"The ID of the file to be sent to the model.","examples":["file-123"]},{"type":"null"}]},"detail":{"anyOf":[{"$ref":"#/definitions/DetailEnum"},{"type":"null"}]},"prompt_cache_breakpoint":{"anyOf":[{"$ref":"#/definitions/PromptCacheBreakpointParam"},{"type":"null"}]}},"type":"object","required":["type"],"title":"Input image","description":"An image input to the model. Learn about [image inputs](https://developers.openai.com/api/docs/guides/images-vision)"},"InputFileContentParam":{"properties":{"type":{"type":"string","enum":["input_file"],"description":"The type of the input item. Always `input_file`.","default":"input_file"},"file_id":{"anyOf":[{"type":"string","description":"The ID of the file to be sent to the model.","examples":["file-123"]},{"type":"null"}]},"filename":{"anyOf":[{"type":"string","description":"The name of the file to be sent to the model."},{"type":"null"}]},"file_data":{"anyOf":[{"type":"string","maxLength":73400320,"description":"The base64-encoded data of the file to be sent to the model."},{"type":"null"}]},"file_url":{"anyOf":[{"type":"string","format":"uri","description":"The URL of the file to be sent to the model."},{"type":"null"}]},"detail":{"$ref":"#/definitions/FileDetailEnum"},"prompt_cache_breakpoint":{"anyOf":[{"$ref":"#/definitions/PromptCacheBreakpointParam"},{"type":"null"}]}},"type":"object","required":["type"],"title":"Input file","description":"A file input to the model."},"ToolCallCallerParam":{"oneOf":[{"$ref":"#/definitions/DirectToolCallCallerParam"},{"$ref":"#/definitions/ProgramToolCallCallerParam"}],"description":"The execution context that produced this tool call."},"ToolSearchExecutionType":{"type":"string","enum":["server","client"]},"EmptyModelParam":{"properties":{},"type":"object","required":[]},"ToolSearchOutputTool":{"description":"A tool definition returned by a tool search output.\n","oneOf":[{"$ref":"#/definitions/FunctionTool"},{"$ref":"#/definitions/FileSearchTool"},{"$ref":"#/definitions/ComputerTool"},{"$ref":"#/definitions/ComputerUsePreviewTool"},{"$ref":"#/definitions/WebSearchTool"},{"$ref":"#/definitions/MCPTool"},{"$ref":"#/definitions/CodeInterpreterTool"},{"$ref":"#/definitions/ProgrammaticToolCallingParam"},{"$ref":"#/definitions/ImageGenTool"},{"$ref":"#/definitions/LocalShellToolParam"},{"$ref":"#/definitions/FunctionShellToolParam"},{"$ref":"#/definitions/CustomToolParam"},{"$ref":"#/definitions/ToolSearchOutputNamespaceToolParam"},{"$ref":"#/definitions/ToolSearchToolParam"},{"$ref":"#/definitions/WebSearchPreviewTool"},{"$ref":"#/definitions/ApplyPatchToolParam"}]},"Tool":{"description":"A tool that can be used to generate a response.\n","oneOf":[{"$ref":"#/definitions/FunctionTool"},{"$ref":"#/definitions/FileSearchTool"},{"$ref":"#/definitions/ComputerTool"},{"$ref":"#/definitions/ComputerUsePreviewTool"},{"$ref":"#/definitions/WebSearchTool"},{"$ref":"#/definitions/MCPTool"},{"$ref":"#/definitions/CodeInterpreterTool"},{"$ref":"#/definitions/ProgrammaticToolCallingParam"},{"$ref":"#/definitions/ImageGenTool"},{"$ref":"#/definitions/LocalShellToolParam"},{"$ref":"#/definitions/FunctionShellToolParam"},{"$ref":"#/definitions/CustomToolParam"},{"$ref":"#/definitions/NamespaceToolParam"},{"$ref":"#/definitions/ToolSearchToolParam"},{"$ref":"#/definitions/WebSearchPreviewTool"},{"$ref":"#/definitions/ApplyPatchToolParam"}]},"ReasoningEffort":{"anyOf":[{"type":"string","enum":["none","minimal","low","medium","high","xhigh","max"],"default":"medium","description":"Constrains effort on reasoning for reasoning models. Currently supported\nvalues are `none`, `minimal`, `low`, `medium`, `high`, `xhigh`, and `max`.\nReducing reasoning effort can result in faster responses and fewer tokens\nused on reasoning in a response. Not all reasoning models support every\nvalue. See the\n[reasoning guide](https://developers.openai.com/api/docs/guides/reasoning)\nfor model-specific support.\n"},{"type":"null"}]},"ResponseFormatText":{"type":"object","title":"Text","description":"Default response format. Used to generate text responses.\n","properties":{"type":{"type":"string","description":"The type of response format being defined. Always `text`.","enum":["text"]}},"required":["type"]},"TextResponseFormatJsonSchema":{"type":"object","title":"JSON schema","description":"JSON Schema response format. Used to generate structured JSON responses.\nLearn more about [Structured Outputs](https://developers.openai.com/api/docs/guides/structured-outputs).\n","properties":{"type":{"type":"string","description":"The type of response format being defined. Always `json_schema`.","enum":["json_schema"]},"description":{"type":"string","description":"A description of what the response format is for, used by the model to\ndetermine how to respond in the format.\n"},"name":{"type":"string","description":"The name of the response format. Must be a-z, A-Z, 0-9, or contain\nunderscores and dashes, with a maximum length of 64.\n"},"schema":{"$ref":"#/definitions/ResponseFormatJsonSchemaSchema"},"strict":{"anyOf":[{"type":"boolean","default":false,"description":"Whether to enable strict schema adherence when generating the output.\nIf set to true, the model will always follow the exact schema defined\nin the `schema` field. Only a subset of JSON Schema is supported when\n`strict` is `true`. To learn more, read the [Structured Outputs\nguide](https://developers.openai.com/api/docs/guides/structured-outputs).\n"},{"type":"null"}]}},"required":["type","schema","name"]},"SummaryTextContent":{"properties":{"type":{"type":"string","enum":["summary_text"],"description":"The type of the object. Always `summary_text`.","default":"summary_text"},"text":{"type":"string","description":"A summary of the reasoning output from the model so far."}},"type":"object","required":["type","text"],"title":"Summary text","description":"A summary text from the model."},"ReasoningTextContent":{"properties":{"type":{"type":"string","enum":["reasoning_text"],"description":"The type of the reasoning text. Always `reasoning_text`.","default":"reasoning_text"},"text":{"type":"string","description":"The reasoning text from the model."}},"type":"object","required":["type","text"],"title":"Reasoning text","description":"Reasoning text from the model."},"ImageGenToolCallError":{"properties":{"code":{"anyOf":[{"type":"string","description":"The error code."},{"type":"null"}]},"type":{"type":"string","description":"The error type."},"message":{"type":"string","description":"A description of the error."},"param":{"anyOf":[{"type":"string","description":"The related request parameter."},{"type":"null"}]},"moderation_details":{"$ref":"#/definitions/ImageGenToolCallModerationDetails"}},"type":"object","required":["code","type","message","param"]},"ImageGenActionEnum":{"type":"string","enum":["generate","edit","auto"]},"ImageBackground":{"type":"string","enum":["transparent","opaque","auto"]},"ImageOutputFormat":{"type":"string","enum":["png","webp","jpeg"]},"CodeInterpreterOutputLogs":{"properties":{"type":{"type":"string","enum":["logs"],"description":"The type of the output. Always `logs`.","default":"logs"},"logs":{"type":"string","description":"The logs output from the code interpreter."}},"type":"object","required":["type","logs"],"title":"Code interpreter output logs","description":"The logs output from the code interpreter."},"CodeInterpreterOutputImage":{"properties":{"type":{"type":"string","enum":["image"],"description":"The type of the output. Always `image`.","default":"image"},"url":{"type":"string","format":"uri","description":"The URL of the image output from the code interpreter."}},"type":"object","required":["type","url"],"title":"Code interpreter output image","description":"The image output from the code interpreter."},"LocalShellExecAction":{"properties":{"type":{"type":"string","enum":["exec"],"description":"The type of the local shell action. Always `exec`.","default":"exec"},"command":{"items":{"type":"string"},"type":"array","description":"The command to run."},"timeout_ms":{"anyOf":[{"type":"integer","description":"Optional timeout in milliseconds for the command."},{"type":"null"}]},"working_directory":{"anyOf":[{"type":"string","description":"Optional working directory to run the command in."},{"type":"null"}]},"env":{"additionalProperties":{"type":"string"},"type":"object","description":"Environment variables to set for the command."},"user":{"anyOf":[{"type":"string","description":"Optional user to run the command as."},{"type":"null"}]}},"type":"object","required":["type","command","env"],"title":"Local shell exec action","description":"Execute a shell command on the server."},"FunctionShellActionParam":{"properties":{"commands":{"items":{"type":"string"},"type":"array","description":"Ordered shell commands for the execution environment to run."},"timeout_ms":{"anyOf":[{"type":"integer","description":"Maximum wall-clock time in milliseconds to allow the shell commands to run."},{"type":"null"}]},"max_output_length":{"anyOf":[{"type":"integer","description":"Maximum number of UTF-8 characters to capture from combined stdout and stderr output."},{"type":"null"}]}},"type":"object","required":["commands"],"title":"Shell action","description":"Commands and limits describing how to run the shell tool call."},"FunctionShellCallItemStatus":{"type":"string","enum":["in_progress","completed","incomplete"],"title":"Shell call status","description":"Status values reported for shell tool calls."},"LocalEnvironmentParam":{"properties":{"type":{"type":"string","enum":["local"],"description":"Use a local computer environment.","default":"local"},"skills":{"items":{"$ref":"#/definitions/LocalSkillParam"},"type":"array","maxItems":200,"description":"An optional list of skills."}},"type":"object","required":["type"]},"ContainerReferenceParam":{"properties":{"type":{"type":"string","enum":["container_reference"],"description":"References a container created with the /v1/containers endpoint","default":"container_reference"},"container_id":{"type":"string","description":"The ID of the referenced container.","examples":["cntr_123"]}},"type":"object","required":["type","container_id"]},"FunctionShellCallOutputContentParam":{"properties":{"stdout":{"type":"string","maxLength":10485760,"description":"Captured stdout output for the shell call."},"stderr":{"type":"string","maxLength":10485760,"description":"Captured stderr output for the shell call."},"outcome":{"$ref":"#/definitions/FunctionShellCallOutputOutcomeParam"}},"type":"object","required":["stdout","stderr","outcome"],"title":"Shell output content","description":"Captured stdout and stderr for a portion of a shell tool call output."},"ApplyPatchCallStatusParam":{"type":"string","enum":["in_progress","completed"],"title":"Apply patch call status","description":"Status values reported for apply_patch tool calls."},"ApplyPatchOperationParam":{"oneOf":[{"$ref":"#/definitions/ApplyPatchCreateFileOperationParam"},{"$ref":"#/definitions/ApplyPatchDeleteFileOperationParam"},{"$ref":"#/definitions/ApplyPatchUpdateFileOperationParam"}],"title":"Apply patch operation","description":"One of the create_file, delete_file, or update_file operations supplied to the apply_patch tool."},"ApplyPatchCallOutputStatusParam":{"type":"string","enum":["completed","failed"],"title":"Apply patch call output status","description":"Outcome values reported for apply_patch tool call outputs."},"MCPListToolsTool":{"type":"object","title":"MCP list tools tool","description":"A tool available on an MCP server.\n","properties":{"name":{"type":"string","description":"The name of the tool.\n"},"description":{"anyOf":[{"type":"string","description":"The description of the tool.\n"},{"type":"null"}]},"input_schema":{"type":"object","description":"The JSON schema describing the tool's input.\n"},"annotations":{"anyOf":[{"type":"object","description":"Additional annotations about the tool.\n"},{"type":"null"}]}},"required":["name","input_schema"]},"MCPToolCallError":{"oneOf":[{"$ref":"#/definitions/MCPProtocolError"},{"$ref":"#/definitions/MCPToolExecutionError"},{"$ref":"#/definitions/HTTPError"}]},"MCPToolCallStatus":{"type":"string","enum":["in_progress","completed","incomplete","calling","failed"]},"FunctionAndCustomToolCallOutput":{"oneOf":[{"$ref":"#/definitions/InputTextContent"},{"$ref":"#/definitions/InputImageContent"},{"$ref":"#/definitions/InputFileContent"}]},"InputTextContent":{"properties":{"type":{"type":"string","enum":["input_text"],"description":"The type of the input item. Always `input_text`.","default":"input_text"},"text":{"type":"string","description":"The text input to the model."},"prompt_cache_breakpoint":{"$ref":"#/definitions/PromptCacheBreakpointConfig"}},"type":"object","required":["type","text"],"title":"Input text","description":"A text input to the model."},"InputImageContent":{"properties":{"type":{"type":"string","enum":["input_image"],"description":"The type of the input item. Always `input_image`.","default":"input_image"},"image_url":{"anyOf":[{"type":"string","format":"uri","description":"The URL of the image to be sent to the model. A fully qualified URL or base64 encoded image in a data URL."},{"type":"null"}]},"file_id":{"anyOf":[{"type":"string","description":"The ID of the file to be sent to the model."},{"type":"null"}]},"detail":{"$ref":"#/definitions/ImageDetail"},"prompt_cache_breakpoint":{"$ref":"#/definitions/PromptCacheBreakpointConfig"}},"type":"object","required":["type","detail"],"title":"Input image","description":"An image input to the model. Learn about [image inputs](https://developers.openai.com/api/docs/guides/images-vision)."},"InputFileContent":{"properties":{"type":{"type":"string","enum":["input_file"],"description":"The type of the input item. Always `input_file`.","default":"input_file"},"file_id":{"anyOf":[{"type":"string","description":"The ID of the file to be sent to the model."},{"type":"null"}]},"filename":{"type":"string","description":"The name of the file to be sent to the model."},"file_data":{"type":"string","description":"The content of the file to be sent to the model.\n"},"prompt_cache_breakpoint":{"$ref":"#/definitions/PromptCacheBreakpointConfig"},"file_url":{"type":"string","format":"uri","description":"The URL of the file to be sent to the model."},"detail":{"$ref":"#/definitions/FileInputDetail"}},"type":"object","required":["type"],"title":"Input file","description":"A file input to the model."},"OutputTextContent":{"properties":{"type":{"type":"string","enum":["output_text"],"description":"The type of the output text. Always `output_text`.","default":"output_text"},"text":{"type":"string","description":"The text output from the model."},"annotations":{"items":{"$ref":"#/definitions/Annotation"},"type":"array","description":"The annotations of the text output."},"logprobs":{"items":{"$ref":"#/definitions/LogProb"},"type":"array"}},"type":"object","required":["type","text","annotations","logprobs"],"title":"Output text","description":"A text output from the model."},"RefusalContent":{"properties":{"type":{"type":"string","enum":["refusal"],"description":"The type of the refusal. Always `refusal`.","default":"refusal"},"refusal":{"type":"string","description":"The refusal explanation from the model."}},"type":"object","required":["type","refusal"],"title":"Refusal","description":"A refusal from the model."},"ClickParam":{"properties":{"type":{"type":"string","enum":["click"],"description":"Specifies the event type. For a click action, this property is always `click`.","default":"click"},"button":{"$ref":"#/definitions/ClickButtonType"},"x":{"type":"integer","description":"The x-coordinate where the click occurred."},"y":{"type":"integer","description":"The y-coordinate where the click occurred."},"keys":{"anyOf":[{"items":{"type":"string"},"type":"array","description":"The keys being held while clicking."},{"type":"null"}]}},"type":"object","required":["type","button","x","y"],"title":"Click","description":"A click action."},"DoubleClickAction":{"properties":{"type":{"type":"string","enum":["double_click"],"description":"Specifies the event type. For a double click action, this property is always set to `double_click`.","default":"double_click"},"x":{"type":"integer","description":"The x-coordinate where the double click occurred."},"y":{"type":"integer","description":"The y-coordinate where the double click occurred."},"keys":{"anyOf":[{"items":{"type":"string"},"type":"array","description":"The keys being held while double-clicking."},{"type":"null"}]}},"type":"object","required":["type","x","y","keys"],"title":"DoubleClick","description":"A double click action."},"DragParam":{"properties":{"type":{"type":"string","enum":["drag"],"description":"Specifies the event type. For a drag action, this property is always set to `drag`.","default":"drag"},"path":{"items":{"$ref":"#/definitions/CoordParam"},"type":"array","description":"An array of coordinates representing the path of the drag action. Coordinates will appear as an array of objects, eg\n```\n[\n  { x: 100, y: 200 },\n  { x: 200, y: 300 }\n]\n```"},"keys":{"anyOf":[{"items":{"type":"string"},"type":"array","description":"The keys being held while dragging the mouse."},{"type":"null"}]}},"type":"object","required":["type","path"],"title":"Drag","description":"A drag action."},"KeyPressAction":{"properties":{"type":{"type":"string","enum":["keypress"],"description":"Specifies the event type. For a keypress action, this property is always set to `keypress`.","default":"keypress"},"keys":{"items":{"type":"string","description":"One of the keys the model is requesting to be pressed."},"type":"array","description":"The combination of keys the model is requesting to be pressed. This is an array of strings, each representing a key."}},"type":"object","required":["type","keys"],"title":"KeyPress","description":"A collection of keypresses the model would like to perform."},"MoveParam":{"properties":{"type":{"type":"string","enum":["move"],"description":"Specifies the event type. For a move action, this property is always set to `move`.","default":"move"},"x":{"type":"integer","description":"The x-coordinate to move to."},"y":{"type":"integer","description":"The y-coordinate to move to."},"keys":{"anyOf":[{"items":{"type":"string"},"type":"array","description":"The keys being held while moving the mouse."},{"type":"null"}]}},"type":"object","required":["type","x","y"],"title":"Move","description":"A mouse move action."},"ScreenshotParam":{"properties":{"type":{"type":"string","enum":["screenshot"],"description":"Specifies the event type. For a screenshot action, this property is always set to `screenshot`.","default":"screenshot"}},"type":"object","required":["type"],"title":"Screenshot","description":"A screenshot action."},"ScrollParam":{"properties":{"type":{"type":"string","enum":["scroll"],"description":"Specifies the event type. For a scroll action, this property is always set to `scroll`.","default":"scroll"},"x":{"type":"integer","description":"The x-coordinate where the scroll occurred."},"y":{"type":"integer","description":"The y-coordinate where the scroll occurred."},"scroll_x":{"type":"integer","description":"The horizontal scroll distance."},"scroll_y":{"type":"integer","description":"The vertical scroll distance."},"keys":{"anyOf":[{"items":{"type":"string"},"type":"array","description":"The keys being held while scrolling."},{"type":"null"}]}},"type":"object","required":["type","x","y","scroll_x","scroll_y"],"title":"Scroll","description":"A scroll action."},"TypeParam":{"properties":{"type":{"type":"string","enum":["type"],"description":"Specifies the event type. For a type action, this property is always set to `type`.","default":"type"},"text":{"type":"string","description":"The text to type."}},"type":"object","required":["type","text"],"title":"Type","description":"An action to type in text."},"WaitParam":{"properties":{"type":{"type":"string","enum":["wait"],"description":"Specifies the event type. For a wait action, this property is always set to `wait`.","default":"wait"}},"type":"object","required":["type"],"title":"Wait","description":"A wait action."},"DirectToolCallCaller":{"properties":{"type":{"type":"string","enum":["direct"],"default":"direct"}},"type":"object","required":["type"]},"ProgramToolCallCaller":{"properties":{"type":{"type":"string","enum":["program"],"default":"program"},"caller_id":{"type":"string","description":"The call ID of the program item that produced this tool call."}},"type":"object","required":["type","caller_id"]},"PromptCacheBreakpointParam":{"properties":{"mode":{"type":"string","enum":["explicit"],"description":"The breakpoint mode. Always `explicit`.","default":"explicit"},"ttl":{"type":"string","enum":["30m","12h"],"description":"The minimum lifetime of this cache breakpoint. Defaults to the request TTL."}},"type":"object","required":["mode"],"title":"Prompt cache breakpoint","description":"Marks the exact end of a reusable prompt prefix. When `ttl` is omitted, the breakpoint inherits the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block."},"DetailEnum":{"type":"string","enum":["low","high","auto","original"]},"FileDetailEnum":{"type":"string","enum":["auto","low","high"]},"DirectToolCallCallerParam":{"properties":{"type":{"type":"string","enum":["direct"],"description":"The caller type. Always `direct`.","default":"direct"}},"type":"object","required":["type"]},"ProgramToolCallCallerParam":{"properties":{"type":{"type":"string","enum":["program"],"description":"The caller type. Always `program`.","default":"program"},"caller_id":{"type":"string","maxLength":64,"minLength":1,"description":"The call ID of the program item that produced this tool call."}},"type":"object","required":["type","caller_id"]},"FunctionTool":{"properties":{"type":{"type":"string","enum":["function"],"description":"The type of the function tool. Always `function`.","default":"function"},"name":{"type":"string","description":"The name of the function to call."},"async":{"type":"boolean"},"description":{"anyOf":[{"type":"string","description":"A description of the function. Used by the model to determine whether or not to call the function."},{"type":"null"}]},"parameters":{"anyOf":[{"additionalProperties":{},"type":"object","description":"A JSON schema object describing the parameters of the function."},{"type":"null"}]},"output_schema":{"anyOf":[{"additionalProperties":{},"type":"object","description":"A JSON schema object describing the JSON value encoded in string outputs for this function."},{"type":"null"}]},"strict":{"anyOf":[{"type":"boolean","description":"Whether strict parameter validation is enforced for this function tool."},{"type":"null"}]},"defer_loading":{"type":"boolean","description":"Whether this function is deferred and loaded via tool search."},"allowed_callers":{"anyOf":[{"items":{"$ref":"#/definitions/CallableToolAllowedCaller"},"type":"array","description":"The tool invocation context(s)."},{"type":"null"}]}},"type":"object","required":["type","name","strict","parameters"],"title":"Function","description":"Defines a function in your own code the model can choose to call. Learn more about [function calling](https://developers.openai.com/api/docs/guides/function-calling)."},"FileSearchTool":{"properties":{"type":{"type":"string","enum":["file_search"],"description":"The type of the file search tool. Always `file_search`.","default":"file_search"},"vector_store_ids":{"items":{"type":"string"},"type":"array","description":"The IDs of the vector stores to search."},"max_num_results":{"type":"integer","description":"The maximum number of results to return. This number should be between 1 and 50 inclusive."},"ranking_options":{"$ref":"#/definitions/RankingOptions"},"filters":{"anyOf":[{"$ref":"#/definitions/Filters"},{"type":"null"}]}},"type":"object","required":["type","vector_store_ids"],"title":"File search","description":"A tool that searches for relevant content from uploaded files. Learn more about the [file search tool](https://developers.openai.com/api/docs/guides/tools-file-search)."},"ComputerTool":{"properties":{"type":{"type":"string","enum":["computer"],"description":"The type of the computer tool. Always `computer`.","default":"computer"}},"type":"object","required":["type"],"title":"Computer","description":"A tool that controls a virtual computer. Learn more about the [computer tool](https://developers.openai.com/api/docs/guides/tools-computer-use)."},"ComputerUsePreviewTool":{"properties":{"type":{"type":"string","enum":["computer_use_preview"],"description":"The type of the computer use tool. Always `computer_use_preview`.","default":"computer_use_preview"},"environment":{"$ref":"#/definitions/ComputerEnvironment"},"display_width":{"type":"integer","description":"The width of the computer display."},"display_height":{"type":"integer","description":"The height of the computer display."}},"type":"object","required":["type","environment","display_width","display_height"],"title":"Computer use preview","description":"A tool that controls a virtual computer. Learn more about the [computer tool](https://developers.openai.com/api/docs/guides/tools-computer-use)."},"WebSearchTool":{"type":"object","title":"Web search","description":"Search the Internet for sources related to the prompt. Learn more about the\n[web search tool](https://developers.openai.com/api/docs/guides/tools-web-search).\n","properties":{"type":{"type":"string","enum":["web_search","web_search_2025_08_26"],"description":"The type of the web search tool. One of `web_search` or `web_search_2025_08_26`.","default":"web_search"},"external_web_access":{"type":"boolean","default":true,"description":"Allow live internet access for web search. Defaults to true when omitted. When false, the web search tool runs in offline/cache-only mode and will not fetch new external content."},"filters":{"anyOf":[{"type":"object","description":"Filters for the search.\n","properties":{"allowed_domains":{"anyOf":[{"type":"array","title":"Allowed domains for the search.","description":"Allowed domains for the search. If not provided, all domains are allowed.\nSubdomains of the provided domains are allowed as well.\n\nExample: `[\"pubmed.ncbi.nlm.nih.gov\"]`\n","items":{"type":"string","description":"Allowed domain for the search."},"default":[]},{"type":"null"}]}}},{"type":"null"}]},"user_location":{"$ref":"#/definitions/WebSearchApproximateLocation"},"search_context_size":{"type":"string","enum":["low","medium","high"],"default":"medium","description":"High level guidance for the amount of context window space to use for the search. One of `low`, `medium`, or `high`. `medium` is the default."}},"required":["type"]},"MCPTool":{"type":"object","title":"MCP tool","description":"Give the model access to additional tools via remote Model Context Protocol\n(MCP) servers. [Learn more about MCP](https://developers.openai.com/api/docs/guides/tools-connectors-mcp).\n","properties":{"type":{"type":"string","enum":["mcp"],"description":"The type of the MCP tool. Always `mcp`."},"server_label":{"type":"string","description":"A label for this MCP server, used to identify it in tool calls.\n"},"server_url":{"type":"string","format":"uri","description":"The URL for the MCP server. One of `server_url`, `connector_id`, or\n`tunnel_id` must be provided.\n"},"connector_id":{"type":"string","enum":["connector_dropbox","connector_gmail","connector_googlecalendar","connector_googledrive","connector_microsoftteams","connector_outlookcalendar","connector_outlookemail","connector_sharepoint"],"description":"Identifier for service connectors, like those available in ChatGPT. One of\n`server_url`, `connector_id`, or `tunnel_id` must be provided. Learn more\nabout service connectors [here](https://developers.openai.com/api/docs/guides/tools-connectors-mcp#connectors).\n\nThis field is deprecated for models released after September 1, 2026.\nUse `server_url` to connect to a remote MCP server, or `tunnel_id` to\nconnect through a Secure MCP Tunnel.\n\nCurrently supported `connector_id` values are:\n\n- Dropbox: `connector_dropbox`\n- Gmail: `connector_gmail`\n- Google Calendar: `connector_googlecalendar`\n- Google Drive: `connector_googledrive`\n- Microsoft Teams: `connector_microsoftteams`\n- Outlook Calendar: `connector_outlookcalendar`\n- Outlook Email: `connector_outlookemail`\n- SharePoint: `connector_sharepoint`\n"},"tunnel_id":{"type":"string","pattern":"^tunnel_[a-z0-9]{32}$","description":"The Secure MCP Tunnel ID to use instead of a direct server URL. One of\n`server_url`, `connector_id`, or `tunnel_id` must be provided.\n"},"authorization":{"type":"string","description":"An OAuth access token that can be used with a remote MCP server, either\nwith a custom MCP server URL or a service connector. Your application\nmust handle the OAuth authorization flow and provide the token here.\n"},"server_description":{"type":"string","description":"Optional description of the MCP server, used to provide more context.\n"},"headers":{"anyOf":[{"type":"object","additionalProperties":{"type":"string"},"description":"Optional HTTP headers to send to the MCP server. Use for authentication\nor other purposes.\n"},{"type":"null"}]},"allowed_tools":{"anyOf":[{"description":"List of allowed tool names or a filter object.\n","oneOf":[{"type":"array","title":"MCP allowed tools","description":"A string array of allowed tool names","items":{"type":"string"}},{"$ref":"#/definitions/MCPToolFilter"}]},{"type":"null"}]},"allowed_callers":{"anyOf":[{"type":"array","minItems":1,"items":{"$ref":"#/definitions/CallableToolAllowedCaller"},"description":"The tool invocation context(s)."},{"type":"null"}]},"require_approval":{"anyOf":[{"description":"Specify which of the MCP server's tools require approval.","oneOf":[{"type":"object","title":"MCP tool approval filter","description":"Specify which of the MCP server's tools require approval. Can be\n`always`, `never`, or a filter object associated with tools\nthat require approval.\n","properties":{"always":{"$ref":"#/definitions/MCPToolFilter"},"never":{"$ref":"#/definitions/MCPToolFilter"}},"additionalProperties":false},{"type":"string","title":"MCP tool approval setting","description":"Specify a single approval policy for all tools. One of `always` or\n`never`. When set to `always`, all tools will require approval. When\nset to `never`, all tools will not require approval.\n","enum":["always","never"]}],"default":"always"},{"type":"null"}]},"defer_loading":{"type":"boolean","description":"Whether this MCP tool is deferred and discovered via tool search.\n"}},"required":["type","server_label"]},"CodeInterpreterTool":{"type":"object","title":"Code interpreter","description":"A tool that runs Python code to help generate a response to a prompt.\n","properties":{"type":{"type":"string","enum":["code_interpreter"],"description":"The type of the code interpreter tool. Always `code_interpreter`.\n"},"container":{"description":"The code interpreter container. Can be a container ID or an object that\nspecifies uploaded file IDs to make available to your code, along with an\noptional `memory_limit` setting.\n","oneOf":[{"type":"string","description":"The container ID."},{"$ref":"#/definitions/AutoCodeInterpreterToolParam"}]},"allowed_callers":{"anyOf":[{"type":"array","minItems":1,"items":{"$ref":"#/definitions/CallableToolAllowedCaller"},"description":"The tool invocation context(s)."},{"type":"null"}]}},"required":["type","container"]},"ProgrammaticToolCallingParam":{"properties":{"type":{"type":"string","enum":["programmatic_tool_calling"],"description":"The type of the tool. Always `programmatic_tool_calling`.","default":"programmatic_tool_calling"}},"type":"object","required":["type"]},"ImageGenTool":{"type":"object","title":"Image generation tool","description":"A tool that generates images using the GPT image models.\n","properties":{"type":{"type":"string","enum":["image_generation"],"description":"The type of the image generation tool. Always `image_generation`.\n"},"model":{"anyOf":[{"type":"string"},{"type":"string","enum":["gpt-image-1","gpt-image-1-mini","gpt-image-1.5","gpt-image-2","gpt-image-2-2026-04-21","gpt-image-2.5-sunburst","gpt-image-2.5-sunburst-2026-09-08","gpt-image-2.5-flare","gpt-image-2.5-flare-2026-09-08"],"description":"The image generation model to use. One of `gpt-image-1-mini`,\n`gpt-image-1.5`, `gpt-image-2`,\n`gpt-image-2-2026-04-21`, `gpt-image-2.5-sunburst`,\n`gpt-image-2.5-sunburst-2026-09-08`, `gpt-image-2.5-flare`,\n`gpt-image-2.5-flare-2026-09-08`, or `chatgpt-image-latest`. Default:\n`gpt-image-2`.\n\n`gpt-image-1` was shut down on October 23, 2026. Use\n`gpt-image-2.5-sunburst` or `gpt-image-2.5-flare` instead.\n","default":"gpt-image-2"}]},"quality":{"type":"string","enum":["low","medium","high","xhigh","max","auto"],"description":"The quality of the generated image. The GPT image models support `low`,\n`medium`, and `high`. `gpt-image-2.5-sunburst` and `gpt-image-2.5-flare`,\nincluding their `2026-09-08` snapshots, also support `xhigh` and `max`.\nDefault: `auto`.\n","default":"auto"},"size":{"anyOf":[{"type":"string"},{"type":"string","enum":["1024x1024","1024x1536","1536x1024","auto"]}],"description":"The size of the generated images. For `gpt-image-2`, `gpt-image-2-2026-04-21`, `gpt-image-2.5-sunburst`, `gpt-image-2.5-sunburst-2026-09-08`, `gpt-image-2.5-flare`, and `gpt-image-2.5-flare-2026-09-08`, arbitrary resolutions are supported as `WIDTHxHEIGHT` strings, for example `1536x864`. Width and height must both be divisible by 16 and the requested aspect ratio must be between 1:3 and 3:1. Resolutions above `2560x1440` are experimental, and the maximum supported resolution is `3840x2160`. The requested size must also satisfy the model's current pixel and edge limits. The standard sizes `1024x1024`, `1536x1024`, and `1024x1536` are supported by the GPT image models; `auto` is supported for models that allow automatic sizing.","default":"auto"},"output_format":{"type":"string","enum":["png","webp","jpeg"],"description":"The output format of the generated image. One of `png`, `webp`, or\n`jpeg`. Default: `png`.\n","default":"png"},"output_compression":{"type":"integer","minimum":0,"maximum":100,"description":"Compression level for the output image. Default: 100.\n","default":100},"moderation":{"type":"string","enum":["auto","low"],"description":"Moderation level for the generated image. Default: `auto`.\n","default":"auto"},"background":{"type":"string","enum":["transparent","opaque","auto"],"description":"Set the background of the generated image. One of `transparent`, `opaque`,\nor `auto`. `gpt-image-2.5-sunburst` and `gpt-image-2.5-flare`, including\ntheir `2026-09-08` snapshots, support `opaque` and `transparent`\nbackgrounds. Transparent backgrounds are available for supported GPT Image\nmodels. For `gpt-image-2` and `gpt-image-2-2026-04-21`, this support is in\npreview. When using `transparent`, set the output format to `png` or `webp`.\nDefault: `auto`.\n","default":"auto"},"input_fidelity":{"anyOf":[{"$ref":"#/definitions/InputFidelity"},{"type":"null"}]},"input_image_mask":{"type":"object","description":"Optional mask for inpainting. Contains `image_url`\n(string, optional) and `file_id` (string, optional).\n","properties":{"image_url":{"type":"string","description":"Base64-encoded mask image.\n"},"file_id":{"type":"string","description":"File ID for the mask image.\n"}},"required":[],"additionalProperties":false},"partial_images":{"type":"integer","minimum":0,"maximum":3,"description":"Number of partial images to generate in streaming mode, from 0 (default value) to 3.\n","default":0},"action":{"$ref":"#/definitions/ImageGenActionEnum"}},"required":["type"]},"LocalShellToolParam":{"properties":{"type":{"type":"string","enum":["local_shell"],"description":"The type of the local shell tool. Always `local_shell`.","default":"local_shell"}},"type":"object","required":["type"],"title":"Local shell tool","description":"A tool that allows the model to execute shell commands in a local environment."},"FunctionShellToolParam":{"properties":{"type":{"type":"string","enum":["shell"],"description":"The type of the shell tool. Always `shell`.","default":"shell"},"environment":{"anyOf":[{"oneOf":[{"$ref":"#/definitions/ContainerAutoParam"},{"$ref":"#/definitions/LocalEnvironmentParam"},{"$ref":"#/definitions/ContainerReferenceParam"}]},{"type":"null"}]},"allowed_callers":{"anyOf":[{"items":{"$ref":"#/definitions/CallableToolAllowedCaller"},"type":"array","minItems":1,"description":"The tool invocation context(s)."},{"type":"null"}]}},"type":"object","required":["type"],"title":"Shell tool","description":"A tool that allows the model to execute shell commands."},"CustomToolParam":{"properties":{"type":{"type":"string","enum":["custom"],"description":"The type of the custom tool. Always `custom`.","default":"custom"},"name":{"type":"string","description":"The name of the custom tool, used to identify it in tool calls."},"async":{"type":"boolean","description":"Whether the tool response can be returned asynchronously versus immediately returned on next response creation."},"description":{"type":"string","description":"Optional description of the custom tool, used to provide more context."},"format":{"oneOf":[{"$ref":"#/definitions/CustomTextFormatParam"},{"$ref":"#/definitions/CustomGrammarFormatParam"}],"description":"The input format for the custom tool. Default is unconstrained text."},"defer_loading":{"type":"boolean","description":"Whether this tool should be deferred and discovered via tool search."},"allowed_callers":{"anyOf":[{"items":{"$ref":"#/definitions/CallableToolAllowedCaller"},"type":"array","minItems":1,"description":"The tool invocation context(s)."},{"type":"null"}]}},"type":"object","required":["type","name"],"title":"Custom tool","description":"A custom tool that processes input using a specified format. Learn more about   [custom tools](https://developers.openai.com/api/docs/guides/function-calling#custom-tools)"},"ToolSearchOutputNamespaceToolParam":{"properties":{"type":{"type":"string","enum":["namespace"],"description":"The type of the tool. Always `namespace`.","default":"namespace"},"name":{"type":"string","minLength":1,"description":"The namespace name used in tool calls (for example, `crm`)."},"description":{"type":"string","description":"A description of the namespace shown to the model."},"tools":{"items":{"oneOf":[{"$ref":"#/definitions/ToolSearchOutputFunctionToolParam"},{"$ref":"#/definitions/CustomToolParam"}],"description":"A function or custom tool loaded into a namespace by tool search."},"type":"array","minItems":1,"description":"The function/custom tools loaded inside this namespace."}},"type":"object","required":["type","name","description","tools"],"title":"Namespace","description":"Groups function/custom tools under a shared namespace."},"ToolSearchToolParam":{"properties":{"type":{"type":"string","enum":["tool_search"],"description":"The type of the tool. Always `tool_search`.","default":"tool_search"},"execution":{"$ref":"#/definitions/ToolSearchExecutionType"},"description":{"anyOf":[{"type":"string","description":"Description shown to the model for a client-executed tool search tool."},{"type":"null"}]},"parameters":{"anyOf":[{"$ref":"#/definitions/EmptyModelParam"},{"type":"null"}]}},"type":"object","required":["type"],"title":"Tool search tool","description":"Hosted or BYOT tool search configuration for deferred tools."},"WebSearchPreviewTool":{"properties":{"type":{"type":"string","enum":["web_search_preview","web_search_preview_2025_03_11"],"description":"The type of the web search tool. One of `web_search_preview` or `web_search_preview_2025_03_11`.","default":"web_search_preview"},"user_location":{"anyOf":[{"$ref":"#/definitions/ApproximateLocation"},{"type":"null"}]},"search_context_size":{"$ref":"#/definitions/SearchContextSize"},"search_content_types":{"items":{"$ref":"#/definitions/SearchContentType"},"type":"array"}},"type":"object","required":["type"],"title":"Web search preview","description":"This tool searches the web for relevant results to use in a response. Learn more about the [web search tool](https://developers.openai.com/api/docs/guides/tools-web-search)."},"ApplyPatchToolParam":{"properties":{"type":{"type":"string","enum":["apply_patch"],"description":"The type of the tool. Always `apply_patch`.","default":"apply_patch"},"allowed_callers":{"anyOf":[{"items":{"$ref":"#/definitions/CallableToolAllowedCaller"},"type":"array","minItems":1,"description":"The tool invocation context(s)."},{"type":"null"}]}},"type":"object","required":["type"],"title":"Apply patch tool","description":"Allows the assistant to create, delete, or update files using unified diffs."},"NamespaceToolParam":{"properties":{"type":{"type":"string","enum":["namespace"],"description":"The type of the tool. Always `namespace`.","default":"namespace"},"name":{"type":"string","minLength":1,"description":"The namespace name used in tool calls (for example, `crm`)."},"description":{"type":"string","description":"A description of the namespace shown to the model."},"tools":{"items":{"oneOf":[{"$ref":"#/definitions/FunctionToolParam"},{"$ref":"#/definitions/CustomToolParam"}],"description":"A function or custom tool that belongs to a namespace."},"type":"array","minItems":1,"description":"The function/custom tools available inside this namespace."}},"type":"object","required":["type","name","description","tools"],"title":"Namespace","description":"Groups function/custom tools under a shared namespace."},"ResponseFormatJsonSchemaSchema":{"type":"object","title":"JSON schema","description":"The schema for the response format, described as a JSON Schema object.\nLearn how to build JSON schemas [here](https://json-schema.org/).\n","additionalProperties":true},"ImageGenToolCallModerationDetails":{"properties":{"moderation_stage":{"type":"string","enum":["input","output","unknown"],"description":"The stage where moderation blocked the image generation call."},"categories":{"items":{"type":"string"},"type":"array","description":"Public moderation categories. New category values may be added over time."}},"type":"object","required":["moderation_stage","categories"]},"LocalSkillParam":{"properties":{"name":{"type":"string","description":"The name of the skill."},"description":{"type":"string","description":"The description of the skill."},"path":{"type":"string","description":"The path to the directory containing the skill."}},"type":"object","required":["name","description","path"]},"FunctionShellCallOutputOutcomeParam":{"oneOf":[{"$ref":"#/definitions/FunctionShellCallOutputTimeoutOutcomeParam"},{"$ref":"#/definitions/FunctionShellCallOutputExitOutcomeParam"}],"title":"Shell call outcome","description":"The exit or timeout outcome associated with this shell call."},"ApplyPatchCreateFileOperationParam":{"properties":{"type":{"type":"string","enum":["create_file"],"description":"The operation type. Always `create_file`.","default":"create_file"},"path":{"type":"string","minLength":1,"description":"Path of the file to create relative to the workspace root."},"diff":{"type":"string","maxLength":10485760,"description":"Unified diff content to apply when creating the file."}},"type":"object","required":["type","path","diff"],"title":"Apply patch create file operation","description":"Instruction for creating a new file via the apply_patch tool."},"ApplyPatchDeleteFileOperationParam":{"properties":{"type":{"type":"string","enum":["delete_file"],"description":"The operation type. Always `delete_file`.","default":"delete_file"},"path":{"type":"string","minLength":1,"description":"Path of the file to delete relative to the workspace root."}},"type":"object","required":["type","path"],"title":"Apply patch delete file operation","description":"Instruction for deleting an existing file via the apply_patch tool."},"ApplyPatchUpdateFileOperationParam":{"properties":{"type":{"type":"string","enum":["update_file"],"description":"The operation type. Always `update_file`.","default":"update_file"},"path":{"type":"string","minLength":1,"description":"Path of the file to update relative to the workspace root."},"diff":{"type":"string","maxLength":10485760,"description":"Unified diff content to apply to the existing file."}},"type":"object","required":["type","path","diff"],"title":"Apply patch update file operation","description":"Instruction for updating an existing file via the apply_patch tool."},"MCPProtocolError":{"properties":{"type":{"type":"string","enum":["mcp_protocol_error"],"default":"mcp_protocol_error"},"code":{"type":"integer"},"message":{"type":"string"}},"type":"object","required":["type","code","message"]},"MCPToolExecutionError":{"properties":{"type":{"type":"string","enum":["mcp_tool_execution_error"],"default":"mcp_tool_execution_error"},"content":{}},"type":"object","required":["type","content"]},"HTTPError":{"properties":{"type":{"type":"string","enum":["http_error"],"default":"http_error"},"code":{"type":"integer"},"message":{"type":"string"}},"type":"object","required":["type","code","message"]},"PromptCacheBreakpointConfig":{"properties":{"mode":{"type":"string","enum":["explicit"],"description":"The breakpoint mode. Always `explicit`.","default":"explicit"},"ttl":{"type":"string","enum":["30m","12h"],"description":"The minimum lifetime of this cache breakpoint. Defaults to the request TTL."}},"type":"object","required":["mode"],"title":"Prompt cache breakpoint","description":"Marks the exact end of a reusable prompt prefix. When `ttl` is omitted, the breakpoint inherits the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block."},"ImageDetail":{"type":"string","enum":["low","high","auto","original"]},"FileInputDetail":{"type":"string","enum":["auto","low","high"]},"Annotation":{"oneOf":[{"$ref":"#/definitions/FileCitationBody"},{"$ref":"#/definitions/UrlCitationBody"},{"$ref":"#/definitions/ContainerFileCitationBody"},{"$ref":"#/definitions/FilePath"}],"description":"An annotation that applies to a span of output text."},"LogProb":{"properties":{"token":{"type":"string"},"logprob":{"type":"number"},"bytes":{"items":{"type":"integer"},"type":"array"},"top_logprobs":{"items":{"$ref":"#/definitions/TopLogProb"},"type":"array"}},"type":"object","required":["token","logprob","bytes","top_logprobs"],"title":"Log probability","description":"The log probability of a token."},"ClickButtonType":{"type":"string","enum":["left","right","wheel","back","forward"]},"CoordParam":{"properties":{"x":{"type":"integer","description":"The x-coordinate."},"y":{"type":"integer","description":"The y-coordinate."}},"type":"object","required":["x","y"],"title":"Coordinate","description":"An x/y coordinate pair, e.g. `{ x: 100, y: 200 }`."},"CallableToolAllowedCaller":{"type":"string","enum":["direct","programmatic"]},"RankingOptions":{"properties":{"ranker":{"$ref":"#/definitions/RankerVersionType"},"score_threshold":{"type":"number","description":"The score threshold for the file search, a number between 0 and 1. Numbers closer to 1 will attempt to return only the most relevant results, but may return fewer results."},"hybrid_search":{"$ref":"#/definitions/HybridSearchOptions"}},"type":"object","required":[]},"Filters":{"anyOf":[{"$ref":"#/definitions/ComparisonFilter"},{"$ref":"#/definitions/CompoundFilter"}]},"ComputerEnvironment":{"type":"string","enum":["windows","mac","linux","ubuntu","browser"]},"WebSearchApproximateLocation":{"anyOf":[{"type":"object","title":"Web search approximate location","description":"The approximate location of the user.\n","properties":{"type":{"type":"string","enum":["approximate"],"description":"The type of location approximation. Always `approximate`.","default":"approximate"},"country":{"anyOf":[{"type":"string","description":"The two-letter [ISO country code](https://en.wikipedia.org/wiki/ISO_3166-1) of the user, e.g. `US`."},{"type":"null"}]},"region":{"anyOf":[{"type":"string","description":"Free text input for the region of the user, e.g. `California`."},{"type":"null"}]},"city":{"anyOf":[{"type":"string","description":"Free text input for the city of the user, e.g. `San Francisco`."},{"type":"null"}]},"timezone":{"anyOf":[{"type":"string","description":"The [IANA timezone](https://timeapi.io/documentation/iana-timezones) of the user, e.g. `America/Los_Angeles`."},{"type":"null"}]}}},{"type":"null"}]},"MCPToolFilter":{"type":"object","title":"MCP tool filter","description":"A filter object to specify which tools are allowed.\n","properties":{"tool_names":{"type":"array","title":"MCP allowed tools","items":{"type":"string"},"description":"List of allowed tool names."},"read_only":{"type":"boolean","description":"Indicates whether or not a tool modifies data or is read-only. If an\nMCP server is [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),\nit will match this filter.\n"}},"required":[],"additionalProperties":false},"AutoCodeInterpreterToolParam":{"properties":{"type":{"type":"string","enum":["auto"],"description":"Always `auto`.","default":"auto"},"file_ids":{"items":{"type":"string","examples":["file-123"]},"type":"array","maxItems":50,"description":"An optional list of uploaded files to make available to your code."},"memory_limit":{"anyOf":[{"$ref":"#/definitions/ContainerMemoryLimit"},{"type":"null"}]},"network_policy":{"oneOf":[{"$ref":"#/definitions/ContainerNetworkPolicyDisabledParam"},{"$ref":"#/definitions/ContainerNetworkPolicyAllowlistParam"}],"description":"Network access policy for the container."}},"type":"object","required":["type"],"title":"CodeInterpreterToolAuto","description":"Configuration for a code interpreter container. Optionally specify the IDs of the files to run the code on."},"InputFidelity":{"type":"string","enum":["high","low"],"description":"Control how much effort the model will exert to match the style and features, especially facial features, of input images. Supports `high` and `low` on `gpt-image-1.5`; `gpt-image-1-mini` supports only `low`. For `gpt-image-2`, omit this parameter. Defaults to `low` on supported models."},"ContainerAutoParam":{"properties":{"type":{"type":"string","enum":["container_auto"],"description":"Automatically creates a container for this request","default":"container_auto"},"file_ids":{"items":{"type":"string","examples":["file-123"]},"type":"array","maxItems":50,"description":"An optional list of uploaded files to make available to your code."},"memory_limit":{"anyOf":[{"$ref":"#/definitions/ContainerMemoryLimit"},{"type":"null"}]},"network_policy":{"oneOf":[{"$ref":"#/definitions/ContainerNetworkPolicyDisabledParam"},{"$ref":"#/definitions/ContainerNetworkPolicyAllowlistParam"}],"description":"Network access policy for the container."},"skills":{"items":{"oneOf":[{"$ref":"#/definitions/SkillReferenceParam"},{"$ref":"#/definitions/InlineSkillParam"}]},"type":"array","maxItems":200,"description":"An optional list of skills referenced by id or inline data."}},"type":"object","required":["type"]},"CustomTextFormatParam":{"properties":{"type":{"type":"string","enum":["text"],"description":"Unconstrained text format. Always `text`.","default":"text"}},"type":"object","required":["type"],"title":"Text format","description":"Unconstrained free-form text."},"CustomGrammarFormatParam":{"properties":{"type":{"type":"string","enum":["grammar"],"description":"Grammar format. Always `grammar`.","default":"grammar"},"syntax":{"$ref":"#/definitions/GrammarSyntax1"},"definition":{"type":"string","description":"The grammar definition."}},"type":"object","required":["type","syntax","definition"],"title":"Grammar format","description":"A grammar defined by the user."},"ToolSearchOutputFunctionToolParam":{"properties":{"name":{"type":"string","maxLength":128,"minLength":1,"pattern":"^(?![\\s\\S]*[\\r\\n])[a-zA-Z0-9_.-]+$","description":"The name of the loaded function tool."},"description":{"anyOf":[{"type":"string"},{"type":"null"}]},"parameters":{"anyOf":[{"$ref":"#/definitions/EmptyModelParam"},{"type":"null"}]},"strict":{"anyOf":[{"type":"boolean","description":"Whether to enforce strict parameter validation. If omitted, Responses attempts to use strict validation when the schema is compatible, and falls back to non-strict validation otherwise."},{"type":"null"}]},"type":{"type":"string","enum":["function"],"default":"function"},"async":{"type":"boolean","description":"Whether the tool response can be returned asynchronously versus immediately returned on next response creation."},"output_schema":{"anyOf":[{"additionalProperties":{},"type":"object","description":"A JSON Schema describing the JSON value encoded in string outputs for this function tool. This does not describe content-array outputs."},{"type":"null"}]},"defer_loading":{"type":"boolean","description":"Whether this function should be deferred and discovered via tool search."},"allowed_callers":{"anyOf":[{"items":{"$ref":"#/definitions/CallableToolAllowedCaller"},"type":"array","minItems":1,"description":"The tool invocation context(s)."},{"type":"null"}]}},"type":"object","required":["name","type"]},"ApproximateLocation":{"properties":{"type":{"type":"string","enum":["approximate"],"description":"The type of location approximation. Always `approximate`.","default":"approximate"},"country":{"anyOf":[{"type":"string","description":"The two-letter [ISO country code](https://en.wikipedia.org/wiki/ISO_3166-1) of the user, e.g. `US`."},{"type":"null"}]},"region":{"anyOf":[{"type":"string","description":"Free text input for the region of the user, e.g. `California`."},{"type":"null"}]},"city":{"anyOf":[{"type":"string","description":"Free text input for the city of the user, e.g. `San Francisco`."},{"type":"null"}]},"timezone":{"anyOf":[{"type":"string","description":"The [IANA timezone](https://timeapi.io/documentation/iana-timezones) of the user, e.g. `America/Los_Angeles`."},{"type":"null"}]}},"type":"object","required":["type"]},"SearchContextSize":{"type":"string","enum":["low","medium","high"]},"SearchContentType":{"type":"string","enum":["text","image"]},"FunctionToolParam":{"properties":{"name":{"type":"string","maxLength":128,"minLength":1,"pattern":"^[a-zA-Z0-9_-]+$"},"description":{"anyOf":[{"type":"string"},{"type":"null"}]},"parameters":{"anyOf":[{"$ref":"#/definitions/EmptyModelParam"},{"type":"null"}]},"strict":{"anyOf":[{"type":"boolean","description":"Whether to enforce strict parameter validation. If omitted, Responses attempts to use strict validation when the schema is compatible, and falls back to non-strict validation otherwise."},{"type":"null"}]},"type":{"type":"string","enum":["function"],"default":"function"},"async":{"type":"boolean","description":"Whether the tool response can be returned asynchronously versus immediately returned on next response creation."},"output_schema":{"anyOf":[{"additionalProperties":{},"type":"object","description":"A JSON Schema describing the JSON value encoded in string outputs for this function tool. This does not describe content-array outputs."},{"type":"null"}]},"defer_loading":{"type":"boolean","description":"Whether this function should be deferred and discovered via tool search."},"allowed_callers":{"anyOf":[{"items":{"$ref":"#/definitions/CallableToolAllowedCaller"},"type":"array","minItems":1,"description":"The tool invocation context(s)."},{"type":"null"}]}},"type":"object","required":["name","type"]},"FunctionShellCallOutputTimeoutOutcomeParam":{"properties":{"type":{"type":"string","enum":["timeout"],"description":"The outcome type. Always `timeout`.","default":"timeout"}},"type":"object","required":["type"],"title":"Shell call timeout outcome","description":"Indicates that the shell call exceeded its configured time limit."},"FunctionShellCallOutputExitOutcomeParam":{"properties":{"type":{"type":"string","enum":["exit"],"description":"The outcome type. Always `exit`.","default":"exit"},"exit_code":{"type":"integer","description":"The exit code returned by the shell process."}},"type":"object","required":["type","exit_code"],"title":"Shell call exit outcome","description":"Indicates that the shell commands finished and returned an exit code."},"FileCitationBody":{"properties":{"type":{"type":"string","enum":["file_citation"],"description":"The type of the file citation. Always `file_citation`.","default":"file_citation"},"file_id":{"type":"string","description":"The ID of the file."},"index":{"type":"integer","description":"The index in the output text at which to insert the file citation."},"filename":{"type":"string","description":"The filename of the file cited."}},"type":"object","required":["type","file_id","index","filename"],"title":"File citation","description":"A citation to a file."},"UrlCitationBody":{"properties":{"type":{"type":"string","enum":["url_citation"],"description":"The type of the URL citation. Always `url_citation`.","default":"url_citation"},"url":{"type":"string","format":"uri","description":"The URL of the web resource."},"start_index":{"type":"integer","description":"The index of the first character of the URL citation in the message."},"end_index":{"type":"integer","description":"The index of the last character of the URL citation in the message."},"title":{"type":"string","description":"The title of the web resource."}},"type":"object","required":["type","url","start_index","end_index","title"],"title":"URL citation","description":"A citation for a web resource used to generate a model response."},"ContainerFileCitationBody":{"properties":{"type":{"type":"string","enum":["container_file_citation"],"description":"The type of the container file citation. Always `container_file_citation`.","default":"container_file_citation"},"container_id":{"type":"string","description":"The ID of the container file."},"file_id":{"type":"string","description":"The ID of the file."},"start_index":{"type":"integer","description":"The index of the first character of the container file citation in the message."},"end_index":{"type":"integer","description":"The index of the last character of the container file citation in the message."},"filename":{"type":"string","description":"The filename of the container file cited."}},"type":"object","required":["type","container_id","file_id","start_index","end_index","filename"],"title":"Container file citation","description":"A citation for a container file used to generate a model response."},"FilePath":{"type":"object","title":"File path","description":"A path to a file.\n","properties":{"type":{"type":"string","description":"The type of the file path. Always `file_path`.\n","enum":["file_path"]},"file_id":{"type":"string","description":"The ID of the file.\n"},"index":{"type":"integer","description":"The index of the file in the list of files.\n"}},"required":["type","file_id","index"]},"TopLogProb":{"properties":{"token":{"type":"string"},"logprob":{"type":"number"},"bytes":{"items":{"type":"integer"},"type":"array"}},"type":"object","required":["token","logprob","bytes"],"title":"Top log probability","description":"The top log probability of a token."},"RankerVersionType":{"type":"string","enum":["auto","default-2024-11-15"]},"HybridSearchOptions":{"properties":{"embedding_weight":{"type":"number","description":"The weight of the embedding in the reciprocal ranking fusion."},"text_weight":{"type":"number","description":"The weight of the text in the reciprocal ranking fusion."}},"type":"object","required":["embedding_weight","text_weight"]},"ComparisonFilter":{"type":"object","additionalProperties":false,"title":"Comparison Filter","description":"A filter used to compare a specified attribute key to a given value using a defined comparison operation.\n","properties":{"type":{"type":"string","default":"eq","enum":["eq","ne","gt","gte","lt","lte","in","nin"],"description":"Specifies the comparison operator: `eq`, `ne`, `gt`, `gte`, `lt`, `lte`, `in`, `nin`.\n- `eq`: equals\n- `ne`: not equal\n- `gt`: greater than\n- `gte`: greater than or equal\n- `lt`: less than\n- `lte`: less than or equal\n- `in`: in\n- `nin`: not in\n"},"key":{"type":"string","description":"The key to compare against the value."},"value":{"oneOf":[{"type":"string"},{"type":"number"},{"type":"boolean"},{"type":"array","items":{"oneOf":[{"type":"string"},{"type":"number"}]}}],"description":"The value to compare against the attribute key; supports string, number, or boolean types."}},"required":["type","key","value"]},"CompoundFilter":{"type":"object","additionalProperties":false,"title":"Compound Filter","description":"Combine multiple filters using `and` or `or`.","properties":{"type":{"type":"string","description":"Type of operation: `and` or `or`.","enum":["and","or"]},"filters":{"type":"array","description":"Array of filters to combine. Items can be `ComparisonFilter` or `CompoundFilter`.","items":{"oneOf":[{"$ref":"#/definitions/ComparisonFilter"},{"$ref":"#/definitions/CompoundFilter"}]}}},"required":["type","filters"]},"ContainerMemoryLimit":{"type":"string","enum":["1g","4g","16g","64g"]},"ContainerNetworkPolicyDisabledParam":{"properties":{"type":{"type":"string","enum":["disabled"],"description":"Disable outbound network access. Always `disabled`.","default":"disabled"}},"type":"object","required":["type"]},"ContainerNetworkPolicyAllowlistParam":{"properties":{"type":{"type":"string","enum":["allowlist"],"description":"Allow outbound network access only to specified domains. Always `allowlist`.","default":"allowlist"},"allowed_domains":{"items":{"type":"string"},"type":"array","minItems":1,"description":"A list of allowed domains when type is `allowlist`."},"domain_secrets":{"items":{"$ref":"#/definitions/ContainerNetworkPolicyDomainSecretParam"},"type":"array","minItems":1,"description":"Optional domain-scoped secrets for allowlisted domains."}},"type":"object","required":["type","allowed_domains"]},"SkillReferenceParam":{"properties":{"type":{"type":"string","enum":["skill_reference"],"description":"References a skill created with the /v1/skills endpoint.","default":"skill_reference"},"skill_id":{"type":"string","maxLength":64,"minLength":1,"description":"The ID of the referenced skill."},"version":{"type":"string","description":"Optional skill version. Use a positive integer or 'latest'. Omit for default."}},"type":"object","required":["type","skill_id"]},"InlineSkillParam":{"properties":{"type":{"type":"string","enum":["inline"],"description":"Defines an inline skill for this request.","default":"inline"},"name":{"type":"string","description":"The name of the skill."},"description":{"type":"string","description":"The description of the skill."},"source":{"$ref":"#/definitions/InlineSkillSourceParam"}},"type":"object","required":["type","name","description","source"]},"GrammarSyntax1":{"type":"string","enum":["lark","regex"]},"ContainerNetworkPolicyDomainSecretParam":{"properties":{"domain":{"type":"string","minLength":1,"description":"The domain associated with the secret."},"name":{"type":"string","minLength":1,"description":"The name of the secret to inject for the domain."},"value":{"type":"string","maxLength":10485760,"minLength":1,"description":"The secret value to inject for the domain."}},"type":"object","required":["domain","name","value"]},"InlineSkillSourceParam":{"properties":{"type":{"type":"string","enum":["base64"],"description":"The type of the inline skill source. Must be `base64`.","default":"base64"},"media_type":{"type":"string","enum":["application/zip"],"description":"The media type of the inline skill payload. Must be `application/zip`.","default":"application/zip"},"data":{"type":"string","maxLength":70254592,"minLength":1,"description":"Base64-encoded skill zip bundle."}},"type":"object","required":["type","media_type","data"],"description":"Inline skill payload"}}},"name":"Compact conversation","id":"openai.compactconversation","example":{},"maxRequests":1,"summary":false}}