Melious
Tools

MCP

Connect MCP-compatible agents to Melious tools over the Model Context Protocol

Melious speaks the Model Context Protocol, so an MCP-compatible client — Claude Desktop, a custom agent, anything that talks the protocol — can discover and run our tools without any Melious-specific glue. It's the same tools as the Tools API, reached over MCP instead of plain REST.

Base path: /v1/mcp Auth: Bearer token or x-api-key. Requires scope kit.mcp.

Two transports

  • JSON-RPC (POST /v1/mcp/jsonrpc) — the standard MCP transport. This is what MCP clients expect; use it unless you have a reason not to.
  • REST (/v1/mcp/initialize, /v1/mcp/tools/list, /v1/mcp/tools/call) — a plain-HTTP convenience surface for hand-rolled clients that don't want to wrap JSON-RPC.

Both expose the same tools and return the same content shapes. The endpoints:

MethodPathWhat it does
POST/v1/mcp/jsonrpcJSON-RPC 2.0 transport (initialize, tools/list, tools/call, ping)
POST/v1/mcp/initializeREST: start a session
POST/v1/mcp/tools/listREST: list tools
POST/v1/mcp/tools/callREST: run a tool
GET/v1/mcp/pingHealth check
GET/v1/mcp/sseServer-Sent Events stream

Connect Claude Desktop

Claude Desktop connects to a remote MCP server through the mcp-remote bridge, which handles the transport and forwards your auth header. Add this to your config:

  • macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
  • Windows: %APPDATA%\Claude\claude_desktop_config.json
claude_desktop_config.json
{
  "mcpServers": {
    "melious": {
      "command": "npx",
      "args": [
        "-y", "mcp-remote",
        "https://api.melious.ai/v1/mcp/jsonrpc",
        "--header", "Authorization: Bearer sk-mel-<YOUR_API_KEY>"
      ]
    }
  }
}

Your API key sits in this file in plaintext. Don't commit it. Treat the config like any other secret-bearing dotfile.

Restart Claude Desktop and the Melious tools show up in its tool list.

JSON-RPC transport

Standard JSON-RPC 2.0. List the tools:

{
  "jsonrpc": "2.0",
  "id": 1,
  "method": "tools/list",
  "params": {}
}

Call one:

{
  "jsonrpc": "2.0",
  "id": 2,
  "method": "tools/call",
  "params": {
    "name": "web-search",
    "arguments": { "query": "Hanseatic League history" }
  }
}

The result wraps tool output in MCP content blocks:

{
  "jsonrpc": "2.0",
  "id": 2,
  "result": {
    "content": [{ "type": "text", "text": "[{\"title\": \"...\", \"url\": \"...\"}]" }],
    "isError": false
  }
}

initialize and ping work as the spec describes. initialize takes protocolVersion, capabilities, and clientInfo, and returns the server's capabilities and serverInfo.

REST transport

If you'd rather not wrap JSON-RPC, the REST endpoints do the same work. Note the REST initialize uses snake_case fields (protocol_version, client_info), unlike the JSON-RPC transport:

curl https://api.melious.ai/v1/mcp/initialize \
  -H "Authorization: Bearer sk-mel-<YOUR_API_KEY>" \
  -H "Content-Type: application/json" \
  -d '{
    "protocol_version": "2024-11-05",
    "capabilities": { "tools": {} },
    "client_info": { "name": "my-agent", "version": "1.0.0" }
  }'

List and call follow the same pattern. POST /v1/mcp/tools/list (optional {"cursor": "..."} for pagination) returns {"tools": [{"name", "description", "inputSchema"}]}. POST /v1/mcp/tools/call takes {"name", "arguments"} and returns {"content", "isError"}.

curl https://api.melious.ai/v1/mcp/tools/call \
  -H "Authorization: Bearer sk-mel-<YOUR_API_KEY>" \
  -H "Content-Type: application/json" \
  -d '{"name": "web-search", "arguments": {"query": "Hanseatic League history"}}'

The SSE stream

GET /v1/mcp/sse is a persistent Server-Sent Events stream for clients that use the SSE transport. It needs the Authorization header like every other endpoint — which means a browser EventSource won't work, since browsers can't set custom headers on it. Use an MCP client, the mcp-remote bridge above, or a server-side SSE reader that can send the header.

Available tools

The same tools as the Tools API — web search, URL scraping, and the documentation lookups (Context7, Microsoft Learn, Svelte). Call tools/list for the live set with current schemas. Document conversion isn't exposed over MCP; it takes file uploads, which the protocol's JSON tool-call shape doesn't carry.

Errors

JSON-RPC errors come back in the standard error member with a Melious code in data. REST errors use the usual {"error": {"code", "message"}} shape:

  • KIT_6150 — malformed MCP request.
  • KIT_6151 — unknown method.
  • KIT_6152 — tool not found.
  • KIT_6153 — invalid URL argument (for tools that take one).
  • KIT_6053 — tool rate limit hit.
  • AUTH_1015 — key is missing the kit.mcp scope.

Tools API for the same tools over plain REST • Tool calling for letting a chat model drive tools directly.

On this page