
Easily turn any gRPC service into an MCP server
Meet our open-source compiler plugin that generates Model Context Protocol (MCP) servers for your gRPC or ConnectRPC APIs

Modern SaaS companies spend a lot of time designing, building, and maintaining APIs across SDKs, CLI tools, and now, LLM integrations. With the rise of the Model Context Protocol (MCP), AI-native interfaces like Claude or Cursor are becoming real API consumers.
This post demonstrates how teams already using gRPC can expose their APIs via MCP with minimal additional effort, thanks to an open-source codegen plugin and a small integration layer — courtesy of Redpanda. Here’s what this new tooling can do:
- Auto-generate MCP handlers from your
.proto
services - Output JSON Schema for method inputs
- Wire up to gRPC or ConnectRPC servers/clients
- Easily integrate with Buf
If you're building tools for AI agents or just want to future-proof your platform, read on. (If you'd rather just skip to the code, here's the GitHub repo.)
What is Model Context Protocol (MCP)?
Model Context Protocol (MCP), introduced by Anthropic in November 2024, is a new protocol designed for building large language model (LLM) tools with structured inputs.
MCP is split into two parts: client and server.
- The client is the actual application you use. For example, Claude desktop or an AI agent.
- The server is basically a plugin. The client interacts with the server to call tools or read resources.
An MCP tool can do everything, such as calling a Redis database for a key-value lookup, or call Redpanda Cloud to create a Redpanda cluster or update its configuration.
In short: MCP clients can use MCP servers to interact with the world.
gRPC and ConnectRPC
gRPC and ConnectRPC are strongly-typed RPC/API frameworks built on Protocol buffers. The superpower of gRPC is its bottom-up definition of API contracts with Protobuf and its excellent support for code generation.
At Redpanda Cloud, we use gRPC and ConnectRPC to build and serve our APIs. It allows us to iterate quickly, where Server and Client stubs are automatically generated and work across programming languages.
Meet the compiler: turn any gRPC service into an MCP server
In case you missed it, Redpanda is evolving into an AI-native platform for data streaming and Agentic AI. Our goal: make it as easy as possible for AI agents and apps (like Claude Desktop) to interact with our APIs.
However, it would be a lot of work to write all the code by hand that wraps our API and makes it available via MCP. It’s not just a one-off job either, since APIs evolve continuously. Luckily, we use gRPC, which is code-generation first. Can we simply write a protoc plugin that does all the wiring and mapping? Of course we can!
Introducing protoc-gen-go-mcp
— open-sourced under Apache 2.0 and ready to generate MCP servers for your gRPC or ConnectRPC APIs. It’s essentially a Protocol Buffers compiler plugin that generates Go code to translate between MCP and gRPC. Since gRPC has a rich schema (Protobuf descriptors) and generation ecosystem (protogen), it’s the perfect match.

