MCP endpoint

POST/api/mcp

Memtro as a stateless Streamable HTTP MCP server: memory and connector tools for any MCP client.

Open Memtro

Memtro is a Model Context Protocol server at https://platform.memtro.com/api/mcp: memory tools and every connector tool the key can use, as the key's holder. This page is the endpoint's transport facts; the MCP server guide has client setup, and the Tools reference every tool.

The transport is Streamable HTTP, stateless, with JSON responses rather than an event stream: each request is complete in itself, with no session to keep. POST, GET and DELETE are all answered by the same handler. A request may run for up to two minutes.

Example

Against https://platform.memtro.com, with your key in MEMTRO_API_KEY.

curl "https://platform.memtro.com/api/mcp?tools=memory" \
  -H "Authorization: Bearer $MEMTRO_API_KEY" \
  -H "Content-Type: application/json" \
  -H "Accept: application/json, text/event-stream" \
  -d '{"jsonrpc": "2.0", "id": 1, "method": "initialize", "params": {"protocolVersion": "2025-06-18", "capabilities": {}, "clientInfo": {"name": "curl", "version": "1"}}}'

A refused key: JSON-RPC, not the OpenAI envelope.

{ "jsonrpc": "2.0", "error": { "code": -32001, "message": "Invalid or revoked API key" }, "id": null }

Authentication

An API key, as Authorization: Bearer or x-api-key. A tool narrowing stored on the key applies, and the query string can only narrow further.

  • This route sets no request id header.

Query parameters

toolsstringOptional

memory serves the memtro_* tools alone.

One of memory, all or true.

actionsstringOptional

none drops every tool that changes anything.

One of none, false, all or true.

connectorsstringOptional

A comma-separated list of connector kinds, such as xero,github: only those systems' tools.

shapestringOptional

system: one tool per connected system; operation: one tool per operation. A key can store its own default.

One of system or operation.

Default:

system

Request body

A JSON-RPC 2.0 message, as the MCP specification defines.

Response

200application/json

The JSON-RPC response the MCP specification defines.

Errors

As a JSON-RPC error, {"jsonrpc": "2.0", "error": {"code", "message"}, "id": null}, with the HTTP status set.

StatusJSON-RPC codeWhen
401-32001

The key is missing, malformed, revoked or expired. The reply carries WWW-Authenticate: Bearer realm="memtro".

402-32001

The organisation has no active subscription.

Notes

A value the server does not recognise in the query string (?tools=everything, an unknown connector) is not refused: it is reported in the server's instructions, where the client will read it. An unknown tools, actions or shape value leaves that setting at its default; an unknown connector is left out, so a connectors list naming none that exist serves no connector tools.

Where agents remember your company

Sign in, add a provider key, create an API key and point your tools at Memtro. It takes about five minutes.

7-day free trial · card on file, nothing charged until it ends · cancel any time