API discovery: Pydantic AI’s MCP client documentation is a practical public API source for teams whose agent calls MCP servers through MCPToolset. A fresh compatibility change adds FastMCP 4 and MCP SDK v2 alongside FastMCP 3, including a small layer that understands the v1 wire spelling and v2 snake-case field names.
Try it
Use it to keep a read-only “release-room” agent alive while a team upgrades an internal MCP service: expose one harmless tool that returns a release note or deployment status, let the agent turn that structured result into a plain-language handoff, then compare the v3 and v4 paths. The useful output is not merely “connected.” It is a feature map: does the server direct tasks, does the client need the task extension, and are sampling, elicitation, and logging assumptions still valid?
Copy-paste agent instruction
Inspect this Python service for every MCPToolset and FastMCP dependency. Create a disposable, read-only contract test against one harmless MCP tool. Record the installed FastMCP and MCP SDK versions, then test tool discovery, one ordinary call, task behavior, and any configured sampling, elicitation, or log_level option. If the service moves to FastMCP 4, flag features that use its modern protocol and install the mcp-tasks extra only when the code explicitly uses the tasks extension. Do not test with production credentials or write-capable tools.
Test caveat
FastMCP 4 is documented here as a preview, not a promise that every MCP feature is equivalent. Its modern protocol does not support server-initiated sampling or elicitation and cannot apply log_level; task behavior also differs from FastMCP 3. A passing client connection cannot certify the server’s authentication, availability, version mix, or task implementation. Use disposable credentials and a read-only test surface before treating the bridge as production-ready.