mirror of
https://github.com/openai/codex.git
synced 2026-04-26 07:35:29 +00:00
Add initialize-time server request capabilities so app-server only sends conversational permission confirmation requests to clients that advertise support. Unsupported clients still fail closed without changing permissions, while capable clients receive the existing request/response flow for narrow grants and preset picker requests.
85 lines
2.0 KiB
JSON
85 lines
2.0 KiB
JSON
{
|
|
"$schema": "http://json-schema.org/draft-07/schema#",
|
|
"definitions": {
|
|
"ClientInfo": {
|
|
"properties": {
|
|
"name": {
|
|
"type": "string"
|
|
},
|
|
"title": {
|
|
"type": [
|
|
"string",
|
|
"null"
|
|
]
|
|
},
|
|
"version": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"required": [
|
|
"name",
|
|
"version"
|
|
],
|
|
"type": "object"
|
|
},
|
|
"InitializeCapabilities": {
|
|
"description": "Client-declared capabilities negotiated during initialize.",
|
|
"properties": {
|
|
"experimentalApi": {
|
|
"default": false,
|
|
"description": "Opt into receiving experimental API methods and fields.",
|
|
"type": "boolean"
|
|
},
|
|
"optOutNotificationMethods": {
|
|
"description": "Exact notification method names that should be suppressed for this connection (for example `thread/started`).",
|
|
"items": {
|
|
"type": "string"
|
|
},
|
|
"type": [
|
|
"array",
|
|
"null"
|
|
]
|
|
},
|
|
"supportedServerRequests": {
|
|
"description": "Server request methods this connection knows how to render and answer.",
|
|
"items": {
|
|
"$ref": "#/definitions/SupportedServerRequestMethod"
|
|
},
|
|
"type": [
|
|
"array",
|
|
"null"
|
|
]
|
|
}
|
|
},
|
|
"type": "object"
|
|
},
|
|
"SupportedServerRequestMethod": {
|
|
"description": "Server-initiated request methods a client can opt into during initialize.",
|
|
"enum": [
|
|
"item/permissions/requestApproval",
|
|
"item/permissionPreset/requestApproval"
|
|
],
|
|
"type": "string"
|
|
}
|
|
},
|
|
"properties": {
|
|
"capabilities": {
|
|
"anyOf": [
|
|
{
|
|
"$ref": "#/definitions/InitializeCapabilities"
|
|
},
|
|
{
|
|
"type": "null"
|
|
}
|
|
]
|
|
},
|
|
"clientInfo": {
|
|
"$ref": "#/definitions/ClientInfo"
|
|
}
|
|
},
|
|
"required": [
|
|
"clientInfo"
|
|
],
|
|
"title": "InitializeParams",
|
|
"type": "object"
|
|
} |