mirror of
https://github.com/openai/codex.git
synced 2026-11-25 15:24:26 +00:00
Include connector IDs in MCP tool call analytics (#32867)
## What changed - Add the optional `connector_id` to `codex_mcp_tool_call_event` parameters. - Populate it from the MCP tool call's `app_context` when available. ## Testing - Extend the completed tool item analytics test to verify the connector ID is serialized. GitOrigin-RevId: ea62202318dd492fa0ffd4ff1d48a66d1cc37e96
This commit is contained in:
1 parent
6e113acf5f
commit
bbfa08fe3b
3 files changed
+18
-1
No files matched your search
@@ -1884,6 +1884,7 @@ fn tool_item_event(input: ToolItemEventInput<'_>) -> Option<TrackEventRequest> {
|
||||
error,
|
||||
duration_ms,
|
||||
plugin_id,
|
||||
app_context,
|
||||
..
|
||||
} => {
|
||||
let (terminal_status, failure_kind) = mcp_tool_call_outcome(status)?;
|
||||
@@ -1915,6 +1916,9 @@ fn tool_item_event(input: ToolItemEventInput<'_>) -> Option<TrackEventRequest> {
|
||||
mcp_tool_name: tool.clone(),
|
||||
mcp_error_present: error.is_some(),
|
||||
plugin_id: plugin_id.clone(),
|
||||
connector_id: app_context
|
||||
.as_ref()
|
||||
.map(|app_context| app_context.connector_id.clone()),
|
||||
},
|
||||
},
|
||||
))
|
||||
|
||||
Reference in new issue
Block a user