litellm/tests/e2e/codex/mcp_server.py
ryan-crabbe-berri 6fa0477d84
test(e2e): add a Codex row that calls a local MCP tool on a first and a resumed turn (#49817)
* test(e2e): add a Codex row that calls a local MCP tool on a first and a resumed turn

* test(e2e): assert the codex mcp row got each value back from the mcp tool call itself

* test(e2e): check the codex mcp row exits cleanly on both turns

* test(e2e): drop the unused content type from the codex mcp result model
2026-11-06 03:59:03 +00:00

19 lines
363 B
Python

from __future__ import annotations
import os
from pathlib import Path
from typing import Final
from mcp.server.mcpserver import MCPServer
server: Final = MCPServer("vault")
@server.tool()
def read_secret() -> str:
"""Return the current secret value."""
return Path(os.environ["SECRET_FILE"]).read_text()
if __name__ == "__main__":
server.run()