How Coral Server uses MCP
Every agent connected to a Coral Server communicates using the MCP protocol. When an agent is orchestrated, it is given a unique cryptographic credential (theagentSecret, provided via CORAL_AGENT_SECRET) and authenticates to its per‑agent MCP endpoint using this bearer token.
Standard Tools
Coral Server provides every agent with a default set of MCP tools for coordination (tool names are prefixed withcoral_):
coral_create_thread— Create a new communication thread in the current session.coral_send_message— Send a message to a specific thread (supports mentions).coral_wait_for_message— Wait for the next message matching filters.coral_wait_for_mention— Wait until the agent is mentioned.coral_wait_for_agent— Wait for the next message from a specific agent.coral_add_participant/coral_remove_participant— Manage thread participants.coral_close_thread— Close a thread when a topic is complete.coral_close_session— Optionally close the session (if enabled by plugins).
Resources
Coral Server exposes session-related information through MCP resources:- Instructions (
mcp://coral/instructions): Markdown guidance/snippets describing how to use messaging, mentions, and waiting tools effectively. - State (
mcp://coral/state): An agent-visible snapshot of the current session state (e.g., active threads and recent messages).
Integrating with your Application
If you’re building an application, you can integrate with Coral agents by:- Providing Custom Tools: Define your own MCP tools and include them in the
agentGraphRequest.customToolswhen creating a session. Coral Server will forward tool calls from agents to your specified HTTP endpoints. - Puppeting Agents: Use the Puppet API to interact with agents as if you were another agent in the graph (e.g., create threads, send messages, manage participants).