API reference · MCP
MCP server
Your workspace as a Model Context Protocol server (JSON-RPC 2.0 over HTTP). Point any AI assistant or MCP client at it with an API key.
A key sees only the tools its scopes allow. With no scopes the server is read-only.
Request
curl -X POST "https://icebot.icebergaisolutions.com/api/mcp" \
-H "Authorization: Bearer $ICEBOT_API_KEY" \
-H "Content-Type: application/json" \
-d '{"jsonrpc":"2.0","id":1,"method":"tools/call","params":{"name":"list_conversations","arguments":{"limit":5,"status":"open"}}}'Body
| Field | Type | Description |
|---|---|---|
jsonrpc (required) | "2.0" | JSON-RPC version. |
id | string | number | Omit for a notification. |
method (required) | initialize | tools/list | tools/call | ping | The MCP method. |
params | object | For tools/call: { name, arguments }. |
{
"jsonrpc": "2.0",
"id": 1,
"method": "tools/call",
"params": {
"name": "list_conversations",
"arguments": {
"limit": 5,
"status": "open"
}
}
}Responses
200
A JSON-RPC response. Tool output is JSON inside a text content block.
{
"jsonrpc": "2.0",
"id": 1,
"result": {
"content": [
{
"type": "text",
"text": "{\"conversations\":[{\"id\":\"6f1c2a90-3b7e-4d55-9a1e-2c8f0b7d4e11\",\"channel\":\"whatsapp\",\"status\":\"open\"}]}"
}
]
}
}Errors
Every endpoint can also return 401 (missing, unknown or revoked key), 403 (origin not allowed) and 429 (rate limited). See Errors.
| Status | error | When |
|---|---|---|
200 | JSON-RPC error object | Unknown method (-32601), bad params (-32602) or a tool the key lacks the scope for (a tool error naming the scope). |
Source of truth: /api/mcp in apps/dashboard/app/api/mcp/route.ts.