mirror of
https://github.com/openai/codex.git
synced 2026-09-10 20:26:47 +00:00
## Why An empty tool map does not distinguish a successfully returned empty catalog from a server whose startup or tool discovery failed. ## What changed - Add nullable `toolsError` to each `mcpServerStatus/list` entry when no catalog is available because startup or tool discovery failed. - Keep `toolsError` null for returned catalogs, including cached and empty catalogs, and continue returning healthy servers when another server fails. - Update the protocol schemas and generated TypeScript type. ## Testing - Extend the app-server status integration test with a broken MCP server and verify its error without losing the healthy server's inventory. GitOrigin-RevId: 30b4ca4d9a45cec6998f5f626d3fddbee90a525d
279 lines
5.7 KiB
JSON
Generated
279 lines
5.7 KiB
JSON
Generated
{
|
|
"$schema": "http://json-schema.org/draft-07/schema#",
|
|
"definitions": {
|
|
"McpAuthStatus": {
|
|
"enum": [
|
|
"unknown",
|
|
"unsupported",
|
|
"notLoggedIn",
|
|
"bearerToken",
|
|
"oAuth"
|
|
],
|
|
"type": "string"
|
|
},
|
|
"McpServerConnectionStatus": {
|
|
"enum": [
|
|
"notStarted",
|
|
"starting",
|
|
"connected",
|
|
"authenticationRequired",
|
|
"failed",
|
|
"cancelled",
|
|
"disabled"
|
|
],
|
|
"type": "string"
|
|
},
|
|
"McpServerInfo": {
|
|
"description": "Presentation metadata advertised by an initialized MCP server.",
|
|
"properties": {
|
|
"description": {
|
|
"type": [
|
|
"string",
|
|
"null"
|
|
]
|
|
},
|
|
"icons": {
|
|
"items": true,
|
|
"type": [
|
|
"array",
|
|
"null"
|
|
]
|
|
},
|
|
"name": {
|
|
"type": "string"
|
|
},
|
|
"title": {
|
|
"type": [
|
|
"string",
|
|
"null"
|
|
]
|
|
},
|
|
"version": {
|
|
"type": "string"
|
|
},
|
|
"websiteUrl": {
|
|
"type": [
|
|
"string",
|
|
"null"
|
|
]
|
|
}
|
|
},
|
|
"required": [
|
|
"name",
|
|
"version"
|
|
],
|
|
"type": "object"
|
|
},
|
|
"McpServerStatus": {
|
|
"properties": {
|
|
"authStatus": {
|
|
"$ref": "#/definitions/McpAuthStatus"
|
|
},
|
|
"name": {
|
|
"type": "string"
|
|
},
|
|
"pluginId": {
|
|
"type": [
|
|
"string",
|
|
"null"
|
|
]
|
|
},
|
|
"resourceTemplates": {
|
|
"items": {
|
|
"$ref": "#/definitions/ResourceTemplate"
|
|
},
|
|
"type": "array"
|
|
},
|
|
"resources": {
|
|
"items": {
|
|
"$ref": "#/definitions/Resource"
|
|
},
|
|
"type": "array"
|
|
},
|
|
"runtimeStatus": {
|
|
"anyOf": [
|
|
{
|
|
"$ref": "#/definitions/McpServerConnectionStatus"
|
|
},
|
|
{
|
|
"type": "null"
|
|
}
|
|
],
|
|
"description": "Current thread-runtime connection state; null when unavailable or the configuration changed."
|
|
},
|
|
"serverInfo": {
|
|
"anyOf": [
|
|
{
|
|
"$ref": "#/definitions/McpServerInfo"
|
|
},
|
|
{
|
|
"type": "null"
|
|
}
|
|
]
|
|
},
|
|
"tools": {
|
|
"additionalProperties": {
|
|
"$ref": "#/definitions/Tool"
|
|
},
|
|
"type": "object"
|
|
},
|
|
"toolsError": {
|
|
"description": "Tool discovery failed and no catalog was returned. Null when a catalog is returned, including cached or empty catalogs.",
|
|
"type": [
|
|
"string",
|
|
"null"
|
|
]
|
|
}
|
|
},
|
|
"required": [
|
|
"authStatus",
|
|
"name",
|
|
"resourceTemplates",
|
|
"resources",
|
|
"tools"
|
|
],
|
|
"type": "object"
|
|
},
|
|
"Resource": {
|
|
"description": "A known resource that the server is capable of reading.",
|
|
"properties": {
|
|
"_meta": true,
|
|
"annotations": true,
|
|
"description": {
|
|
"type": [
|
|
"string",
|
|
"null"
|
|
]
|
|
},
|
|
"icons": {
|
|
"items": true,
|
|
"type": [
|
|
"array",
|
|
"null"
|
|
]
|
|
},
|
|
"mimeType": {
|
|
"type": [
|
|
"string",
|
|
"null"
|
|
]
|
|
},
|
|
"name": {
|
|
"type": "string"
|
|
},
|
|
"size": {
|
|
"format": "int64",
|
|
"type": [
|
|
"integer",
|
|
"null"
|
|
]
|
|
},
|
|
"title": {
|
|
"type": [
|
|
"string",
|
|
"null"
|
|
]
|
|
},
|
|
"uri": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"required": [
|
|
"name",
|
|
"uri"
|
|
],
|
|
"type": "object"
|
|
},
|
|
"ResourceTemplate": {
|
|
"description": "A template description for resources available on the server.",
|
|
"properties": {
|
|
"annotations": true,
|
|
"description": {
|
|
"type": [
|
|
"string",
|
|
"null"
|
|
]
|
|
},
|
|
"mimeType": {
|
|
"type": [
|
|
"string",
|
|
"null"
|
|
]
|
|
},
|
|
"name": {
|
|
"type": "string"
|
|
},
|
|
"title": {
|
|
"type": [
|
|
"string",
|
|
"null"
|
|
]
|
|
},
|
|
"uriTemplate": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"required": [
|
|
"name",
|
|
"uriTemplate"
|
|
],
|
|
"type": "object"
|
|
},
|
|
"Tool": {
|
|
"description": "Definition for a tool the client can call.",
|
|
"properties": {
|
|
"_meta": true,
|
|
"annotations": true,
|
|
"description": {
|
|
"type": [
|
|
"string",
|
|
"null"
|
|
]
|
|
},
|
|
"icons": {
|
|
"items": true,
|
|
"type": [
|
|
"array",
|
|
"null"
|
|
]
|
|
},
|
|
"inputSchema": true,
|
|
"name": {
|
|
"type": "string"
|
|
},
|
|
"outputSchema": true,
|
|
"title": {
|
|
"type": [
|
|
"string",
|
|
"null"
|
|
]
|
|
}
|
|
},
|
|
"required": [
|
|
"inputSchema",
|
|
"name"
|
|
],
|
|
"type": "object"
|
|
}
|
|
},
|
|
"properties": {
|
|
"data": {
|
|
"items": {
|
|
"$ref": "#/definitions/McpServerStatus"
|
|
},
|
|
"type": "array"
|
|
},
|
|
"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"
|
|
]
|
|
}
|
|
},
|
|
"required": [
|
|
"data"
|
|
],
|
|
"title": "ListMcpServerStatusResponse",
|
|
"type": "object"
|
|
} |