{
  "$schema": "http://json-schema.org/draft-07/schema#",
  "title": "CodexAppServerProtocolV2",
  "type": "object",
  "definitions": {
    "ApprovalsReviewer": {
      "description": "Configures who approval requests are routed to for review. Examples include sandbox escapes, blocked network access, MCP approval prompts, and ARC escalations. Defaults to `user`. `guardian_subagent` uses a carefully prompted subagent to gather relevant context and apply a risk-based decision framework before approving or denying the request.",
      "type": "string",
      "enum": [
        "user",
        "guardian_subagent"
      ]
    },
    "AskForApproval": {
      "oneOf": [
        {
          "type": "string",
          "enum": [
            "untrusted",
            "on-failure",
            "on-request",
            "never"
          ]
        },
        {
          "type": "object",
          "required": [
            "granular"
          ],
          "properties": {
            "granular": {
              "type": "object",
              "required": [
                "mcp_elicitations",
                "rules",
                "sandbox_approval"
              ],
              "properties": {
                "mcp_elicitations": {
                  "type": "boolean"
                },
                "request_permissions": {
                  "default": false,
                  "type": "boolean"
                },
                "rules": {
                  "type": "boolean"
                },
                "sandbox_approval": {
                  "type": "boolean"
                },
                "skill_approval": {
                  "default": false,
                  "type": "boolean"
                }
              }
            }
          },
          "additionalProperties": false,
          "title": "GranularAskForApproval"
        }
      ]
    },
    "DynamicToolSpec": {
      "type": "object",
      "required": [
        "description",
        "inputSchema",
        "name"
      ],
      "properties": {
        "deferLoading": {
          "type": "boolean"
        },
        "description": {
          "type": "string"
        },
        "inputSchema": true,
        "name": {
          "type": "string"
        }
      }
    },
    "Personality": {
      "type": "string",
      "enum": [
        "none",
        "friendly",
        "pragmatic"
      ]
    },
    "SandboxMode": {
      "type": "string",
      "enum": [
        "read-only",
        "workspace-write",
        "danger-full-access"
      ]
    },
    "ServiceTier": {
      "type": "string",
      "enum": [
        "fast",
        "flex"
      ]
    },
    "ThreadStartSource": {
      "type": "string",
      "enum": [
        "startup",
        "clear"
      ]
    },
    "ThreadStartParams": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ThreadStartParams",
      "type": "object",
      "properties": {
        "approvalPolicy": {
          "anyOf": [
            {
              "$ref": "#/definitions/AskForApproval"
            },
            {
              "type": "null"
            }
          ]
        },
        "approvalsReviewer": {
          "description": "Override where approval requests are routed for review on this thread and subsequent turns.",
          "anyOf": [
            {
              "$ref": "#/definitions/ApprovalsReviewer"
            },
            {
              "type": "null"
            }
          ]
        },
        "baseInstructions": {
          "type": [
            "string",
            "null"
          ]
        },
        "config": {
          "type": [
            "object",
            "null"
          ],
          "additionalProperties": true
        },
        "cwd": {
          "type": [
            "string",
            "null"
          ]
        },
        "developerInstructions": {
          "type": [
            "string",
            "null"
          ]
        },
        "serviceName": {
          "type": [
            "string",
            "null"
          ]
        },
        "ephemeral": {
          "type": [
            "boolean",
            "null"
          ]
        },
        "serviceTier": {
          "anyOf": [
            {
              "anyOf": [
                {
                  "$ref": "#/definitions/ServiceTier"
                },
                {
                  "type": "null"
                }
              ]
            },
            {
              "type": "null"
            }
          ]
        },
        "sessionStartSource": {
          "anyOf": [
            {
              "$ref": "#/definitions/ThreadStartSource"
            },
            {
              "type": "null"
            }
          ]
        },
        "model": {
          "type": [
            "string",
            "null"
          ]
        },
        "modelProvider": {
          "type": [
            "string",
            "null"
          ]
        },
        "sandbox": {
          "anyOf": [
            {
              "$ref": "#/definitions/SandboxMode"
            },
            {
              "type": "null"
            }
          ]
        },
        "personality": {
          "anyOf": [
            {
              "$ref": "#/definitions/Personality"
            },
            {
              "type": "null"
            }
          ]
        }
      }
    },
    "ContentItem": {
      "oneOf": [
        {
          "type": "object",
          "required": [
            "text",
            "type"
          ],
          "properties": {
            "text": {
              "type": "string"
            },
            "type": {
              "type": "string",
              "enum": [
                "input_text"
              ],
              "title": "InputTextContentItemType"
            }
          },
          "title": "InputTextContentItem"
        },
        {
          "type": "object",
          "required": [
            "image_url",
            "type"
          ],
          "properties": {
            "detail": {
              "anyOf": [
                {
                  "$ref": "#/definitions/ImageDetail"
                },
                {
                  "type": "null"
                }
              ]
            },
            "image_url": {
              "type": "string"
            },
            "type": {
              "type": "string",
              "enum": [
                "input_image"
              ],
              "title": "InputImageContentItemType"
            }
          },
          "title": "InputImageContentItem"
        },
        {
          "type": "object",
          "required": [
            "text",
            "type"
          ],
          "properties": {
            "text": {
              "type": "string"
            },
            "type": {
              "type": "string",
              "enum": [
                "output_text"
              ],
              "title": "OutputTextContentItemType"
            }
          },
          "title": "OutputTextContentItem"
        }
      ]
    },
    "FunctionCallOutputBody": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "array",
          "items": {
            "$ref": "#/definitions/FunctionCallOutputContentItem"
          }
        }
      ]
    },
    "FunctionCallOutputContentItem": {
      "description": "Responses API compatible content items that can be returned by a tool call. This is a subset of ContentItem with the types we support as function call outputs.",
      "oneOf": [
        {
          "type": "object",
          "required": [
            "text",
            "type"
          ],
          "properties": {
            "text": {
              "type": "string"
            },
            "type": {
              "type": "string",
              "enum": [
                "input_text"
              ],
              "title": "InputTextFunctionCallOutputContentItemType"
            }
          },
          "title": "InputTextFunctionCallOutputContentItem"
        },
        {
          "type": "object",
          "required": [
            "image_url",
            "type"
          ],
          "properties": {
            "detail": {
              "anyOf": [
                {
                  "$ref": "#/definitions/ImageDetail"
                },
                {
                  "type": "null"
                }
              ]
            },
            "image_url": {
              "type": "string"
            },
            "type": {
              "type": "string",
              "enum": [
                "input_image"
              ],
              "title": "InputImageFunctionCallOutputContentItemType"
            }
          },
          "title": "InputImageFunctionCallOutputContentItem"
        }
      ]
    },
    "GhostCommit": {
      "description": "Details of a ghost commit created from a repository state.",
      "type": "object",
      "required": [
        "id",
        "preexisting_untracked_dirs",
        "preexisting_untracked_files"
      ],
      "properties": {
        "id": {
          "type": "string"
        },
        "parent": {
          "type": [
            "string",
            "null"
          ]
        },
        "preexisting_untracked_dirs": {
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "preexisting_untracked_files": {
          "type": "array",
          "items": {
            "type": "string"
          }
        }
      }
    },
    "ImageDetail": {
      "type": "string",
      "enum": [
        "auto",
        "low",
        "high",
        "original"
      ]
    },
    "LocalShellAction": {
      "oneOf": [
        {
          "type": "object",
          "required": [
            "command",
            "type"
          ],
          "properties": {
            "command": {
              "type": "array",
              "items": {
                "type": "string"
              }
            },
            "env": {
              "type": [
                "object",
                "null"
              ],
              "additionalProperties": {
                "type": "string"
              }
            },
            "timeout_ms": {
              "type": [
                "integer",
                "null"
              ],
              "format": "uint64",
              "minimum": 0.0
            },
            "type": {
              "type": "string",
              "enum": [
                "exec"
              ],
              "title": "ExecLocalShellActionType"
            },
            "user": {
              "type": [
                "string",
                "null"
              ]
            },
            "working_directory": {
              "type": [
                "string",
                "null"
              ]
            }
          },
          "title": "ExecLocalShellAction"
        }
      ]
    },
    "LocalShellStatus": {
      "type": "string",
      "enum": [
        "completed",
        "in_progress",
        "incomplete"
      ]
    },
    "MessagePhase": {
      "description": "Classifies an assistant message as interim commentary or final answer text.\n\nProviders do not emit this consistently, so callers must treat `None` as \"phase unknown\" and keep compatibility behavior for legacy models.",
      "oneOf": [
        {
          "description": "Mid-turn assistant text (for example preamble/progress narration).\n\nAdditional tool calls or assistant output may follow before turn completion.",
          "type": "string",
          "enum": [
            "commentary"
          ]
        },
        {
          "description": "The assistant's terminal answer text for the current turn.",
          "type": "string",
          "enum": [
            "final_answer"
          ]
        }
      ]
    },
    "ReasoningItemContent": {
      "oneOf": [
        {
          "type": "object",
          "required": [
            "text",
            "type"
          ],
          "properties": {
            "text": {
              "type": "string"
            },
            "type": {
              "type": "string",
              "enum": [
                "reasoning_text"
              ],
              "title": "ReasoningTextReasoningItemContentType"
            }
          },
          "title": "ReasoningTextReasoningItemContent"
        },
        {
          "type": "object",
          "required": [
            "text",
            "type"
          ],
          "properties": {
            "text": {
              "type": "string"
            },
            "type": {
              "type": "string",
              "enum": [
                "text"
              ],
              "title": "TextReasoningItemContentType"
            }
          },
          "title": "TextReasoningItemContent"
        }
      ]
    },
    "ReasoningItemReasoningSummary": {
      "oneOf": [
        {
          "type": "object",
          "required": [
            "text",
            "type"
          ],
          "properties": {
            "text": {
              "type": "string"
            },
            "type": {
              "type": "string",
              "enum": [
                "summary_text"
              ],
              "title": "SummaryTextReasoningItemReasoningSummaryType"
            }
          },
          "title": "SummaryTextReasoningItemReasoningSummary"
        }
      ]
    },
    "ResponseItem": {
      "oneOf": [
        {
          "type": "object",
          "required": [
            "content",
            "role",
            "type"
          ],
          "properties": {
            "content": {
              "type": "array",
              "items": {
                "$ref": "#/definitions/ContentItem"
              }
            },
            "end_turn": {
              "type": [
                "boolean",
                "null"
              ]
            },
            "id": {
              "writeOnly": true,
              "type": [
                "string",
                "null"
              ]
            },
            "phase": {
              "anyOf": [
                {
                  "$ref": "#/definitions/MessagePhase"
                },
                {
                  "type": "null"
                }
              ]
            },
            "role": {
              "type": "string"
            },
            "type": {
              "type": "string",
              "enum": [
                "message"
              ],
              "title": "MessageResponseItemType"
            }
          },
          "title": "MessageResponseItem"
        },
        {
          "type": "object",
          "required": [
            "summary",
            "type"
          ],
          "properties": {
            "content": {
              "default": null,
              "type": [
                "array",
                "null"
              ],
              "items": {
                "$ref": "#/definitions/ReasoningItemContent"
              }
            },
            "encrypted_content": {
              "type": [
                "string",
                "null"
              ]
            },
            "summary": {
              "type": "array",
              "items": {
                "$ref": "#/definitions/ReasoningItemReasoningSummary"
              }
            },
            "type": {
              "type": "string",
              "enum": [
                "reasoning"
              ],
              "title": "ReasoningResponseItemType"
            }
          },
          "title": "ReasoningResponseItem"
        },
        {
          "type": "object",
          "required": [
            "action",
            "status",
            "type"
          ],
          "properties": {
            "action": {
              "$ref": "#/definitions/LocalShellAction"
            },
            "call_id": {
              "description": "Set when using the Responses API.",
              "type": [
                "string",
                "null"
              ]
            },
            "id": {
              "description": "Legacy id field retained for compatibility with older payloads.",
              "writeOnly": true,
              "type": [
                "string",
                "null"
              ]
            },
            "status": {
              "$ref": "#/definitions/LocalShellStatus"
            },
            "type": {
              "type": "string",
              "enum": [
                "local_shell_call"
              ],
              "title": "LocalShellCallResponseItemType"
            }
          },
          "title": "LocalShellCallResponseItem"
        },
        {
          "type": "object",
          "required": [
            "arguments",
            "call_id",
            "name",
            "type"
          ],
          "properties": {
            "arguments": {
              "type": "string"
            },
            "call_id": {
              "type": "string"
            },
            "id": {
              "writeOnly": true,
              "type": [
                "string",
                "null"
              ]
            },
            "name": {
              "type": "string"
            },
            "namespace": {
              "type": [
                "string",
                "null"
              ]
            },
            "type": {
              "type": "string",
              "enum": [
                "function_call"
              ],
              "title": "FunctionCallResponseItemType"
            }
          },
          "title": "FunctionCallResponseItem"
        },
        {
          "type": "object",
          "required": [
            "arguments",
            "execution",
            "type"
          ],
          "properties": {
            "arguments": true,
            "call_id": {
              "type": [
                "string",
                "null"
              ]
            },
            "execution": {
              "type": "string"
            },
            "id": {
              "writeOnly": true,
              "type": [
                "string",
                "null"
              ]
            },
            "status": {
              "type": [
                "string",
                "null"
              ]
            },
            "type": {
              "type": "string",
              "enum": [
                "tool_search_call"
              ],
              "title": "ToolSearchCallResponseItemType"
            }
          },
          "title": "ToolSearchCallResponseItem"
        },
        {
          "type": "object",
          "required": [
            "call_id",
            "output",
            "type"
          ],
          "properties": {
            "call_id": {
              "type": "string"
            },
            "output": {
              "$ref": "#/definitions/FunctionCallOutputBody"
            },
            "type": {
              "type": "string",
              "enum": [
                "function_call_output"
              ],
              "title": "FunctionCallOutputResponseItemType"
            }
          },
          "title": "FunctionCallOutputResponseItem"
        },
        {
          "type": "object",
          "required": [
            "call_id",
            "input",
            "name",
            "type"
          ],
          "properties": {
            "call_id": {
              "type": "string"
            },
            "id": {
              "writeOnly": true,
              "type": [
                "string",
                "null"
              ]
            },
            "input": {
              "type": "string"
            },
            "name": {
              "type": "string"
            },
            "status": {
              "type": [
                "string",
                "null"
              ]
            },
            "type": {
              "type": "string",
              "enum": [
                "custom_tool_call"
              ],
              "title": "CustomToolCallResponseItemType"
            }
          },
          "title": "CustomToolCallResponseItem"
        },
        {
          "type": "object",
          "required": [
            "call_id",
            "output",
            "type"
          ],
          "properties": {
            "call_id": {
              "type": "string"
            },
            "name": {
              "type": [
                "string",
                "null"
              ]
            },
            "output": {
              "$ref": "#/definitions/FunctionCallOutputBody"
            },
            "type": {
              "type": "string",
              "enum": [
                "custom_tool_call_output"
              ],
              "title": "CustomToolCallOutputResponseItemType"
            }
          },
          "title": "CustomToolCallOutputResponseItem"
        },
        {
          "type": "object",
          "required": [
            "execution",
            "status",
            "tools",
            "type"
          ],
          "properties": {
            "call_id": {
              "type": [
                "string",
                "null"
              ]
            },
            "execution": {
              "type": "string"
            },
            "status": {
              "type": "string"
            },
            "tools": {
              "type": "array",
              "items": true
            },
            "type": {
              "type": "string",
              "enum": [
                "tool_search_output"
              ],
              "title": "ToolSearchOutputResponseItemType"
            }
          },
          "title": "ToolSearchOutputResponseItem"
        },
        {
          "type": "object",
          "required": [
            "type"
          ],
          "properties": {
            "action": {
              "anyOf": [
                {
                  "$ref": "#/definitions/ResponsesApiWebSearchAction"
                },
                {
                  "type": "null"
                }
              ]
            },
            "id": {
              "writeOnly": true,
              "type": [
                "string",
                "null"
              ]
            },
            "status": {
              "type": [
                "string",
                "null"
              ]
            },
            "type": {
              "type": "string",
              "enum": [
                "web_search_call"
              ],
              "title": "WebSearchCallResponseItemType"
            }
          },
          "title": "WebSearchCallResponseItem"
        },
        {
          "type": "object",
          "required": [
            "id",
            "result",
            "status",
            "type"
          ],
          "properties": {
            "id": {
              "type": "string"
            },
            "result": {
              "type": "string"
            },
            "revised_prompt": {
              "type": [
                "string",
                "null"
              ]
            },
            "status": {
              "type": "string"
            },
            "type": {
              "type": "string",
              "enum": [
                "image_generation_call"
              ],
              "title": "ImageGenerationCallResponseItemType"
            }
          },
          "title": "ImageGenerationCallResponseItem"
        },
        {
          "type": "object",
          "required": [
            "ghost_commit",
            "type"
          ],
          "properties": {
            "ghost_commit": {
              "$ref": "#/definitions/GhostCommit"
            },
            "type": {
              "type": "string",
              "enum": [
                "ghost_snapshot"
              ],
              "title": "GhostSnapshotResponseItemType"
            }
          },
          "title": "GhostSnapshotResponseItem"
        },
        {
          "type": "object",
          "required": [
            "encrypted_content",
            "type"
          ],
          "properties": {
            "encrypted_content": {
              "type": "string"
            },
            "type": {
              "type": "string",
              "enum": [
                "compaction"
              ],
              "title": "CompactionResponseItemType"
            }
          },
          "title": "CompactionResponseItem"
        },
        {
          "type": "object",
          "required": [
            "type"
          ],
          "properties": {
            "type": {
              "type": "string",
              "enum": [
                "other"
              ],
              "title": "OtherResponseItemType"
            }
          },
          "title": "OtherResponseItem"
        }
      ]
    },
    "ResponsesApiWebSearchAction": {
      "oneOf": [
        {
          "type": "object",
          "required": [
            "type"
          ],
          "properties": {
            "queries": {
              "type": [
                "array",
                "null"
              ],
              "items": {
                "type": "string"
              }
            },
            "query": {
              "type": [
                "string",
                "null"
              ]
            },
            "type": {
              "type": "string",
              "enum": [
                "search"
              ],
              "title": "SearchResponsesApiWebSearchActionType"
            }
          },
          "title": "SearchResponsesApiWebSearchAction"
        },
        {
          "type": "object",
          "required": [
            "type"
          ],
          "properties": {
            "type": {
              "type": "string",
              "enum": [
                "open_page"
              ],
              "title": "OpenPageResponsesApiWebSearchActionType"
            },
            "url": {
              "type": [
                "string",
                "null"
              ]
            }
          },
          "title": "OpenPageResponsesApiWebSearchAction"
        },
        {
          "type": "object",
          "required": [
            "type"
          ],
          "properties": {
            "pattern": {
              "type": [
                "string",
                "null"
              ]
            },
            "type": {
              "type": "string",
              "enum": [
                "find_in_page"
              ],
              "title": "FindInPageResponsesApiWebSearchActionType"
            },
            "url": {
              "type": [
                "string",
                "null"
              ]
            }
          },
          "title": "FindInPageResponsesApiWebSearchAction"
        },
        {
          "type": "object",
          "required": [
            "type"
          ],
          "properties": {
            "type": {
              "type": "string",
              "enum": [
                "other"
              ],
              "title": "OtherResponsesApiWebSearchActionType"
            }
          },
          "title": "OtherResponsesApiWebSearchAction"
        }
      ]
    },
    "ThreadResumeParams": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ThreadResumeParams",
      "description": "There are three ways to resume a thread: 1. By thread_id: load the thread from disk by thread_id and resume it. 2. By history: instantiate the thread from memory and resume it. 3. By path: load the thread from disk by path and resume it.\n\nThe precedence is: history > path > thread_id. If using history or path, the thread_id param will be ignored.\n\nPrefer using thread_id whenever possible.",
      "type": "object",
      "required": [
        "threadId"
      ],
      "properties": {
        "approvalPolicy": {
          "anyOf": [
            {
              "$ref": "#/definitions/AskForApproval"
            },
            {
              "type": "null"
            }
          ]
        },
        "approvalsReviewer": {
          "description": "Override where approval requests are routed for review on this thread and subsequent turns.",
          "anyOf": [
            {
              "$ref": "#/definitions/ApprovalsReviewer"
            },
            {
              "type": "null"
            }
          ]
        },
        "baseInstructions": {
          "type": [
            "string",
            "null"
          ]
        },
        "config": {
          "type": [
            "object",
            "null"
          ],
          "additionalProperties": true
        },
        "cwd": {
          "type": [
            "string",
            "null"
          ]
        },
        "developerInstructions": {
          "type": [
            "string",
            "null"
          ]
        },
        "serviceTier": {
          "anyOf": [
            {
              "anyOf": [
                {
                  "$ref": "#/definitions/ServiceTier"
                },
                {
                  "type": "null"
                }
              ]
            },
            {
              "type": "null"
            }
          ]
        },
        "model": {
          "description": "Configuration overrides for the resumed thread, if any.",
          "type": [
            "string",
            "null"
          ]
        },
        "modelProvider": {
          "type": [
            "string",
            "null"
          ]
        },
        "threadId": {
          "type": "string"
        },
        "sandbox": {
          "anyOf": [
            {
              "$ref": "#/definitions/SandboxMode"
            },
            {
              "type": "null"
            }
          ]
        },
        "personality": {
          "anyOf": [
            {
              "$ref": "#/definitions/Personality"
            },
            {
              "type": "null"
            }
          ]
        }
      }
    },
    "ThreadForkParams": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ThreadForkParams",
      "description": "There are two ways to fork a thread: 1. By thread_id: load the thread from disk by thread_id and fork it into a new thread. 2. By path: load the thread from disk by path and fork it into a new thread.\n\nIf using path, the thread_id param will be ignored.\n\nPrefer using thread_id whenever possible.",
      "type": "object",
      "required": [
        "threadId"
      ],
      "properties": {
        "approvalPolicy": {
          "anyOf": [
            {
              "$ref": "#/definitions/AskForApproval"
            },
            {
              "type": "null"
            }
          ]
        },
        "approvalsReviewer": {
          "description": "Override where approval requests are routed for review on this thread and subsequent turns.",
          "anyOf": [
            {
              "$ref": "#/definitions/ApprovalsReviewer"
            },
            {
              "type": "null"
            }
          ]
        },
        "baseInstructions": {
          "type": [
            "string",
            "null"
          ]
        },
        "config": {
          "type": [
            "object",
            "null"
          ],
          "additionalProperties": true
        },
        "cwd": {
          "type": [
            "string",
            "null"
          ]
        },
        "developerInstructions": {
          "type": [
            "string",
            "null"
          ]
        },
        "ephemeral": {
          "type": "boolean"
        },
        "model": {
          "description": "Configuration overrides for the forked thread, if any.",
          "type": [
            "string",
            "null"
          ]
        },
        "modelProvider": {
          "type": [
            "string",
            "null"
          ]
        },
        "serviceTier": {
          "anyOf": [
            {
              "anyOf": [
                {
                  "$ref": "#/definitions/ServiceTier"
                },
                {
                  "type": "null"
                }
              ]
            },
            {
              "type": "null"
            }
          ]
        },
        "threadId": {
          "type": "string"
        },
        "sandbox": {
          "anyOf": [
            {
              "$ref": "#/definitions/SandboxMode"
            },
            {
              "type": "null"
            }
          ]
        }
      }
    },
    "ThreadArchiveParams": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ThreadArchiveParams",
      "type": "object",
      "required": [
        "threadId"
      ],
      "properties": {
        "threadId": {
          "type": "string"
        }
      }
    },
    "ThreadUnsubscribeParams": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ThreadUnsubscribeParams",
      "type": "object",
      "required": [
        "threadId"
      ],
      "properties": {
        "threadId": {
          "type": "string"
        }
      }
    },
    "AccountLoginCompletedNotification": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "AccountLoginCompletedNotification",
      "type": "object",
      "required": [
        "success"
      ],
      "properties": {
        "error": {
          "type": [
            "string",
            "null"
          ]
        },
        "loginId": {
          "type": [
            "string",
            "null"
          ]
        },
        "success": {
          "type": "boolean"
        }
      }
    },
    "WindowsSandboxSetupCompletedNotification": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "WindowsSandboxSetupCompletedNotification",
      "type": "object",
      "required": [
        "mode",
        "success"
      ],
      "properties": {
        "error": {
          "type": [
            "string",
            "null"
          ]
        },
        "mode": {
          "$ref": "#/definitions/WindowsSandboxSetupMode"
        },
        "success": {
          "type": "boolean"
        }
      }
    },
    "ThreadSetNameParams": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ThreadSetNameParams",
      "type": "object",
      "required": [
        "name",
        "threadId"
      ],
      "properties": {
        "name": {
          "type": "string"
        },
        "threadId": {
          "type": "string"
        }
      }
    },
    "ThreadMetadataGitInfoUpdateParams": {
      "type": "object",
      "properties": {
        "branch": {
          "description": "Omit to leave the stored branch unchanged, set to `null` to clear it, or provide a non-empty string to replace it.",
          "type": [
            "string",
            "null"
          ]
        },
        "originUrl": {
          "description": "Omit to leave the stored origin URL unchanged, set to `null` to clear it, or provide a non-empty string to replace it.",
          "type": [
            "string",
            "null"
          ]
        },
        "sha": {
          "description": "Omit to leave the stored commit unchanged, set to `null` to clear it, or provide a non-empty string to replace it.",
          "type": [
            "string",
            "null"
          ]
        }
      }
    },
    "ThreadMetadataUpdateParams": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ThreadMetadataUpdateParams",
      "type": "object",
      "required": [
        "threadId"
      ],
      "properties": {
        "gitInfo": {
          "description": "Patch the stored Git metadata for this thread. Omit a field to leave it unchanged, set it to `null` to clear it, or provide a string to replace the stored value.",
          "anyOf": [
            {
              "$ref": "#/definitions/ThreadMetadataGitInfoUpdateParams"
            },
            {
              "type": "null"
            }
          ]
        },
        "threadId": {
          "type": "string"
        }
      }
    },
    "ThreadMemoryMode": {
      "type": "string",
      "enum": [
        "enabled",
        "disabled"
      ]
    },
    "WindowsWorldWritableWarningNotification": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "WindowsWorldWritableWarningNotification",
      "type": "object",
      "required": [
        "extraCount",
        "failedScan",
        "samplePaths"
      ],
      "properties": {
        "extraCount": {
          "type": "integer",
          "format": "uint",
          "minimum": 0.0
        },
        "failedScan": {
          "type": "boolean"
        },
        "samplePaths": {
          "type": "array",
          "items": {
            "type": "string"
          }
        }
      }
    },
    "ThreadUnarchiveParams": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ThreadUnarchiveParams",
      "type": "object",
      "required": [
        "threadId"
      ],
      "properties": {
        "threadId": {
          "type": "string"
        }
      }
    },
    "ThreadCompactStartParams": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ThreadCompactStartParams",
      "type": "object",
      "required": [
        "threadId"
      ],
      "properties": {
        "threadId": {
          "type": "string"
        }
      }
    },
    "ThreadShellCommandParams": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ThreadShellCommandParams",
      "type": "object",
      "required": [
        "command",
        "threadId"
      ],
      "properties": {
        "command": {
          "description": "Shell command string evaluated by the thread's configured shell. Unlike `command/exec`, this intentionally preserves shell syntax such as pipes, redirects, and quoting. This runs unsandboxed with full access rather than inheriting the thread sandbox policy.",
          "type": "string"
        },
        "threadId": {
          "type": "string"
        }
      }
    },
    "ThreadRealtimeClosedNotification": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ThreadRealtimeClosedNotification",
      "description": "EXPERIMENTAL - emitted when thread realtime transport closes.",
      "type": "object",
      "required": [
        "threadId"
      ],
      "properties": {
        "reason": {
          "type": [
            "string",
            "null"
          ]
        },
        "threadId": {
          "type": "string"
        }
      }
    },
    "ThreadRollbackParams": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ThreadRollbackParams",
      "type": "object",
      "required": [
        "numTurns",
        "threadId"
      ],
      "properties": {
        "numTurns": {
          "description": "The number of turns to drop from the end of the thread. Must be >= 1.\n\nThis only modifies the thread's history and does not revert local file changes that have been made by the agent. Clients are responsible for reverting these changes.",
          "type": "integer",
          "format": "uint32",
          "minimum": 0.0
        },
        "threadId": {
          "type": "string"
        }
      }
    },
    "SortDirection": {
      "type": "string",
      "enum": [
        "asc",
        "desc"
      ]
    },
    "ThreadSortKey": {
      "type": "string",
      "enum": [
        "created_at",
        "updated_at"
      ]
    },
    "ThreadSourceKind": {
      "type": "string",
      "enum": [
        "cli",
        "vscode",
        "exec",
        "appServer",
        "subAgent",
        "subAgentReview",
        "subAgentCompact",
        "subAgentThreadSpawn",
        "subAgentOther",
        "unknown"
      ]
    },
    "ThreadListParams": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ThreadListParams",
      "type": "object",
      "properties": {
        "archived": {
          "description": "Optional archived filter; when set to true, only archived threads are returned. If false or null, only non-archived threads are returned.",
          "type": [
            "boolean",
            "null"
          ]
        },
        "cursor": {
          "description": "Opaque pagination cursor returned by a previous call.",
          "type": [
            "string",
            "null"
          ]
        },
        "cwd": {
          "description": "Optional cwd filter; when set, only threads whose session cwd exactly matches this path are returned.",
          "type": [
            "string",
            "null"
          ]
        },
        "limit": {
          "description": "Optional page size; defaults to a reasonable server-side value.",
          "type": [
            "integer",
            "null"
          ],
          "format": "uint32",
          "minimum": 0.0
        },
        "modelProviders": {
          "description": "Optional provider filter; when set, only sessions recorded under these providers are returned. When present but empty, includes all providers.",
          "type": [
            "array",
            "null"
          ],
          "items": {
            "type": "string"
          }
        },
        "searchTerm": {
          "description": "Optional substring filter for the extracted thread title.",
          "type": [
            "string",
            "null"
          ]
        },
        "sortDirection": {
          "description": "Optional sort direction; defaults to descending (newest first).",
          "anyOf": [
            {
              "$ref": "#/definitions/SortDirection"
            },
            {
              "type": "null"
            }
          ]
        },
        "sortKey": {
          "description": "Optional sort key; defaults to created_at.",
          "anyOf": [
            {
              "$ref": "#/definitions/ThreadSortKey"
            },
            {
              "type": "null"
            }
          ]
        },
        "sourceKinds": {
          "description": "Optional source filter; when set, only sessions from these source kinds are returned. When omitted or empty, defaults to interactive sources.",
          "type": [
            "array",
            "null"
          ],
          "items": {
            "$ref": "#/definitions/ThreadSourceKind"
          }
        }
      }
    },
    "ThreadLoadedListParams": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ThreadLoadedListParams",
      "type": "object",
      "properties": {
        "cursor": {
          "description": "Opaque pagination cursor returned by a previous call.",
          "type": [
            "string",
            "null"
          ]
        },
        "limit": {
          "description": "Optional page size; defaults to no limit.",
          "type": [
            "integer",
            "null"
          ],
          "format": "uint32",
          "minimum": 0.0
        }
      }
    },
    "ThreadReadParams": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ThreadReadParams",
      "type": "object",
      "required": [
        "threadId"
      ],
      "properties": {
        "includeTurns": {
          "description": "When true, include turns and their items from rollout history.",
          "default": false,
          "type": "boolean"
        },
        "threadId": {
          "type": "string"
        }
      }
    },
    "ThreadTurnsListParams": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ThreadTurnsListParams",
      "type": "object",
      "required": [
        "threadId"
      ],
      "properties": {
        "cursor": {
          "description": "Opaque cursor to pass to the next call to continue after the last turn.",
          "type": [
            "string",
            "null"
          ]
        },
        "limit": {
          "description": "Optional turn page size.",
          "type": [
            "integer",
            "null"
          ],
          "format": "uint32",
          "minimum": 0.0
        },
        "sortDirection": {
          "description": "Optional turn pagination direction; defaults to descending.",
          "anyOf": [
            {
              "$ref": "#/definitions/SortDirection"
            },
            {
              "type": "null"
            }
          ]
        },
        "threadId": {
          "type": "string"
        }
      }
    },
    "ThreadInjectItemsParams": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ThreadInjectItemsParams",
      "type": "object",
      "required": [
        "items",
        "threadId"
      ],
      "properties": {
        "items": {
          "description": "Raw Responses API items to append to the thread's model-visible history.",
          "type": "array",
          "items": true
        },
        "threadId": {
          "type": "string"
        }
      }
    },
    "SkillsListExtraRootsForCwd": {
      "type": "object",
      "required": [
        "cwd",
        "extraUserRoots"
      ],
      "properties": {
        "cwd": {
          "type": "string"
        },
        "extraUserRoots": {
          "type": "array",
          "items": {
            "type": "string"
          }
        }
      }
    },
    "SkillsListParams": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "SkillsListParams",
      "type": "object",
      "properties": {
        "cwds": {
          "description": "When empty, defaults to the current session working directory.",
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "forceReload": {
          "description": "When true, bypass the skills cache and re-scan skills from disk.",
          "type": "boolean"
        },
        "perCwdExtraUserRoots": {
          "description": "Optional per-cwd extra roots to scan as user-scoped skills.",
          "default": null,
          "type": [
            "array",
            "null"
          ],
          "items": {
            "$ref": "#/definitions/SkillsListExtraRootsForCwd"
          }
        }
      }
    },
    "MarketplaceAddParams": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "MarketplaceAddParams",
      "type": "object",
      "required": [
        "source"
      ],
      "properties": {
        "refName": {
          "type": [
            "string",
            "null"
          ]
        },
        "source": {
          "type": "string"
        },
        "sparsePaths": {
          "type": [
            "array",
            "null"
          ],
          "items": {
            "type": "string"
          }
        }
      }
    },
    "MarketplaceRemoveParams": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "MarketplaceRemoveParams",
      "type": "object",
      "required": [
        "marketplaceName"
      ],
      "properties": {
        "marketplaceName": {
          "type": "string"
        }
      }
    },
    "AbsolutePathBuf": {
      "description": "A path that is guaranteed to be absolute and normalized (though it is not guaranteed to be canonicalized or exist on the filesystem).\n\nIMPORTANT: When deserializing an `AbsolutePathBuf`, a base path must be set using [AbsolutePathBufGuard::new]. If no base path is set, the deserialization will fail unless the path being deserialized is already absolute.",
      "type": "string"
    },
    "PluginListParams": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "PluginListParams",
      "type": "object",
      "properties": {
        "cwds": {
          "description": "Optional working directories used to discover repo marketplaces. When omitted, only home-scoped marketplaces and the official curated marketplace are considered.",
          "type": [
            "array",
            "null"
          ],
          "items": {
            "$ref": "#/definitions/AbsolutePathBuf"
          }
        }
      }
    },
    "PluginReadParams": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "PluginReadParams",
      "type": "object",
      "required": [
        "pluginName"
      ],
      "properties": {
        "marketplacePath": {
          "anyOf": [
            {
              "$ref": "#/definitions/AbsolutePathBuf"
            },
            {
              "type": "null"
            }
          ]
        },
        "pluginName": {
          "type": "string"
        },
        "remoteMarketplaceName": {
          "type": [
            "string",
            "null"
          ]
        }
      }
    },
    "AppsListParams": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "AppsListParams",
      "description": "EXPERIMENTAL - list available apps/connectors.",
      "type": "object",
      "properties": {
        "cursor": {
          "description": "Opaque pagination cursor returned by a previous call.",
          "type": [
            "string",
            "null"
          ]
        },
        "forceRefetch": {
          "description": "When true, bypass app caches and fetch the latest data from sources.",
          "type": "boolean"
        },
        "limit": {
          "description": "Optional page size; defaults to a reasonable server-side value.",
          "type": [
            "integer",
            "null"
          ],
          "format": "uint32",
          "minimum": 0.0
        },
        "threadId": {
          "description": "Optional thread id used to evaluate app feature gating from that thread's config.",
          "type": [
            "string",
            "null"
          ]
        }
      }
    },
    "FsReadFileParams": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "FsReadFileParams",
      "description": "Read a file from the host filesystem.",
      "type": "object",
      "required": [
        "path"
      ],
      "properties": {
        "path": {
          "description": "Absolute path to read.",
          "allOf": [
            {
              "$ref": "#/definitions/AbsolutePathBuf"
            }
          ]
        }
      }
    },
    "FsWriteFileParams": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "FsWriteFileParams",
      "description": "Write a file on the host filesystem.",
      "type": "object",
      "required": [
        "dataBase64",
        "path"
      ],
      "properties": {
        "dataBase64": {
          "description": "File contents encoded as base64.",
          "type": "string"
        },
        "path": {
          "description": "Absolute path to write.",
          "allOf": [
            {
              "$ref": "#/definitions/AbsolutePathBuf"
            }
          ]
        }
      }
    },
    "FsCreateDirectoryParams": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "FsCreateDirectoryParams",
      "description": "Create a directory on the host filesystem.",
      "type": "object",
      "required": [
        "path"
      ],
      "properties": {
        "path": {
          "description": "Absolute directory path to create.",
          "allOf": [
            {
              "$ref": "#/definitions/AbsolutePathBuf"
            }
          ]
        },
        "recursive": {
          "description": "Whether parent directories should also be created. Defaults to `true`.",
          "type": [
            "boolean",
            "null"
          ]
        }
      }
    },
    "FsGetMetadataParams": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "FsGetMetadataParams",
      "description": "Request metadata for an absolute path.",
      "type": "object",
      "required": [
        "path"
      ],
      "properties": {
        "path": {
          "description": "Absolute path to inspect.",
          "allOf": [
            {
              "$ref": "#/definitions/AbsolutePathBuf"
            }
          ]
        }
      }
    },
    "FsReadDirectoryParams": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "FsReadDirectoryParams",
      "description": "List direct child names for a directory.",
      "type": "object",
      "required": [
        "path"
      ],
      "properties": {
        "path": {
          "description": "Absolute directory path to read.",
          "allOf": [
            {
              "$ref": "#/definitions/AbsolutePathBuf"
            }
          ]
        }
      }
    },
    "FsRemoveParams": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "FsRemoveParams",
      "description": "Remove a file or directory tree from the host filesystem.",
      "type": "object",
      "required": [
        "path"
      ],
      "properties": {
        "force": {
          "description": "Whether missing paths should be ignored. Defaults to `true`.",
          "type": [
            "boolean",
            "null"
          ]
        },
        "path": {
          "description": "Absolute path to remove.",
          "allOf": [
            {
              "$ref": "#/definitions/AbsolutePathBuf"
            }
          ]
        },
        "recursive": {
          "description": "Whether directory removal should recurse. Defaults to `true`.",
          "type": [
            "boolean",
            "null"
          ]
        }
      }
    },
    "FsCopyParams": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "FsCopyParams",
      "description": "Copy a file or directory tree on the host filesystem.",
      "type": "object",
      "required": [
        "destinationPath",
        "sourcePath"
      ],
      "properties": {
        "destinationPath": {
          "description": "Absolute destination path.",
          "allOf": [
            {
              "$ref": "#/definitions/AbsolutePathBuf"
            }
          ]
        },
        "recursive": {
          "description": "Required for directory copies; ignored for file copies.",
          "type": "boolean"
        },
        "sourcePath": {
          "description": "Absolute source path.",
          "allOf": [
            {
              "$ref": "#/definitions/AbsolutePathBuf"
            }
          ]
        }
      }
    },
    "FsWatchParams": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "FsWatchParams",
      "description": "Start filesystem watch notifications for an absolute path.",
      "type": "object",
      "required": [
        "path",
        "watchId"
      ],
      "properties": {
        "path": {
          "description": "Absolute file or directory path to watch.",
          "allOf": [
            {
              "$ref": "#/definitions/AbsolutePathBuf"
            }
          ]
        },
        "watchId": {
          "description": "Connection-scoped watch identifier used for `fs/unwatch` and `fs/changed`.",
          "type": "string"
        }
      }
    },
    "FsUnwatchParams": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "FsUnwatchParams",
      "description": "Stop filesystem watch notifications for a prior `fs/watch`.",
      "type": "object",
      "required": [
        "watchId"
      ],
      "properties": {
        "watchId": {
          "description": "Watch identifier previously provided to `fs/watch`.",
          "type": "string"
        }
      }
    },
    "SkillsConfigWriteParams": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "SkillsConfigWriteParams",
      "type": "object",
      "required": [
        "enabled"
      ],
      "properties": {
        "enabled": {
          "type": "boolean"
        },
        "name": {
          "description": "Name-based selector.",
          "type": [
            "string",
            "null"
          ]
        },
        "path": {
          "description": "Path-based selector.",
          "anyOf": [
            {
              "$ref": "#/definitions/AbsolutePathBuf"
            },
            {
              "type": "null"
            }
          ]
        }
      }
    },
    "PluginInstallParams": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "PluginInstallParams",
      "type": "object",
      "required": [
        "pluginName"
      ],
      "properties": {
        "marketplacePath": {
          "anyOf": [
            {
              "$ref": "#/definitions/AbsolutePathBuf"
            },
            {
              "type": "null"
            }
          ]
        },
        "pluginName": {
          "type": "string"
        },
        "remoteMarketplaceName": {
          "type": [
            "string",
            "null"
          ]
        }
      }
    },
    "PluginUninstallParams": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "PluginUninstallParams",
      "type": "object",
      "required": [
        "pluginId"
      ],
      "properties": {
        "pluginId": {
          "type": "string"
        }
      }
    },
    "ByteRange": {
      "type": "object",
      "required": [
        "end",
        "start"
      ],
      "properties": {
        "end": {
          "type": "integer",
          "format": "uint",
          "minimum": 0.0
        },
        "start": {
          "type": "integer",
          "format": "uint",
          "minimum": 0.0
        }
      }
    },
    "CollaborationMode": {
      "description": "Collaboration mode for a Codex session.",
      "type": "object",
      "required": [
        "mode",
        "settings"
      ],
      "properties": {
        "mode": {
          "$ref": "#/definitions/ModeKind"
        },
        "settings": {
          "$ref": "#/definitions/Settings"
        }
      }
    },
    "ModeKind": {
      "description": "Initial collaboration mode to use when the TUI starts.",
      "type": "string",
      "enum": [
        "plan",
        "default"
      ]
    },
    "NetworkAccess": {
      "type": "string",
      "enum": [
        "restricted",
        "enabled"
      ]
    },
    "ReadOnlyAccess": {
      "oneOf": [
        {
          "type": "object",
          "required": [
            "type"
          ],
          "properties": {
            "includePlatformDefaults": {
              "default": true,
              "type": "boolean"
            },
            "readableRoots": {
              "default": [],
              "type": "array",
              "items": {
                "$ref": "#/definitions/AbsolutePathBuf"
              }
            },
            "type": {
              "type": "string",
              "enum": [
                "restricted"
              ],
              "title": "RestrictedReadOnlyAccessType"
            }
          },
          "title": "RestrictedReadOnlyAccess"
        },
        {
          "type": "object",
          "required": [
            "type"
          ],
          "properties": {
            "type": {
              "type": "string",
              "enum": [
                "fullAccess"
              ],
              "title": "FullAccessReadOnlyAccessType"
            }
          },
          "title": "FullAccessReadOnlyAccess"
        }
      ]
    },
    "ReasoningEffort": {
      "description": "See https://platform.openai.com/docs/guides/reasoning?api-mode=responses#get-started-with-reasoning",
      "type": "string",
      "enum": [
        "none",
        "minimal",
        "low",
        "medium",
        "high",
        "xhigh"
      ]
    },
    "ReasoningSummary": {
      "description": "A summary of the reasoning performed by the model. This can be useful for debugging and understanding the model's reasoning process. See https://platform.openai.com/docs/guides/reasoning?api-mode=responses#reasoning-summaries",
      "oneOf": [
        {
          "type": "string",
          "enum": [
            "auto",
            "concise",
            "detailed"
          ]
        },
        {
          "description": "Option to disable reasoning summaries.",
          "type": "string",
          "enum": [
            "none"
          ]
        }
      ]
    },
    "SandboxPolicy": {
      "oneOf": [
        {
          "type": "object",
          "required": [
            "type"
          ],
          "properties": {
            "type": {
              "type": "string",
              "enum": [
                "dangerFullAccess"
              ],
              "title": "DangerFullAccessSandboxPolicyType"
            }
          },
          "title": "DangerFullAccessSandboxPolicy"
        },
        {
          "type": "object",
          "required": [
            "type"
          ],
          "properties": {
            "access": {
              "default": {
                "type": "fullAccess"
              },
              "allOf": [
                {
                  "$ref": "#/definitions/ReadOnlyAccess"
                }
              ]
            },
            "networkAccess": {
              "default": false,
              "type": "boolean"
            },
            "type": {
              "type": "string",
              "enum": [
                "readOnly"
              ],
              "title": "ReadOnlySandboxPolicyType"
            }
          },
          "title": "ReadOnlySandboxPolicy"
        },
        {
          "type": "object",
          "required": [
            "type"
          ],
          "properties": {
            "networkAccess": {
              "default": "restricted",
              "allOf": [
                {
                  "$ref": "#/definitions/NetworkAccess"
                }
              ]
            },
            "type": {
              "type": "string",
              "enum": [
                "externalSandbox"
              ],
              "title": "ExternalSandboxSandboxPolicyType"
            }
          },
          "title": "ExternalSandboxSandboxPolicy"
        },
        {
          "type": "object",
          "required": [
            "type"
          ],
          "properties": {
            "excludeSlashTmp": {
              "default": false,
              "type": "boolean"
            },
            "excludeTmpdirEnvVar": {
              "default": false,
              "type": "boolean"
            },
            "networkAccess": {
              "default": false,
              "type": "boolean"
            },
            "readOnlyAccess": {
              "default": {
                "type": "fullAccess"
              },
              "allOf": [
                {
                  "$ref": "#/definitions/ReadOnlyAccess"
                }
              ]
            },
            "type": {
              "type": "string",
              "enum": [
                "workspaceWrite"
              ],
              "title": "WorkspaceWriteSandboxPolicyType"
            },
            "writableRoots": {
              "default": [],
              "type": "array",
              "items": {
                "$ref": "#/definitions/AbsolutePathBuf"
              }
            }
          },
          "title": "WorkspaceWriteSandboxPolicy"
        }
      ]
    },
    "Settings": {
      "description": "Settings for a collaboration mode.",
      "type": "object",
      "required": [
        "model"
      ],
      "properties": {
        "developer_instructions": {
          "type": [
            "string",
            "null"
          ]
        },
        "model": {
          "type": "string"
        },
        "reasoning_effort": {
          "anyOf": [
            {
              "$ref": "#/definitions/ReasoningEffort"
            },
            {
              "type": "null"
            }
          ]
        }
      }
    },
    "TextElement": {
      "type": "object",
      "required": [
        "byteRange"
      ],
      "properties": {
        "byteRange": {
          "description": "Byte range in the parent `text` buffer that this element occupies.",
          "allOf": [
            {
              "$ref": "#/definitions/ByteRange"
            }
          ]
        },
        "placeholder": {
          "description": "Optional human-readable placeholder for the element, displayed in the UI.",
          "type": [
            "string",
            "null"
          ]
        }
      }
    },
    "UserInput": {
      "oneOf": [
        {
          "type": "object",
          "required": [
            "text",
            "type"
          ],
          "properties": {
            "text": {
              "type": "string"
            },
            "text_elements": {
              "description": "UI-defined spans within `text` used to render or persist special elements.",
              "default": [],
              "type": "array",
              "items": {
                "$ref": "#/definitions/TextElement"
              }
            },
            "type": {
              "type": "string",
              "enum": [
                "text"
              ],
              "title": "TextUserInputType"
            }
          },
          "title": "TextUserInput"
        },
        {
          "type": "object",
          "required": [
            "type",
            "url"
          ],
          "properties": {
            "type": {
              "type": "string",
              "enum": [
                "image"
              ],
              "title": "ImageUserInputType"
            },
            "url": {
              "type": "string"
            }
          },
          "title": "ImageUserInput"
        },
        {
          "type": "object",
          "required": [
            "path",
            "type"
          ],
          "properties": {
            "path": {
              "type": "string"
            },
            "type": {
              "type": "string",
              "enum": [
                "localImage"
              ],
              "title": "LocalImageUserInputType"
            }
          },
          "title": "LocalImageUserInput"
        },
        {
          "type": "object",
          "required": [
            "name",
            "path",
            "type"
          ],
          "properties": {
            "name": {
              "type": "string"
            },
            "path": {
              "type": "string"
            },
            "type": {
              "type": "string",
              "enum": [
                "skill"
              ],
              "title": "SkillUserInputType"
            }
          },
          "title": "SkillUserInput"
        },
        {
          "type": "object",
          "required": [
            "name",
            "path",
            "type"
          ],
          "properties": {
            "name": {
              "type": "string"
            },
            "path": {
              "type": "string"
            },
            "type": {
              "type": "string",
              "enum": [
                "mention"
              ],
              "title": "MentionUserInputType"
            }
          },
          "title": "MentionUserInput"
        }
      ]
    },
    "TurnStartParams": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "TurnStartParams",
      "type": "object",
      "required": [
        "input",
        "threadId"
      ],
      "properties": {
        "approvalPolicy": {
          "description": "Override the approval policy for this turn and subsequent turns.",
          "anyOf": [
            {
              "$ref": "#/definitions/AskForApproval"
            },
            {
              "type": "null"
            }
          ]
        },
        "approvalsReviewer": {
          "description": "Override where approval requests are routed for review on this turn and subsequent turns.",
          "anyOf": [
            {
              "$ref": "#/definitions/ApprovalsReviewer"
            },
            {
              "type": "null"
            }
          ]
        },
        "threadId": {
          "type": "string"
        },
        "cwd": {
          "description": "Override the working directory for this turn and subsequent turns.",
          "type": [
            "string",
            "null"
          ]
        },
        "effort": {
          "description": "Override the reasoning effort for this turn and subsequent turns.",
          "anyOf": [
            {
              "$ref": "#/definitions/ReasoningEffort"
            },
            {
              "type": "null"
            }
          ]
        },
        "input": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/UserInput"
          }
        },
        "model": {
          "description": "Override the model for this turn and subsequent turns.",
          "type": [
            "string",
            "null"
          ]
        },
        "outputSchema": {
          "description": "Optional JSON Schema used to constrain the final assistant message for this turn."
        },
        "personality": {
          "description": "Override the personality for this turn and subsequent turns.",
          "anyOf": [
            {
              "$ref": "#/definitions/Personality"
            },
            {
              "type": "null"
            }
          ]
        },
        "summary": {
          "description": "Override the reasoning summary for this turn and subsequent turns.",
          "anyOf": [
            {
              "$ref": "#/definitions/ReasoningSummary"
            },
            {
              "type": "null"
            }
          ]
        },
        "sandboxPolicy": {
          "description": "Override the sandbox policy for this turn and subsequent turns.",
          "anyOf": [
            {
              "$ref": "#/definitions/SandboxPolicy"
            },
            {
              "type": "null"
            }
          ]
        },
        "serviceTier": {
          "description": "Override the service tier for this turn and subsequent turns.",
          "anyOf": [
            {
              "anyOf": [
                {
                  "$ref": "#/definitions/ServiceTier"
                },
                {
                  "type": "null"
                }
              ]
            },
            {
              "type": "null"
            }
          ]
        }
      }
    },
    "TurnSteerParams": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "TurnSteerParams",
      "type": "object",
      "required": [
        "expectedTurnId",
        "input",
        "threadId"
      ],
      "properties": {
        "expectedTurnId": {
          "description": "Required active turn id precondition. The request fails when it does not match the currently active turn.",
          "type": "string"
        },
        "input": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/UserInput"
          }
        },
        "threadId": {
          "type": "string"
        }
      }
    },
    "TurnInterruptParams": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "TurnInterruptParams",
      "type": "object",
      "required": [
        "threadId",
        "turnId"
      ],
      "properties": {
        "threadId": {
          "type": "string"
        },
        "turnId": {
          "type": "string"
        }
      }
    },
    "RealtimeOutputModality": {
      "type": "string",
      "enum": [
        "text",
        "audio"
      ]
    },
    "RealtimeVoice": {
      "type": "string",
      "enum": [
        "alloy",
        "arbor",
        "ash",
        "ballad",
        "breeze",
        "cedar",
        "coral",
        "cove",
        "echo",
        "ember",
        "juniper",
        "maple",
        "marin",
        "sage",
        "shimmer",
        "sol",
        "spruce",
        "vale",
        "verse"
      ]
    },
    "ThreadRealtimeStartTransport": {
      "description": "EXPERIMENTAL - transport used by thread realtime.",
      "oneOf": [
        {
          "type": "object",
          "required": [
            "type"
          ],
          "properties": {
            "type": {
              "type": "string",
              "enum": [
                "websocket"
              ],
              "title": "WebsocketThreadRealtimeStartTransportType"
            }
          },
          "title": "WebsocketThreadRealtimeStartTransport"
        },
        {
          "type": "object",
          "required": [
            "sdp",
            "type"
          ],
          "properties": {
            "sdp": {
              "description": "SDP offer generated by a WebRTC RTCPeerConnection after configuring audio and the realtime events data channel.",
              "type": "string"
            },
            "type": {
              "type": "string",
              "enum": [
                "webrtc"
              ],
              "title": "WebrtcThreadRealtimeStartTransportType"
            }
          },
          "title": "WebrtcThreadRealtimeStartTransport"
        }
      ]
    },
    "ThreadRealtimeErrorNotification": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ThreadRealtimeErrorNotification",
      "description": "EXPERIMENTAL - emitted when thread realtime encounters an error.",
      "type": "object",
      "required": [
        "message",
        "threadId"
      ],
      "properties": {
        "message": {
          "type": "string"
        },
        "threadId": {
          "type": "string"
        }
      }
    },
    "ThreadRealtimeAudioChunk": {
      "description": "EXPERIMENTAL - thread realtime audio chunk.",
      "type": "object",
      "required": [
        "data",
        "numChannels",
        "sampleRate"
      ],
      "properties": {
        "data": {
          "type": "string"
        },
        "itemId": {
          "type": [
            "string",
            "null"
          ]
        },
        "numChannels": {
          "type": "integer",
          "format": "uint16",
          "minimum": 0.0
        },
        "sampleRate": {
          "type": "integer",
          "format": "uint32",
          "minimum": 0.0
        },
        "samplesPerChannel": {
          "type": [
            "integer",
            "null"
          ],
          "format": "uint32",
          "minimum": 0.0
        }
      }
    },
    "ThreadRealtimeSdpNotification": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ThreadRealtimeSdpNotification",
      "description": "EXPERIMENTAL - emitted with the remote SDP for a WebRTC realtime session.",
      "type": "object",
      "required": [
        "sdp",
        "threadId"
      ],
      "properties": {
        "sdp": {
          "type": "string"
        },
        "threadId": {
          "type": "string"
        }
      }
    },
    "ThreadRealtimeOutputAudioDeltaNotification": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ThreadRealtimeOutputAudioDeltaNotification",
      "description": "EXPERIMENTAL - streamed output audio emitted by thread realtime.",
      "type": "object",
      "required": [
        "audio",
        "threadId"
      ],
      "properties": {
        "audio": {
          "$ref": "#/definitions/ThreadRealtimeAudioChunk"
        },
        "threadId": {
          "type": "string"
        }
      }
    },
    "ThreadRealtimeTranscriptDoneNotification": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ThreadRealtimeTranscriptDoneNotification",
      "description": "EXPERIMENTAL - final transcript text emitted when realtime completes a transcript part.",
      "type": "object",
      "required": [
        "role",
        "text",
        "threadId"
      ],
      "properties": {
        "role": {
          "type": "string"
        },
        "text": {
          "description": "Final complete text for the transcript part.",
          "type": "string"
        },
        "threadId": {
          "type": "string"
        }
      }
    },
    "ThreadRealtimeTranscriptDeltaNotification": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ThreadRealtimeTranscriptDeltaNotification",
      "description": "EXPERIMENTAL - flat transcript delta emitted whenever realtime transcript text changes.",
      "type": "object",
      "required": [
        "delta",
        "role",
        "threadId"
      ],
      "properties": {
        "delta": {
          "description": "Live transcript delta from the realtime event.",
          "type": "string"
        },
        "role": {
          "type": "string"
        },
        "threadId": {
          "type": "string"
        }
      }
    },
    "ReviewDelivery": {
      "type": "string",
      "enum": [
        "inline",
        "detached"
      ]
    },
    "ReviewTarget": {
      "oneOf": [
        {
          "description": "Review the working tree: staged, unstaged, and untracked files.",
          "type": "object",
          "required": [
            "type"
          ],
          "properties": {
            "type": {
              "type": "string",
              "enum": [
                "uncommittedChanges"
              ],
              "title": "UncommittedChangesReviewTargetType"
            }
          },
          "title": "UncommittedChangesReviewTarget"
        },
        {
          "description": "Review changes between the current branch and the given base branch.",
          "type": "object",
          "required": [
            "branch",
            "type"
          ],
          "properties": {
            "branch": {
              "type": "string"
            },
            "type": {
              "type": "string",
              "enum": [
                "baseBranch"
              ],
              "title": "BaseBranchReviewTargetType"
            }
          },
          "title": "BaseBranchReviewTarget"
        },
        {
          "description": "Review the changes introduced by a specific commit.",
          "type": "object",
          "required": [
            "sha",
            "type"
          ],
          "properties": {
            "sha": {
              "type": "string"
            },
            "title": {
              "description": "Optional human-readable label (e.g., commit subject) for UIs.",
              "type": [
                "string",
                "null"
              ]
            },
            "type": {
              "type": "string",
              "enum": [
                "commit"
              ],
              "title": "CommitReviewTargetType"
            }
          },
          "title": "CommitReviewTarget"
        },
        {
          "description": "Arbitrary instructions, equivalent to the old free-form prompt.",
          "type": "object",
          "required": [
            "instructions",
            "type"
          ],
          "properties": {
            "instructions": {
              "type": "string"
            },
            "type": {
              "type": "string",
              "enum": [
                "custom"
              ],
              "title": "CustomReviewTargetType"
            }
          },
          "title": "CustomReviewTarget"
        }
      ]
    },
    "ReviewStartParams": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ReviewStartParams",
      "type": "object",
      "required": [
        "target",
        "threadId"
      ],
      "properties": {
        "delivery": {
          "description": "Where to run the review: inline (default) on the current thread or detached on a new thread (returned in `reviewThreadId`).",
          "default": null,
          "anyOf": [
            {
              "$ref": "#/definitions/ReviewDelivery"
            },
            {
              "type": "null"
            }
          ]
        },
        "target": {
          "$ref": "#/definitions/ReviewTarget"
        },
        "threadId": {
          "type": "string"
        }
      }
    },
    "ModelListParams": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ModelListParams",
      "type": "object",
      "properties": {
        "cursor": {
          "description": "Opaque pagination cursor returned by a previous call.",
          "type": [
            "string",
            "null"
          ]
        },
        "includeHidden": {
          "description": "When true, include models that are hidden from the default picker list.",
          "type": [
            "boolean",
            "null"
          ]
        },
        "limit": {
          "description": "Optional page size; defaults to a reasonable server-side value.",
          "type": [
            "integer",
            "null"
          ],
          "format": "uint32",
          "minimum": 0.0
        }
      }
    },
    "ExperimentalFeatureListParams": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ExperimentalFeatureListParams",
      "type": "object",
      "properties": {
        "cursor": {
          "description": "Opaque pagination cursor returned by a previous call.",
          "type": [
            "string",
            "null"
          ]
        },
        "limit": {
          "description": "Optional page size; defaults to a reasonable server-side value.",
          "type": [
            "integer",
            "null"
          ],
          "format": "uint32",
          "minimum": 0.0
        }
      }
    },
    "ExperimentalFeatureEnablementSetParams": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ExperimentalFeatureEnablementSetParams",
      "type": "object",
      "required": [
        "enablement"
      ],
      "properties": {
        "enablement": {
          "description": "Process-wide runtime feature enablement keyed by canonical feature name.\n\nOnly named features are updated. Omitted features are left unchanged. Send an empty map for a no-op.",
          "type": "object",
          "additionalProperties": {
            "type": "boolean"
          }
        }
      }
    },
    "ThreadRealtimeItemAddedNotification": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ThreadRealtimeItemAddedNotification",
      "description": "EXPERIMENTAL - raw non-audio thread realtime item emitted by the backend.",
      "type": "object",
      "required": [
        "item",
        "threadId"
      ],
      "properties": {
        "item": true,
        "threadId": {
          "type": "string"
        }
      }
    },
    "ThreadRealtimeStartedNotification": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ThreadRealtimeStartedNotification",
      "description": "EXPERIMENTAL - emitted when thread realtime startup is accepted.",
      "type": "object",
      "required": [
        "threadId",
        "version"
      ],
      "properties": {
        "sessionId": {
          "type": [
            "string",
            "null"
          ]
        },
        "threadId": {
          "type": "string"
        },
        "version": {
          "$ref": "#/definitions/RealtimeConversationVersion"
        }
      }
    },
    "McpServerOauthLoginParams": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "McpServerOauthLoginParams",
      "type": "object",
      "required": [
        "name"
      ],
      "properties": {
        "name": {
          "type": "string"
        },
        "scopes": {
          "type": [
            "array",
            "null"
          ],
          "items": {
            "type": "string"
          }
        },
        "timeoutSecs": {
          "type": [
            "integer",
            "null"
          ],
          "format": "int64"
        }
      }
    },
    "McpServerStatusDetail": {
      "type": "string",
      "enum": [
        "full",
        "toolsAndAuthOnly"
      ]
    },
    "ListMcpServerStatusParams": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ListMcpServerStatusParams",
      "type": "object",
      "properties": {
        "cursor": {
          "description": "Opaque pagination cursor returned by a previous call.",
          "type": [
            "string",
            "null"
          ]
        },
        "detail": {
          "description": "Controls how much MCP inventory data to fetch for each server. Defaults to `Full` when omitted.",
          "anyOf": [
            {
              "$ref": "#/definitions/McpServerStatusDetail"
            },
            {
              "type": "null"
            }
          ]
        },
        "limit": {
          "description": "Optional page size; defaults to a server-defined value.",
          "type": [
            "integer",
            "null"
          ],
          "format": "uint32",
          "minimum": 0.0
        }
      }
    },
    "McpResourceReadParams": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "McpResourceReadParams",
      "type": "object",
      "required": [
        "server",
        "threadId",
        "uri"
      ],
      "properties": {
        "server": {
          "type": "string"
        },
        "threadId": {
          "type": "string"
        },
        "uri": {
          "type": "string"
        }
      }
    },
    "McpServerToolCallParams": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "McpServerToolCallParams",
      "type": "object",
      "required": [
        "server",
        "threadId",
        "tool"
      ],
      "properties": {
        "_meta": true,
        "arguments": true,
        "server": {
          "type": "string"
        },
        "threadId": {
          "type": "string"
        },
        "tool": {
          "type": "string"
        }
      }
    },
    "WindowsSandboxSetupMode": {
      "type": "string",
      "enum": [
        "elevated",
        "unelevated"
      ]
    },
    "WindowsSandboxSetupStartParams": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "WindowsSandboxSetupStartParams",
      "type": "object",
      "required": [
        "mode"
      ],
      "properties": {
        "cwd": {
          "anyOf": [
            {
              "$ref": "#/definitions/AbsolutePathBuf"
            },
            {
              "type": "null"
            }
          ]
        },
        "mode": {
          "$ref": "#/definitions/WindowsSandboxSetupMode"
        }
      }
    },
    "LoginAccountParams": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "LoginAccountParams",
      "oneOf": [
        {
          "type": "object",
          "required": [
            "apiKey",
            "type"
          ],
          "properties": {
            "apiKey": {
              "type": "string"
            },
            "type": {
              "type": "string",
              "enum": [
                "apiKey"
              ],
              "title": "ApiKeyv2::LoginAccountParamsType"
            }
          },
          "title": "ApiKeyv2::LoginAccountParams"
        },
        {
          "type": "object",
          "required": [
            "type"
          ],
          "properties": {
            "type": {
              "type": "string",
              "enum": [
                "chatgpt"
              ],
              "title": "Chatgptv2::LoginAccountParamsType"
            }
          },
          "title": "Chatgptv2::LoginAccountParams"
        },
        {
          "type": "object",
          "required": [
            "type"
          ],
          "properties": {
            "type": {
              "type": "string",
              "enum": [
                "chatgptDeviceCode"
              ],
              "title": "ChatgptDeviceCodev2::LoginAccountParamsType"
            }
          },
          "title": "ChatgptDeviceCodev2::LoginAccountParams"
        },
        {
          "description": "[UNSTABLE] FOR OPENAI INTERNAL USE ONLY - DO NOT USE. The access token must contain the same scopes that Codex-managed ChatGPT auth tokens have.",
          "type": "object",
          "required": [
            "accessToken",
            "chatgptAccountId",
            "type"
          ],
          "properties": {
            "accessToken": {
              "description": "Access token (JWT) supplied by the client. This token is used for backend API requests and email extraction.",
              "type": "string"
            },
            "chatgptAccountId": {
              "description": "Workspace/account identifier supplied by the client.",
              "type": "string"
            },
            "chatgptPlanType": {
              "description": "Optional plan type supplied by the client.\n\nWhen `null`, Codex attempts to derive the plan type from access-token claims. If unavailable, the plan defaults to `unknown`.",
              "type": [
                "string",
                "null"
              ]
            },
            "type": {
              "type": "string",
              "enum": [
                "chatgptAuthTokens"
              ],
              "title": "ChatgptAuthTokensv2::LoginAccountParamsType"
            }
          },
          "title": "ChatgptAuthTokensv2::LoginAccountParams"
        }
      ]
    },
    "CancelLoginAccountParams": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "CancelLoginAccountParams",
      "type": "object",
      "required": [
        "loginId"
      ],
      "properties": {
        "loginId": {
          "type": "string"
        }
      }
    },
    "AddCreditsNudgeCreditType": {
      "type": "string",
      "enum": [
        "credits",
        "usage_limit"
      ]
    },
    "SendAddCreditsNudgeEmailParams": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "SendAddCreditsNudgeEmailParams",
      "type": "object",
      "required": [
        "creditType"
      ],
      "properties": {
        "creditType": {
          "$ref": "#/definitions/AddCreditsNudgeCreditType"
        }
      }
    },
    "FeedbackUploadParams": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "FeedbackUploadParams",
      "type": "object",
      "required": [
        "classification",
        "includeLogs"
      ],
      "properties": {
        "classification": {
          "type": "string"
        },
        "extraLogFiles": {
          "type": [
            "array",
            "null"
          ],
          "items": {
            "type": "string"
          }
        },
        "includeLogs": {
          "type": "boolean"
        },
        "reason": {
          "type": [
            "string",
            "null"
          ]
        },
        "tags": {
          "type": [
            "object",
            "null"
          ],
          "additionalProperties": {
            "type": "string"
          }
        },
        "threadId": {
          "type": [
            "string",
            "null"
          ]
        }
      }
    },
    "CommandExecTerminalSize": {
      "description": "PTY size in character cells for `command/exec` PTY sessions.",
      "type": "object",
      "required": [
        "cols",
        "rows"
      ],
      "properties": {
        "cols": {
          "description": "Terminal width in character cells.",
          "type": "integer",
          "format": "uint16",
          "minimum": 0.0
        },
        "rows": {
          "description": "Terminal height in character cells.",
          "type": "integer",
          "format": "uint16",
          "minimum": 0.0
        }
      }
    },
    "CommandExecParams": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "CommandExecParams",
      "description": "Run a standalone command (argv vector) in the server sandbox without creating a thread or turn.\n\nThe final `command/exec` response is deferred until the process exits and is sent only after all `command/exec/outputDelta` notifications for that connection have been emitted.",
      "type": "object",
      "required": [
        "command"
      ],
      "properties": {
        "command": {
          "description": "Command argv vector. Empty arrays are rejected.",
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "cwd": {
          "description": "Optional working directory. Defaults to the server cwd.",
          "type": [
            "string",
            "null"
          ]
        },
        "disableOutputCap": {
          "description": "Disable stdout/stderr capture truncation for this request.\n\nCannot be combined with `outputBytesCap`.",
          "type": "boolean"
        },
        "disableTimeout": {
          "description": "Disable the timeout entirely for this request.\n\nCannot be combined with `timeoutMs`.",
          "type": "boolean"
        },
        "env": {
          "description": "Optional environment overrides merged into the server-computed environment.\n\nMatching names override inherited values. Set a key to `null` to unset an inherited variable.",
          "type": [
            "object",
            "null"
          ],
          "additionalProperties": {
            "type": [
              "string",
              "null"
            ]
          }
        },
        "outputBytesCap": {
          "description": "Optional per-stream stdout/stderr capture cap in bytes.\n\nWhen omitted, the server default applies. Cannot be combined with `disableOutputCap`.",
          "type": [
            "integer",
            "null"
          ],
          "format": "uint",
          "minimum": 0.0
        },
        "processId": {
          "description": "Optional client-supplied, connection-scoped process id.\n\nRequired for `tty`, `streamStdin`, `streamStdoutStderr`, and follow-up `command/exec/write`, `command/exec/resize`, and `command/exec/terminate` calls. When omitted, buffered execution gets an internal id that is not exposed to the client.",
          "type": [
            "string",
            "null"
          ]
        },
        "sandboxPolicy": {
          "description": "Optional sandbox policy for this command.\n\nUses the same shape as thread/turn execution sandbox configuration and defaults to the user's configured policy when omitted.",
          "anyOf": [
            {
              "$ref": "#/definitions/SandboxPolicy"
            },
            {
              "type": "null"
            }
          ]
        },
        "size": {
          "description": "Optional initial PTY size in character cells. Only valid when `tty` is true.",
          "anyOf": [
            {
              "$ref": "#/definitions/CommandExecTerminalSize"
            },
            {
              "type": "null"
            }
          ]
        },
        "streamStdin": {
          "description": "Allow follow-up `command/exec/write` requests to write stdin bytes.\n\nRequires a client-supplied `processId`.",
          "type": "boolean"
        },
        "streamStdoutStderr": {
          "description": "Stream stdout/stderr via `command/exec/outputDelta` notifications.\n\nStreamed bytes are not duplicated into the final response and require a client-supplied `processId`.",
          "type": "boolean"
        },
        "timeoutMs": {
          "description": "Optional timeout in milliseconds.\n\nWhen omitted, the server default applies. Cannot be combined with `disableTimeout`.",
          "type": [
            "integer",
            "null"
          ],
          "format": "int64"
        },
        "tty": {
          "description": "Enable PTY mode.\n\nThis implies `streamStdin` and `streamStdoutStderr`.",
          "type": "boolean"
        }
      }
    },
    "CommandExecWriteParams": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "CommandExecWriteParams",
      "description": "Write stdin bytes to a running `command/exec` session, close stdin, or both.",
      "type": "object",
      "required": [
        "processId"
      ],
      "properties": {
        "closeStdin": {
          "description": "Close stdin after writing `deltaBase64`, if present.",
          "type": "boolean"
        },
        "deltaBase64": {
          "description": "Optional base64-encoded stdin bytes to write.",
          "type": [
            "string",
            "null"
          ]
        },
        "processId": {
          "description": "Client-supplied, connection-scoped `processId` from the original `command/exec` request.",
          "type": "string"
        }
      }
    },
    "CommandExecTerminateParams": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "CommandExecTerminateParams",
      "description": "Terminate a running `command/exec` session.",
      "type": "object",
      "required": [
        "processId"
      ],
      "properties": {
        "processId": {
          "description": "Client-supplied, connection-scoped `processId` from the original `command/exec` request.",
          "type": "string"
        }
      }
    },
    "CommandExecResizeParams": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "CommandExecResizeParams",
      "description": "Resize a running PTY-backed `command/exec` session.",
      "type": "object",
      "required": [
        "processId",
        "size"
      ],
      "properties": {
        "processId": {
          "description": "Client-supplied, connection-scoped `processId` from the original `command/exec` request.",
          "type": "string"
        },
        "size": {
          "description": "New PTY size in character cells.",
          "allOf": [
            {
              "$ref": "#/definitions/CommandExecTerminalSize"
            }
          ]
        }
      }
    },
    "ConfigReadParams": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ConfigReadParams",
      "type": "object",
      "properties": {
        "cwd": {
          "description": "Optional working directory to resolve project config layers. If specified, return the effective config as seen from that directory (i.e., including any project layers between `cwd` and the project/repo root).",
          "type": [
            "string",
            "null"
          ]
        },
        "includeLayers": {
          "default": false,
          "type": "boolean"
        }
      }
    },
    "ExternalAgentConfigDetectParams": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ExternalAgentConfigDetectParams",
      "type": "object",
      "properties": {
        "cwds": {
          "description": "Zero or more working directories to include for repo-scoped detection.",
          "type": [
            "array",
            "null"
          ],
          "items": {
            "type": "string"
          }
        },
        "includeHome": {
          "description": "If true, include detection under the user's home (~/.claude, ~/.codex, etc.).",
          "type": "boolean"
        }
      }
    },
    "ExternalAgentConfigMigrationItem": {
      "type": "object",
      "required": [
        "description",
        "itemType"
      ],
      "properties": {
        "cwd": {
          "description": "Null or empty means home-scoped migration; non-empty means repo-scoped migration.",
          "type": [
            "string",
            "null"
          ]
        },
        "description": {
          "type": "string"
        },
        "details": {
          "anyOf": [
            {
              "$ref": "#/definitions/MigrationDetails"
            },
            {
              "type": "null"
            }
          ]
        },
        "itemType": {
          "$ref": "#/definitions/ExternalAgentConfigMigrationItemType"
        }
      }
    },
    "ExternalAgentConfigMigrationItemType": {
      "type": "string",
      "enum": [
        "AGENTS_MD",
        "CONFIG",
        "SKILLS",
        "PLUGINS",
        "MCP_SERVER_CONFIG"
      ]
    },
    "MigrationDetails": {
      "type": "object",
      "required": [
        "plugins"
      ],
      "properties": {
        "plugins": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/PluginsMigration"
          }
        }
      }
    },
    "PluginsMigration": {
      "type": "object",
      "required": [
        "marketplaceName",
        "pluginNames"
      ],
      "properties": {
        "marketplaceName": {
          "type": "string"
        },
        "pluginNames": {
          "type": "array",
          "items": {
            "type": "string"
          }
        }
      }
    },
    "ExternalAgentConfigImportParams": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ExternalAgentConfigImportParams",
      "type": "object",
      "required": [
        "migrationItems"
      ],
      "properties": {
        "migrationItems": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/ExternalAgentConfigMigrationItem"
          }
        }
      }
    },
    "MergeStrategy": {
      "type": "string",
      "enum": [
        "replace",
        "upsert"
      ]
    },
    "ConfigValueWriteParams": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ConfigValueWriteParams",
      "type": "object",
      "required": [
        "keyPath",
        "mergeStrategy",
        "value"
      ],
      "properties": {
        "expectedVersion": {
          "type": [
            "string",
            "null"
          ]
        },
        "filePath": {
          "description": "Path to the config file to write; defaults to the user's `config.toml` when omitted.",
          "type": [
            "string",
            "null"
          ]
        },
        "keyPath": {
          "type": "string"
        },
        "mergeStrategy": {
          "$ref": "#/definitions/MergeStrategy"
        },
        "value": true
      }
    },
    "ConfigEdit": {
      "type": "object",
      "required": [
        "keyPath",
        "mergeStrategy",
        "value"
      ],
      "properties": {
        "keyPath": {
          "type": "string"
        },
        "mergeStrategy": {
          "$ref": "#/definitions/MergeStrategy"
        },
        "value": true
      }
    },
    "ConfigBatchWriteParams": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ConfigBatchWriteParams",
      "type": "object",
      "required": [
        "edits"
      ],
      "properties": {
        "edits": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/ConfigEdit"
          }
        },
        "expectedVersion": {
          "type": [
            "string",
            "null"
          ]
        },
        "filePath": {
          "description": "Path to the config file to write; defaults to the user's `config.toml` when omitted.",
          "type": [
            "string",
            "null"
          ]
        },
        "reloadUserConfig": {
          "description": "When true, hot-reload the updated user config into all loaded threads after writing.",
          "type": "boolean"
        }
      }
    },
    "GetAccountParams": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "GetAccountParams",
      "type": "object",
      "properties": {
        "refreshToken": {
          "description": "When `true`, requests a proactive token refresh before returning.\n\nIn managed auth mode this triggers the normal refresh-token flow. In external auth mode this flag is ignored. Clients should refresh tokens themselves and call `account/login/start` with `chatgptAuthTokens`.",
          "default": false,
          "type": "boolean"
        }
      }
    },
    "AgentPath": {
      "type": "string"
    },
    "CodexErrorInfo": {
      "description": "This translation layer make sure that we expose codex error code in camel case.\n\nWhen an upstream HTTP status is available (for example, from the Responses API or a provider), it is forwarded in `httpStatusCode` on the relevant `codexErrorInfo` variant.",
      "oneOf": [
        {
          "type": "string",
          "enum": [
            "contextWindowExceeded",
            "usageLimitExceeded",
            "serverOverloaded",
            "internalServerError",
            "unauthorized",
            "badRequest",
            "threadRollbackFailed",
            "sandboxError",
            "other"
          ]
        },
        {
          "type": "object",
          "required": [
            "httpConnectionFailed"
          ],
          "properties": {
            "httpConnectionFailed": {
              "type": "object",
              "properties": {
                "httpStatusCode": {
                  "type": [
                    "integer",
                    "null"
                  ],
                  "format": "uint16",
                  "minimum": 0.0
                }
              }
            }
          },
          "additionalProperties": false,
          "title": "HttpConnectionFailedCodexErrorInfo"
        },
        {
          "description": "Failed to connect to the response SSE stream.",
          "type": "object",
          "required": [
            "responseStreamConnectionFailed"
          ],
          "properties": {
            "responseStreamConnectionFailed": {
              "type": "object",
              "properties": {
                "httpStatusCode": {
                  "type": [
                    "integer",
                    "null"
                  ],
                  "format": "uint16",
                  "minimum": 0.0
                }
              }
            }
          },
          "additionalProperties": false,
          "title": "ResponseStreamConnectionFailedCodexErrorInfo"
        },
        {
          "description": "The response SSE stream disconnected in the middle of a turn before completion.",
          "type": "object",
          "required": [
            "responseStreamDisconnected"
          ],
          "properties": {
            "responseStreamDisconnected": {
              "type": "object",
              "properties": {
                "httpStatusCode": {
                  "type": [
                    "integer",
                    "null"
                  ],
                  "format": "uint16",
                  "minimum": 0.0
                }
              }
            }
          },
          "additionalProperties": false,
          "title": "ResponseStreamDisconnectedCodexErrorInfo"
        },
        {
          "description": "Reached the retry limit for responses.",
          "type": "object",
          "required": [
            "responseTooManyFailedAttempts"
          ],
          "properties": {
            "responseTooManyFailedAttempts": {
              "type": "object",
              "properties": {
                "httpStatusCode": {
                  "type": [
                    "integer",
                    "null"
                  ],
                  "format": "uint16",
                  "minimum": 0.0
                }
              }
            }
          },
          "additionalProperties": false,
          "title": "ResponseTooManyFailedAttemptsCodexErrorInfo"
        },
        {
          "description": "Returned when `turn/start` or `turn/steer` is submitted while the current active turn cannot accept same-turn steering, for example `/review` or manual `/compact`.",
          "type": "object",
          "required": [
            "activeTurnNotSteerable"
          ],
          "properties": {
            "activeTurnNotSteerable": {
              "type": "object",
              "required": [
                "turnKind"
              ],
              "properties": {
                "turnKind": {
                  "$ref": "#/definitions/NonSteerableTurnKind"
                }
              }
            }
          },
          "additionalProperties": false,
          "title": "ActiveTurnNotSteerableCodexErrorInfo"
        }
      ]
    },
    "CollabAgentState": {
      "type": "object",
      "required": [
        "status"
      ],
      "properties": {
        "message": {
          "type": [
            "string",
            "null"
          ]
        },
        "status": {
          "$ref": "#/definitions/CollabAgentStatus"
        }
      }
    },
    "CollabAgentStatus": {
      "type": "string",
      "enum": [
        "pendingInit",
        "running",
        "interrupted",
        "completed",
        "errored",
        "shutdown",
        "notFound"
      ]
    },
    "CollabAgentTool": {
      "type": "string",
      "enum": [
        "spawnAgent",
        "sendInput",
        "resumeAgent",
        "wait",
        "closeAgent"
      ]
    },
    "CollabAgentToolCallStatus": {
      "type": "string",
      "enum": [
        "inProgress",
        "completed",
        "failed"
      ]
    },
    "CommandAction": {
      "oneOf": [
        {
          "type": "object",
          "required": [
            "command",
            "name",
            "path",
            "type"
          ],
          "properties": {
            "command": {
              "type": "string"
            },
            "name": {
              "type": "string"
            },
            "path": {
              "$ref": "#/definitions/AbsolutePathBuf"
            },
            "type": {
              "type": "string",
              "enum": [
                "read"
              ],
              "title": "ReadCommandActionType"
            }
          },
          "title": "ReadCommandAction"
        },
        {
          "type": "object",
          "required": [
            "command",
            "type"
          ],
          "properties": {
            "command": {
              "type": "string"
            },
            "path": {
              "type": [
                "string",
                "null"
              ]
            },
            "type": {
              "type": "string",
              "enum": [
                "listFiles"
              ],
              "title": "ListFilesCommandActionType"
            }
          },
          "title": "ListFilesCommandAction"
        },
        {
          "type": "object",
          "required": [
            "command",
            "type"
          ],
          "properties": {
            "command": {
              "type": "string"
            },
            "path": {
              "type": [
                "string",
                "null"
              ]
            },
            "query": {
              "type": [
                "string",
                "null"
              ]
            },
            "type": {
              "type": "string",
              "enum": [
                "search"
              ],
              "title": "SearchCommandActionType"
            }
          },
          "title": "SearchCommandAction"
        },
        {
          "type": "object",
          "required": [
            "command",
            "type"
          ],
          "properties": {
            "command": {
              "type": "string"
            },
            "type": {
              "type": "string",
              "enum": [
                "unknown"
              ],
              "title": "UnknownCommandActionType"
            }
          },
          "title": "UnknownCommandAction"
        }
      ]
    },
    "CommandExecutionSource": {
      "type": "string",
      "enum": [
        "agent",
        "userShell",
        "unifiedExecStartup",
        "unifiedExecInteraction"
      ]
    },
    "CommandExecutionStatus": {
      "type": "string",
      "enum": [
        "inProgress",
        "completed",
        "failed",
        "declined"
      ]
    },
    "DynamicToolCallOutputContentItem": {
      "oneOf": [
        {
          "type": "object",
          "required": [
            "text",
            "type"
          ],
          "properties": {
            "text": {
              "type": "string"
            },
            "type": {
              "type": "string",
              "enum": [
                "inputText"
              ],
              "title": "InputTextDynamicToolCallOutputContentItemType"
            }
          },
          "title": "InputTextDynamicToolCallOutputContentItem"
        },
        {
          "type": "object",
          "required": [
            "imageUrl",
            "type"
          ],
          "properties": {
            "imageUrl": {
              "type": "string"
            },
            "type": {
              "type": "string",
              "enum": [
                "inputImage"
              ],
              "title": "InputImageDynamicToolCallOutputContentItemType"
            }
          },
          "title": "InputImageDynamicToolCallOutputContentItem"
        }
      ]
    },
    "DynamicToolCallStatus": {
      "type": "string",
      "enum": [
        "inProgress",
        "completed",
        "failed"
      ]
    },
    "FileUpdateChange": {
      "type": "object",
      "required": [
        "diff",
        "kind",
        "path"
      ],
      "properties": {
        "diff": {
          "type": "string"
        },
        "kind": {
          "$ref": "#/definitions/PatchChangeKind"
        },
        "path": {
          "type": "string"
        }
      }
    },
    "GitInfo": {
      "type": "object",
      "properties": {
        "branch": {
          "type": [
            "string",
            "null"
          ]
        },
        "originUrl": {
          "type": [
            "string",
            "null"
          ]
        },
        "sha": {
          "type": [
            "string",
            "null"
          ]
        }
      }
    },
    "HookPromptFragment": {
      "type": "object",
      "required": [
        "hookRunId",
        "text"
      ],
      "properties": {
        "hookRunId": {
          "type": "string"
        },
        "text": {
          "type": "string"
        }
      }
    },
    "McpToolCallError": {
      "type": "object",
      "required": [
        "message"
      ],
      "properties": {
        "message": {
          "type": "string"
        }
      }
    },
    "McpToolCallResult": {
      "type": "object",
      "required": [
        "content"
      ],
      "properties": {
        "_meta": true,
        "content": {
          "type": "array",
          "items": true
        },
        "structuredContent": true
      }
    },
    "McpToolCallStatus": {
      "type": "string",
      "enum": [
        "inProgress",
        "completed",
        "failed"
      ]
    },
    "MemoryCitation": {
      "type": "object",
      "required": [
        "entries",
        "threadIds"
      ],
      "properties": {
        "entries": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/MemoryCitationEntry"
          }
        },
        "threadIds": {
          "type": "array",
          "items": {
            "type": "string"
          }
        }
      }
    },
    "MemoryCitationEntry": {
      "type": "object",
      "required": [
        "lineEnd",
        "lineStart",
        "note",
        "path"
      ],
      "properties": {
        "lineEnd": {
          "type": "integer",
          "format": "uint32",
          "minimum": 0.0
        },
        "lineStart": {
          "type": "integer",
          "format": "uint32",
          "minimum": 0.0
        },
        "note": {
          "type": "string"
        },
        "path": {
          "type": "string"
        }
      }
    },
    "NonSteerableTurnKind": {
      "type": "string",
      "enum": [
        "review",
        "compact"
      ]
    },
    "PatchApplyStatus": {
      "type": "string",
      "enum": [
        "inProgress",
        "completed",
        "failed",
        "declined"
      ]
    },
    "PatchChangeKind": {
      "oneOf": [
        {
          "type": "object",
          "required": [
            "type"
          ],
          "properties": {
            "type": {
              "type": "string",
              "enum": [
                "add"
              ],
              "title": "AddPatchChangeKindType"
            }
          },
          "title": "AddPatchChangeKind"
        },
        {
          "type": "object",
          "required": [
            "type"
          ],
          "properties": {
            "type": {
              "type": "string",
              "enum": [
                "delete"
              ],
              "title": "DeletePatchChangeKindType"
            }
          },
          "title": "DeletePatchChangeKind"
        },
        {
          "type": "object",
          "required": [
            "type"
          ],
          "properties": {
            "move_path": {
              "type": [
                "string",
                "null"
              ]
            },
            "type": {
              "type": "string",
              "enum": [
                "update"
              ],
              "title": "UpdatePatchChangeKindType"
            }
          },
          "title": "UpdatePatchChangeKind"
        }
      ]
    },
    "SessionSource": {
      "oneOf": [
        {
          "type": "string",
          "enum": [
            "cli",
            "vscode",
            "exec",
            "appServer",
            "unknown"
          ]
        },
        {
          "type": "object",
          "required": [
            "custom"
          ],
          "properties": {
            "custom": {
              "type": "string"
            }
          },
          "additionalProperties": false,
          "title": "CustomSessionSource"
        },
        {
          "type": "object",
          "required": [
            "subAgent"
          ],
          "properties": {
            "subAgent": {
              "$ref": "#/definitions/SubAgentSource"
            }
          },
          "additionalProperties": false,
          "title": "SubAgentSessionSource"
        }
      ]
    },
    "SubAgentSource": {
      "oneOf": [
        {
          "type": "string",
          "enum": [
            "review",
            "compact",
            "memory_consolidation"
          ]
        },
        {
          "type": "object",
          "required": [
            "thread_spawn"
          ],
          "properties": {
            "thread_spawn": {
              "type": "object",
              "required": [
                "depth",
                "parent_thread_id"
              ],
              "properties": {
                "agent_nickname": {
                  "default": null,
                  "type": [
                    "string",
                    "null"
                  ]
                },
                "agent_path": {
                  "default": null,
                  "anyOf": [
                    {
                      "$ref": "#/definitions/AgentPath"
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "agent_role": {
                  "default": null,
                  "type": [
                    "string",
                    "null"
                  ]
                },
                "depth": {
                  "type": "integer",
                  "format": "int32"
                },
                "parent_thread_id": {
                  "$ref": "#/definitions/ThreadId"
                }
              }
            }
          },
          "additionalProperties": false,
          "title": "ThreadSpawnSubAgentSource"
        },
        {
          "type": "object",
          "required": [
            "other"
          ],
          "properties": {
            "other": {
              "type": "string"
            }
          },
          "additionalProperties": false,
          "title": "OtherSubAgentSource"
        }
      ]
    },
    "Thread": {
      "type": "object",
      "required": [
        "cliVersion",
        "createdAt",
        "cwd",
        "ephemeral",
        "id",
        "modelProvider",
        "preview",
        "source",
        "status",
        "turns",
        "updatedAt"
      ],
      "properties": {
        "agentNickname": {
          "description": "Optional random unique nickname assigned to an AgentControl-spawned sub-agent.",
          "type": [
            "string",
            "null"
          ]
        },
        "agentRole": {
          "description": "Optional role (agent_role) assigned to an AgentControl-spawned sub-agent.",
          "type": [
            "string",
            "null"
          ]
        },
        "cliVersion": {
          "description": "Version of the CLI that created the thread.",
          "type": "string"
        },
        "createdAt": {
          "description": "Unix timestamp (in seconds) when the thread was created.",
          "type": "integer",
          "format": "int64"
        },
        "cwd": {
          "description": "Working directory captured for the thread.",
          "allOf": [
            {
              "$ref": "#/definitions/AbsolutePathBuf"
            }
          ]
        },
        "ephemeral": {
          "description": "Whether the thread is ephemeral and should not be materialized on disk.",
          "type": "boolean"
        },
        "forkedFromId": {
          "description": "Source thread id when this thread was created by forking another thread.",
          "type": [
            "string",
            "null"
          ]
        },
        "gitInfo": {
          "description": "Optional Git metadata captured when the thread was created.",
          "anyOf": [
            {
              "$ref": "#/definitions/GitInfo"
            },
            {
              "type": "null"
            }
          ]
        },
        "id": {
          "type": "string"
        },
        "modelProvider": {
          "description": "Model provider used for this thread (for example, 'openai').",
          "type": "string"
        },
        "name": {
          "description": "Optional user-facing thread title.",
          "type": [
            "string",
            "null"
          ]
        },
        "path": {
          "description": "[UNSTABLE] Path to the thread on disk.",
          "type": [
            "string",
            "null"
          ]
        },
        "preview": {
          "description": "Usually the first user message in the thread, if available.",
          "type": "string"
        },
        "source": {
          "description": "Origin of the thread (CLI, VSCode, codex exec, codex app-server, etc.).",
          "allOf": [
            {
              "$ref": "#/definitions/SessionSource"
            }
          ]
        },
        "status": {
          "description": "Current runtime status for the thread.",
          "allOf": [
            {
              "$ref": "#/definitions/ThreadStatus"
            }
          ]
        },
        "turns": {
          "description": "Only populated on `thread/resume`, `thread/rollback`, `thread/fork`, and `thread/read` (when `includeTurns` is true) responses. For all other responses and notifications returning a Thread, the turns field will be an empty list.",
          "type": "array",
          "items": {
            "$ref": "#/definitions/Turn"
          }
        },
        "updatedAt": {
          "description": "Unix timestamp (in seconds) when the thread was last updated.",
          "type": "integer",
          "format": "int64"
        }
      }
    },
    "ThreadActiveFlag": {
      "type": "string",
      "enum": [
        "waitingOnApproval",
        "waitingOnUserInput"
      ]
    },
    "ThreadId": {
      "type": "string"
    },
    "ThreadItem": {
      "oneOf": [
        {
          "type": "object",
          "required": [
            "content",
            "id",
            "type"
          ],
          "properties": {
            "content": {
              "type": "array",
              "items": {
                "$ref": "#/definitions/UserInput"
              }
            },
            "id": {
              "type": "string"
            },
            "type": {
              "type": "string",
              "enum": [
                "userMessage"
              ],
              "title": "UserMessageThreadItemType"
            }
          },
          "title": "UserMessageThreadItem"
        },
        {
          "type": "object",
          "required": [
            "fragments",
            "id",
            "type"
          ],
          "properties": {
            "fragments": {
              "type": "array",
              "items": {
                "$ref": "#/definitions/HookPromptFragment"
              }
            },
            "id": {
              "type": "string"
            },
            "type": {
              "type": "string",
              "enum": [
                "hookPrompt"
              ],
              "title": "HookPromptThreadItemType"
            }
          },
          "title": "HookPromptThreadItem"
        },
        {
          "type": "object",
          "required": [
            "id",
            "text",
            "type"
          ],
          "properties": {
            "id": {
              "type": "string"
            },
            "memoryCitation": {
              "default": null,
              "anyOf": [
                {
                  "$ref": "#/definitions/MemoryCitation"
                },
                {
                  "type": "null"
                }
              ]
            },
            "phase": {
              "default": null,
              "anyOf": [
                {
                  "$ref": "#/definitions/MessagePhase"
                },
                {
                  "type": "null"
                }
              ]
            },
            "text": {
              "type": "string"
            },
            "type": {
              "type": "string",
              "enum": [
                "agentMessage"
              ],
              "title": "AgentMessageThreadItemType"
            }
          },
          "title": "AgentMessageThreadItem"
        },
        {
          "description": "EXPERIMENTAL - proposed plan item content. The completed plan item is authoritative and may not match the concatenation of `PlanDelta` text.",
          "type": "object",
          "required": [
            "id",
            "text",
            "type"
          ],
          "properties": {
            "id": {
              "type": "string"
            },
            "text": {
              "type": "string"
            },
            "type": {
              "type": "string",
              "enum": [
                "plan"
              ],
              "title": "PlanThreadItemType"
            }
          },
          "title": "PlanThreadItem"
        },
        {
          "type": "object",
          "required": [
            "id",
            "type"
          ],
          "properties": {
            "content": {
              "default": [],
              "type": "array",
              "items": {
                "type": "string"
              }
            },
            "id": {
              "type": "string"
            },
            "summary": {
              "default": [],
              "type": "array",
              "items": {
                "type": "string"
              }
            },
            "type": {
              "type": "string",
              "enum": [
                "reasoning"
              ],
              "title": "ReasoningThreadItemType"
            }
          },
          "title": "ReasoningThreadItem"
        },
        {
          "type": "object",
          "required": [
            "command",
            "commandActions",
            "cwd",
            "id",
            "status",
            "type"
          ],
          "properties": {
            "aggregatedOutput": {
              "description": "The command's output, aggregated from stdout and stderr.",
              "type": [
                "string",
                "null"
              ]
            },
            "command": {
              "description": "The command to be executed.",
              "type": "string"
            },
            "commandActions": {
              "description": "A best-effort parsing of the command to understand the action(s) it will perform. This returns a list of CommandAction objects because a single shell command may be composed of many commands piped together.",
              "type": "array",
              "items": {
                "$ref": "#/definitions/CommandAction"
              }
            },
            "cwd": {
              "description": "The command's working directory.",
              "allOf": [
                {
                  "$ref": "#/definitions/AbsolutePathBuf"
                }
              ]
            },
            "durationMs": {
              "description": "The duration of the command execution in milliseconds.",
              "type": [
                "integer",
                "null"
              ],
              "format": "int64"
            },
            "exitCode": {
              "description": "The command's exit code.",
              "type": [
                "integer",
                "null"
              ],
              "format": "int32"
            },
            "id": {
              "type": "string"
            },
            "processId": {
              "description": "Identifier for the underlying PTY process (when available).",
              "type": [
                "string",
                "null"
              ]
            },
            "source": {
              "default": "agent",
              "allOf": [
                {
                  "$ref": "#/definitions/CommandExecutionSource"
                }
              ]
            },
            "status": {
              "$ref": "#/definitions/CommandExecutionStatus"
            },
            "type": {
              "type": "string",
              "enum": [
                "commandExecution"
              ],
              "title": "CommandExecutionThreadItemType"
            }
          },
          "title": "CommandExecutionThreadItem"
        },
        {
          "type": "object",
          "required": [
            "changes",
            "id",
            "status",
            "type"
          ],
          "properties": {
            "changes": {
              "type": "array",
              "items": {
                "$ref": "#/definitions/FileUpdateChange"
              }
            },
            "id": {
              "type": "string"
            },
            "status": {
              "$ref": "#/definitions/PatchApplyStatus"
            },
            "type": {
              "type": "string",
              "enum": [
                "fileChange"
              ],
              "title": "FileChangeThreadItemType"
            }
          },
          "title": "FileChangeThreadItem"
        },
        {
          "type": "object",
          "required": [
            "arguments",
            "id",
            "server",
            "status",
            "tool",
            "type"
          ],
          "properties": {
            "arguments": true,
            "durationMs": {
              "description": "The duration of the MCP tool call in milliseconds.",
              "type": [
                "integer",
                "null"
              ],
              "format": "int64"
            },
            "error": {
              "anyOf": [
                {
                  "$ref": "#/definitions/McpToolCallError"
                },
                {
                  "type": "null"
                }
              ]
            },
            "id": {
              "type": "string"
            },
            "mcpAppResourceUri": {
              "type": [
                "string",
                "null"
              ]
            },
            "result": {
              "anyOf": [
                {
                  "$ref": "#/definitions/McpToolCallResult"
                },
                {
                  "type": "null"
                }
              ]
            },
            "server": {
              "type": "string"
            },
            "status": {
              "$ref": "#/definitions/McpToolCallStatus"
            },
            "tool": {
              "type": "string"
            },
            "type": {
              "type": "string",
              "enum": [
                "mcpToolCall"
              ],
              "title": "McpToolCallThreadItemType"
            }
          },
          "title": "McpToolCallThreadItem"
        },
        {
          "type": "object",
          "required": [
            "arguments",
            "id",
            "status",
            "tool",
            "type"
          ],
          "properties": {
            "arguments": true,
            "contentItems": {
              "type": [
                "array",
                "null"
              ],
              "items": {
                "$ref": "#/definitions/DynamicToolCallOutputContentItem"
              }
            },
            "durationMs": {
              "description": "The duration of the dynamic tool call in milliseconds.",
              "type": [
                "integer",
                "null"
              ],
              "format": "int64"
            },
            "id": {
              "type": "string"
            },
            "status": {
              "$ref": "#/definitions/DynamicToolCallStatus"
            },
            "success": {
              "type": [
                "boolean",
                "null"
              ]
            },
            "tool": {
              "type": "string"
            },
            "type": {
              "type": "string",
              "enum": [
                "dynamicToolCall"
              ],
              "title": "DynamicToolCallThreadItemType"
            }
          },
          "title": "DynamicToolCallThreadItem"
        },
        {
          "type": "object",
          "required": [
            "agentsStates",
            "id",
            "receiverThreadIds",
            "senderThreadId",
            "status",
            "tool",
            "type"
          ],
          "properties": {
            "agentsStates": {
              "description": "Last known status of the target agents, when available.",
              "type": "object",
              "additionalProperties": {
                "$ref": "#/definitions/CollabAgentState"
              }
            },
            "id": {
              "description": "Unique identifier for this collab tool call.",
              "type": "string"
            },
            "model": {
              "description": "Model requested for the spawned agent, when applicable.",
              "type": [
                "string",
                "null"
              ]
            },
            "prompt": {
              "description": "Prompt text sent as part of the collab tool call, when available.",
              "type": [
                "string",
                "null"
              ]
            },
            "reasoningEffort": {
              "description": "Reasoning effort requested for the spawned agent, when applicable.",
              "anyOf": [
                {
                  "$ref": "#/definitions/ReasoningEffort"
                },
                {
                  "type": "null"
                }
              ]
            },
            "receiverThreadIds": {
              "description": "Thread ID of the receiving agent, when applicable. In case of spawn operation, this corresponds to the newly spawned agent.",
              "type": "array",
              "items": {
                "type": "string"
              }
            },
            "senderThreadId": {
              "description": "Thread ID of the agent issuing the collab request.",
              "type": "string"
            },
            "status": {
              "description": "Current status of the collab tool call.",
              "allOf": [
                {
                  "$ref": "#/definitions/CollabAgentToolCallStatus"
                }
              ]
            },
            "tool": {
              "description": "Name of the collab tool that was invoked.",
              "allOf": [
                {
                  "$ref": "#/definitions/CollabAgentTool"
                }
              ]
            },
            "type": {
              "type": "string",
              "enum": [
                "collabAgentToolCall"
              ],
              "title": "CollabAgentToolCallThreadItemType"
            }
          },
          "title": "CollabAgentToolCallThreadItem"
        },
        {
          "type": "object",
          "required": [
            "id",
            "query",
            "type"
          ],
          "properties": {
            "action": {
              "anyOf": [
                {
                  "$ref": "#/definitions/WebSearchAction"
                },
                {
                  "type": "null"
                }
              ]
            },
            "id": {
              "type": "string"
            },
            "query": {
              "type": "string"
            },
            "type": {
              "type": "string",
              "enum": [
                "webSearch"
              ],
              "title": "WebSearchThreadItemType"
            }
          },
          "title": "WebSearchThreadItem"
        },
        {
          "type": "object",
          "required": [
            "id",
            "path",
            "type"
          ],
          "properties": {
            "id": {
              "type": "string"
            },
            "path": {
              "$ref": "#/definitions/AbsolutePathBuf"
            },
            "type": {
              "type": "string",
              "enum": [
                "imageView"
              ],
              "title": "ImageViewThreadItemType"
            }
          },
          "title": "ImageViewThreadItem"
        },
        {
          "type": "object",
          "required": [
            "id",
            "result",
            "status",
            "type"
          ],
          "properties": {
            "id": {
              "type": "string"
            },
            "result": {
              "type": "string"
            },
            "revisedPrompt": {
              "type": [
                "string",
                "null"
              ]
            },
            "savedPath": {
              "anyOf": [
                {
                  "$ref": "#/definitions/AbsolutePathBuf"
                },
                {
                  "type": "null"
                }
              ]
            },
            "status": {
              "type": "string"
            },
            "type": {
              "type": "string",
              "enum": [
                "imageGeneration"
              ],
              "title": "ImageGenerationThreadItemType"
            }
          },
          "title": "ImageGenerationThreadItem"
        },
        {
          "type": "object",
          "required": [
            "id",
            "review",
            "type"
          ],
          "properties": {
            "id": {
              "type": "string"
            },
            "review": {
              "type": "string"
            },
            "type": {
              "type": "string",
              "enum": [
                "enteredReviewMode"
              ],
              "title": "EnteredReviewModeThreadItemType"
            }
          },
          "title": "EnteredReviewModeThreadItem"
        },
        {
          "type": "object",
          "required": [
            "id",
            "review",
            "type"
          ],
          "properties": {
            "id": {
              "type": "string"
            },
            "review": {
              "type": "string"
            },
            "type": {
              "type": "string",
              "enum": [
                "exitedReviewMode"
              ],
              "title": "ExitedReviewModeThreadItemType"
            }
          },
          "title": "ExitedReviewModeThreadItem"
        },
        {
          "type": "object",
          "required": [
            "id",
            "type"
          ],
          "properties": {
            "id": {
              "type": "string"
            },
            "type": {
              "type": "string",
              "enum": [
                "contextCompaction"
              ],
              "title": "ContextCompactionThreadItemType"
            }
          },
          "title": "ContextCompactionThreadItem"
        }
      ]
    },
    "ThreadStatus": {
      "oneOf": [
        {
          "type": "object",
          "required": [
            "type"
          ],
          "properties": {
            "type": {
              "type": "string",
              "enum": [
                "notLoaded"
              ],
              "title": "NotLoadedThreadStatusType"
            }
          },
          "title": "NotLoadedThreadStatus"
        },
        {
          "type": "object",
          "required": [
            "type"
          ],
          "properties": {
            "type": {
              "type": "string",
              "enum": [
                "idle"
              ],
              "title": "IdleThreadStatusType"
            }
          },
          "title": "IdleThreadStatus"
        },
        {
          "type": "object",
          "required": [
            "type"
          ],
          "properties": {
            "type": {
              "type": "string",
              "enum": [
                "systemError"
              ],
              "title": "SystemErrorThreadStatusType"
            }
          },
          "title": "SystemErrorThreadStatus"
        },
        {
          "type": "object",
          "required": [
            "activeFlags",
            "type"
          ],
          "properties": {
            "activeFlags": {
              "type": "array",
              "items": {
                "$ref": "#/definitions/ThreadActiveFlag"
              }
            },
            "type": {
              "type": "string",
              "enum": [
                "active"
              ],
              "title": "ActiveThreadStatusType"
            }
          },
          "title": "ActiveThreadStatus"
        }
      ]
    },
    "Turn": {
      "type": "object",
      "required": [
        "id",
        "items",
        "status"
      ],
      "properties": {
        "completedAt": {
          "description": "Unix timestamp (in seconds) when the turn completed.",
          "type": [
            "integer",
            "null"
          ],
          "format": "int64"
        },
        "durationMs": {
          "description": "Duration between turn start and completion in milliseconds, if known.",
          "type": [
            "integer",
            "null"
          ],
          "format": "int64"
        },
        "error": {
          "description": "Only populated when the Turn's status is failed.",
          "anyOf": [
            {
              "$ref": "#/definitions/TurnError"
            },
            {
              "type": "null"
            }
          ]
        },
        "id": {
          "type": "string"
        },
        "items": {
          "description": "Only populated on a `thread/resume` or `thread/fork` response. For all other responses and notifications returning a Turn, the items field will be an empty list.",
          "type": "array",
          "items": {
            "$ref": "#/definitions/ThreadItem"
          }
        },
        "startedAt": {
          "description": "Unix timestamp (in seconds) when the turn started.",
          "type": [
            "integer",
            "null"
          ],
          "format": "int64"
        },
        "status": {
          "$ref": "#/definitions/TurnStatus"
        }
      }
    },
    "TurnError": {
      "type": "object",
      "required": [
        "message"
      ],
      "properties": {
        "additionalDetails": {
          "default": null,
          "type": [
            "string",
            "null"
          ]
        },
        "codexErrorInfo": {
          "anyOf": [
            {
              "$ref": "#/definitions/CodexErrorInfo"
            },
            {
              "type": "null"
            }
          ]
        },
        "message": {
          "type": "string"
        }
      }
    },
    "TurnStatus": {
      "type": "string",
      "enum": [
        "completed",
        "interrupted",
        "failed",
        "inProgress"
      ]
    },
    "WebSearchAction": {
      "oneOf": [
        {
          "type": "object",
          "required": [
            "type"
          ],
          "properties": {
            "queries": {
              "type": [
                "array",
                "null"
              ],
              "items": {
                "type": "string"
              }
            },
            "query": {
              "type": [
                "string",
                "null"
              ]
            },
            "type": {
              "type": "string",
              "enum": [
                "search"
              ],
              "title": "SearchWebSearchActionType"
            }
          },
          "title": "SearchWebSearchAction"
        },
        {
          "type": "object",
          "required": [
            "type"
          ],
          "properties": {
            "type": {
              "type": "string",
              "enum": [
                "openPage"
              ],
              "title": "OpenPageWebSearchActionType"
            },
            "url": {
              "type": [
                "string",
                "null"
              ]
            }
          },
          "title": "OpenPageWebSearchAction"
        },
        {
          "type": "object",
          "required": [
            "type"
          ],
          "properties": {
            "pattern": {
              "type": [
                "string",
                "null"
              ]
            },
            "type": {
              "type": "string",
              "enum": [
                "findInPage"
              ],
              "title": "FindInPageWebSearchActionType"
            },
            "url": {
              "type": [
                "string",
                "null"
              ]
            }
          },
          "title": "FindInPageWebSearchAction"
        },
        {
          "type": "object",
          "required": [
            "type"
          ],
          "properties": {
            "type": {
              "type": "string",
              "enum": [
                "other"
              ],
              "title": "OtherWebSearchActionType"
            }
          },
          "title": "OtherWebSearchAction"
        }
      ]
    },
    "ThreadStartResponse": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ThreadStartResponse",
      "type": "object",
      "required": [
        "approvalPolicy",
        "approvalsReviewer",
        "cwd",
        "model",
        "modelProvider",
        "sandbox",
        "thread"
      ],
      "properties": {
        "approvalPolicy": {
          "$ref": "#/definitions/AskForApproval"
        },
        "approvalsReviewer": {
          "description": "Reviewer currently used for approval requests on this thread.",
          "allOf": [
            {
              "$ref": "#/definitions/ApprovalsReviewer"
            }
          ]
        },
        "cwd": {
          "$ref": "#/definitions/AbsolutePathBuf"
        },
        "instructionSources": {
          "description": "Instruction source files currently loaded for this thread.",
          "default": [],
          "type": "array",
          "items": {
            "$ref": "#/definitions/AbsolutePathBuf"
          }
        },
        "model": {
          "type": "string"
        },
        "modelProvider": {
          "type": "string"
        },
        "reasoningEffort": {
          "anyOf": [
            {
              "$ref": "#/definitions/ReasoningEffort"
            },
            {
              "type": "null"
            }
          ]
        },
        "sandbox": {
          "$ref": "#/definitions/SandboxPolicy"
        },
        "serviceTier": {
          "anyOf": [
            {
              "$ref": "#/definitions/ServiceTier"
            },
            {
              "type": "null"
            }
          ]
        },
        "thread": {
          "$ref": "#/definitions/Thread"
        }
      }
    },
    "ThreadResumeResponse": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ThreadResumeResponse",
      "type": "object",
      "required": [
        "approvalPolicy",
        "approvalsReviewer",
        "cwd",
        "model",
        "modelProvider",
        "sandbox",
        "thread"
      ],
      "properties": {
        "approvalPolicy": {
          "$ref": "#/definitions/AskForApproval"
        },
        "approvalsReviewer": {
          "description": "Reviewer currently used for approval requests on this thread.",
          "allOf": [
            {
              "$ref": "#/definitions/ApprovalsReviewer"
            }
          ]
        },
        "cwd": {
          "$ref": "#/definitions/AbsolutePathBuf"
        },
        "instructionSources": {
          "description": "Instruction source files currently loaded for this thread.",
          "default": [],
          "type": "array",
          "items": {
            "$ref": "#/definitions/AbsolutePathBuf"
          }
        },
        "model": {
          "type": "string"
        },
        "modelProvider": {
          "type": "string"
        },
        "reasoningEffort": {
          "anyOf": [
            {
              "$ref": "#/definitions/ReasoningEffort"
            },
            {
              "type": "null"
            }
          ]
        },
        "sandbox": {
          "$ref": "#/definitions/SandboxPolicy"
        },
        "serviceTier": {
          "anyOf": [
            {
              "$ref": "#/definitions/ServiceTier"
            },
            {
              "type": "null"
            }
          ]
        },
        "thread": {
          "$ref": "#/definitions/Thread"
        }
      }
    },
    "ThreadForkResponse": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ThreadForkResponse",
      "type": "object",
      "required": [
        "approvalPolicy",
        "approvalsReviewer",
        "cwd",
        "model",
        "modelProvider",
        "sandbox",
        "thread"
      ],
      "properties": {
        "approvalPolicy": {
          "$ref": "#/definitions/AskForApproval"
        },
        "approvalsReviewer": {
          "description": "Reviewer currently used for approval requests on this thread.",
          "allOf": [
            {
              "$ref": "#/definitions/ApprovalsReviewer"
            }
          ]
        },
        "cwd": {
          "$ref": "#/definitions/AbsolutePathBuf"
        },
        "instructionSources": {
          "description": "Instruction source files currently loaded for this thread.",
          "default": [],
          "type": "array",
          "items": {
            "$ref": "#/definitions/AbsolutePathBuf"
          }
        },
        "model": {
          "type": "string"
        },
        "modelProvider": {
          "type": "string"
        },
        "reasoningEffort": {
          "anyOf": [
            {
              "$ref": "#/definitions/ReasoningEffort"
            },
            {
              "type": "null"
            }
          ]
        },
        "sandbox": {
          "$ref": "#/definitions/SandboxPolicy"
        },
        "serviceTier": {
          "anyOf": [
            {
              "$ref": "#/definitions/ServiceTier"
            },
            {
              "type": "null"
            }
          ]
        },
        "thread": {
          "$ref": "#/definitions/Thread"
        }
      }
    },
    "ThreadArchiveResponse": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ThreadArchiveResponse",
      "type": "object"
    },
    "ThreadUnsubscribeStatus": {
      "type": "string",
      "enum": [
        "notLoaded",
        "notSubscribed",
        "unsubscribed"
      ]
    },
    "ThreadUnsubscribeResponse": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ThreadUnsubscribeResponse",
      "type": "object",
      "required": [
        "status"
      ],
      "properties": {
        "status": {
          "$ref": "#/definitions/ThreadUnsubscribeStatus"
        }
      }
    },
    "RealtimeConversationVersion": {
      "type": "string",
      "enum": [
        "v1",
        "v2"
      ]
    },
    "ConfigWarningNotification": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ConfigWarningNotification",
      "type": "object",
      "required": [
        "summary"
      ],
      "properties": {
        "details": {
          "description": "Optional extra guidance or error details.",
          "type": [
            "string",
            "null"
          ]
        },
        "path": {
          "description": "Optional path to the config file that triggered the warning.",
          "type": [
            "string",
            "null"
          ]
        },
        "range": {
          "description": "Optional range for the error location inside the config file.",
          "anyOf": [
            {
              "$ref": "#/definitions/TextRange"
            },
            {
              "type": "null"
            }
          ]
        },
        "summary": {
          "description": "Concise summary of the warning.",
          "type": "string"
        }
      }
    },
    "ThreadSetNameResponse": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ThreadSetNameResponse",
      "type": "object"
    },
    "ThreadMetadataUpdateResponse": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ThreadMetadataUpdateResponse",
      "type": "object",
      "required": [
        "thread"
      ],
      "properties": {
        "thread": {
          "$ref": "#/definitions/Thread"
        }
      }
    },
    "TextRange": {
      "type": "object",
      "required": [
        "end",
        "start"
      ],
      "properties": {
        "end": {
          "$ref": "#/definitions/TextPosition"
        },
        "start": {
          "$ref": "#/definitions/TextPosition"
        }
      }
    },
    "TextPosition": {
      "type": "object",
      "required": [
        "column",
        "line"
      ],
      "properties": {
        "column": {
          "description": "1-based column number (in Unicode scalar values).",
          "type": "integer",
          "format": "uint",
          "minimum": 0.0
        },
        "line": {
          "description": "1-based line number.",
          "type": "integer",
          "format": "uint",
          "minimum": 0.0
        }
      }
    },
    "ThreadUnarchiveResponse": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ThreadUnarchiveResponse",
      "type": "object",
      "required": [
        "thread"
      ],
      "properties": {
        "thread": {
          "$ref": "#/definitions/Thread"
        }
      }
    },
    "ThreadCompactStartResponse": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ThreadCompactStartResponse",
      "type": "object"
    },
    "ThreadShellCommandResponse": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ThreadShellCommandResponse",
      "type": "object"
    },
    "DeprecationNoticeNotification": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "DeprecationNoticeNotification",
      "type": "object",
      "required": [
        "summary"
      ],
      "properties": {
        "details": {
          "description": "Optional extra guidance, such as migration steps or rationale.",
          "type": [
            "string",
            "null"
          ]
        },
        "summary": {
          "description": "Concise summary of what is deprecated.",
          "type": "string"
        }
      }
    },
    "ThreadRollbackResponse": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ThreadRollbackResponse",
      "type": "object",
      "required": [
        "thread"
      ],
      "properties": {
        "thread": {
          "description": "The updated thread after applying the rollback, with `turns` populated.\n\nThe ThreadItems stored in each Turn are lossy since we explicitly do not persist all agent interactions, such as command executions. This is the same behavior as `thread/resume`.",
          "allOf": [
            {
              "$ref": "#/definitions/Thread"
            }
          ]
        }
      }
    },
    "ThreadListResponse": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ThreadListResponse",
      "type": "object",
      "required": [
        "data"
      ],
      "properties": {
        "backwardsCursor": {
          "description": "Opaque cursor to pass as `cursor` when reversing `sortDirection`. This is only populated when the page contains at least one thread. Use it with the opposite `sortDirection`; for timestamp sorts it anchors at the start of the page timestamp so same-second updates are not skipped.",
          "type": [
            "string",
            "null"
          ]
        },
        "data": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/Thread"
          }
        },
        "nextCursor": {
          "description": "Opaque cursor to pass to the next call to continue after the last item. if None, there are no more items to return.",
          "type": [
            "string",
            "null"
          ]
        }
      }
    },
    "ThreadLoadedListResponse": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ThreadLoadedListResponse",
      "type": "object",
      "required": [
        "data"
      ],
      "properties": {
        "data": {
          "description": "Thread ids for sessions currently loaded in memory.",
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "nextCursor": {
          "description": "Opaque cursor to pass to the next call to continue after the last item. if None, there are no more items to return.",
          "type": [
            "string",
            "null"
          ]
        }
      }
    },
    "ThreadReadResponse": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ThreadReadResponse",
      "type": "object",
      "required": [
        "thread"
      ],
      "properties": {
        "thread": {
          "$ref": "#/definitions/Thread"
        }
      }
    },
    "ThreadTurnsListResponse": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ThreadTurnsListResponse",
      "type": "object",
      "required": [
        "data"
      ],
      "properties": {
        "backwardsCursor": {
          "description": "Opaque cursor to pass as `cursor` when reversing `sortDirection`. This is only populated when the page contains at least one turn. Use it with the opposite `sortDirection` to include the anchor turn again and catch updates to that turn.",
          "type": [
            "string",
            "null"
          ]
        },
        "data": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/Turn"
          }
        },
        "nextCursor": {
          "description": "Opaque cursor to pass to the next call to continue after the last turn. if None, there are no more turns to return.",
          "type": [
            "string",
            "null"
          ]
        }
      }
    },
    "ThreadInjectItemsResponse": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ThreadInjectItemsResponse",
      "type": "object"
    },
    "SkillDependencies": {
      "type": "object",
      "required": [
        "tools"
      ],
      "properties": {
        "tools": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/SkillToolDependency"
          }
        }
      }
    },
    "SkillErrorInfo": {
      "type": "object",
      "required": [
        "message",
        "path"
      ],
      "properties": {
        "message": {
          "type": "string"
        },
        "path": {
          "type": "string"
        }
      }
    },
    "SkillInterface": {
      "type": "object",
      "properties": {
        "brandColor": {
          "type": [
            "string",
            "null"
          ]
        },
        "defaultPrompt": {
          "type": [
            "string",
            "null"
          ]
        },
        "displayName": {
          "type": [
            "string",
            "null"
          ]
        },
        "iconLarge": {
          "anyOf": [
            {
              "$ref": "#/definitions/AbsolutePathBuf"
            },
            {
              "type": "null"
            }
          ]
        },
        "iconSmall": {
          "anyOf": [
            {
              "$ref": "#/definitions/AbsolutePathBuf"
            },
            {
              "type": "null"
            }
          ]
        },
        "shortDescription": {
          "type": [
            "string",
            "null"
          ]
        }
      }
    },
    "SkillMetadata": {
      "type": "object",
      "required": [
        "description",
        "enabled",
        "name",
        "path",
        "scope"
      ],
      "properties": {
        "dependencies": {
          "anyOf": [
            {
              "$ref": "#/definitions/SkillDependencies"
            },
            {
              "type": "null"
            }
          ]
        },
        "description": {
          "type": "string"
        },
        "enabled": {
          "type": "boolean"
        },
        "interface": {
          "anyOf": [
            {
              "$ref": "#/definitions/SkillInterface"
            },
            {
              "type": "null"
            }
          ]
        },
        "name": {
          "type": "string"
        },
        "path": {
          "$ref": "#/definitions/AbsolutePathBuf"
        },
        "scope": {
          "$ref": "#/definitions/SkillScope"
        },
        "shortDescription": {
          "description": "Legacy short_description from SKILL.md. Prefer SKILL.json interface.short_description.",
          "type": [
            "string",
            "null"
          ]
        }
      }
    },
    "SkillScope": {
      "type": "string",
      "enum": [
        "user",
        "repo",
        "system",
        "admin"
      ]
    },
    "SkillToolDependency": {
      "type": "object",
      "required": [
        "type",
        "value"
      ],
      "properties": {
        "command": {
          "type": [
            "string",
            "null"
          ]
        },
        "description": {
          "type": [
            "string",
            "null"
          ]
        },
        "transport": {
          "type": [
            "string",
            "null"
          ]
        },
        "type": {
          "type": "string"
        },
        "url": {
          "type": [
            "string",
            "null"
          ]
        },
        "value": {
          "type": "string"
        }
      }
    },
    "SkillsListEntry": {
      "type": "object",
      "required": [
        "cwd",
        "errors",
        "skills"
      ],
      "properties": {
        "cwd": {
          "type": "string"
        },
        "errors": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/SkillErrorInfo"
          }
        },
        "skills": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/SkillMetadata"
          }
        }
      }
    },
    "SkillsListResponse": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "SkillsListResponse",
      "type": "object",
      "required": [
        "data"
      ],
      "properties": {
        "data": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/SkillsListEntry"
          }
        }
      }
    },
    "MarketplaceAddResponse": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "MarketplaceAddResponse",
      "type": "object",
      "required": [
        "alreadyAdded",
        "installedRoot",
        "marketplaceName"
      ],
      "properties": {
        "alreadyAdded": {
          "type": "boolean"
        },
        "installedRoot": {
          "$ref": "#/definitions/AbsolutePathBuf"
        },
        "marketplaceName": {
          "type": "string"
        }
      }
    },
    "MarketplaceRemoveResponse": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "MarketplaceRemoveResponse",
      "type": "object",
      "required": [
        "marketplaceName"
      ],
      "properties": {
        "installedRoot": {
          "anyOf": [
            {
              "$ref": "#/definitions/AbsolutePathBuf"
            },
            {
              "type": "null"
            }
          ]
        },
        "marketplaceName": {
          "type": "string"
        }
      }
    },
    "MarketplaceInterface": {
      "type": "object",
      "properties": {
        "displayName": {
          "type": [
            "string",
            "null"
          ]
        }
      }
    },
    "MarketplaceLoadErrorInfo": {
      "type": "object",
      "required": [
        "marketplacePath",
        "message"
      ],
      "properties": {
        "marketplacePath": {
          "$ref": "#/definitions/AbsolutePathBuf"
        },
        "message": {
          "type": "string"
        }
      }
    },
    "PluginAuthPolicy": {
      "type": "string",
      "enum": [
        "ON_INSTALL",
        "ON_USE"
      ]
    },
    "PluginInstallPolicy": {
      "type": "string",
      "enum": [
        "NOT_AVAILABLE",
        "AVAILABLE",
        "INSTALLED_BY_DEFAULT"
      ]
    },
    "PluginInterface": {
      "type": "object",
      "required": [
        "capabilities",
        "screenshotUrls",
        "screenshots"
      ],
      "properties": {
        "brandColor": {
          "type": [
            "string",
            "null"
          ]
        },
        "capabilities": {
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "category": {
          "type": [
            "string",
            "null"
          ]
        },
        "composerIcon": {
          "description": "Local composer icon path, resolved from the installed plugin package.",
          "anyOf": [
            {
              "$ref": "#/definitions/AbsolutePathBuf"
            },
            {
              "type": "null"
            }
          ]
        },
        "composerIconUrl": {
          "description": "Remote composer icon URL from the plugin catalog.",
          "type": [
            "string",
            "null"
          ]
        },
        "defaultPrompt": {
          "description": "Starter prompts for the plugin. Capped at 3 entries with a maximum of 128 characters per entry.",
          "type": [
            "array",
            "null"
          ],
          "items": {
            "type": "string"
          }
        },
        "developerName": {
          "type": [
            "string",
            "null"
          ]
        },
        "displayName": {
          "type": [
            "string",
            "null"
          ]
        },
        "logo": {
          "description": "Local logo path, resolved from the installed plugin package.",
          "anyOf": [
            {
              "$ref": "#/definitions/AbsolutePathBuf"
            },
            {
              "type": "null"
            }
          ]
        },
        "logoUrl": {
          "description": "Remote logo URL from the plugin catalog.",
          "type": [
            "string",
            "null"
          ]
        },
        "longDescription": {
          "type": [
            "string",
            "null"
          ]
        },
        "privacyPolicyUrl": {
          "type": [
            "string",
            "null"
          ]
        },
        "screenshotUrls": {
          "description": "Remote screenshot URLs from the plugin catalog.",
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "screenshots": {
          "description": "Local screenshot paths, resolved from the installed plugin package.",
          "type": "array",
          "items": {
            "$ref": "#/definitions/AbsolutePathBuf"
          }
        },
        "shortDescription": {
          "type": [
            "string",
            "null"
          ]
        },
        "termsOfServiceUrl": {
          "type": [
            "string",
            "null"
          ]
        },
        "websiteUrl": {
          "type": [
            "string",
            "null"
          ]
        }
      }
    },
    "PluginMarketplaceEntry": {
      "type": "object",
      "required": [
        "name",
        "plugins"
      ],
      "properties": {
        "interface": {
          "anyOf": [
            {
              "$ref": "#/definitions/MarketplaceInterface"
            },
            {
              "type": "null"
            }
          ]
        },
        "name": {
          "type": "string"
        },
        "path": {
          "description": "Local marketplace file path when the marketplace is backed by a local file. Remote-only catalog marketplaces do not have a local path.",
          "anyOf": [
            {
              "$ref": "#/definitions/AbsolutePathBuf"
            },
            {
              "type": "null"
            }
          ]
        },
        "plugins": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/PluginSummary"
          }
        }
      }
    },
    "PluginSource": {
      "oneOf": [
        {
          "type": "object",
          "required": [
            "path",
            "type"
          ],
          "properties": {
            "path": {
              "$ref": "#/definitions/AbsolutePathBuf"
            },
            "type": {
              "type": "string",
              "enum": [
                "local"
              ],
              "title": "LocalPluginSourceType"
            }
          },
          "title": "LocalPluginSource"
        },
        {
          "type": "object",
          "required": [
            "type",
            "url"
          ],
          "properties": {
            "path": {
              "type": [
                "string",
                "null"
              ]
            },
            "refName": {
              "type": [
                "string",
                "null"
              ]
            },
            "sha": {
              "type": [
                "string",
                "null"
              ]
            },
            "type": {
              "type": "string",
              "enum": [
                "git"
              ],
              "title": "GitPluginSourceType"
            },
            "url": {
              "type": "string"
            }
          },
          "title": "GitPluginSource"
        },
        {
          "description": "The plugin is available in the remote catalog. Download metadata is kept server-side and is not exposed through the app-server API.",
          "type": "object",
          "required": [
            "type"
          ],
          "properties": {
            "type": {
              "type": "string",
              "enum": [
                "remote"
              ],
              "title": "RemotePluginSourceType"
            }
          },
          "title": "RemotePluginSource"
        }
      ]
    },
    "PluginSummary": {
      "type": "object",
      "required": [
        "authPolicy",
        "enabled",
        "id",
        "installPolicy",
        "installed",
        "name",
        "source"
      ],
      "properties": {
        "authPolicy": {
          "$ref": "#/definitions/PluginAuthPolicy"
        },
        "enabled": {
          "type": "boolean"
        },
        "id": {
          "type": "string"
        },
        "installPolicy": {
          "$ref": "#/definitions/PluginInstallPolicy"
        },
        "installed": {
          "type": "boolean"
        },
        "interface": {
          "anyOf": [
            {
              "$ref": "#/definitions/PluginInterface"
            },
            {
              "type": "null"
            }
          ]
        },
        "name": {
          "type": "string"
        },
        "source": {
          "$ref": "#/definitions/PluginSource"
        }
      }
    },
    "PluginListResponse": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "PluginListResponse",
      "type": "object",
      "required": [
        "marketplaces"
      ],
      "properties": {
        "featuredPluginIds": {
          "default": [],
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "marketplaceLoadErrors": {
          "default": [],
          "type": "array",
          "items": {
            "$ref": "#/definitions/MarketplaceLoadErrorInfo"
          }
        },
        "marketplaces": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/PluginMarketplaceEntry"
          }
        }
      }
    },
    "AppSummary": {
      "description": "EXPERIMENTAL - app metadata summary for plugin responses.",
      "type": "object",
      "required": [
        "id",
        "name",
        "needsAuth"
      ],
      "properties": {
        "description": {
          "type": [
            "string",
            "null"
          ]
        },
        "id": {
          "type": "string"
        },
        "installUrl": {
          "type": [
            "string",
            "null"
          ]
        },
        "name": {
          "type": "string"
        },
        "needsAuth": {
          "type": "boolean"
        }
      }
    },
    "PluginDetail": {
      "type": "object",
      "required": [
        "apps",
        "marketplaceName",
        "marketplacePath",
        "mcpServers",
        "skills",
        "summary"
      ],
      "properties": {
        "apps": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/AppSummary"
          }
        },
        "description": {
          "type": [
            "string",
            "null"
          ]
        },
        "marketplaceName": {
          "type": "string"
        },
        "marketplacePath": {
          "$ref": "#/definitions/AbsolutePathBuf"
        },
        "mcpServers": {
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "skills": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/SkillSummary"
          }
        },
        "summary": {
          "$ref": "#/definitions/PluginSummary"
        }
      }
    },
    "SkillSummary": {
      "type": "object",
      "required": [
        "description",
        "enabled",
        "name",
        "path"
      ],
      "properties": {
        "description": {
          "type": "string"
        },
        "enabled": {
          "type": "boolean"
        },
        "interface": {
          "anyOf": [
            {
              "$ref": "#/definitions/SkillInterface"
            },
            {
              "type": "null"
            }
          ]
        },
        "name": {
          "type": "string"
        },
        "path": {
          "$ref": "#/definitions/AbsolutePathBuf"
        },
        "shortDescription": {
          "type": [
            "string",
            "null"
          ]
        }
      }
    },
    "PluginReadResponse": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "PluginReadResponse",
      "type": "object",
      "required": [
        "plugin"
      ],
      "properties": {
        "plugin": {
          "$ref": "#/definitions/PluginDetail"
        }
      }
    },
    "AppBranding": {
      "description": "EXPERIMENTAL - app metadata returned by app-list APIs.",
      "type": "object",
      "required": [
        "isDiscoverableApp"
      ],
      "properties": {
        "category": {
          "type": [
            "string",
            "null"
          ]
        },
        "developer": {
          "type": [
            "string",
            "null"
          ]
        },
        "isDiscoverableApp": {
          "type": "boolean"
        },
        "privacyPolicy": {
          "type": [
            "string",
            "null"
          ]
        },
        "termsOfService": {
          "type": [
            "string",
            "null"
          ]
        },
        "website": {
          "type": [
            "string",
            "null"
          ]
        }
      }
    },
    "AppInfo": {
      "description": "EXPERIMENTAL - app metadata returned by app-list APIs.",
      "type": "object",
      "required": [
        "id",
        "name"
      ],
      "properties": {
        "appMetadata": {
          "anyOf": [
            {
              "$ref": "#/definitions/AppMetadata"
            },
            {
              "type": "null"
            }
          ]
        },
        "branding": {
          "anyOf": [
            {
              "$ref": "#/definitions/AppBranding"
            },
            {
              "type": "null"
            }
          ]
        },
        "description": {
          "type": [
            "string",
            "null"
          ]
        },
        "distributionChannel": {
          "type": [
            "string",
            "null"
          ]
        },
        "id": {
          "type": "string"
        },
        "installUrl": {
          "type": [
            "string",
            "null"
          ]
        },
        "isAccessible": {
          "default": false,
          "type": "boolean"
        },
        "isEnabled": {
          "description": "Whether this app is enabled in config.toml. Example: ```toml [apps.bad_app] enabled = false ```",
          "default": true,
          "type": "boolean"
        },
        "labels": {
          "type": [
            "object",
            "null"
          ],
          "additionalProperties": {
            "type": "string"
          }
        },
        "logoUrl": {
          "type": [
            "string",
            "null"
          ]
        },
        "logoUrlDark": {
          "type": [
            "string",
            "null"
          ]
        },
        "name": {
          "type": "string"
        },
        "pluginDisplayNames": {
          "default": [],
          "type": "array",
          "items": {
            "type": "string"
          }
        }
      }
    },
    "AppMetadata": {
      "type": "object",
      "properties": {
        "categories": {
          "type": [
            "array",
            "null"
          ],
          "items": {
            "type": "string"
          }
        },
        "developer": {
          "type": [
            "string",
            "null"
          ]
        },
        "firstPartyRequiresInstall": {
          "type": [
            "boolean",
            "null"
          ]
        },
        "firstPartyType": {
          "type": [
            "string",
            "null"
          ]
        },
        "review": {
          "anyOf": [
            {
              "$ref": "#/definitions/AppReview"
            },
            {
              "type": "null"
            }
          ]
        },
        "screenshots": {
          "type": [
            "array",
            "null"
          ],
          "items": {
            "$ref": "#/definitions/AppScreenshot"
          }
        },
        "seoDescription": {
          "type": [
            "string",
            "null"
          ]
        },
        "showInComposerWhenUnlinked": {
          "type": [
            "boolean",
            "null"
          ]
        },
        "subCategories": {
          "type": [
            "array",
            "null"
          ],
          "items": {
            "type": "string"
          }
        },
        "version": {
          "type": [
            "string",
            "null"
          ]
        },
        "versionId": {
          "type": [
            "string",
            "null"
          ]
        },
        "versionNotes": {
          "type": [
            "string",
            "null"
          ]
        }
      }
    },
    "AppReview": {
      "type": "object",
      "required": [
        "status"
      ],
      "properties": {
        "status": {
          "type": "string"
        }
      }
    },
    "AppScreenshot": {
      "type": "object",
      "required": [
        "userPrompt"
      ],
      "properties": {
        "fileId": {
          "type": [
            "string",
            "null"
          ]
        },
        "url": {
          "type": [
            "string",
            "null"
          ]
        },
        "userPrompt": {
          "type": "string"
        }
      }
    },
    "AppsListResponse": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "AppsListResponse",
      "description": "EXPERIMENTAL - app list response.",
      "type": "object",
      "required": [
        "data"
      ],
      "properties": {
        "data": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/AppInfo"
          }
        },
        "nextCursor": {
          "description": "Opaque cursor to pass to the next call to continue after the last item. If None, there are no more items to return.",
          "type": [
            "string",
            "null"
          ]
        }
      }
    },
    "FsReadFileResponse": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "FsReadFileResponse",
      "description": "Base64-encoded file contents returned by `fs/readFile`.",
      "type": "object",
      "required": [
        "dataBase64"
      ],
      "properties": {
        "dataBase64": {
          "description": "File contents encoded as base64.",
          "type": "string"
        }
      }
    },
    "FsWriteFileResponse": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "FsWriteFileResponse",
      "description": "Successful response for `fs/writeFile`.",
      "type": "object"
    },
    "FsCreateDirectoryResponse": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "FsCreateDirectoryResponse",
      "description": "Successful response for `fs/createDirectory`.",
      "type": "object"
    },
    "FsGetMetadataResponse": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "FsGetMetadataResponse",
      "description": "Metadata returned by `fs/getMetadata`.",
      "type": "object",
      "required": [
        "createdAtMs",
        "isDirectory",
        "isFile",
        "isSymlink",
        "modifiedAtMs"
      ],
      "properties": {
        "createdAtMs": {
          "description": "File creation time in Unix milliseconds when available, otherwise `0`.",
          "type": "integer",
          "format": "int64"
        },
        "isDirectory": {
          "description": "Whether the path resolves to a directory.",
          "type": "boolean"
        },
        "isFile": {
          "description": "Whether the path resolves to a regular file.",
          "type": "boolean"
        },
        "isSymlink": {
          "description": "Whether the path itself is a symbolic link.",
          "type": "boolean"
        },
        "modifiedAtMs": {
          "description": "File modification time in Unix milliseconds when available, otherwise `0`.",
          "type": "integer",
          "format": "int64"
        }
      }
    },
    "FsReadDirectoryEntry": {
      "description": "A directory entry returned by `fs/readDirectory`.",
      "type": "object",
      "required": [
        "fileName",
        "isDirectory",
        "isFile"
      ],
      "properties": {
        "fileName": {
          "description": "Direct child entry name only, not an absolute or relative path.",
          "type": "string"
        },
        "isDirectory": {
          "description": "Whether this entry resolves to a directory.",
          "type": "boolean"
        },
        "isFile": {
          "description": "Whether this entry resolves to a regular file.",
          "type": "boolean"
        }
      }
    },
    "FsReadDirectoryResponse": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "FsReadDirectoryResponse",
      "description": "Directory entries returned by `fs/readDirectory`.",
      "type": "object",
      "required": [
        "entries"
      ],
      "properties": {
        "entries": {
          "description": "Direct child entries in the requested directory.",
          "type": "array",
          "items": {
            "$ref": "#/definitions/FsReadDirectoryEntry"
          }
        }
      }
    },
    "FsRemoveResponse": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "FsRemoveResponse",
      "description": "Successful response for `fs/remove`.",
      "type": "object"
    },
    "FsCopyResponse": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "FsCopyResponse",
      "description": "Successful response for `fs/copy`.",
      "type": "object"
    },
    "FsWatchResponse": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "FsWatchResponse",
      "description": "Successful response for `fs/watch`.",
      "type": "object",
      "required": [
        "path"
      ],
      "properties": {
        "path": {
          "description": "Canonicalized path associated with the watch.",
          "allOf": [
            {
              "$ref": "#/definitions/AbsolutePathBuf"
            }
          ]
        }
      }
    },
    "FsUnwatchResponse": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "FsUnwatchResponse",
      "description": "Successful response for `fs/unwatch`.",
      "type": "object"
    },
    "SkillsConfigWriteResponse": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "SkillsConfigWriteResponse",
      "type": "object",
      "required": [
        "effectiveEnabled"
      ],
      "properties": {
        "effectiveEnabled": {
          "type": "boolean"
        }
      }
    },
    "PluginInstallResponse": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "PluginInstallResponse",
      "type": "object",
      "required": [
        "appsNeedingAuth",
        "authPolicy"
      ],
      "properties": {
        "appsNeedingAuth": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/AppSummary"
          }
        },
        "authPolicy": {
          "$ref": "#/definitions/PluginAuthPolicy"
        }
      }
    },
    "PluginUninstallResponse": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "PluginUninstallResponse",
      "type": "object"
    },
    "TurnStartResponse": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "TurnStartResponse",
      "type": "object",
      "required": [
        "turn"
      ],
      "properties": {
        "turn": {
          "$ref": "#/definitions/Turn"
        }
      }
    },
    "TurnSteerResponse": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "TurnSteerResponse",
      "type": "object",
      "required": [
        "turnId"
      ],
      "properties": {
        "turnId": {
          "type": "string"
        }
      }
    },
    "TurnInterruptResponse": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "TurnInterruptResponse",
      "type": "object"
    },
    "WarningNotification": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "WarningNotification",
      "type": "object",
      "required": [
        "message"
      ],
      "properties": {
        "message": {
          "description": "Concise warning message for the user.",
          "type": "string"
        },
        "threadId": {
          "description": "Optional thread target when the warning applies to a specific thread.",
          "type": [
            "string",
            "null"
          ]
        }
      }
    },
    "ModelReroutedNotification": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ModelReroutedNotification",
      "type": "object",
      "required": [
        "fromModel",
        "reason",
        "threadId",
        "toModel",
        "turnId"
      ],
      "properties": {
        "fromModel": {
          "type": "string"
        },
        "reason": {
          "$ref": "#/definitions/ModelRerouteReason"
        },
        "threadId": {
          "type": "string"
        },
        "toModel": {
          "type": "string"
        },
        "turnId": {
          "type": "string"
        }
      }
    },
    "ModelRerouteReason": {
      "type": "string",
      "enum": [
        "highRiskCyberActivity"
      ]
    },
    "ContextCompactedNotification": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ContextCompactedNotification",
      "description": "Deprecated: Use `ContextCompaction` item type instead.",
      "type": "object",
      "required": [
        "threadId",
        "turnId"
      ],
      "properties": {
        "threadId": {
          "type": "string"
        },
        "turnId": {
          "type": "string"
        }
      }
    },
    "RealtimeVoicesList": {
      "type": "object",
      "required": [
        "defaultV1",
        "defaultV2",
        "v1",
        "v2"
      ],
      "properties": {
        "defaultV1": {
          "$ref": "#/definitions/RealtimeVoice"
        },
        "defaultV2": {
          "$ref": "#/definitions/RealtimeVoice"
        },
        "v1": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/RealtimeVoice"
          }
        },
        "v2": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/RealtimeVoice"
          }
        }
      }
    },
    "ReasoningTextDeltaNotification": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ReasoningTextDeltaNotification",
      "type": "object",
      "required": [
        "contentIndex",
        "delta",
        "itemId",
        "threadId",
        "turnId"
      ],
      "properties": {
        "contentIndex": {
          "type": "integer",
          "format": "int64"
        },
        "delta": {
          "type": "string"
        },
        "itemId": {
          "type": "string"
        },
        "threadId": {
          "type": "string"
        },
        "turnId": {
          "type": "string"
        }
      }
    },
    "ReviewStartResponse": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ReviewStartResponse",
      "type": "object",
      "required": [
        "reviewThreadId",
        "turn"
      ],
      "properties": {
        "reviewThreadId": {
          "description": "Identifies the thread where the review runs.\n\nFor inline reviews, this is the original thread id. For detached reviews, this is the id of the new review thread.",
          "type": "string"
        },
        "turn": {
          "$ref": "#/definitions/Turn"
        }
      }
    },
    "InputModality": {
      "description": "Canonical user-input modality tags advertised by a model.",
      "oneOf": [
        {
          "description": "Plain text turns and tool payloads.",
          "type": "string",
          "enum": [
            "text"
          ]
        },
        {
          "description": "Image attachments included in user turns.",
          "type": "string",
          "enum": [
            "image"
          ]
        }
      ]
    },
    "Model": {
      "type": "object",
      "required": [
        "defaultReasoningEffort",
        "description",
        "displayName",
        "hidden",
        "id",
        "isDefault",
        "model",
        "supportedReasoningEfforts"
      ],
      "properties": {
        "additionalSpeedTiers": {
          "default": [],
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "availabilityNux": {
          "anyOf": [
            {
              "$ref": "#/definitions/ModelAvailabilityNux"
            },
            {
              "type": "null"
            }
          ]
        },
        "defaultReasoningEffort": {
          "$ref": "#/definitions/ReasoningEffort"
        },
        "description": {
          "type": "string"
        },
        "displayName": {
          "type": "string"
        },
        "hidden": {
          "type": "boolean"
        },
        "id": {
          "type": "string"
        },
        "inputModalities": {
          "default": [
            "text",
            "image"
          ],
          "type": "array",
          "items": {
            "$ref": "#/definitions/InputModality"
          }
        },
        "isDefault": {
          "type": "boolean"
        },
        "model": {
          "type": "string"
        },
        "supportedReasoningEfforts": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/ReasoningEffortOption"
          }
        },
        "supportsPersonality": {
          "default": false,
          "type": "boolean"
        },
        "upgrade": {
          "type": [
            "string",
            "null"
          ]
        },
        "upgradeInfo": {
          "anyOf": [
            {
              "$ref": "#/definitions/ModelUpgradeInfo"
            },
            {
              "type": "null"
            }
          ]
        }
      }
    },
    "ModelAvailabilityNux": {
      "type": "object",
      "required": [
        "message"
      ],
      "properties": {
        "message": {
          "type": "string"
        }
      }
    },
    "ModelUpgradeInfo": {
      "type": "object",
      "required": [
        "model"
      ],
      "properties": {
        "migrationMarkdown": {
          "type": [
            "string",
            "null"
          ]
        },
        "model": {
          "type": "string"
        },
        "modelLink": {
          "type": [
            "string",
            "null"
          ]
        },
        "upgradeCopy": {
          "type": [
            "string",
            "null"
          ]
        }
      }
    },
    "ReasoningEffortOption": {
      "type": "object",
      "required": [
        "description",
        "reasoningEffort"
      ],
      "properties": {
        "description": {
          "type": "string"
        },
        "reasoningEffort": {
          "$ref": "#/definitions/ReasoningEffort"
        }
      }
    },
    "ModelListResponse": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ModelListResponse",
      "type": "object",
      "required": [
        "data"
      ],
      "properties": {
        "data": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/Model"
          }
        },
        "nextCursor": {
          "description": "Opaque cursor to pass to the next call to continue after the last item. If None, there are no more items to return.",
          "type": [
            "string",
            "null"
          ]
        }
      }
    },
    "ExperimentalFeature": {
      "type": "object",
      "required": [
        "defaultEnabled",
        "enabled",
        "name",
        "stage"
      ],
      "properties": {
        "announcement": {
          "description": "Announcement copy shown to users when the feature is introduced. Null when this feature is not in beta.",
          "type": [
            "string",
            "null"
          ]
        },
        "defaultEnabled": {
          "description": "Whether this feature is enabled by default.",
          "type": "boolean"
        },
        "description": {
          "description": "Short summary describing what the feature does. Null when this feature is not in beta.",
          "type": [
            "string",
            "null"
          ]
        },
        "displayName": {
          "description": "User-facing display name shown in the experimental features UI. Null when this feature is not in beta.",
          "type": [
            "string",
            "null"
          ]
        },
        "enabled": {
          "description": "Whether this feature is currently enabled in the loaded config.",
          "type": "boolean"
        },
        "name": {
          "description": "Stable key used in config.toml and CLI flag toggles.",
          "type": "string"
        },
        "stage": {
          "description": "Lifecycle stage of this feature flag.",
          "allOf": [
            {
              "$ref": "#/definitions/ExperimentalFeatureStage"
            }
          ]
        }
      }
    },
    "ExperimentalFeatureStage": {
      "oneOf": [
        {
          "description": "Feature is available for user testing and feedback.",
          "type": "string",
          "enum": [
            "beta"
          ]
        },
        {
          "description": "Feature is still being built and not ready for broad use.",
          "type": "string",
          "enum": [
            "underDevelopment"
          ]
        },
        {
          "description": "Feature is production-ready.",
          "type": "string",
          "enum": [
            "stable"
          ]
        },
        {
          "description": "Feature is deprecated and should be avoided.",
          "type": "string",
          "enum": [
            "deprecated"
          ]
        },
        {
          "description": "Feature flag is retained only for backwards compatibility.",
          "type": "string",
          "enum": [
            "removed"
          ]
        }
      ]
    },
    "ExperimentalFeatureListResponse": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ExperimentalFeatureListResponse",
      "type": "object",
      "required": [
        "data"
      ],
      "properties": {
        "data": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/ExperimentalFeature"
          }
        },
        "nextCursor": {
          "description": "Opaque cursor to pass to the next call to continue after the last item. If None, there are no more items to return.",
          "type": [
            "string",
            "null"
          ]
        }
      }
    },
    "ExperimentalFeatureEnablementSetResponse": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ExperimentalFeatureEnablementSetResponse",
      "type": "object",
      "required": [
        "enablement"
      ],
      "properties": {
        "enablement": {
          "description": "Feature enablement entries updated by this request.",
          "type": "object",
          "additionalProperties": {
            "type": "boolean"
          }
        }
      }
    },
    "CollaborationModeMask": {
      "description": "EXPERIMENTAL - collaboration mode preset metadata for clients.",
      "type": "object",
      "required": [
        "name"
      ],
      "properties": {
        "mode": {
          "anyOf": [
            {
              "$ref": "#/definitions/ModeKind"
            },
            {
              "type": "null"
            }
          ]
        },
        "model": {
          "type": [
            "string",
            "null"
          ]
        },
        "name": {
          "type": "string"
        },
        "reasoning_effort": {
          "anyOf": [
            {
              "anyOf": [
                {
                  "$ref": "#/definitions/ReasoningEffort"
                },
                {
                  "type": "null"
                }
              ]
            },
            {
              "type": "null"
            }
          ]
        }
      }
    },
    "ReasoningSummaryPartAddedNotification": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ReasoningSummaryPartAddedNotification",
      "type": "object",
      "required": [
        "itemId",
        "summaryIndex",
        "threadId",
        "turnId"
      ],
      "properties": {
        "itemId": {
          "type": "string"
        },
        "summaryIndex": {
          "type": "integer",
          "format": "int64"
        },
        "threadId": {
          "type": "string"
        },
        "turnId": {
          "type": "string"
        }
      }
    },
    "ReasoningSummaryTextDeltaNotification": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ReasoningSummaryTextDeltaNotification",
      "type": "object",
      "required": [
        "delta",
        "itemId",
        "summaryIndex",
        "threadId",
        "turnId"
      ],
      "properties": {
        "delta": {
          "type": "string"
        },
        "itemId": {
          "type": "string"
        },
        "summaryIndex": {
          "type": "integer",
          "format": "int64"
        },
        "threadId": {
          "type": "string"
        },
        "turnId": {
          "type": "string"
        }
      }
    },
    "McpServerOauthLoginResponse": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "McpServerOauthLoginResponse",
      "type": "object",
      "required": [
        "authorizationUrl"
      ],
      "properties": {
        "authorizationUrl": {
          "type": "string"
        }
      }
    },
    "McpServerRefreshResponse": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "McpServerRefreshResponse",
      "type": "object"
    },
    "McpAuthStatus": {
      "type": "string",
      "enum": [
        "unsupported",
        "notLoggedIn",
        "bearerToken",
        "oAuth"
      ]
    },
    "McpServerStatus": {
      "type": "object",
      "required": [
        "authStatus",
        "name",
        "resourceTemplates",
        "resources",
        "tools"
      ],
      "properties": {
        "authStatus": {
          "$ref": "#/definitions/McpAuthStatus"
        },
        "name": {
          "type": "string"
        },
        "resourceTemplates": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/ResourceTemplate"
          }
        },
        "resources": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/Resource"
          }
        },
        "tools": {
          "type": "object",
          "additionalProperties": {
            "$ref": "#/definitions/Tool"
          }
        }
      }
    },
    "Resource": {
      "description": "A known resource that the server is capable of reading.",
      "type": "object",
      "required": [
        "name",
        "uri"
      ],
      "properties": {
        "_meta": true,
        "annotations": true,
        "description": {
          "type": [
            "string",
            "null"
          ]
        },
        "icons": {
          "type": [
            "array",
            "null"
          ],
          "items": true
        },
        "mimeType": {
          "type": [
            "string",
            "null"
          ]
        },
        "name": {
          "type": "string"
        },
        "size": {
          "type": [
            "integer",
            "null"
          ],
          "format": "int64"
        },
        "title": {
          "type": [
            "string",
            "null"
          ]
        },
        "uri": {
          "type": "string"
        }
      }
    },
    "ResourceTemplate": {
      "description": "A template description for resources available on the server.",
      "type": "object",
      "required": [
        "name",
        "uriTemplate"
      ],
      "properties": {
        "annotations": true,
        "description": {
          "type": [
            "string",
            "null"
          ]
        },
        "mimeType": {
          "type": [
            "string",
            "null"
          ]
        },
        "name": {
          "type": "string"
        },
        "title": {
          "type": [
            "string",
            "null"
          ]
        },
        "uriTemplate": {
          "type": "string"
        }
      }
    },
    "Tool": {
      "description": "Definition for a tool the client can call.",
      "type": "object",
      "required": [
        "inputSchema",
        "name"
      ],
      "properties": {
        "_meta": true,
        "annotations": true,
        "description": {
          "type": [
            "string",
            "null"
          ]
        },
        "icons": {
          "type": [
            "array",
            "null"
          ],
          "items": true
        },
        "inputSchema": true,
        "name": {
          "type": "string"
        },
        "outputSchema": true,
        "title": {
          "type": [
            "string",
            "null"
          ]
        }
      }
    },
    "ListMcpServerStatusResponse": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ListMcpServerStatusResponse",
      "type": "object",
      "required": [
        "data"
      ],
      "properties": {
        "data": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/McpServerStatus"
          }
        },
        "nextCursor": {
          "description": "Opaque cursor to pass to the next call to continue after the last item. If None, there are no more items to return.",
          "type": [
            "string",
            "null"
          ]
        }
      }
    },
    "ResourceContent": {
      "description": "Contents returned when reading a resource from an MCP server.",
      "anyOf": [
        {
          "type": "object",
          "required": [
            "text",
            "uri"
          ],
          "properties": {
            "_meta": true,
            "mimeType": {
              "type": [
                "string",
                "null"
              ]
            },
            "text": {
              "type": "string"
            },
            "uri": {
              "description": "The URI of this resource.",
              "type": "string"
            }
          }
        },
        {
          "type": "object",
          "required": [
            "blob",
            "uri"
          ],
          "properties": {
            "_meta": true,
            "blob": {
              "type": "string"
            },
            "mimeType": {
              "type": [
                "string",
                "null"
              ]
            },
            "uri": {
              "description": "The URI of this resource.",
              "type": "string"
            }
          }
        }
      ]
    },
    "McpResourceReadResponse": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "McpResourceReadResponse",
      "type": "object",
      "required": [
        "contents"
      ],
      "properties": {
        "contents": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/ResourceContent"
          }
        }
      }
    },
    "McpServerToolCallResponse": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "McpServerToolCallResponse",
      "type": "object",
      "required": [
        "content"
      ],
      "properties": {
        "_meta": true,
        "content": {
          "type": "array",
          "items": true
        },
        "isError": {
          "type": [
            "boolean",
            "null"
          ]
        },
        "structuredContent": true
      }
    },
    "WindowsSandboxSetupStartResponse": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "WindowsSandboxSetupStartResponse",
      "type": "object",
      "required": [
        "started"
      ],
      "properties": {
        "started": {
          "type": "boolean"
        }
      }
    },
    "LoginAccountResponse": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "LoginAccountResponse",
      "oneOf": [
        {
          "type": "object",
          "required": [
            "type"
          ],
          "properties": {
            "type": {
              "type": "string",
              "enum": [
                "apiKey"
              ],
              "title": "ApiKeyv2::LoginAccountResponseType"
            }
          },
          "title": "ApiKeyv2::LoginAccountResponse"
        },
        {
          "type": "object",
          "required": [
            "authUrl",
            "loginId",
            "type"
          ],
          "properties": {
            "authUrl": {
              "description": "URL the client should open in a browser to initiate the OAuth flow.",
              "type": "string"
            },
            "loginId": {
              "type": "string"
            },
            "type": {
              "type": "string",
              "enum": [
                "chatgpt"
              ],
              "title": "Chatgptv2::LoginAccountResponseType"
            }
          },
          "title": "Chatgptv2::LoginAccountResponse"
        },
        {
          "type": "object",
          "required": [
            "loginId",
            "type",
            "userCode",
            "verificationUrl"
          ],
          "properties": {
            "loginId": {
              "type": "string"
            },
            "type": {
              "type": "string",
              "enum": [
                "chatgptDeviceCode"
              ],
              "title": "ChatgptDeviceCodev2::LoginAccountResponseType"
            },
            "userCode": {
              "description": "One-time code the user must enter after signing in.",
              "type": "string"
            },
            "verificationUrl": {
              "description": "URL the client should open in a browser to complete device code authorization.",
              "type": "string"
            }
          },
          "title": "ChatgptDeviceCodev2::LoginAccountResponse"
        },
        {
          "type": "object",
          "required": [
            "type"
          ],
          "properties": {
            "type": {
              "type": "string",
              "enum": [
                "chatgptAuthTokens"
              ],
              "title": "ChatgptAuthTokensv2::LoginAccountResponseType"
            }
          },
          "title": "ChatgptAuthTokensv2::LoginAccountResponse"
        }
      ]
    },
    "CancelLoginAccountStatus": {
      "type": "string",
      "enum": [
        "canceled",
        "notFound"
      ]
    },
    "CancelLoginAccountResponse": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "CancelLoginAccountResponse",
      "type": "object",
      "required": [
        "status"
      ],
      "properties": {
        "status": {
          "$ref": "#/definitions/CancelLoginAccountStatus"
        }
      }
    },
    "LogoutAccountResponse": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "LogoutAccountResponse",
      "type": "object"
    },
    "CreditsSnapshot": {
      "type": "object",
      "required": [
        "hasCredits",
        "unlimited"
      ],
      "properties": {
        "balance": {
          "type": [
            "string",
            "null"
          ]
        },
        "hasCredits": {
          "type": "boolean"
        },
        "unlimited": {
          "type": "boolean"
        }
      }
    },
    "PlanType": {
      "type": "string",
      "enum": [
        "free",
        "go",
        "plus",
        "pro",
        "prolite",
        "team",
        "self_serve_business_usage_based",
        "business",
        "enterprise_cbp_usage_based",
        "enterprise",
        "edu",
        "unknown"
      ]
    },
    "RateLimitReachedType": {
      "type": "string",
      "enum": [
        "rate_limit_reached",
        "workspace_owner_credits_depleted",
        "workspace_member_credits_depleted",
        "workspace_owner_usage_limit_reached",
        "workspace_member_usage_limit_reached"
      ]
    },
    "RateLimitSnapshot": {
      "type": "object",
      "properties": {
        "credits": {
          "anyOf": [
            {
              "$ref": "#/definitions/CreditsSnapshot"
            },
            {
              "type": "null"
            }
          ]
        },
        "limitId": {
          "type": [
            "string",
            "null"
          ]
        },
        "limitName": {
          "type": [
            "string",
            "null"
          ]
        },
        "planType": {
          "anyOf": [
            {
              "$ref": "#/definitions/PlanType"
            },
            {
              "type": "null"
            }
          ]
        },
        "primary": {
          "anyOf": [
            {
              "$ref": "#/definitions/RateLimitWindow"
            },
            {
              "type": "null"
            }
          ]
        },
        "rateLimitReachedType": {
          "anyOf": [
            {
              "$ref": "#/definitions/RateLimitReachedType"
            },
            {
              "type": "null"
            }
          ]
        },
        "secondary": {
          "anyOf": [
            {
              "$ref": "#/definitions/RateLimitWindow"
            },
            {
              "type": "null"
            }
          ]
        }
      }
    },
    "RateLimitWindow": {
      "type": "object",
      "required": [
        "usedPercent"
      ],
      "properties": {
        "resetsAt": {
          "type": [
            "integer",
            "null"
          ],
          "format": "int64"
        },
        "usedPercent": {
          "type": "integer",
          "format": "int32"
        },
        "windowDurationMins": {
          "type": [
            "integer",
            "null"
          ],
          "format": "int64"
        }
      }
    },
    "GetAccountRateLimitsResponse": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "GetAccountRateLimitsResponse",
      "type": "object",
      "required": [
        "rateLimits"
      ],
      "properties": {
        "rateLimits": {
          "description": "Backward-compatible single-bucket view; mirrors the historical payload.",
          "allOf": [
            {
              "$ref": "#/definitions/RateLimitSnapshot"
            }
          ]
        },
        "rateLimitsByLimitId": {
          "description": "Multi-bucket view keyed by metered `limit_id` (for example, `codex`).",
          "type": [
            "object",
            "null"
          ],
          "additionalProperties": {
            "$ref": "#/definitions/RateLimitSnapshot"
          }
        }
      }
    },
    "AddCreditsNudgeEmailStatus": {
      "type": "string",
      "enum": [
        "sent",
        "cooldown_active"
      ]
    },
    "SendAddCreditsNudgeEmailResponse": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "SendAddCreditsNudgeEmailResponse",
      "type": "object",
      "required": [
        "status"
      ],
      "properties": {
        "status": {
          "$ref": "#/definitions/AddCreditsNudgeEmailStatus"
        }
      }
    },
    "FeedbackUploadResponse": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "FeedbackUploadResponse",
      "type": "object",
      "required": [
        "threadId"
      ],
      "properties": {
        "threadId": {
          "type": "string"
        }
      }
    },
    "CommandExecResponse": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "CommandExecResponse",
      "description": "Final buffered result for `command/exec`.",
      "type": "object",
      "required": [
        "exitCode",
        "stderr",
        "stdout"
      ],
      "properties": {
        "exitCode": {
          "description": "Process exit code.",
          "type": "integer",
          "format": "int32"
        },
        "stderr": {
          "description": "Buffered stderr capture.\n\nEmpty when stderr was streamed via `command/exec/outputDelta`.",
          "type": "string"
        },
        "stdout": {
          "description": "Buffered stdout capture.\n\nEmpty when stdout was streamed via `command/exec/outputDelta`.",
          "type": "string"
        }
      }
    },
    "CommandExecWriteResponse": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "CommandExecWriteResponse",
      "description": "Empty success response for `command/exec/write`.",
      "type": "object"
    },
    "CommandExecTerminateResponse": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "CommandExecTerminateResponse",
      "description": "Empty success response for `command/exec/terminate`.",
      "type": "object"
    },
    "CommandExecResizeResponse": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "CommandExecResizeResponse",
      "description": "Empty success response for `command/exec/resize`.",
      "type": "object"
    },
    "AnalyticsConfig": {
      "type": "object",
      "properties": {
        "enabled": {
          "type": [
            "boolean",
            "null"
          ]
        }
      },
      "additionalProperties": true
    },
    "AppConfig": {
      "type": "object",
      "properties": {
        "default_tools_approval_mode": {
          "anyOf": [
            {
              "$ref": "#/definitions/AppToolApproval"
            },
            {
              "type": "null"
            }
          ]
        },
        "default_tools_enabled": {
          "type": [
            "boolean",
            "null"
          ]
        },
        "destructive_enabled": {
          "type": [
            "boolean",
            "null"
          ]
        },
        "enabled": {
          "default": true,
          "type": "boolean"
        },
        "open_world_enabled": {
          "type": [
            "boolean",
            "null"
          ]
        },
        "tools": {
          "anyOf": [
            {
              "$ref": "#/definitions/AppToolsConfig"
            },
            {
              "type": "null"
            }
          ]
        }
      }
    },
    "AppToolApproval": {
      "type": "string",
      "enum": [
        "auto",
        "prompt",
        "approve"
      ]
    },
    "AppToolConfig": {
      "type": "object",
      "properties": {
        "approval_mode": {
          "anyOf": [
            {
              "$ref": "#/definitions/AppToolApproval"
            },
            {
              "type": "null"
            }
          ]
        },
        "enabled": {
          "type": [
            "boolean",
            "null"
          ]
        }
      }
    },
    "AppToolsConfig": {
      "type": "object"
    },
    "AppsConfig": {
      "type": "object",
      "properties": {
        "_default": {
          "default": null,
          "anyOf": [
            {
              "$ref": "#/definitions/AppsDefaultConfig"
            },
            {
              "type": "null"
            }
          ]
        }
      }
    },
    "AppsDefaultConfig": {
      "type": "object",
      "properties": {
        "destructive_enabled": {
          "default": true,
          "type": "boolean"
        },
        "enabled": {
          "default": true,
          "type": "boolean"
        },
        "open_world_enabled": {
          "default": true,
          "type": "boolean"
        }
      }
    },
    "Config": {
      "type": "object",
      "properties": {
        "analytics": {
          "anyOf": [
            {
              "$ref": "#/definitions/AnalyticsConfig"
            },
            {
              "type": "null"
            }
          ]
        },
        "approval_policy": {
          "anyOf": [
            {
              "$ref": "#/definitions/AskForApproval"
            },
            {
              "type": "null"
            }
          ]
        },
        "approvals_reviewer": {
          "description": "[UNSTABLE] Optional default for where approval requests are routed for review.",
          "anyOf": [
            {
              "$ref": "#/definitions/ApprovalsReviewer"
            },
            {
              "type": "null"
            }
          ]
        },
        "web_search": {
          "anyOf": [
            {
              "$ref": "#/definitions/WebSearchMode"
            },
            {
              "type": "null"
            }
          ]
        },
        "compact_prompt": {
          "type": [
            "string",
            "null"
          ]
        },
        "developer_instructions": {
          "type": [
            "string",
            "null"
          ]
        },
        "forced_chatgpt_workspace_id": {
          "type": [
            "string",
            "null"
          ]
        },
        "forced_login_method": {
          "anyOf": [
            {
              "$ref": "#/definitions/ForcedLoginMethod"
            },
            {
              "type": "null"
            }
          ]
        },
        "instructions": {
          "type": [
            "string",
            "null"
          ]
        },
        "model": {
          "type": [
            "string",
            "null"
          ]
        },
        "model_auto_compact_token_limit": {
          "type": [
            "integer",
            "null"
          ],
          "format": "int64"
        },
        "model_context_window": {
          "type": [
            "integer",
            "null"
          ],
          "format": "int64"
        },
        "model_provider": {
          "type": [
            "string",
            "null"
          ]
        },
        "model_reasoning_effort": {
          "anyOf": [
            {
              "$ref": "#/definitions/ReasoningEffort"
            },
            {
              "type": "null"
            }
          ]
        },
        "model_reasoning_summary": {
          "anyOf": [
            {
              "$ref": "#/definitions/ReasoningSummary"
            },
            {
              "type": "null"
            }
          ]
        },
        "model_verbosity": {
          "anyOf": [
            {
              "$ref": "#/definitions/Verbosity"
            },
            {
              "type": "null"
            }
          ]
        },
        "profile": {
          "type": [
            "string",
            "null"
          ]
        },
        "profiles": {
          "default": {},
          "type": "object",
          "additionalProperties": {
            "$ref": "#/definitions/ProfileV2"
          }
        },
        "review_model": {
          "type": [
            "string",
            "null"
          ]
        },
        "sandbox_mode": {
          "anyOf": [
            {
              "$ref": "#/definitions/SandboxMode"
            },
            {
              "type": "null"
            }
          ]
        },
        "sandbox_workspace_write": {
          "anyOf": [
            {
              "$ref": "#/definitions/SandboxWorkspaceWrite"
            },
            {
              "type": "null"
            }
          ]
        },
        "service_tier": {
          "anyOf": [
            {
              "$ref": "#/definitions/ServiceTier"
            },
            {
              "type": "null"
            }
          ]
        },
        "tools": {
          "anyOf": [
            {
              "$ref": "#/definitions/ToolsV2"
            },
            {
              "type": "null"
            }
          ]
        }
      },
      "additionalProperties": true
    },
    "ConfigLayer": {
      "type": "object",
      "required": [
        "config",
        "name",
        "version"
      ],
      "properties": {
        "config": true,
        "disabledReason": {
          "type": [
            "string",
            "null"
          ]
        },
        "name": {
          "$ref": "#/definitions/ConfigLayerSource"
        },
        "version": {
          "type": "string"
        }
      }
    },
    "ConfigLayerMetadata": {
      "type": "object",
      "required": [
        "name",
        "version"
      ],
      "properties": {
        "name": {
          "$ref": "#/definitions/ConfigLayerSource"
        },
        "version": {
          "type": "string"
        }
      }
    },
    "ConfigLayerSource": {
      "oneOf": [
        {
          "description": "Managed preferences layer delivered by MDM (macOS only).",
          "type": "object",
          "required": [
            "domain",
            "key",
            "type"
          ],
          "properties": {
            "domain": {
              "type": "string"
            },
            "key": {
              "type": "string"
            },
            "type": {
              "type": "string",
              "enum": [
                "mdm"
              ],
              "title": "MdmConfigLayerSourceType"
            }
          },
          "title": "MdmConfigLayerSource"
        },
        {
          "description": "Managed config layer from a file (usually `managed_config.toml`).",
          "type": "object",
          "required": [
            "file",
            "type"
          ],
          "properties": {
            "file": {
              "description": "This is the path to the system config.toml file, though it is not guaranteed to exist.",
              "allOf": [
                {
                  "$ref": "#/definitions/AbsolutePathBuf"
                }
              ]
            },
            "type": {
              "type": "string",
              "enum": [
                "system"
              ],
              "title": "SystemConfigLayerSourceType"
            }
          },
          "title": "SystemConfigLayerSource"
        },
        {
          "description": "User config layer from $CODEX_HOME/config.toml. This layer is special in that it is expected to be: - writable by the user - generally outside the workspace directory",
          "type": "object",
          "required": [
            "file",
            "type"
          ],
          "properties": {
            "file": {
              "description": "This is the path to the user's config.toml file, though it is not guaranteed to exist.",
              "allOf": [
                {
                  "$ref": "#/definitions/AbsolutePathBuf"
                }
              ]
            },
            "type": {
              "type": "string",
              "enum": [
                "user"
              ],
              "title": "UserConfigLayerSourceType"
            }
          },
          "title": "UserConfigLayerSource"
        },
        {
          "description": "Path to a .codex/ folder within a project. There could be multiple of these between `cwd` and the project/repo root.",
          "type": "object",
          "required": [
            "dotCodexFolder",
            "type"
          ],
          "properties": {
            "dotCodexFolder": {
              "$ref": "#/definitions/AbsolutePathBuf"
            },
            "type": {
              "type": "string",
              "enum": [
                "project"
              ],
              "title": "ProjectConfigLayerSourceType"
            }
          },
          "title": "ProjectConfigLayerSource"
        },
        {
          "description": "Session-layer overrides supplied via `-c`/`--config`.",
          "type": "object",
          "required": [
            "type"
          ],
          "properties": {
            "type": {
              "type": "string",
              "enum": [
                "sessionFlags"
              ],
              "title": "SessionFlagsConfigLayerSourceType"
            }
          },
          "title": "SessionFlagsConfigLayerSource"
        },
        {
          "description": "`managed_config.toml` was designed to be a config that was loaded as the last layer on top of everything else. This scheme did not quite work out as intended, but we keep this variant as a \"best effort\" while we phase out `managed_config.toml` in favor of `requirements.toml`.",
          "type": "object",
          "required": [
            "file",
            "type"
          ],
          "properties": {
            "file": {
              "$ref": "#/definitions/AbsolutePathBuf"
            },
            "type": {
              "type": "string",
              "enum": [
                "legacyManagedConfigTomlFromFile"
              ],
              "title": "LegacyManagedConfigTomlFromFileConfigLayerSourceType"
            }
          },
          "title": "LegacyManagedConfigTomlFromFileConfigLayerSource"
        },
        {
          "type": "object",
          "required": [
            "type"
          ],
          "properties": {
            "type": {
              "type": "string",
              "enum": [
                "legacyManagedConfigTomlFromMdm"
              ],
              "title": "LegacyManagedConfigTomlFromMdmConfigLayerSourceType"
            }
          },
          "title": "LegacyManagedConfigTomlFromMdmConfigLayerSource"
        }
      ]
    },
    "ForcedLoginMethod": {
      "type": "string",
      "enum": [
        "chatgpt",
        "api"
      ]
    },
    "ProfileV2": {
      "type": "object",
      "properties": {
        "approval_policy": {
          "anyOf": [
            {
              "$ref": "#/definitions/AskForApproval"
            },
            {
              "type": "null"
            }
          ]
        },
        "approvals_reviewer": {
          "description": "[UNSTABLE] Optional profile-level override for where approval requests are routed for review. If omitted, the enclosing config default is used.",
          "anyOf": [
            {
              "$ref": "#/definitions/ApprovalsReviewer"
            },
            {
              "type": "null"
            }
          ]
        },
        "chatgpt_base_url": {
          "type": [
            "string",
            "null"
          ]
        },
        "model": {
          "type": [
            "string",
            "null"
          ]
        },
        "model_provider": {
          "type": [
            "string",
            "null"
          ]
        },
        "model_reasoning_effort": {
          "anyOf": [
            {
              "$ref": "#/definitions/ReasoningEffort"
            },
            {
              "type": "null"
            }
          ]
        },
        "model_reasoning_summary": {
          "anyOf": [
            {
              "$ref": "#/definitions/ReasoningSummary"
            },
            {
              "type": "null"
            }
          ]
        },
        "model_verbosity": {
          "anyOf": [
            {
              "$ref": "#/definitions/Verbosity"
            },
            {
              "type": "null"
            }
          ]
        },
        "service_tier": {
          "anyOf": [
            {
              "$ref": "#/definitions/ServiceTier"
            },
            {
              "type": "null"
            }
          ]
        },
        "tools": {
          "anyOf": [
            {
              "$ref": "#/definitions/ToolsV2"
            },
            {
              "type": "null"
            }
          ]
        },
        "web_search": {
          "anyOf": [
            {
              "$ref": "#/definitions/WebSearchMode"
            },
            {
              "type": "null"
            }
          ]
        }
      },
      "additionalProperties": true
    },
    "SandboxWorkspaceWrite": {
      "type": "object",
      "properties": {
        "exclude_slash_tmp": {
          "default": false,
          "type": "boolean"
        },
        "exclude_tmpdir_env_var": {
          "default": false,
          "type": "boolean"
        },
        "network_access": {
          "default": false,
          "type": "boolean"
        },
        "writable_roots": {
          "default": [],
          "type": "array",
          "items": {
            "type": "string"
          }
        }
      }
    },
    "ToolsV2": {
      "type": "object",
      "properties": {
        "view_image": {
          "type": [
            "boolean",
            "null"
          ]
        },
        "web_search": {
          "anyOf": [
            {
              "$ref": "#/definitions/WebSearchToolConfig"
            },
            {
              "type": "null"
            }
          ]
        }
      }
    },
    "Verbosity": {
      "description": "Controls output length/detail on GPT-5 models via the Responses API. Serialized with lowercase values to match the OpenAI API.",
      "type": "string",
      "enum": [
        "low",
        "medium",
        "high"
      ]
    },
    "WebSearchContextSize": {
      "type": "string",
      "enum": [
        "low",
        "medium",
        "high"
      ]
    },
    "WebSearchLocation": {
      "type": "object",
      "properties": {
        "city": {
          "type": [
            "string",
            "null"
          ]
        },
        "country": {
          "type": [
            "string",
            "null"
          ]
        },
        "region": {
          "type": [
            "string",
            "null"
          ]
        },
        "timezone": {
          "type": [
            "string",
            "null"
          ]
        }
      },
      "additionalProperties": false
    },
    "WebSearchMode": {
      "type": "string",
      "enum": [
        "disabled",
        "cached",
        "live"
      ]
    },
    "WebSearchToolConfig": {
      "type": "object",
      "properties": {
        "allowed_domains": {
          "type": [
            "array",
            "null"
          ],
          "items": {
            "type": "string"
          }
        },
        "context_size": {
          "anyOf": [
            {
              "$ref": "#/definitions/WebSearchContextSize"
            },
            {
              "type": "null"
            }
          ]
        },
        "location": {
          "anyOf": [
            {
              "$ref": "#/definitions/WebSearchLocation"
            },
            {
              "type": "null"
            }
          ]
        }
      },
      "additionalProperties": false
    },
    "ConfigReadResponse": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ConfigReadResponse",
      "type": "object",
      "required": [
        "config",
        "origins"
      ],
      "properties": {
        "config": {
          "$ref": "#/definitions/Config"
        },
        "layers": {
          "type": [
            "array",
            "null"
          ],
          "items": {
            "$ref": "#/definitions/ConfigLayer"
          }
        },
        "origins": {
          "type": "object",
          "additionalProperties": {
            "$ref": "#/definitions/ConfigLayerMetadata"
          }
        }
      }
    },
    "ExternalAgentConfigDetectResponse": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ExternalAgentConfigDetectResponse",
      "type": "object",
      "required": [
        "items"
      ],
      "properties": {
        "items": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/ExternalAgentConfigMigrationItem"
          }
        }
      }
    },
    "ExternalAgentConfigImportResponse": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ExternalAgentConfigImportResponse",
      "type": "object"
    },
    "OverriddenMetadata": {
      "type": "object",
      "required": [
        "effectiveValue",
        "message",
        "overridingLayer"
      ],
      "properties": {
        "effectiveValue": true,
        "message": {
          "type": "string"
        },
        "overridingLayer": {
          "$ref": "#/definitions/ConfigLayerMetadata"
        }
      }
    },
    "WriteStatus": {
      "type": "string",
      "enum": [
        "ok",
        "okOverridden"
      ]
    },
    "ConfigWriteResponse": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ConfigWriteResponse",
      "type": "object",
      "required": [
        "filePath",
        "status",
        "version"
      ],
      "properties": {
        "filePath": {
          "description": "Canonical path to the config file that was written.",
          "allOf": [
            {
              "$ref": "#/definitions/AbsolutePathBuf"
            }
          ]
        },
        "overriddenMetadata": {
          "anyOf": [
            {
              "$ref": "#/definitions/OverriddenMetadata"
            },
            {
              "type": "null"
            }
          ]
        },
        "status": {
          "$ref": "#/definitions/WriteStatus"
        },
        "version": {
          "type": "string"
        }
      }
    },
    "ConfigRequirements": {
      "type": "object",
      "properties": {
        "allowedApprovalPolicies": {
          "type": [
            "array",
            "null"
          ],
          "items": {
            "$ref": "#/definitions/AskForApproval"
          }
        },
        "featureRequirements": {
          "type": [
            "object",
            "null"
          ],
          "additionalProperties": {
            "type": "boolean"
          }
        },
        "allowedSandboxModes": {
          "type": [
            "array",
            "null"
          ],
          "items": {
            "$ref": "#/definitions/SandboxMode"
          }
        },
        "allowedWebSearchModes": {
          "type": [
            "array",
            "null"
          ],
          "items": {
            "$ref": "#/definitions/WebSearchMode"
          }
        },
        "enforceResidency": {
          "anyOf": [
            {
              "$ref": "#/definitions/ResidencyRequirement"
            },
            {
              "type": "null"
            }
          ]
        }
      }
    },
    "NetworkDomainPermission": {
      "type": "string",
      "enum": [
        "allow",
        "deny"
      ]
    },
    "NetworkRequirements": {
      "type": "object",
      "properties": {
        "allowLocalBinding": {
          "type": [
            "boolean",
            "null"
          ]
        },
        "allowUnixSockets": {
          "description": "Legacy compatibility view derived from `unix_sockets`.",
          "type": [
            "array",
            "null"
          ],
          "items": {
            "type": "string"
          }
        },
        "allowUpstreamProxy": {
          "type": [
            "boolean",
            "null"
          ]
        },
        "allowedDomains": {
          "description": "Legacy compatibility view derived from `domains`.",
          "type": [
            "array",
            "null"
          ],
          "items": {
            "type": "string"
          }
        },
        "dangerouslyAllowAllUnixSockets": {
          "type": [
            "boolean",
            "null"
          ]
        },
        "dangerouslyAllowNonLoopbackProxy": {
          "type": [
            "boolean",
            "null"
          ]
        },
        "deniedDomains": {
          "description": "Legacy compatibility view derived from `domains`.",
          "type": [
            "array",
            "null"
          ],
          "items": {
            "type": "string"
          }
        },
        "domains": {
          "description": "Canonical network permission map for `experimental_network`.",
          "type": [
            "object",
            "null"
          ],
          "additionalProperties": {
            "$ref": "#/definitions/NetworkDomainPermission"
          }
        },
        "enabled": {
          "type": [
            "boolean",
            "null"
          ]
        },
        "httpPort": {
          "type": [
            "integer",
            "null"
          ],
          "format": "uint16",
          "minimum": 0.0
        },
        "managedAllowedDomainsOnly": {
          "description": "When true, only managed allowlist entries are respected while managed network enforcement is active.",
          "type": [
            "boolean",
            "null"
          ]
        },
        "socksPort": {
          "type": [
            "integer",
            "null"
          ],
          "format": "uint16",
          "minimum": 0.0
        },
        "unixSockets": {
          "description": "Canonical unix socket permission map for `experimental_network`.",
          "type": [
            "object",
            "null"
          ],
          "additionalProperties": {
            "$ref": "#/definitions/NetworkUnixSocketPermission"
          }
        }
      }
    },
    "NetworkUnixSocketPermission": {
      "type": "string",
      "enum": [
        "allow",
        "none"
      ]
    },
    "ResidencyRequirement": {
      "type": "string",
      "enum": [
        "us"
      ]
    },
    "ConfigRequirementsReadResponse": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ConfigRequirementsReadResponse",
      "type": "object",
      "properties": {
        "requirements": {
          "description": "Null if no requirements are configured (e.g. no requirements.toml/MDM entries).",
          "anyOf": [
            {
              "$ref": "#/definitions/ConfigRequirements"
            },
            {
              "type": "null"
            }
          ]
        }
      }
    },
    "Account": {
      "oneOf": [
        {
          "type": "object",
          "required": [
            "type"
          ],
          "properties": {
            "type": {
              "type": "string",
              "enum": [
                "apiKey"
              ],
              "title": "ApiKeyAccountType"
            }
          },
          "title": "ApiKeyAccount"
        },
        {
          "type": "object",
          "required": [
            "email",
            "planType",
            "type"
          ],
          "properties": {
            "email": {
              "type": "string"
            },
            "planType": {
              "$ref": "#/definitions/PlanType"
            },
            "type": {
              "type": "string",
              "enum": [
                "chatgpt"
              ],
              "title": "ChatgptAccountType"
            }
          },
          "title": "ChatgptAccount"
        }
      ]
    },
    "GetAccountResponse": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "GetAccountResponse",
      "type": "object",
      "required": [
        "requiresOpenaiAuth"
      ],
      "properties": {
        "account": {
          "anyOf": [
            {
              "$ref": "#/definitions/Account"
            },
            {
              "type": "null"
            }
          ]
        },
        "requiresOpenaiAuth": {
          "type": "boolean"
        }
      }
    },
    "ErrorNotification": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ErrorNotification",
      "type": "object",
      "required": [
        "error",
        "threadId",
        "turnId",
        "willRetry"
      ],
      "properties": {
        "error": {
          "$ref": "#/definitions/TurnError"
        },
        "threadId": {
          "type": "string"
        },
        "turnId": {
          "type": "string"
        },
        "willRetry": {
          "type": "boolean"
        }
      }
    },
    "ThreadStartedNotification": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ThreadStartedNotification",
      "type": "object",
      "required": [
        "thread"
      ],
      "properties": {
        "thread": {
          "$ref": "#/definitions/Thread"
        }
      }
    },
    "ThreadStatusChangedNotification": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ThreadStatusChangedNotification",
      "type": "object",
      "required": [
        "status",
        "threadId"
      ],
      "properties": {
        "status": {
          "$ref": "#/definitions/ThreadStatus"
        },
        "threadId": {
          "type": "string"
        }
      }
    },
    "ThreadArchivedNotification": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ThreadArchivedNotification",
      "type": "object",
      "required": [
        "threadId"
      ],
      "properties": {
        "threadId": {
          "type": "string"
        }
      }
    },
    "ThreadUnarchivedNotification": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ThreadUnarchivedNotification",
      "type": "object",
      "required": [
        "threadId"
      ],
      "properties": {
        "threadId": {
          "type": "string"
        }
      }
    },
    "ThreadClosedNotification": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ThreadClosedNotification",
      "type": "object",
      "required": [
        "threadId"
      ],
      "properties": {
        "threadId": {
          "type": "string"
        }
      }
    },
    "SkillsChangedNotification": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "SkillsChangedNotification",
      "description": "Notification emitted when watched local skill files change.\n\nTreat this as an invalidation signal and re-run `skills/list` with the client's current parameters when refreshed skill metadata is needed.",
      "type": "object"
    },
    "ThreadNameUpdatedNotification": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ThreadNameUpdatedNotification",
      "type": "object",
      "required": [
        "threadId"
      ],
      "properties": {
        "threadId": {
          "type": "string"
        },
        "threadName": {
          "type": [
            "string",
            "null"
          ]
        }
      }
    },
    "ThreadTokenUsage": {
      "type": "object",
      "required": [
        "last",
        "total"
      ],
      "properties": {
        "last": {
          "$ref": "#/definitions/TokenUsageBreakdown"
        },
        "modelContextWindow": {
          "type": [
            "integer",
            "null"
          ],
          "format": "int64"
        },
        "total": {
          "$ref": "#/definitions/TokenUsageBreakdown"
        }
      }
    },
    "TokenUsageBreakdown": {
      "type": "object",
      "required": [
        "cachedInputTokens",
        "inputTokens",
        "outputTokens",
        "reasoningOutputTokens",
        "totalTokens"
      ],
      "properties": {
        "cachedInputTokens": {
          "type": "integer",
          "format": "int64"
        },
        "inputTokens": {
          "type": "integer",
          "format": "int64"
        },
        "outputTokens": {
          "type": "integer",
          "format": "int64"
        },
        "reasoningOutputTokens": {
          "type": "integer",
          "format": "int64"
        },
        "totalTokens": {
          "type": "integer",
          "format": "int64"
        }
      }
    },
    "ThreadTokenUsageUpdatedNotification": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ThreadTokenUsageUpdatedNotification",
      "type": "object",
      "required": [
        "threadId",
        "tokenUsage",
        "turnId"
      ],
      "properties": {
        "threadId": {
          "type": "string"
        },
        "tokenUsage": {
          "$ref": "#/definitions/ThreadTokenUsage"
        },
        "turnId": {
          "type": "string"
        }
      }
    },
    "TurnStartedNotification": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "TurnStartedNotification",
      "type": "object",
      "required": [
        "threadId",
        "turn"
      ],
      "properties": {
        "threadId": {
          "type": "string"
        },
        "turn": {
          "$ref": "#/definitions/Turn"
        }
      }
    },
    "HookEventName": {
      "type": "string",
      "enum": [
        "preToolUse",
        "permissionRequest",
        "postToolUse",
        "sessionStart",
        "userPromptSubmit",
        "stop"
      ]
    },
    "HookExecutionMode": {
      "type": "string",
      "enum": [
        "sync",
        "async"
      ]
    },
    "HookHandlerType": {
      "type": "string",
      "enum": [
        "command",
        "prompt",
        "agent"
      ]
    },
    "HookOutputEntry": {
      "type": "object",
      "required": [
        "kind",
        "text"
      ],
      "properties": {
        "kind": {
          "$ref": "#/definitions/HookOutputEntryKind"
        },
        "text": {
          "type": "string"
        }
      }
    },
    "HookOutputEntryKind": {
      "type": "string",
      "enum": [
        "warning",
        "stop",
        "feedback",
        "context",
        "error"
      ]
    },
    "HookRunStatus": {
      "type": "string",
      "enum": [
        "running",
        "completed",
        "failed",
        "blocked",
        "stopped"
      ]
    },
    "HookRunSummary": {
      "type": "object",
      "required": [
        "displayOrder",
        "entries",
        "eventName",
        "executionMode",
        "handlerType",
        "id",
        "scope",
        "sourcePath",
        "startedAt",
        "status"
      ],
      "properties": {
        "completedAt": {
          "type": [
            "integer",
            "null"
          ],
          "format": "int64"
        },
        "displayOrder": {
          "type": "integer",
          "format": "int64"
        },
        "durationMs": {
          "type": [
            "integer",
            "null"
          ],
          "format": "int64"
        },
        "entries": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/HookOutputEntry"
          }
        },
        "eventName": {
          "$ref": "#/definitions/HookEventName"
        },
        "executionMode": {
          "$ref": "#/definitions/HookExecutionMode"
        },
        "handlerType": {
          "$ref": "#/definitions/HookHandlerType"
        },
        "id": {
          "type": "string"
        },
        "scope": {
          "$ref": "#/definitions/HookScope"
        },
        "source": {
          "default": "unknown",
          "allOf": [
            {
              "$ref": "#/definitions/HookSource"
            }
          ]
        },
        "sourcePath": {
          "$ref": "#/definitions/AbsolutePathBuf"
        },
        "startedAt": {
          "type": "integer",
          "format": "int64"
        },
        "status": {
          "$ref": "#/definitions/HookRunStatus"
        },
        "statusMessage": {
          "type": [
            "string",
            "null"
          ]
        }
      }
    },
    "HookScope": {
      "type": "string",
      "enum": [
        "thread",
        "turn"
      ]
    },
    "HookSource": {
      "type": "string",
      "enum": [
        "system",
        "user",
        "project",
        "mdm",
        "sessionFlags",
        "legacyManagedConfigFile",
        "legacyManagedConfigMdm",
        "unknown"
      ]
    },
    "HookStartedNotification": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "HookStartedNotification",
      "type": "object",
      "required": [
        "run",
        "threadId"
      ],
      "properties": {
        "run": {
          "$ref": "#/definitions/HookRunSummary"
        },
        "threadId": {
          "type": "string"
        },
        "turnId": {
          "type": [
            "string",
            "null"
          ]
        }
      }
    },
    "TurnCompletedNotification": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "TurnCompletedNotification",
      "type": "object",
      "required": [
        "threadId",
        "turn"
      ],
      "properties": {
        "threadId": {
          "type": "string"
        },
        "turn": {
          "$ref": "#/definitions/Turn"
        }
      }
    },
    "HookCompletedNotification": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "HookCompletedNotification",
      "type": "object",
      "required": [
        "run",
        "threadId"
      ],
      "properties": {
        "run": {
          "$ref": "#/definitions/HookRunSummary"
        },
        "threadId": {
          "type": "string"
        },
        "turnId": {
          "type": [
            "string",
            "null"
          ]
        }
      }
    },
    "TurnDiffUpdatedNotification": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "TurnDiffUpdatedNotification",
      "description": "Notification that the turn-level unified diff has changed. Contains the latest aggregated diff across all file changes in the turn.",
      "type": "object",
      "required": [
        "diff",
        "threadId",
        "turnId"
      ],
      "properties": {
        "diff": {
          "type": "string"
        },
        "threadId": {
          "type": "string"
        },
        "turnId": {
          "type": "string"
        }
      }
    },
    "TurnPlanStep": {
      "type": "object",
      "required": [
        "status",
        "step"
      ],
      "properties": {
        "status": {
          "$ref": "#/definitions/TurnPlanStepStatus"
        },
        "step": {
          "type": "string"
        }
      }
    },
    "TurnPlanStepStatus": {
      "type": "string",
      "enum": [
        "pending",
        "inProgress",
        "completed"
      ]
    },
    "TurnPlanUpdatedNotification": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "TurnPlanUpdatedNotification",
      "type": "object",
      "required": [
        "plan",
        "threadId",
        "turnId"
      ],
      "properties": {
        "explanation": {
          "type": [
            "string",
            "null"
          ]
        },
        "plan": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/TurnPlanStep"
          }
        },
        "threadId": {
          "type": "string"
        },
        "turnId": {
          "type": "string"
        }
      }
    },
    "ItemStartedNotification": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ItemStartedNotification",
      "type": "object",
      "required": [
        "item",
        "threadId",
        "turnId"
      ],
      "properties": {
        "item": {
          "$ref": "#/definitions/ThreadItem"
        },
        "threadId": {
          "type": "string"
        },
        "turnId": {
          "type": "string"
        }
      }
    },
    "GuardianApprovalReview": {
      "description": "[UNSTABLE] Temporary approval auto-review payload used by `item/autoApprovalReview/*` notifications. This shape is expected to change soon.",
      "type": "object",
      "required": [
        "status"
      ],
      "properties": {
        "rationale": {
          "type": [
            "string",
            "null"
          ]
        },
        "riskLevel": {
          "anyOf": [
            {
              "$ref": "#/definitions/GuardianRiskLevel"
            },
            {
              "type": "null"
            }
          ]
        },
        "status": {
          "$ref": "#/definitions/GuardianApprovalReviewStatus"
        },
        "userAuthorization": {
          "anyOf": [
            {
              "$ref": "#/definitions/GuardianUserAuthorization"
            },
            {
              "type": "null"
            }
          ]
        }
      }
    },
    "GuardianApprovalReviewAction": {
      "oneOf": [
        {
          "type": "object",
          "required": [
            "command",
            "cwd",
            "source",
            "type"
          ],
          "properties": {
            "command": {
              "type": "string"
            },
            "cwd": {
              "$ref": "#/definitions/AbsolutePathBuf"
            },
            "source": {
              "$ref": "#/definitions/GuardianCommandSource"
            },
            "type": {
              "type": "string",
              "enum": [
                "command"
              ],
              "title": "CommandGuardianApprovalReviewActionType"
            }
          },
          "title": "CommandGuardianApprovalReviewAction"
        },
        {
          "type": "object",
          "required": [
            "argv",
            "cwd",
            "program",
            "source",
            "type"
          ],
          "properties": {
            "argv": {
              "type": "array",
              "items": {
                "type": "string"
              }
            },
            "cwd": {
              "$ref": "#/definitions/AbsolutePathBuf"
            },
            "program": {
              "type": "string"
            },
            "source": {
              "$ref": "#/definitions/GuardianCommandSource"
            },
            "type": {
              "type": "string",
              "enum": [
                "execve"
              ],
              "title": "ExecveGuardianApprovalReviewActionType"
            }
          },
          "title": "ExecveGuardianApprovalReviewAction"
        },
        {
          "type": "object",
          "required": [
            "cwd",
            "files",
            "type"
          ],
          "properties": {
            "cwd": {
              "$ref": "#/definitions/AbsolutePathBuf"
            },
            "files": {
              "type": "array",
              "items": {
                "$ref": "#/definitions/AbsolutePathBuf"
              }
            },
            "type": {
              "type": "string",
              "enum": [
                "applyPatch"
              ],
              "title": "ApplyPatchGuardianApprovalReviewActionType"
            }
          },
          "title": "ApplyPatchGuardianApprovalReviewAction"
        },
        {
          "type": "object",
          "required": [
            "host",
            "port",
            "protocol",
            "target",
            "type"
          ],
          "properties": {
            "host": {
              "type": "string"
            },
            "port": {
              "type": "integer",
              "format": "uint16",
              "minimum": 0.0
            },
            "protocol": {
              "$ref": "#/definitions/NetworkApprovalProtocol"
            },
            "target": {
              "type": "string"
            },
            "type": {
              "type": "string",
              "enum": [
                "networkAccess"
              ],
              "title": "NetworkAccessGuardianApprovalReviewActionType"
            }
          },
          "title": "NetworkAccessGuardianApprovalReviewAction"
        },
        {
          "type": "object",
          "required": [
            "server",
            "toolName",
            "type"
          ],
          "properties": {
            "connectorId": {
              "type": [
                "string",
                "null"
              ]
            },
            "connectorName": {
              "type": [
                "string",
                "null"
              ]
            },
            "server": {
              "type": "string"
            },
            "toolName": {
              "type": "string"
            },
            "toolTitle": {
              "type": [
                "string",
                "null"
              ]
            },
            "type": {
              "type": "string",
              "enum": [
                "mcpToolCall"
              ],
              "title": "McpToolCallGuardianApprovalReviewActionType"
            }
          },
          "title": "McpToolCallGuardianApprovalReviewAction"
        }
      ]
    },
    "GuardianApprovalReviewStatus": {
      "description": "[UNSTABLE] Lifecycle state for an approval auto-review.",
      "type": "string",
      "enum": [
        "inProgress",
        "approved",
        "denied",
        "timedOut",
        "aborted"
      ]
    },
    "GuardianCommandSource": {
      "type": "string",
      "enum": [
        "shell",
        "unifiedExec"
      ]
    },
    "GuardianRiskLevel": {
      "description": "[UNSTABLE] Risk level assigned by approval auto-review.",
      "type": "string",
      "enum": [
        "low",
        "medium",
        "high",
        "critical"
      ]
    },
    "GuardianUserAuthorization": {
      "description": "[UNSTABLE] Authorization level assigned by approval auto-review.",
      "type": "string",
      "enum": [
        "unknown",
        "low",
        "medium",
        "high"
      ]
    },
    "NetworkApprovalProtocol": {
      "type": "string",
      "enum": [
        "http",
        "https",
        "socks5Tcp",
        "socks5Udp"
      ]
    },
    "ItemGuardianApprovalReviewStartedNotification": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ItemGuardianApprovalReviewStartedNotification",
      "description": "[UNSTABLE] Temporary notification payload for approval auto-review. This shape is expected to change soon.",
      "type": "object",
      "required": [
        "action",
        "review",
        "reviewId",
        "threadId",
        "turnId"
      ],
      "properties": {
        "action": {
          "$ref": "#/definitions/GuardianApprovalReviewAction"
        },
        "review": {
          "$ref": "#/definitions/GuardianApprovalReview"
        },
        "reviewId": {
          "description": "Stable identifier for this review.",
          "type": "string"
        },
        "targetItemId": {
          "description": "Identifier for the reviewed item or tool call when one exists.\n\nIn most cases, one review maps to one target item. The exceptions are - execve reviews, where a single command may contain multiple execve calls to review (only possible when using the shell_zsh_fork feature) - network policy reviews, where there is no target item\n\nA network call is triggered by a CommandExecution item, so having a target_item_id set to the CommandExecution item would be misleading because the review is about the network call, not the command execution. Therefore, target_item_id is set to None for network policy reviews.",
          "type": [
            "string",
            "null"
          ]
        },
        "threadId": {
          "type": "string"
        },
        "turnId": {
          "type": "string"
        }
      }
    },
    "AutoReviewDecisionSource": {
      "description": "[UNSTABLE] Source that produced a terminal approval auto-review decision.",
      "type": "string",
      "enum": [
        "agent"
      ]
    },
    "ItemGuardianApprovalReviewCompletedNotification": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ItemGuardianApprovalReviewCompletedNotification",
      "description": "[UNSTABLE] Temporary notification payload for approval auto-review. This shape is expected to change soon.",
      "type": "object",
      "required": [
        "action",
        "decisionSource",
        "review",
        "reviewId",
        "threadId",
        "turnId"
      ],
      "properties": {
        "action": {
          "$ref": "#/definitions/GuardianApprovalReviewAction"
        },
        "decisionSource": {
          "$ref": "#/definitions/AutoReviewDecisionSource"
        },
        "review": {
          "$ref": "#/definitions/GuardianApprovalReview"
        },
        "reviewId": {
          "description": "Stable identifier for this review.",
          "type": "string"
        },
        "targetItemId": {
          "description": "Identifier for the reviewed item or tool call when one exists.\n\nIn most cases, one review maps to one target item. The exceptions are - execve reviews, where a single command may contain multiple execve calls to review (only possible when using the shell_zsh_fork feature) - network policy reviews, where there is no target item\n\nA network call is triggered by a CommandExecution item, so having a target_item_id set to the CommandExecution item would be misleading because the review is about the network call, not the command execution. Therefore, target_item_id is set to None for network policy reviews.",
          "type": [
            "string",
            "null"
          ]
        },
        "threadId": {
          "type": "string"
        },
        "turnId": {
          "type": "string"
        }
      }
    },
    "ItemCompletedNotification": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ItemCompletedNotification",
      "type": "object",
      "required": [
        "item",
        "threadId",
        "turnId"
      ],
      "properties": {
        "item": {
          "$ref": "#/definitions/ThreadItem"
        },
        "threadId": {
          "type": "string"
        },
        "turnId": {
          "type": "string"
        }
      }
    },
    "RawResponseItemCompletedNotification": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "RawResponseItemCompletedNotification",
      "type": "object",
      "required": [
        "item",
        "threadId",
        "turnId"
      ],
      "properties": {
        "item": {
          "$ref": "#/definitions/ResponseItem"
        },
        "threadId": {
          "type": "string"
        },
        "turnId": {
          "type": "string"
        }
      }
    },
    "AgentMessageDeltaNotification": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "AgentMessageDeltaNotification",
      "type": "object",
      "required": [
        "delta",
        "itemId",
        "threadId",
        "turnId"
      ],
      "properties": {
        "delta": {
          "type": "string"
        },
        "itemId": {
          "type": "string"
        },
        "threadId": {
          "type": "string"
        },
        "turnId": {
          "type": "string"
        }
      }
    },
    "PlanDeltaNotification": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "PlanDeltaNotification",
      "description": "EXPERIMENTAL - proposed plan streaming deltas for plan items. Clients should not assume concatenated deltas match the completed plan item content.",
      "type": "object",
      "required": [
        "delta",
        "itemId",
        "threadId",
        "turnId"
      ],
      "properties": {
        "delta": {
          "type": "string"
        },
        "itemId": {
          "type": "string"
        },
        "threadId": {
          "type": "string"
        },
        "turnId": {
          "type": "string"
        }
      }
    },
    "CommandExecOutputStream": {
      "description": "Stream label for `command/exec/outputDelta` notifications.",
      "oneOf": [
        {
          "description": "stdout stream. PTY mode multiplexes terminal output here.",
          "type": "string",
          "enum": [
            "stdout"
          ]
        },
        {
          "description": "stderr stream.",
          "type": "string",
          "enum": [
            "stderr"
          ]
        }
      ]
    },
    "CommandExecOutputDeltaNotification": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "CommandExecOutputDeltaNotification",
      "description": "Base64-encoded output chunk emitted for a streaming `command/exec` request.\n\nThese notifications are connection-scoped. If the originating connection closes, the server terminates the process.",
      "type": "object",
      "required": [
        "capReached",
        "deltaBase64",
        "processId",
        "stream"
      ],
      "properties": {
        "capReached": {
          "description": "`true` on the final streamed chunk for a stream when `outputBytesCap` truncated later output on that stream.",
          "type": "boolean"
        },
        "deltaBase64": {
          "description": "Base64-encoded output bytes.",
          "type": "string"
        },
        "processId": {
          "description": "Client-supplied, connection-scoped `processId` from the original `command/exec` request.",
          "type": "string"
        },
        "stream": {
          "description": "Output stream for this chunk.",
          "allOf": [
            {
              "$ref": "#/definitions/CommandExecOutputStream"
            }
          ]
        }
      }
    },
    "CommandExecutionOutputDeltaNotification": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "CommandExecutionOutputDeltaNotification",
      "type": "object",
      "required": [
        "delta",
        "itemId",
        "threadId",
        "turnId"
      ],
      "properties": {
        "delta": {
          "type": "string"
        },
        "itemId": {
          "type": "string"
        },
        "threadId": {
          "type": "string"
        },
        "turnId": {
          "type": "string"
        }
      }
    },
    "TerminalInteractionNotification": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "TerminalInteractionNotification",
      "type": "object",
      "required": [
        "itemId",
        "processId",
        "stdin",
        "threadId",
        "turnId"
      ],
      "properties": {
        "itemId": {
          "type": "string"
        },
        "processId": {
          "type": "string"
        },
        "stdin": {
          "type": "string"
        },
        "threadId": {
          "type": "string"
        },
        "turnId": {
          "type": "string"
        }
      }
    },
    "FileChangeOutputDeltaNotification": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "FileChangeOutputDeltaNotification",
      "type": "object",
      "required": [
        "delta",
        "itemId",
        "threadId",
        "turnId"
      ],
      "properties": {
        "delta": {
          "type": "string"
        },
        "itemId": {
          "type": "string"
        },
        "threadId": {
          "type": "string"
        },
        "turnId": {
          "type": "string"
        }
      }
    },
    "RequestId": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "integer",
          "format": "int64"
        }
      ]
    },
    "ServerRequestResolvedNotification": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ServerRequestResolvedNotification",
      "type": "object",
      "required": [
        "requestId",
        "threadId"
      ],
      "properties": {
        "requestId": {
          "$ref": "#/definitions/RequestId"
        },
        "threadId": {
          "type": "string"
        }
      }
    },
    "McpToolCallProgressNotification": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "McpToolCallProgressNotification",
      "type": "object",
      "required": [
        "itemId",
        "message",
        "threadId",
        "turnId"
      ],
      "properties": {
        "itemId": {
          "type": "string"
        },
        "message": {
          "type": "string"
        },
        "threadId": {
          "type": "string"
        },
        "turnId": {
          "type": "string"
        }
      }
    },
    "McpServerOauthLoginCompletedNotification": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "McpServerOauthLoginCompletedNotification",
      "type": "object",
      "required": [
        "name",
        "success"
      ],
      "properties": {
        "error": {
          "type": [
            "string",
            "null"
          ]
        },
        "name": {
          "type": "string"
        },
        "success": {
          "type": "boolean"
        }
      }
    },
    "McpServerStartupState": {
      "type": "string",
      "enum": [
        "starting",
        "ready",
        "failed",
        "cancelled"
      ]
    },
    "McpServerStatusUpdatedNotification": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "McpServerStatusUpdatedNotification",
      "type": "object",
      "required": [
        "name",
        "status"
      ],
      "properties": {
        "error": {
          "type": [
            "string",
            "null"
          ]
        },
        "name": {
          "type": "string"
        },
        "status": {
          "$ref": "#/definitions/McpServerStartupState"
        }
      }
    },
    "AuthMode": {
      "description": "Authentication mode for OpenAI-backed providers.",
      "oneOf": [
        {
          "description": "OpenAI API key provided by the caller and stored by Codex.",
          "type": "string",
          "enum": [
            "apikey"
          ]
        },
        {
          "description": "ChatGPT OAuth managed by Codex (tokens persisted and refreshed by Codex).",
          "type": "string",
          "enum": [
            "chatgpt"
          ]
        },
        {
          "description": "[UNSTABLE] FOR OPENAI INTERNAL USE ONLY - DO NOT USE.\n\nChatGPT auth tokens are supplied by an external host app and are only stored in memory. Token refresh must be handled by the external host app.",
          "type": "string",
          "enum": [
            "chatgptAuthTokens"
          ]
        }
      ]
    },
    "AccountUpdatedNotification": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "AccountUpdatedNotification",
      "type": "object",
      "properties": {
        "authMode": {
          "anyOf": [
            {
              "$ref": "#/definitions/AuthMode"
            },
            {
              "type": "null"
            }
          ]
        },
        "planType": {
          "anyOf": [
            {
              "$ref": "#/definitions/PlanType"
            },
            {
              "type": "null"
            }
          ]
        }
      }
    },
    "AccountRateLimitsUpdatedNotification": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "AccountRateLimitsUpdatedNotification",
      "type": "object",
      "required": [
        "rateLimits"
      ],
      "properties": {
        "rateLimits": {
          "$ref": "#/definitions/RateLimitSnapshot"
        }
      }
    },
    "AppListUpdatedNotification": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "AppListUpdatedNotification",
      "description": "EXPERIMENTAL - notification emitted when the app list changes.",
      "type": "object",
      "required": [
        "data"
      ],
      "properties": {
        "data": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/AppInfo"
          }
        }
      }
    },
    "ExternalAgentConfigImportCompletedNotification": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ExternalAgentConfigImportCompletedNotification",
      "type": "object"
    },
    "FsChangedNotification": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "FsChangedNotification",
      "description": "Filesystem watch notification emitted for `fs/watch` subscribers.",
      "type": "object",
      "required": [
        "changedPaths",
        "watchId"
      ],
      "properties": {
        "changedPaths": {
          "description": "File or directory paths associated with this event.",
          "type": "array",
          "items": {
            "$ref": "#/definitions/AbsolutePathBuf"
          }
        },
        "watchId": {
          "description": "Watch identifier previously provided to `fs/watch`.",
          "type": "string"
        }
      }
    },
    "FuzzyFileSearchSessionCompletedNotification": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "FuzzyFileSearchSessionCompletedNotification",
      "type": "object",
      "required": [
        "sessionId"
      ],
      "properties": {
        "sessionId": {
          "type": "string"
        }
      }
    },
    "ClientInfo": {
      "type": "object",
      "required": [
        "name",
        "version"
      ],
      "properties": {
        "name": {
          "type": "string"
        },
        "title": {
          "type": [
            "string",
            "null"
          ]
        },
        "version": {
          "type": "string"
        }
      }
    },
    "InitializeCapabilities": {
      "description": "Client-declared capabilities negotiated during initialize.",
      "type": "object",
      "properties": {
        "experimentalApi": {
          "description": "Opt into receiving experimental API methods and fields.",
          "default": false,
          "type": "boolean"
        },
        "optOutNotificationMethods": {
          "description": "Exact notification method names that should be suppressed for this connection (for example `thread/started`).",
          "type": [
            "array",
            "null"
          ],
          "items": {
            "type": "string"
          }
        }
      }
    },
    "FuzzyFileSearchResult": {
      "description": "Superset of [`codex_file_search::FileMatch`]",
      "type": "object",
      "required": [
        "file_name",
        "match_type",
        "path",
        "root",
        "score"
      ],
      "properties": {
        "file_name": {
          "type": "string"
        },
        "indices": {
          "type": [
            "array",
            "null"
          ],
          "items": {
            "type": "integer",
            "format": "uint32",
            "minimum": 0.0
          }
        },
        "match_type": {
          "$ref": "#/definitions/FuzzyFileSearchMatchType"
        },
        "path": {
          "type": "string"
        },
        "root": {
          "type": "string"
        },
        "score": {
          "type": "integer",
          "format": "uint32",
          "minimum": 0.0
        }
      }
    },
    "InitializeParams": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "InitializeParams",
      "type": "object",
      "required": [
        "clientInfo"
      ],
      "properties": {
        "capabilities": {
          "anyOf": [
            {
              "$ref": "#/definitions/InitializeCapabilities"
            },
            {
              "type": "null"
            }
          ]
        },
        "clientInfo": {
          "$ref": "#/definitions/ClientInfo"
        }
      }
    },
    "FuzzyFileSearchMatchType": {
      "type": "string",
      "enum": [
        "file",
        "directory"
      ]
    },
    "FuzzyFileSearchSessionUpdatedNotification": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "FuzzyFileSearchSessionUpdatedNotification",
      "type": "object",
      "required": [
        "files",
        "query",
        "sessionId"
      ],
      "properties": {
        "files": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/FuzzyFileSearchResult"
          }
        },
        "query": {
          "type": "string"
        },
        "sessionId": {
          "type": "string"
        }
      }
    },
    "FuzzyFileSearchParams": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "FuzzyFileSearchParams",
      "type": "object",
      "required": [
        "query",
        "roots"
      ],
      "properties": {
        "cancellationToken": {
          "type": [
            "string",
            "null"
          ]
        },
        "query": {
          "type": "string"
        },
        "roots": {
          "type": "array",
          "items": {
            "type": "string"
          }
        }
      }
    },
    "ClientRequest": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ClientRequest",
      "description": "Request from the client to the server.",
      "oneOf": [
        {
          "type": "object",
          "required": [
            "id",
            "method",
            "params"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "initialize"
              ],
              "title": "InitializeRequestMethod"
            },
            "params": {
              "$ref": "#/definitions/InitializeParams"
            }
          },
          "title": "InitializeRequest"
        },
        {
          "description": "NEW APIs",
          "type": "object",
          "required": [
            "id",
            "method",
            "params"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "thread/start"
              ],
              "title": "Thread/startRequestMethod"
            },
            "params": {
              "$ref": "#/definitions/ThreadStartParams"
            }
          },
          "title": "Thread/startRequest"
        },
        {
          "type": "object",
          "required": [
            "id",
            "method",
            "params"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "thread/resume"
              ],
              "title": "Thread/resumeRequestMethod"
            },
            "params": {
              "$ref": "#/definitions/ThreadResumeParams"
            }
          },
          "title": "Thread/resumeRequest"
        },
        {
          "type": "object",
          "required": [
            "id",
            "method",
            "params"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "thread/fork"
              ],
              "title": "Thread/forkRequestMethod"
            },
            "params": {
              "$ref": "#/definitions/ThreadForkParams"
            }
          },
          "title": "Thread/forkRequest"
        },
        {
          "type": "object",
          "required": [
            "id",
            "method",
            "params"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "thread/archive"
              ],
              "title": "Thread/archiveRequestMethod"
            },
            "params": {
              "$ref": "#/definitions/ThreadArchiveParams"
            }
          },
          "title": "Thread/archiveRequest"
        },
        {
          "type": "object",
          "required": [
            "id",
            "method",
            "params"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "thread/unsubscribe"
              ],
              "title": "Thread/unsubscribeRequestMethod"
            },
            "params": {
              "$ref": "#/definitions/ThreadUnsubscribeParams"
            }
          },
          "title": "Thread/unsubscribeRequest"
        },
        {
          "type": "object",
          "required": [
            "id",
            "method",
            "params"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "thread/name/set"
              ],
              "title": "Thread/name/setRequestMethod"
            },
            "params": {
              "$ref": "#/definitions/ThreadSetNameParams"
            }
          },
          "title": "Thread/name/setRequest"
        },
        {
          "type": "object",
          "required": [
            "id",
            "method",
            "params"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "thread/metadata/update"
              ],
              "title": "Thread/metadata/updateRequestMethod"
            },
            "params": {
              "$ref": "#/definitions/ThreadMetadataUpdateParams"
            }
          },
          "title": "Thread/metadata/updateRequest"
        },
        {
          "type": "object",
          "required": [
            "id",
            "method",
            "params"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "thread/unarchive"
              ],
              "title": "Thread/unarchiveRequestMethod"
            },
            "params": {
              "$ref": "#/definitions/ThreadUnarchiveParams"
            }
          },
          "title": "Thread/unarchiveRequest"
        },
        {
          "type": "object",
          "required": [
            "id",
            "method",
            "params"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "thread/compact/start"
              ],
              "title": "Thread/compact/startRequestMethod"
            },
            "params": {
              "$ref": "#/definitions/ThreadCompactStartParams"
            }
          },
          "title": "Thread/compact/startRequest"
        },
        {
          "type": "object",
          "required": [
            "id",
            "method",
            "params"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "thread/shellCommand"
              ],
              "title": "Thread/shellCommandRequestMethod"
            },
            "params": {
              "$ref": "#/definitions/ThreadShellCommandParams"
            }
          },
          "title": "Thread/shellCommandRequest"
        },
        {
          "type": "object",
          "required": [
            "id",
            "method",
            "params"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "thread/rollback"
              ],
              "title": "Thread/rollbackRequestMethod"
            },
            "params": {
              "$ref": "#/definitions/ThreadRollbackParams"
            }
          },
          "title": "Thread/rollbackRequest"
        },
        {
          "type": "object",
          "required": [
            "id",
            "method",
            "params"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "thread/list"
              ],
              "title": "Thread/listRequestMethod"
            },
            "params": {
              "$ref": "#/definitions/ThreadListParams"
            }
          },
          "title": "Thread/listRequest"
        },
        {
          "type": "object",
          "required": [
            "id",
            "method",
            "params"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "thread/loaded/list"
              ],
              "title": "Thread/loaded/listRequestMethod"
            },
            "params": {
              "$ref": "#/definitions/ThreadLoadedListParams"
            }
          },
          "title": "Thread/loaded/listRequest"
        },
        {
          "type": "object",
          "required": [
            "id",
            "method",
            "params"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "thread/read"
              ],
              "title": "Thread/readRequestMethod"
            },
            "params": {
              "$ref": "#/definitions/ThreadReadParams"
            }
          },
          "title": "Thread/readRequest"
        },
        {
          "type": "object",
          "required": [
            "id",
            "method",
            "params"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "thread/turns/list"
              ],
              "title": "Thread/turns/listRequestMethod"
            },
            "params": {
              "$ref": "#/definitions/ThreadTurnsListParams"
            }
          },
          "title": "Thread/turns/listRequest"
        },
        {
          "description": "Append raw Responses API items to the thread history without starting a user turn.",
          "type": "object",
          "required": [
            "id",
            "method",
            "params"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "thread/inject_items"
              ],
              "title": "Thread/injectItemsRequestMethod"
            },
            "params": {
              "$ref": "#/definitions/ThreadInjectItemsParams"
            }
          },
          "title": "Thread/injectItemsRequest"
        },
        {
          "type": "object",
          "required": [
            "id",
            "method",
            "params"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "skills/list"
              ],
              "title": "Skills/listRequestMethod"
            },
            "params": {
              "$ref": "#/definitions/SkillsListParams"
            }
          },
          "title": "Skills/listRequest"
        },
        {
          "type": "object",
          "required": [
            "id",
            "method",
            "params"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "marketplace/add"
              ],
              "title": "Marketplace/addRequestMethod"
            },
            "params": {
              "$ref": "#/definitions/MarketplaceAddParams"
            }
          },
          "title": "Marketplace/addRequest"
        },
        {
          "type": "object",
          "required": [
            "id",
            "method",
            "params"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "marketplace/remove"
              ],
              "title": "Marketplace/removeRequestMethod"
            },
            "params": {
              "$ref": "#/definitions/MarketplaceRemoveParams"
            }
          },
          "title": "Marketplace/removeRequest"
        },
        {
          "type": "object",
          "required": [
            "id",
            "method",
            "params"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "plugin/list"
              ],
              "title": "Plugin/listRequestMethod"
            },
            "params": {
              "$ref": "#/definitions/PluginListParams"
            }
          },
          "title": "Plugin/listRequest"
        },
        {
          "type": "object",
          "required": [
            "id",
            "method",
            "params"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "plugin/read"
              ],
              "title": "Plugin/readRequestMethod"
            },
            "params": {
              "$ref": "#/definitions/PluginReadParams"
            }
          },
          "title": "Plugin/readRequest"
        },
        {
          "type": "object",
          "required": [
            "id",
            "method",
            "params"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "app/list"
              ],
              "title": "App/listRequestMethod"
            },
            "params": {
              "$ref": "#/definitions/AppsListParams"
            }
          },
          "title": "App/listRequest"
        },
        {
          "type": "object",
          "required": [
            "id",
            "method",
            "params"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "fs/readFile"
              ],
              "title": "Fs/readFileRequestMethod"
            },
            "params": {
              "$ref": "#/definitions/FsReadFileParams"
            }
          },
          "title": "Fs/readFileRequest"
        },
        {
          "type": "object",
          "required": [
            "id",
            "method",
            "params"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "fs/writeFile"
              ],
              "title": "Fs/writeFileRequestMethod"
            },
            "params": {
              "$ref": "#/definitions/FsWriteFileParams"
            }
          },
          "title": "Fs/writeFileRequest"
        },
        {
          "type": "object",
          "required": [
            "id",
            "method",
            "params"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "fs/createDirectory"
              ],
              "title": "Fs/createDirectoryRequestMethod"
            },
            "params": {
              "$ref": "#/definitions/FsCreateDirectoryParams"
            }
          },
          "title": "Fs/createDirectoryRequest"
        },
        {
          "type": "object",
          "required": [
            "id",
            "method",
            "params"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "fs/getMetadata"
              ],
              "title": "Fs/getMetadataRequestMethod"
            },
            "params": {
              "$ref": "#/definitions/FsGetMetadataParams"
            }
          },
          "title": "Fs/getMetadataRequest"
        },
        {
          "type": "object",
          "required": [
            "id",
            "method",
            "params"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "fs/readDirectory"
              ],
              "title": "Fs/readDirectoryRequestMethod"
            },
            "params": {
              "$ref": "#/definitions/FsReadDirectoryParams"
            }
          },
          "title": "Fs/readDirectoryRequest"
        },
        {
          "type": "object",
          "required": [
            "id",
            "method",
            "params"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "fs/remove"
              ],
              "title": "Fs/removeRequestMethod"
            },
            "params": {
              "$ref": "#/definitions/FsRemoveParams"
            }
          },
          "title": "Fs/removeRequest"
        },
        {
          "type": "object",
          "required": [
            "id",
            "method",
            "params"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "fs/copy"
              ],
              "title": "Fs/copyRequestMethod"
            },
            "params": {
              "$ref": "#/definitions/FsCopyParams"
            }
          },
          "title": "Fs/copyRequest"
        },
        {
          "type": "object",
          "required": [
            "id",
            "method",
            "params"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "fs/watch"
              ],
              "title": "Fs/watchRequestMethod"
            },
            "params": {
              "$ref": "#/definitions/FsWatchParams"
            }
          },
          "title": "Fs/watchRequest"
        },
        {
          "type": "object",
          "required": [
            "id",
            "method",
            "params"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "fs/unwatch"
              ],
              "title": "Fs/unwatchRequestMethod"
            },
            "params": {
              "$ref": "#/definitions/FsUnwatchParams"
            }
          },
          "title": "Fs/unwatchRequest"
        },
        {
          "type": "object",
          "required": [
            "id",
            "method",
            "params"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "skills/config/write"
              ],
              "title": "Skills/config/writeRequestMethod"
            },
            "params": {
              "$ref": "#/definitions/SkillsConfigWriteParams"
            }
          },
          "title": "Skills/config/writeRequest"
        },
        {
          "type": "object",
          "required": [
            "id",
            "method",
            "params"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "plugin/install"
              ],
              "title": "Plugin/installRequestMethod"
            },
            "params": {
              "$ref": "#/definitions/PluginInstallParams"
            }
          },
          "title": "Plugin/installRequest"
        },
        {
          "type": "object",
          "required": [
            "id",
            "method",
            "params"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "plugin/uninstall"
              ],
              "title": "Plugin/uninstallRequestMethod"
            },
            "params": {
              "$ref": "#/definitions/PluginUninstallParams"
            }
          },
          "title": "Plugin/uninstallRequest"
        },
        {
          "type": "object",
          "required": [
            "id",
            "method",
            "params"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "turn/start"
              ],
              "title": "Turn/startRequestMethod"
            },
            "params": {
              "$ref": "#/definitions/TurnStartParams"
            }
          },
          "title": "Turn/startRequest"
        },
        {
          "type": "object",
          "required": [
            "id",
            "method",
            "params"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "turn/steer"
              ],
              "title": "Turn/steerRequestMethod"
            },
            "params": {
              "$ref": "#/definitions/TurnSteerParams"
            }
          },
          "title": "Turn/steerRequest"
        },
        {
          "type": "object",
          "required": [
            "id",
            "method",
            "params"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "turn/interrupt"
              ],
              "title": "Turn/interruptRequestMethod"
            },
            "params": {
              "$ref": "#/definitions/TurnInterruptParams"
            }
          },
          "title": "Turn/interruptRequest"
        },
        {
          "type": "object",
          "required": [
            "id",
            "method",
            "params"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "review/start"
              ],
              "title": "Review/startRequestMethod"
            },
            "params": {
              "$ref": "#/definitions/ReviewStartParams"
            }
          },
          "title": "Review/startRequest"
        },
        {
          "type": "object",
          "required": [
            "id",
            "method",
            "params"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "model/list"
              ],
              "title": "Model/listRequestMethod"
            },
            "params": {
              "$ref": "#/definitions/ModelListParams"
            }
          },
          "title": "Model/listRequest"
        },
        {
          "type": "object",
          "required": [
            "id",
            "method",
            "params"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "experimentalFeature/list"
              ],
              "title": "ExperimentalFeature/listRequestMethod"
            },
            "params": {
              "$ref": "#/definitions/ExperimentalFeatureListParams"
            }
          },
          "title": "ExperimentalFeature/listRequest"
        },
        {
          "type": "object",
          "required": [
            "id",
            "method",
            "params"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "experimentalFeature/enablement/set"
              ],
              "title": "ExperimentalFeature/enablement/setRequestMethod"
            },
            "params": {
              "$ref": "#/definitions/ExperimentalFeatureEnablementSetParams"
            }
          },
          "title": "ExperimentalFeature/enablement/setRequest"
        },
        {
          "type": "object",
          "required": [
            "id",
            "method",
            "params"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "mcpServer/oauth/login"
              ],
              "title": "McpServer/oauth/loginRequestMethod"
            },
            "params": {
              "$ref": "#/definitions/McpServerOauthLoginParams"
            }
          },
          "title": "McpServer/oauth/loginRequest"
        },
        {
          "type": "object",
          "required": [
            "id",
            "method"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "config/mcpServer/reload"
              ],
              "title": "Config/mcpServer/reloadRequestMethod"
            },
            "params": {
              "type": "null"
            }
          },
          "title": "Config/mcpServer/reloadRequest"
        },
        {
          "type": "object",
          "required": [
            "id",
            "method",
            "params"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "mcpServerStatus/list"
              ],
              "title": "McpServerStatus/listRequestMethod"
            },
            "params": {
              "$ref": "#/definitions/ListMcpServerStatusParams"
            }
          },
          "title": "McpServerStatus/listRequest"
        },
        {
          "type": "object",
          "required": [
            "id",
            "method",
            "params"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "mcpServer/resource/read"
              ],
              "title": "McpServer/resource/readRequestMethod"
            },
            "params": {
              "$ref": "#/definitions/McpResourceReadParams"
            }
          },
          "title": "McpServer/resource/readRequest"
        },
        {
          "type": "object",
          "required": [
            "id",
            "method",
            "params"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "mcpServer/tool/call"
              ],
              "title": "McpServer/tool/callRequestMethod"
            },
            "params": {
              "$ref": "#/definitions/McpServerToolCallParams"
            }
          },
          "title": "McpServer/tool/callRequest"
        },
        {
          "type": "object",
          "required": [
            "id",
            "method",
            "params"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "windowsSandbox/setupStart"
              ],
              "title": "WindowsSandbox/setupStartRequestMethod"
            },
            "params": {
              "$ref": "#/definitions/WindowsSandboxSetupStartParams"
            }
          },
          "title": "WindowsSandbox/setupStartRequest"
        },
        {
          "type": "object",
          "required": [
            "id",
            "method",
            "params"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "account/login/start"
              ],
              "title": "Account/login/startRequestMethod"
            },
            "params": {
              "$ref": "#/definitions/LoginAccountParams"
            }
          },
          "title": "Account/login/startRequest"
        },
        {
          "type": "object",
          "required": [
            "id",
            "method",
            "params"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "account/login/cancel"
              ],
              "title": "Account/login/cancelRequestMethod"
            },
            "params": {
              "$ref": "#/definitions/CancelLoginAccountParams"
            }
          },
          "title": "Account/login/cancelRequest"
        },
        {
          "type": "object",
          "required": [
            "id",
            "method"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "account/logout"
              ],
              "title": "Account/logoutRequestMethod"
            },
            "params": {
              "type": "null"
            }
          },
          "title": "Account/logoutRequest"
        },
        {
          "type": "object",
          "required": [
            "id",
            "method"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "account/rateLimits/read"
              ],
              "title": "Account/rateLimits/readRequestMethod"
            },
            "params": {
              "type": "null"
            }
          },
          "title": "Account/rateLimits/readRequest"
        },
        {
          "type": "object",
          "required": [
            "id",
            "method",
            "params"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "account/sendAddCreditsNudgeEmail"
              ],
              "title": "Account/sendAddCreditsNudgeEmailRequestMethod"
            },
            "params": {
              "$ref": "#/definitions/SendAddCreditsNudgeEmailParams"
            }
          },
          "title": "Account/sendAddCreditsNudgeEmailRequest"
        },
        {
          "type": "object",
          "required": [
            "id",
            "method",
            "params"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "feedback/upload"
              ],
              "title": "Feedback/uploadRequestMethod"
            },
            "params": {
              "$ref": "#/definitions/FeedbackUploadParams"
            }
          },
          "title": "Feedback/uploadRequest"
        },
        {
          "description": "Execute a standalone command (argv vector) under the server's sandbox.",
          "type": "object",
          "required": [
            "id",
            "method",
            "params"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "command/exec"
              ],
              "title": "Command/execRequestMethod"
            },
            "params": {
              "$ref": "#/definitions/CommandExecParams"
            }
          },
          "title": "Command/execRequest"
        },
        {
          "description": "Write stdin bytes to a running `command/exec` session or close stdin.",
          "type": "object",
          "required": [
            "id",
            "method",
            "params"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "command/exec/write"
              ],
              "title": "Command/exec/writeRequestMethod"
            },
            "params": {
              "$ref": "#/definitions/CommandExecWriteParams"
            }
          },
          "title": "Command/exec/writeRequest"
        },
        {
          "description": "Terminate a running `command/exec` session by client-supplied `processId`.",
          "type": "object",
          "required": [
            "id",
            "method",
            "params"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "command/exec/terminate"
              ],
              "title": "Command/exec/terminateRequestMethod"
            },
            "params": {
              "$ref": "#/definitions/CommandExecTerminateParams"
            }
          },
          "title": "Command/exec/terminateRequest"
        },
        {
          "description": "Resize a running PTY-backed `command/exec` session by client-supplied `processId`.",
          "type": "object",
          "required": [
            "id",
            "method",
            "params"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "command/exec/resize"
              ],
              "title": "Command/exec/resizeRequestMethod"
            },
            "params": {
              "$ref": "#/definitions/CommandExecResizeParams"
            }
          },
          "title": "Command/exec/resizeRequest"
        },
        {
          "type": "object",
          "required": [
            "id",
            "method",
            "params"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "config/read"
              ],
              "title": "Config/readRequestMethod"
            },
            "params": {
              "$ref": "#/definitions/ConfigReadParams"
            }
          },
          "title": "Config/readRequest"
        },
        {
          "type": "object",
          "required": [
            "id",
            "method",
            "params"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "externalAgentConfig/detect"
              ],
              "title": "ExternalAgentConfig/detectRequestMethod"
            },
            "params": {
              "$ref": "#/definitions/ExternalAgentConfigDetectParams"
            }
          },
          "title": "ExternalAgentConfig/detectRequest"
        },
        {
          "type": "object",
          "required": [
            "id",
            "method",
            "params"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "externalAgentConfig/import"
              ],
              "title": "ExternalAgentConfig/importRequestMethod"
            },
            "params": {
              "$ref": "#/definitions/ExternalAgentConfigImportParams"
            }
          },
          "title": "ExternalAgentConfig/importRequest"
        },
        {
          "type": "object",
          "required": [
            "id",
            "method",
            "params"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "config/value/write"
              ],
              "title": "Config/value/writeRequestMethod"
            },
            "params": {
              "$ref": "#/definitions/ConfigValueWriteParams"
            }
          },
          "title": "Config/value/writeRequest"
        },
        {
          "type": "object",
          "required": [
            "id",
            "method",
            "params"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "config/batchWrite"
              ],
              "title": "Config/batchWriteRequestMethod"
            },
            "params": {
              "$ref": "#/definitions/ConfigBatchWriteParams"
            }
          },
          "title": "Config/batchWriteRequest"
        },
        {
          "type": "object",
          "required": [
            "id",
            "method"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "configRequirements/read"
              ],
              "title": "ConfigRequirements/readRequestMethod"
            },
            "params": {
              "type": "null"
            }
          },
          "title": "ConfigRequirements/readRequest"
        },
        {
          "type": "object",
          "required": [
            "id",
            "method",
            "params"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "account/read"
              ],
              "title": "Account/readRequestMethod"
            },
            "params": {
              "$ref": "#/definitions/GetAccountParams"
            }
          },
          "title": "Account/readRequest"
        },
        {
          "type": "object",
          "required": [
            "id",
            "method",
            "params"
          ],
          "properties": {
            "id": {
              "$ref": "#/definitions/RequestId"
            },
            "method": {
              "type": "string",
              "enum": [
                "fuzzyFileSearch"
              ],
              "title": "FuzzyFileSearchRequestMethod"
            },
            "params": {
              "$ref": "#/definitions/FuzzyFileSearchParams"
            }
          },
          "title": "FuzzyFileSearchRequest"
        }
      ]
    },
    "ServerNotification": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "ServerNotification",
      "description": "Notification sent from the server to the client.",
      "oneOf": [
        {
          "description": "NEW NOTIFICATIONS",
          "type": "object",
          "required": [
            "method",
            "params"
          ],
          "properties": {
            "method": {
              "type": "string",
              "enum": [
                "error"
              ],
              "title": "ErrorNotificationMethod"
            },
            "params": {
              "$ref": "#/definitions/ErrorNotification"
            }
          },
          "title": "ErrorNotification"
        },
        {
          "type": "object",
          "required": [
            "method",
            "params"
          ],
          "properties": {
            "method": {
              "type": "string",
              "enum": [
                "thread/started"
              ],
              "title": "Thread/startedNotificationMethod"
            },
            "params": {
              "$ref": "#/definitions/ThreadStartedNotification"
            }
          },
          "title": "Thread/startedNotification"
        },
        {
          "type": "object",
          "required": [
            "method",
            "params"
          ],
          "properties": {
            "method": {
              "type": "string",
              "enum": [
                "thread/status/changed"
              ],
              "title": "Thread/status/changedNotificationMethod"
            },
            "params": {
              "$ref": "#/definitions/ThreadStatusChangedNotification"
            }
          },
          "title": "Thread/status/changedNotification"
        },
        {
          "type": "object",
          "required": [
            "method",
            "params"
          ],
          "properties": {
            "method": {
              "type": "string",
              "enum": [
                "thread/archived"
              ],
              "title": "Thread/archivedNotificationMethod"
            },
            "params": {
              "$ref": "#/definitions/ThreadArchivedNotification"
            }
          },
          "title": "Thread/archivedNotification"
        },
        {
          "type": "object",
          "required": [
            "method",
            "params"
          ],
          "properties": {
            "method": {
              "type": "string",
              "enum": [
                "thread/unarchived"
              ],
              "title": "Thread/unarchivedNotificationMethod"
            },
            "params": {
              "$ref": "#/definitions/ThreadUnarchivedNotification"
            }
          },
          "title": "Thread/unarchivedNotification"
        },
        {
          "type": "object",
          "required": [
            "method",
            "params"
          ],
          "properties": {
            "method": {
              "type": "string",
              "enum": [
                "thread/closed"
              ],
              "title": "Thread/closedNotificationMethod"
            },
            "params": {
              "$ref": "#/definitions/ThreadClosedNotification"
            }
          },
          "title": "Thread/closedNotification"
        },
        {
          "type": "object",
          "required": [
            "method",
            "params"
          ],
          "properties": {
            "method": {
              "type": "string",
              "enum": [
                "skills/changed"
              ],
              "title": "Skills/changedNotificationMethod"
            },
            "params": {
              "$ref": "#/definitions/SkillsChangedNotification"
            }
          },
          "title": "Skills/changedNotification"
        },
        {
          "type": "object",
          "required": [
            "method",
            "params"
          ],
          "properties": {
            "method": {
              "type": "string",
              "enum": [
                "thread/name/updated"
              ],
              "title": "Thread/name/updatedNotificationMethod"
            },
            "params": {
              "$ref": "#/definitions/ThreadNameUpdatedNotification"
            }
          },
          "title": "Thread/name/updatedNotification"
        },
        {
          "type": "object",
          "required": [
            "method",
            "params"
          ],
          "properties": {
            "method": {
              "type": "string",
              "enum": [
                "thread/tokenUsage/updated"
              ],
              "title": "Thread/tokenUsage/updatedNotificationMethod"
            },
            "params": {
              "$ref": "#/definitions/ThreadTokenUsageUpdatedNotification"
            }
          },
          "title": "Thread/tokenUsage/updatedNotification"
        },
        {
          "type": "object",
          "required": [
            "method",
            "params"
          ],
          "properties": {
            "method": {
              "type": "string",
              "enum": [
                "turn/started"
              ],
              "title": "Turn/startedNotificationMethod"
            },
            "params": {
              "$ref": "#/definitions/TurnStartedNotification"
            }
          },
          "title": "Turn/startedNotification"
        },
        {
          "type": "object",
          "required": [
            "method",
            "params"
          ],
          "properties": {
            "method": {
              "type": "string",
              "enum": [
                "hook/started"
              ],
              "title": "Hook/startedNotificationMethod"
            },
            "params": {
              "$ref": "#/definitions/HookStartedNotification"
            }
          },
          "title": "Hook/startedNotification"
        },
        {
          "type": "object",
          "required": [
            "method",
            "params"
          ],
          "properties": {
            "method": {
              "type": "string",
              "enum": [
                "turn/completed"
              ],
              "title": "Turn/completedNotificationMethod"
            },
            "params": {
              "$ref": "#/definitions/TurnCompletedNotification"
            }
          },
          "title": "Turn/completedNotification"
        },
        {
          "type": "object",
          "required": [
            "method",
            "params"
          ],
          "properties": {
            "method": {
              "type": "string",
              "enum": [
                "hook/completed"
              ],
              "title": "Hook/completedNotificationMethod"
            },
            "params": {
              "$ref": "#/definitions/HookCompletedNotification"
            }
          },
          "title": "Hook/completedNotification"
        },
        {
          "type": "object",
          "required": [
            "method",
            "params"
          ],
          "properties": {
            "method": {
              "type": "string",
              "enum": [
                "turn/diff/updated"
              ],
              "title": "Turn/diff/updatedNotificationMethod"
            },
            "params": {
              "$ref": "#/definitions/TurnDiffUpdatedNotification"
            }
          },
          "title": "Turn/diff/updatedNotification"
        },
        {
          "type": "object",
          "required": [
            "method",
            "params"
          ],
          "properties": {
            "method": {
              "type": "string",
              "enum": [
                "turn/plan/updated"
              ],
              "title": "Turn/plan/updatedNotificationMethod"
            },
            "params": {
              "$ref": "#/definitions/TurnPlanUpdatedNotification"
            }
          },
          "title": "Turn/plan/updatedNotification"
        },
        {
          "type": "object",
          "required": [
            "method",
            "params"
          ],
          "properties": {
            "method": {
              "type": "string",
              "enum": [
                "item/started"
              ],
              "title": "Item/startedNotificationMethod"
            },
            "params": {
              "$ref": "#/definitions/ItemStartedNotification"
            }
          },
          "title": "Item/startedNotification"
        },
        {
          "type": "object",
          "required": [
            "method",
            "params"
          ],
          "properties": {
            "method": {
              "type": "string",
              "enum": [
                "item/autoApprovalReview/started"
              ],
              "title": "Item/autoApprovalReview/startedNotificationMethod"
            },
            "params": {
              "$ref": "#/definitions/ItemGuardianApprovalReviewStartedNotification"
            }
          },
          "title": "Item/autoApprovalReview/startedNotification"
        },
        {
          "type": "object",
          "required": [
            "method",
            "params"
          ],
          "properties": {
            "method": {
              "type": "string",
              "enum": [
                "item/autoApprovalReview/completed"
              ],
              "title": "Item/autoApprovalReview/completedNotificationMethod"
            },
            "params": {
              "$ref": "#/definitions/ItemGuardianApprovalReviewCompletedNotification"
            }
          },
          "title": "Item/autoApprovalReview/completedNotification"
        },
        {
          "type": "object",
          "required": [
            "method",
            "params"
          ],
          "properties": {
            "method": {
              "type": "string",
              "enum": [
                "item/completed"
              ],
              "title": "Item/completedNotificationMethod"
            },
            "params": {
              "$ref": "#/definitions/ItemCompletedNotification"
            }
          },
          "title": "Item/completedNotification"
        },
        {
          "type": "object",
          "required": [
            "method",
            "params"
          ],
          "properties": {
            "method": {
              "type": "string",
              "enum": [
                "item/agentMessage/delta"
              ],
              "title": "Item/agentMessage/deltaNotificationMethod"
            },
            "params": {
              "$ref": "#/definitions/AgentMessageDeltaNotification"
            }
          },
          "title": "Item/agentMessage/deltaNotification"
        },
        {
          "description": "EXPERIMENTAL - proposed plan streaming deltas for plan items.",
          "type": "object",
          "required": [
            "method",
            "params"
          ],
          "properties": {
            "method": {
              "type": "string",
              "enum": [
                "item/plan/delta"
              ],
              "title": "Item/plan/deltaNotificationMethod"
            },
            "params": {
              "$ref": "#/definitions/PlanDeltaNotification"
            }
          },
          "title": "Item/plan/deltaNotification"
        },
        {
          "description": "Stream base64-encoded stdout/stderr chunks for a running `command/exec` session.",
          "type": "object",
          "required": [
            "method",
            "params"
          ],
          "properties": {
            "method": {
              "type": "string",
              "enum": [
                "command/exec/outputDelta"
              ],
              "title": "Command/exec/outputDeltaNotificationMethod"
            },
            "params": {
              "$ref": "#/definitions/CommandExecOutputDeltaNotification"
            }
          },
          "title": "Command/exec/outputDeltaNotification"
        },
        {
          "type": "object",
          "required": [
            "method",
            "params"
          ],
          "properties": {
            "method": {
              "type": "string",
              "enum": [
                "item/commandExecution/outputDelta"
              ],
              "title": "Item/commandExecution/outputDeltaNotificationMethod"
            },
            "params": {
              "$ref": "#/definitions/CommandExecutionOutputDeltaNotification"
            }
          },
          "title": "Item/commandExecution/outputDeltaNotification"
        },
        {
          "type": "object",
          "required": [
            "method",
            "params"
          ],
          "properties": {
            "method": {
              "type": "string",
              "enum": [
                "item/commandExecution/terminalInteraction"
              ],
              "title": "Item/commandExecution/terminalInteractionNotificationMethod"
            },
            "params": {
              "$ref": "#/definitions/TerminalInteractionNotification"
            }
          },
          "title": "Item/commandExecution/terminalInteractionNotification"
        },
        {
          "type": "object",
          "required": [
            "method",
            "params"
          ],
          "properties": {
            "method": {
              "type": "string",
              "enum": [
                "item/fileChange/outputDelta"
              ],
              "title": "Item/fileChange/outputDeltaNotificationMethod"
            },
            "params": {
              "$ref": "#/definitions/FileChangeOutputDeltaNotification"
            }
          },
          "title": "Item/fileChange/outputDeltaNotification"
        },
        {
          "type": "object",
          "required": [
            "method",
            "params"
          ],
          "properties": {
            "method": {
              "type": "string",
              "enum": [
                "serverRequest/resolved"
              ],
              "title": "ServerRequest/resolvedNotificationMethod"
            },
            "params": {
              "$ref": "#/definitions/ServerRequestResolvedNotification"
            }
          },
          "title": "ServerRequest/resolvedNotification"
        },
        {
          "type": "object",
          "required": [
            "method",
            "params"
          ],
          "properties": {
            "method": {
              "type": "string",
              "enum": [
                "item/mcpToolCall/progress"
              ],
              "title": "Item/mcpToolCall/progressNotificationMethod"
            },
            "params": {
              "$ref": "#/definitions/McpToolCallProgressNotification"
            }
          },
          "title": "Item/mcpToolCall/progressNotification"
        },
        {
          "type": "object",
          "required": [
            "method",
            "params"
          ],
          "properties": {
            "method": {
              "type": "string",
              "enum": [
                "mcpServer/oauthLogin/completed"
              ],
              "title": "McpServer/oauthLogin/completedNotificationMethod"
            },
            "params": {
              "$ref": "#/definitions/McpServerOauthLoginCompletedNotification"
            }
          },
          "title": "McpServer/oauthLogin/completedNotification"
        },
        {
          "type": "object",
          "required": [
            "method",
            "params"
          ],
          "properties": {
            "method": {
              "type": "string",
              "enum": [
                "mcpServer/startupStatus/updated"
              ],
              "title": "McpServer/startupStatus/updatedNotificationMethod"
            },
            "params": {
              "$ref": "#/definitions/McpServerStatusUpdatedNotification"
            }
          },
          "title": "McpServer/startupStatus/updatedNotification"
        },
        {
          "type": "object",
          "required": [
            "method",
            "params"
          ],
          "properties": {
            "method": {
              "type": "string",
              "enum": [
                "account/updated"
              ],
              "title": "Account/updatedNotificationMethod"
            },
            "params": {
              "$ref": "#/definitions/AccountUpdatedNotification"
            }
          },
          "title": "Account/updatedNotification"
        },
        {
          "type": "object",
          "required": [
            "method",
            "params"
          ],
          "properties": {
            "method": {
              "type": "string",
              "enum": [
                "account/rateLimits/updated"
              ],
              "title": "Account/rateLimits/updatedNotificationMethod"
            },
            "params": {
              "$ref": "#/definitions/AccountRateLimitsUpdatedNotification"
            }
          },
          "title": "Account/rateLimits/updatedNotification"
        },
        {
          "type": "object",
          "required": [
            "method",
            "params"
          ],
          "properties": {
            "method": {
              "type": "string",
              "enum": [
                "app/list/updated"
              ],
              "title": "App/list/updatedNotificationMethod"
            },
            "params": {
              "$ref": "#/definitions/AppListUpdatedNotification"
            }
          },
          "title": "App/list/updatedNotification"
        },
        {
          "type": "object",
          "required": [
            "method",
            "params"
          ],
          "properties": {
            "method": {
              "type": "string",
              "enum": [
                "externalAgentConfig/import/completed"
              ],
              "title": "ExternalAgentConfig/import/completedNotificationMethod"
            },
            "params": {
              "$ref": "#/definitions/ExternalAgentConfigImportCompletedNotification"
            }
          },
          "title": "ExternalAgentConfig/import/completedNotification"
        },
        {
          "type": "object",
          "required": [
            "method",
            "params"
          ],
          "properties": {
            "method": {
              "type": "string",
              "enum": [
                "fs/changed"
              ],
              "title": "Fs/changedNotificationMethod"
            },
            "params": {
              "$ref": "#/definitions/FsChangedNotification"
            }
          },
          "title": "Fs/changedNotification"
        },
        {
          "type": "object",
          "required": [
            "method",
            "params"
          ],
          "properties": {
            "method": {
              "type": "string",
              "enum": [
                "item/reasoning/summaryTextDelta"
              ],
              "title": "Item/reasoning/summaryTextDeltaNotificationMethod"
            },
            "params": {
              "$ref": "#/definitions/ReasoningSummaryTextDeltaNotification"
            }
          },
          "title": "Item/reasoning/summaryTextDeltaNotification"
        },
        {
          "type": "object",
          "required": [
            "method",
            "params"
          ],
          "properties": {
            "method": {
              "type": "string",
              "enum": [
                "item/reasoning/summaryPartAdded"
              ],
              "title": "Item/reasoning/summaryPartAddedNotificationMethod"
            },
            "params": {
              "$ref": "#/definitions/ReasoningSummaryPartAddedNotification"
            }
          },
          "title": "Item/reasoning/summaryPartAddedNotification"
        },
        {
          "type": "object",
          "required": [
            "method",
            "params"
          ],
          "properties": {
            "method": {
              "type": "string",
              "enum": [
                "item/reasoning/textDelta"
              ],
              "title": "Item/reasoning/textDeltaNotificationMethod"
            },
            "params": {
              "$ref": "#/definitions/ReasoningTextDeltaNotification"
            }
          },
          "title": "Item/reasoning/textDeltaNotification"
        },
        {
          "description": "Deprecated: Use `ContextCompaction` item type instead.",
          "type": "object",
          "required": [
            "method",
            "params"
          ],
          "properties": {
            "method": {
              "type": "string",
              "enum": [
                "thread/compacted"
              ],
              "title": "Thread/compactedNotificationMethod"
            },
            "params": {
              "$ref": "#/definitions/ContextCompactedNotification"
            }
          },
          "title": "Thread/compactedNotification"
        },
        {
          "type": "object",
          "required": [
            "method",
            "params"
          ],
          "properties": {
            "method": {
              "type": "string",
              "enum": [
                "model/rerouted"
              ],
              "title": "Model/reroutedNotificationMethod"
            },
            "params": {
              "$ref": "#/definitions/ModelReroutedNotification"
            }
          },
          "title": "Model/reroutedNotification"
        },
        {
          "type": "object",
          "required": [
            "method",
            "params"
          ],
          "properties": {
            "method": {
              "type": "string",
              "enum": [
                "warning"
              ],
              "title": "WarningNotificationMethod"
            },
            "params": {
              "$ref": "#/definitions/WarningNotification"
            }
          },
          "title": "WarningNotification"
        },
        {
          "type": "object",
          "required": [
            "method",
            "params"
          ],
          "properties": {
            "method": {
              "type": "string",
              "enum": [
                "deprecationNotice"
              ],
              "title": "DeprecationNoticeNotificationMethod"
            },
            "params": {
              "$ref": "#/definitions/DeprecationNoticeNotification"
            }
          },
          "title": "DeprecationNoticeNotification"
        },
        {
          "type": "object",
          "required": [
            "method",
            "params"
          ],
          "properties": {
            "method": {
              "type": "string",
              "enum": [
                "configWarning"
              ],
              "title": "ConfigWarningNotificationMethod"
            },
            "params": {
              "$ref": "#/definitions/ConfigWarningNotification"
            }
          },
          "title": "ConfigWarningNotification"
        },
        {
          "type": "object",
          "required": [
            "method",
            "params"
          ],
          "properties": {
            "method": {
              "type": "string",
              "enum": [
                "fuzzyFileSearch/sessionUpdated"
              ],
              "title": "FuzzyFileSearch/sessionUpdatedNotificationMethod"
            },
            "params": {
              "$ref": "#/definitions/FuzzyFileSearchSessionUpdatedNotification"
            }
          },
          "title": "FuzzyFileSearch/sessionUpdatedNotification"
        },
        {
          "type": "object",
          "required": [
            "method",
            "params"
          ],
          "properties": {
            "method": {
              "type": "string",
              "enum": [
                "fuzzyFileSearch/sessionCompleted"
              ],
              "title": "FuzzyFileSearch/sessionCompletedNotificationMethod"
            },
            "params": {
              "$ref": "#/definitions/FuzzyFileSearchSessionCompletedNotification"
            }
          },
          "title": "FuzzyFileSearch/sessionCompletedNotification"
        },
        {
          "type": "object",
          "required": [
            "method",
            "params"
          ],
          "properties": {
            "method": {
              "type": "string",
              "enum": [
                "thread/realtime/started"
              ],
              "title": "Thread/realtime/startedNotificationMethod"
            },
            "params": {
              "$ref": "#/definitions/ThreadRealtimeStartedNotification"
            }
          },
          "title": "Thread/realtime/startedNotification"
        },
        {
          "type": "object",
          "required": [
            "method",
            "params"
          ],
          "properties": {
            "method": {
              "type": "string",
              "enum": [
                "thread/realtime/itemAdded"
              ],
              "title": "Thread/realtime/itemAddedNotificationMethod"
            },
            "params": {
              "$ref": "#/definitions/ThreadRealtimeItemAddedNotification"
            }
          },
          "title": "Thread/realtime/itemAddedNotification"
        },
        {
          "type": "object",
          "required": [
            "method",
            "params"
          ],
          "properties": {
            "method": {
              "type": "string",
              "enum": [
                "thread/realtime/transcript/delta"
              ],
              "title": "Thread/realtime/transcript/deltaNotificationMethod"
            },
            "params": {
              "$ref": "#/definitions/ThreadRealtimeTranscriptDeltaNotification"
            }
          },
          "title": "Thread/realtime/transcript/deltaNotification"
        },
        {
          "type": "object",
          "required": [
            "method",
            "params"
          ],
          "properties": {
            "method": {
              "type": "string",
              "enum": [
                "thread/realtime/transcript/done"
              ],
              "title": "Thread/realtime/transcript/doneNotificationMethod"
            },
            "params": {
              "$ref": "#/definitions/ThreadRealtimeTranscriptDoneNotification"
            }
          },
          "title": "Thread/realtime/transcript/doneNotification"
        },
        {
          "type": "object",
          "required": [
            "method",
            "params"
          ],
          "properties": {
            "method": {
              "type": "string",
              "enum": [
                "thread/realtime/outputAudio/delta"
              ],
              "title": "Thread/realtime/outputAudio/deltaNotificationMethod"
            },
            "params": {
              "$ref": "#/definitions/ThreadRealtimeOutputAudioDeltaNotification"
            }
          },
          "title": "Thread/realtime/outputAudio/deltaNotification"
        },
        {
          "type": "object",
          "required": [
            "method",
            "params"
          ],
          "properties": {
            "method": {
              "type": "string",
              "enum": [
                "thread/realtime/sdp"
              ],
              "title": "Thread/realtime/sdpNotificationMethod"
            },
            "params": {
              "$ref": "#/definitions/ThreadRealtimeSdpNotification"
            }
          },
          "title": "Thread/realtime/sdpNotification"
        },
        {
          "type": "object",
          "required": [
            "method",
            "params"
          ],
          "properties": {
            "method": {
              "type": "string",
              "enum": [
                "thread/realtime/error"
              ],
              "title": "Thread/realtime/errorNotificationMethod"
            },
            "params": {
              "$ref": "#/definitions/ThreadRealtimeErrorNotification"
            }
          },
          "title": "Thread/realtime/errorNotification"
        },
        {
          "type": "object",
          "required": [
            "method",
            "params"
          ],
          "properties": {
            "method": {
              "type": "string",
              "enum": [
                "thread/realtime/closed"
              ],
              "title": "Thread/realtime/closedNotificationMethod"
            },
            "params": {
              "$ref": "#/definitions/ThreadRealtimeClosedNotification"
            }
          },
          "title": "Thread/realtime/closedNotification"
        },
        {
          "description": "Notifies the user of world-writable directories on Windows, which cannot be protected by the sandbox.",
          "type": "object",
          "required": [
            "method",
            "params"
          ],
          "properties": {
            "method": {
              "type": "string",
              "enum": [
                "windows/worldWritableWarning"
              ],
              "title": "Windows/worldWritableWarningNotificationMethod"
            },
            "params": {
              "$ref": "#/definitions/WindowsWorldWritableWarningNotification"
            }
          },
          "title": "Windows/worldWritableWarningNotification"
        },
        {
          "type": "object",
          "required": [
            "method",
            "params"
          ],
          "properties": {
            "method": {
              "type": "string",
              "enum": [
                "windowsSandbox/setupCompleted"
              ],
              "title": "WindowsSandbox/setupCompletedNotificationMethod"
            },
            "params": {
              "$ref": "#/definitions/WindowsSandboxSetupCompletedNotification"
            }
          },
          "title": "WindowsSandbox/setupCompletedNotification"
        },
        {
          "type": "object",
          "required": [
            "method",
            "params"
          ],
          "properties": {
            "method": {
              "type": "string",
              "enum": [
                "account/login/completed"
              ],
              "title": "Account/login/completedNotificationMethod"
            },
            "params": {
              "$ref": "#/definitions/AccountLoginCompletedNotification"
            }
          },
          "title": "Account/login/completedNotification"
        }
      ]
    }
  }
}