Drive KubeMQ from an LLM
Orchestrate durable messaging and A2A agents from an LLM over MCP in a single session — the end-to-end fabric in action.
KubeMQ must be running — see the Quickstart (steps 1–2 get you there; instant if it's already up).
The MCP gateway is already live on http://localhost:9090/mcp — no enable step. Once an
MCP host is pointed at it and at least one agent is registered, the same conversation can
enqueue durable work and call an agent — messaging and agents, one fabric, one session.
Two quick prerequisites
If you haven't done these yet: connect an MCP host
to http://localhost:9090/mcp, and register an agent
for it to call. Both take a couple of minutes.
1 · One prompt, two tool calls
Ask your connected LLM host something that needs both capabilities, for example:
"Enqueue order 1042 for the fulfillment worker, then ask the order-status agent for an ETA."
The host resolves that into two MCP tool calls against the same /mcp session — one
against KubeMQ's durable queue, one against the agent bridge:
{ "name": "queue_send", "arguments": { "channel": "orders", "body": "{\"id\":1042}" } }{ "name": "agent_send", "arguments": { "agent_id": "order-status-agent", "message": "What is the ETA for order 1042?" } }2 · Verify
You should see two results come back in the conversation, both round-tripped through the same MCP session — no separate connection, no glue code.
Expected result
queue_send returns the MCP queue envelope with a generated message ID (and the
orders channel ticks in the dashboard):
{
"content": [
{ "type": "text", "text": "{\"message_id\":\"a1b2c3...\",\"sent_at\":\"2026-06-08T10:00:00Z\",\"is_error\":false}" }
],
"isError": false
}agent_send returns the order-status agent's reply, bridged from its A2A response:
{
"content": [
{ "type": "text", "text": "{\"status\":\"in-transit\",\"eta\":\"2 days\"}" }
],
"isError": false
}Didn't work?
- MCP host has no tools — confirm it completed the
initializehandshake againsthttp://localhost:9090/mcp; see Connect an MCP host. agent_sendreturns "Agent not found" — register the agent first; theagent_idmust match exactly.queue_sendreturns a-32602error — the channel name starts with the reserved_AGENTS_.prefix, orchannel/bodyis missing.
Go deeper
Was this page helpful?