MCP Hub
Back to servers

threadline-mcp

MCP server for Threadline — persistent memory and context layer for AI agents. inject() before your LLM call, update() after. Relevance-scored injection, grant-based access, user-owned context.

glama
Updated
Apr 2, 2026

threadline-mcp

MCP server for Threadline — the memory governance layer for AI agents.

Use Threadline's persistent, user-consented memory in any MCP-compatible client: Cursor, Claude Desktop, or your own agent.

Install

npm install -g threadline-mcp

Setup

Get your API key at threadline.to/dashboard.

Claude Desktop

Add to claude_desktop_config.json:

{
  "mcpServers": {
    "threadline": {
      "command": "threadline-mcp",
      "env": {
        "THREADLINE_API_KEY": "tl_live_your_key_here"
      }
    }
  }
}

Cursor

Add to your MCP config in Cursor settings:

{
  "threadline": {
    "command": "threadline-mcp",
    "env": {
      "THREADLINE_API_KEY": "tl_live_your_key_here"
    }
  }
}

Any MCP client

THREADLINE_API_KEY=tl_live_your_key_here threadline-mcp

Tools

inject

Inject user context into a base system prompt before an LLM call.

{
  "userId": "user-uuid",
  "basePrompt": "You are a helpful assistant."
}

Returns an enriched prompt with relevant facts about the user automatically inserted.

update

Update a user's context after an LLM interaction. Extracts and stores structured facts for future sessions.

{
  "userId": "user-uuid",
  "userMessage": "I prefer concise answers and I'm building in TypeScript.",
  "agentResponse": "Got it, keeping it brief."
}

How it works

Your MCP client (Cursor / Claude Desktop)
        │
        ▼
threadline-mcp (this package)
        │
        ▼
api.threadline.to
        │
   ┌────┴────┐
   ▼         ▼
Supabase   Redis
(context)  (<50ms)
  • inject() — fetches stored context, scores by recency + relevance, returns enriched prompt
  • update() — two-stage extraction pipeline classifies and stores new facts across 7 scopes

Links

Reviews

No reviews yet

Sign in to write a review