Skip to content

ChatGPT

ChatGPT connects to AutoMem through a remote MCP sidecar — a separately deployed HTTP service that translates MCP protocol requests to AutoMem API calls. This is required because ChatGPT is cloud-based and cannot spawn local processes.


graph TB
    subgraph "Remote MCP (HTTP/SSE Transport)"
        CGP["ChatGPT Developer Mode"]
        SIDECAR["MCP Sidecar (separate deployment) — POST /mcp / GET /mcp/sse"]
        AUTOMEM["AutoMem API :8001"]

        CGP -->|"HTTP POST"| SIDECAR
        SIDECAR -->|"HTTP"| AUTOMEM
    end
  • Local MCP (Claude Desktop, Cursor, Claude Code): AI platform → stdio → MCP server → AutoMem API
  • Remote MCP (ChatGPT, Claude.ai, ElevenLabs): AI platform → HTTPS → MCP sidecar → AutoMem API

The MCP sidecar is part of the AutoMem server repository (mcp-sse-server/), deployed separately from your local tools.


  1. A deployed AutoMem service (see deployment guide)
  2. The MCP sidecar deployed and accessible over HTTPS
  3. A ChatGPT Plus, Pro, Team, or Enterprise account (Developer Mode required)

The sidecar is included in the AutoMem Railway one-click template. For manual deployment:

Required environment variables:

VariablePurpose
AUTOMEM_API_URLAutoMem service URL (e.g., http://memory-service.railway.internal:8001)
AUTOMEM_API_TOKENAPI token for AutoMem service authentication
PORTServer listen port (default: 8080)

Railway deployment:

  1. Deploy via Railway one-click template (includes sidecar)
  2. Go to mcp-sse-server service → Settings → Networking → Generate Domain
  3. Note the public URL: https://your-mcp-bridge.up.railway.app

Sidecar endpoints:

EndpointMethodPurpose
/mcpPOSTStreamable HTTP — full-duplex MCP (recommended)
/mcp/sseGETSSE stream — server→client events (legacy)
/mcp/messages?sessionId=<id>POSTSSE client→server messages (legacy)
/healthGETService health probe

  1. Open ChatGPT → SettingsConnectorsAdvanced
  2. Enable Developer Mode
  3. Click + Add Server
  4. Enter the server URL

Streamable HTTP (recommended):

https://your-mcp-bridge.up.railway.app/mcp?api_token=YOUR_AUTOMEM_TOKEN

SSE (fallback if Streamable HTTP not supported):

https://your-mcp-bridge.up.railway.app/mcp/sse?api_token=YOUR_AUTOMEM_TOKEN
  1. Save the configuration

All six AutoMem tools are available via remote MCP:

ToolDescription
store_memoryStore content with tags, importance, and metadata
recall_memoryHybrid search (semantic + keyword + tags + time)
associate_memoriesCreate typed relationships between memories
update_memoryModify existing memory fields
delete_memoryPermanently remove a memory
check_database_healthCheck FalkorDB and Qdrant connection status

Test the connection by asking ChatGPT:

Check the health of the AutoMem service

Then test storing and recalling:

Store a memory: I prefer dark mode in all applications
What are my preferences?

ChatGPT cannot connect to the MCP endpoint

Section titled “ChatGPT cannot connect to the MCP endpoint”
  1. Verify the sidecar is running: curl https://your-mcp-bridge.up.railway.app/health
  2. Check DNS resolves for your domain
  3. Ensure HTTPS (port 443) is open — ChatGPT requires TLS
  4. Verify TLS certificate is valid (Railway domains use wildcard certs automatically)
  1. Check AUTOMEM_API_TOKEN is set in the sidecar’s environment variables
  2. Verify the token in the URL matches exactly (no extra spaces)
  3. Ensure the token is URL-encoded if it contains special characters
  4. Test token directly: curl -H "Authorization: Bearer $TOKEN" https://your-automem.up.railway.app/health

Memory service connection errors (502/504)

Section titled “Memory service connection errors (502/504)”

Symptom in sidecar logs:

[AutoMem] Fetch failed for http://memory-service.railway.internal:8001/memory:
Error: connect ECONNREFUSED fd12:ca03:42be:0:1000:50:1079:5b6c:8001
CauseSolution
Missing PORT=8001 in memory serviceAdd PORT=8001 to memory service environment variables
Wrong internal hostnameUpdate to memory-service.railway.internal:8001
Service not runningCheck Railway dashboard for deployment status

Symptom: Logs show literal ${{...}} syntax:

[AutoMem] GET http://${{FalkorDB.RAILWAY_PRIVATE_DOMAIN}}:6379/health

Railway variable references (${{...}}) only work in template deployments. Use hardcoded values for manual service configuration.

If using SSE transport (legacy), the sidecar sends heartbeats every 20 seconds. Some proxies buffer SSE streams — ensure your proxy is configured for streaming responses.

Consider switching to Streamable HTTP (/mcp) instead of SSE (/mcp/sse) for better reliability.


  • URL-based tokens (?api_token=) appear in server logs and browser history
  • ChatGPT’s connector UI does not support custom headers, making URL-based auth unavoidable
  • Use Railway’s private networking to keep the sidecar-to-AutoMem communication internal
  • Rotate your AUTOMEM_API_TOKEN periodically

Other cloud-based platforms using the same remote MCP sidecar: