MCP Vertex AI: Google Cloud Integration
Calling MCP tools from models hosted on Vertex AI, and where Google's function-calling model diverges from native MCP.
Vertex AI doesn't speak MCP natively, but Gemini models on Vertex support function calling, which a thin adapter can map to your MCP server's tools/list and tools/call methods.
Building the Adapter
On startup, fetch your MCP server's tool schemas and translate them into Vertex's FunctionDeclaration format. When Vertex returns a function call, forward it as a tools/call JSON-RPC request and relay the result back as the function response.
Where It Diverges
Vertex has no equivalent to MCP resources or prompts — only tool calling maps cleanly. If your server leans on resource templates for context injection, you'll need to fold that data into the tool response instead.