Starting with the Protobuf API definition, protoc-gen-go-mcp
generates a *.pb.mcp.go
for every gRPC Service. This code is built to integrate with Go MCP Libraries. Currently, we support mcp-go.
Example: automatically generating an MCP server
The following code demonstrates how easily the compiler translates MCP to gRPC, saving us a ton of time. We have a struct that holds all our gRPC client stubs:
type CloudClientSet struct {
Region controlplanev1connect.RegionServiceClient
Cluster controlplanev1connect.ClusterServiceClient
Network controlplanev1connect.NetworkServiceClient
Organization iamv1connect.OrganizationServiceClient
ResourceGroup controlplanev1connect.ResourceGroupServiceClient
Serverless controlplanev1connect.ServerlessClusterServiceClient
Operation controlplanev1connect.OperationServiceClient
ServerlessRegion controlplanev1connect.ServerlessRegionServiceClient
}
The generated code provides functions to wire these up with the MCP server:
controlplanev1mcp.ForwardToConnectRegionServiceClient(s, cl.Region)
controlplanev1mcp.ForwardToConnectResourceGroupServiceClient(s, cl.ResourceGroup)
controlplanev1mcp.ForwardToConnectClusterServiceClient(s, cl.Cluster)
controlplanev1mcp.ForwardToConnectNetworkServiceClient(s, cl.Network)
controlplanev1mcp.ForwardToConnectServerlessClusterServiceClient(s, cl.Serverless)
controlplanev1mcp.ForwardToConnectServerlessRegionServiceClient(s, cl.ServerlessRegion)
controlplanev1mcp.ForwardToConnectOperationServiceClient(s, cl.Operation)
controlplanev1mcp.ForwardToConnectServerlessRegionServiceClient(s, cl.ServerlessRegion)
controlplanev1mcp.ForwardToConnectServerlessRegionServiceClient(s, cl.ServerlessRegion)
That’s it! All translation between MCP and gRPC is performed in the generated controlplanev1mcp
package and strongly-typed, based on Protobuf semantics.
Check out the example in this Redpanda GitHub repository. You can also see how we use it ourselves within rpk
.
See it in action: Install Redpanda Cloud MCP on Claude Desktop
Redpanda Cloud now provides an MCP server, offering direct integration with LLMs. And it’s all powered by protoc-gen-go-mcp
.
As of April 2025, the most common method for implementing MCP is via stdio, where the MCP client spawns the MCP server as a subprocess and uses stdin/stdout to interact with it. HTTP support (“SSE mode”) exists, but adoption is tiny. The most popular MCP Client - Claude Desktop, only supports stdio mode. So, Redpanda Cloud focuses on stdio mode for now.

Redpanda’s CLI, rpk
, facilitates this process. Users already use rpk
to interact with Redpanda, Redpanda Cloud, and Redpanda Connect. It manages translation between MCP and our API (gRPC), as well as authentication.
Now, let’s walk through how to install the Redpanda Cloud MCP server to your Claude Desktop.
Step 1. Install the MCP server
Prerequisites
- Install an MCP-enabled client, preferably Claude Desktop.
- Install latest version of rpk. The commands shown here are only available from Redpanda version 25.1.2.
Next, run:
rpk cloud mcp install --client claude
This command configures Claude Desktop’s claude_desktop_config.json
to run rpk cloud mcp stdio
and launch the Redpanda Cloud MCP server. After running this command, restart Claude Desktop.
Optional: If you don’t use Claude, but a different client, you can do this setup manually, by patching the following JSON into your config:
{
"mcpServers": {
"redpandaCloud": {
"command": "rpk",
"args": [
"--config",
"<YOUR RPK CONFIG FOLDER>/rpk.yaml",
"cloud",
"mcp",
"stdio"
]
}
}
}
Most MCP clients use a similar configuration. For example, Cursor.
Step 2. Log into Redpanda Cloud with rpk
To authenticate the MCP server with your Cloud account, make sure you’re logged in.
You can do this by running:
rpk cloud login
Step 3. Use Claude to interact with Redpanda Cloud

Claude will show the number of available tools next to the hammer icon. Each tool represents one Redpanda Cloud API endpoint. Clicking on the tools icon shows the names of the available API endpoints.
You can now interact with Redpanda Cloud via Claude! For example, you can create a Serverless cluster, simply by prompting Claude.

As you can see, we automatically make use of the LLM’s reasoning capabilities. One API call failed because the name is already used. It automatically corrected the API call, and then used a different name.
Note: Whenever Claude needs to interact with a tool, it will ask for permission to do so. We recommend using the “Allow once” option and inspecting the tool call and its input. This way, we can make sure the AI does what we want.

Additionally, Redpanda Cloud MCP blocks “Delete” calls by default. This safeguard can be turned off by running the following command:
rpk cloud mcp install --allow-delete
Wrapping up
With protoc-gen-go-mcp
and rpk
, Redpanda Cloud becomes a first-class citizen in the world of LLMs. Not just that — all developers using gRPC can now expose their APIs via MCP, with near-zero effort.
If you’re looking for more tooling like this to improve the AI journey of your SaaS, check out our Redpanda Agentic AI. If you have questions for our engineers, join the Redpanda Community on Slack.
Let's keep in touch
Subscribe and never miss another blog post, announcement, or community event. We hate spam and will never sell your contact information.