[router] add mcp list and mcp call in output array (#11112)
This commit is contained in:
@@ -797,6 +797,17 @@ pub enum ResponseReasoningContent {
|
||||
ReasoningText { text: String },
|
||||
}
|
||||
|
||||
/// MCP Tool information for the mcp_list_tools output item
|
||||
#[derive(Debug, Clone, Deserialize, Serialize)]
|
||||
pub struct McpToolInfo {
|
||||
pub name: String,
|
||||
#[serde(skip_serializing_if = "Option::is_none")]
|
||||
pub description: Option<String>,
|
||||
pub input_schema: Value,
|
||||
#[serde(skip_serializing_if = "Option::is_none")]
|
||||
pub annotations: Option<Value>,
|
||||
}
|
||||
|
||||
#[derive(Debug, Clone, Deserialize, Serialize)]
|
||||
#[serde(tag = "type")]
|
||||
#[serde(rename_all = "snake_case")]
|
||||
@@ -826,6 +837,25 @@ pub enum ResponseOutputItem {
|
||||
output: Option<String>,
|
||||
status: String,
|
||||
},
|
||||
#[serde(rename = "mcp_list_tools")]
|
||||
McpListTools {
|
||||
id: String,
|
||||
server_label: String,
|
||||
tools: Vec<McpToolInfo>,
|
||||
},
|
||||
#[serde(rename = "mcp_call")]
|
||||
McpCall {
|
||||
id: String,
|
||||
status: String,
|
||||
#[serde(skip_serializing_if = "Option::is_none")]
|
||||
approval_request_id: Option<String>,
|
||||
arguments: String,
|
||||
#[serde(skip_serializing_if = "Option::is_none")]
|
||||
error: Option<String>,
|
||||
name: String,
|
||||
output: String,
|
||||
server_label: String,
|
||||
},
|
||||
}
|
||||
|
||||
#[derive(Debug, Clone, Deserialize, Serialize)]
|
||||
|
||||
Reference in New Issue
Block a user