Remote MCP

Remote MCP: one URL for every agent

cachly runs a hosted MCP endpoint. Any agent platform that can call a remote MCP server can use your Brain with one URL. You sign in with your cachly account, or you send your API key. You install nothing on your machine.

The short version

  • URL: https://mcp.cachly.dev/mcp
  • Transport: MCP Streamable HTTP.
  • Auth, way 1: sign in with your cachly account (OAuth). This is the way for Claude.ai and ChatGPT, which cannot send a header of your own.
  • Auth, way 2: the HTTP header Authorization: Bearer cky_... with your cachly API key. This is the way for editors, CLIs and frameworks that let you set headers.
  • Both ways open your own Brain.
  • Without either, any client can still connect and read the tool list. Directories such as Glama, Smithery and mcptry use this. Calling a tool always needs one of the two ways.

What we tested: on 19.11.2026 the official MCP TypeScript SDK client connected with an API key (initialize answered 200), and a list_remembered call came back in 0.8 to 1.5 seconds. The sign-in way is new and not yet tested by us in Claude.ai or ChatGPT. The snippets for each platform below come from the vendors' documentation. We have not tried them one by one, and each snippet says so.

If your tool runs on your own machine and supports local servers, the local setup with npx @cachly-dev/mcp-server stays the fuller option. See the MCP tool reference.

Claude.ai and Claude Desktop (sign-in)

Open Settings → Connectors → Add custom connector. Enter https://mcp.cachly.dev/mcp as the URL and save. Claude connects and shows the cachly tools right away. The first time Claude calls one of them, a Connect card appears in the chat. Press it and sign in with your cachly account. Claude then repeats the same tool call. You need no API key and no header.

Which Brain opens: the Brain of your account that is running and was created last. Brains that are paused, still starting, or owned by a team organization are not picked. If your account has no running Brain, the tools tell you so and link to the dashboard.

Team and Enterprise: every member signs in with their own cachly account and gets their own Brain.

Per Anthropic docs, not tested by us. Source

ChatGPT (sign-in)

ChatGPT adds remote MCP servers in developer mode. Turn it on under Settings → Apps → Advanced settings. In Business and Enterprise workspaces an admin has to allow it first. Then create a connector with the URL https://mcp.cachly.dev/mcp and choose OAuth as the authentication. Sign in with your cachly account. The same Brain rule as for Claude applies.

Per OpenAI docs, not tested by us. Source

Get your API key

Sign in to the dashboard and open Setup AI (/setup-ai). Pick your Brain and press Generate key. The key starts with cky_live_. The page shows it once, so copy it right away.

From a terminal, npx @cachly-dev/mcp-server setup signs you in and creates a key too.

Then keep the key in an environment variable. The examples use CACHLY_KEY:

shell
export CACHLY_KEY=cky_live_...

Test it with curl

This sends the first message of an MCP session. A JSON answer with serverInfo means the key and the endpoint work. The Accept header with both types is required by the transport.

curl
curl -sS https://mcp.cachly.dev/mcp \
  -H "Authorization: Bearer $CACHLY_KEY" \
  -H "Content-Type: application/json" \
  -H "Accept: application/json, text/event-stream" \
  -d '{"jsonrpc":"2.0","id":1,"method":"initialize","params":{"protocolVersion":"2025-03-26","capabilities":{},"clientInfo":{"name":"curl-test","version":"0"}}}'

Editors and CLIs

Cursor

File ~/.cursor/mcp.json:

{
  "mcpServers": {
    "cachly": {
      "url": "https://mcp.cachly.dev/mcp",
      "headers": {
        "Authorization": "Bearer ${env:CACHLY_KEY}"
      }
    }
  }
}

Per Cursor docs, not tested by us. Source

VS Code and GitHub Copilot

File .vscode/mcp.json. VS Code asks for the key once and hides it while you type:

{
  "servers": {
    "cachly": {
      "type": "http",
      "url": "https://mcp.cachly.dev/mcp",
      "headers": {
        "Authorization": "Bearer ${input:cachly-key}"
      }
    }
  },
  "inputs": [
    {
      "type": "promptString",
      "id": "cachly-key",
      "description": "cachly API key",
      "password": true
    }
  ]
}

Per VS Code docs, not tested by us. Source

Codex CLI

File ~/.codex/config.toml. Codex reads the token from the variable named in bearer_token_env_var:

[mcp_servers.cachly]
url = "https://mcp.cachly.dev/mcp"
bearer_token_env_var = "CACHLY_KEY"

Per OpenAI docs, not tested by us. Source

Gemini CLI

