MCP server (Streamable HTTP)
Custral’s Model Context Protocol server, over the Streamable HTTP transport, stateless. Point an MCP client (Claude, Cursor, …) at this URL rather than calling it by hand. Send JSON-RPC 2.0 with Accept: application/json, text/event-stream; the reply streams back as server-sent events. The tools offered depend on the key’s scopes (GET /v1/mcp/tools lists them without the handshake). Requires scope: mcp:read, plus each tool’s resource scope; writes also need mcp:write. Unlike the rest of /v1, this endpoint answers auth failures with real HTTP status codes, because MCP clients expect them.
Authorizations
A Custral API key, created in Settings → Developers → Applications, sent as Authorization: Bearer sk_…. The X-Api-Key header is also accepted and takes precedence. Use a secret key (sk_…) from your server; a publishable key (pk_…) may hold only objects:read and usage:write. Never expose a secret key in a browser.