[codex] preserve MCP result meta in McpToolCallItemResult (#22946)

## Summary

https://openai.slack.com/archives/C0ARA9UAQEA/p1778890981647319?thread_ts=1778888537.934319&cid=C0ARA9UAQEA


- Add `_meta` to exec JSONL MCP tool call result events.
- Copy MCP result metadata through the JSONL event conversion.
- Add a focused test that verifies `_meta` is serialized as `_meta` and
not `meta`.


## Verification

https://www.notion.so/openai/Miaolin-0516-_meta-population-debug-3628e50b62b08074b365e0ce1ffb8f74
This commit is contained in:
Miaolin Min
2026-05-16 13:27:44 -07:00
committed by GitHub
parent b200dd1b6f
commit 6941f5c2c5
5 changed files with 58 additions and 0 deletions
+1
View File
@@ -60,6 +60,7 @@ export type McpToolCallItem = {
/** Result payload returned by the MCP server for successful calls. */
result?: {
content: McpContentBlock[];
_meta?: unknown;
structured_content: unknown;
};
/** Error message reported for failed calls. */