In settings.json. Use httpUrl, not url: in Gemini CLI, url means the older SSE transport.

{
  "mcpServers": {
    "cachly": {
      "httpUrl": "https://mcp.cachly.dev/mcp",
      "headers": {
        "Authorization": "Bearer cky_..."
      }
    }
  }
}

Per Gemini CLI docs, not tested by us. Source

Workflow tools

n8n

In an AI Agent, add the MCP Client Tool node. Set the endpoint to https://mcp.cachly.dev/mcp and the transport to HTTP Streamable. For authentication choose Bearer and paste your key. Or choose Header Auth with the name Authorization and the value Bearer cky_....

Older n8n versions had a bug that dropped the header. Use a current version.

Per n8n docs, not tested by us. Source

There is also a community node, @cachly-dev/n8n-nodes-cachly, with the actions learn, recall and remember context. It is a separate path and does not use the remote endpoint.

Agent frameworks and APIs

Mastra (TypeScript)

import { MCPClient } from "@mastra/mcp";

const mcp = new MCPClient({
  servers: {
    cachly: {
      url: new URL("https://mcp.cachly.dev/mcp"),
      requestInit: {
        headers: { Authorization: `Bearer ${process.env.CACHLY_KEY}` },
      },
    },
  },
});

Per Mastra docs, not tested by us. Source

Vercel AI SDK (TypeScript)

import { createMCPClient } from "@ai-sdk/mcp";

const client = await createMCPClient({
  transport: {
    type: "http",
    url: "https://mcp.cachly.dev/mcp",
    headers: { Authorization: `Bearer ${process.env.CACHLY_KEY}` },
  },
});

Per Vercel docs, not tested by us. Source

OpenAI Agents SDK (Python)

from agents import Agent
from agents.mcp import MCPServerStreamableHttp

async with MCPServerStreamableHttp(
    name="cachly",
    params={
        "url": "https://mcp.cachly.dev/mcp",
        "headers": {"Authorization": f"Bearer {key}"},
    },
) as server:
    agent = Agent(name="Assistant", mcp_servers=[server])

Per OpenAI docs, not tested by us. Source

Anthropic Messages API, MCP connector (beta)

The beta header and the exact field names are in the vendor docs. Check them there before you copy this.

# Beta. Add the beta header named in the docs linked below.
mcp_servers=[{
    "type": "url",
    "url": "https://mcp.cachly.dev/mcp",
    "name": "cachly",
    "authorization_token": "cky_...",
}],
tools=[{"type": "mcp_toolset", "mcp_server_name": "cachly"}],

Per Anthropic docs, not tested by us. Source

LangChain (Python)

With the langchain-mcp-adapters package:

from langchain_mcp_adapters.client import MultiServerMCPClient

client = MultiServerMCPClient({
    "cachly": {
        "transport": "streamable_http",
        "url": "https://mcp.cachly.dev/mcp",
        "headers": {"Authorization": "Bearer cky_..."},
    }
})

Per LangChain docs, not tested by us. Source

Google ADK (Python)

from google.adk.tools.mcp_tool import McpToolset
from google.adk.tools.mcp_tool.mcp_session_manager import (
    StreamableHTTPConnectionParams,
)

toolset = McpToolset(
    connection_params=StreamableHTTPConnectionParams(
        url="https://mcp.cachly.dev/mcp",
        headers={"Authorization": "Bearer cky_..."},
    )
)

Per Google docs, not tested by us. Source

No-code builders

  • Dify: Tools → MCP, with custom headers. Dify docs
  • Flowise: Custom MCP tool, headers in the server config. Flowise docs
  • Langflow 1.7 and later: MCP server with headers. Langflow docs
  • Microsoft Copilot Studio: API key in the header Authorization. Microsoft docs

All four per the vendors' docs, not tested by us.

Not yet

  • Picking a Brain when you sign in: there is no choice yet. The sign-in way always opens the running Brain you created last. With an API key you can pick one with the header X-Cachly-Instance.
  • Make and Zapier: we found no documented way to send a custom header to a remote MCP server.
  • Windsurf and CrewAI: they support the transport, but we found no documented header option. Use the local npx @cachly-dev/mcp-server setup there.

Security

  • Keep the key in an environment variable or a secret store. Never commit it to a repository or paste it into a shared config file.
  • A key belongs to one user and opens that user's Brain. Do not hand it to people who should not read it.
  • Signing in gives the app a token for this server only. It expires after a short time, and the app renews it. To stop the access, remove the connector in the app.
  • To revoke a key, open Setup AI (/setup-ai) and use the Revoke button under Your API keys. Every editor or agent that uses the key stops working until it gets a new one.