Skip to main content
Glama

🎉 MCP Session Saver

English | 简体中文

An MCP service for saving session records. Session content can be saved to a specified directory and stored as Markdown files organized by IDE name, date, and session description.

✨ Key Features

  • 📝 Save Session Records - Save AI conversations as Markdown files

  • 📁 Smart Organization - Automatically categorized by IDE/date/description

  • 🔍 Session Management - Read, search, and delete sessions

  • 🌐 Multi-IDE Support - Compatible with Qoder, Cursor, Claude Desktop, Windsurf, Trae, Codebuddy, Lingma, Continue, Aider, and more

Related MCP server: Claude Code History MCP Server

🚀 Quick Start

No installation required. Simply add to your IDE's MCP configuration:

{
  "mcpServers": {
    "session-saver": {
      "command": "npx",
      "args": ["-y", "mcp-session-saver"]
    }
  }
}

Method 2: Global Installation

npm install -g mcp-session-saver

MCP Configuration:

{
  "mcpServers": {
    "session-saver": {
      "command": "mcp-session-saver"
    }
  }
}

Method 3: Local Installation

npm install mcp-session-saver

📁 Custom Storage Path (Optional)

Add environment variable in MCP configuration:

{
  "mcpServers": {
    "session-saver": {
      "command": "npx",
      "args": ["-y", "mcp-session-saver"],
      "env": {
        "MCP_SESSION_BASE_DIR": "D:\\MyProjects\\sessions"
      }
    }
  }
}

🎯 How to Use

After configuration, simply say in your IDE:

Save current session
List all sessions
Search session content

📚 Documentation

🛠️ Tech Stack

  • JavaScript (ES Module)

  • @modelcontextprotocol/sdk

  • Node.js >= 16.0.0

📝 License

MIT

👏 Contributing

Issues and Pull Requests are welcome!

Available Tools

5 tools
delete_sessionA

【删除会话】当用户说"删除这个会话"、"移除这条记录"、"清理这个对话"、"不需要这个会话了"等时调用。永久删除指定的会话文件。触发词:删除、移除、清理、不需要会话/对话/记录

Inputs: file_path (required).

list_sessionsB

【列出会话】当用户说"查看会话列表"、"列出所有会话"、"显示已保存的对话"、"有哪些会话记录"等时调用。支持按IDE和日期筛选。触发词:列表、查看、显示、所有、历史会话/对话/记录

Inputs: base_dir, ide_name, date_filter.

read_sessionA

【读取会话】当用户说"打开这个会话"、"查看会话内容"、"读取这个文件"、"显示对话详情"等时调用。读取并显示指定会话的完整内容。触发词:打开、读取、查看、显示会话/对话内容/详情

Inputs: file_path (required).

save_sessionA

【保存会话】当用户说"保存当前会话"、"存储会话"、"记录对话"、"保存对话内容"等时调用。将AI对话内容保存为Markdown文件,按IDE/日期自动分类存储。

⚠️ 调用前必须执行的步骤:

  1. AI助手必须先在内部整理完整的对话历史

  2. 将所有用户问题和AI回答按时间顺序格式化

  3. 使用清晰的Markdown格式(# 用户、# AI助手等标题)

  4. 将整理好的完整对话作为content参数传入

❌ 禁止行为:

  • 禁止传入对话摘要或总结

  • 禁止遗漏任何历史问答

  • 禁止使用简化格式

✅ 正确格式示例:

用户

[第一个问题的完整内容...]

AI助手

[第一个回答的完整内容...]

用户

[第二个问题的完整内容...]

AI助手

[第二个回答的完整内容...]

触发词:保存、存储、记录、归档会话/对话/聊天

Inputs: content (required), ide_name (required), session_description (required), base_dir, +1 more.

search_sessionsA

【搜索会话】当用户说"搜索包含 XX 的会话"、"查找关于 XX 的对话"、"找一下 XX 相关记录"、"哪些会话提到了 XX"等时调用。在会话文件名和内容中搜索关键词,不区分大小写。触发词:搜索、查找、找、包含、相关会话/对话/记录

Inputs: keyword (required), base_dir, ide_name, date_filter.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    A4/5.0

    Scored across 5 tools

    Disambiguation5/5

    Each tool has a clearly distinct purpose: delete, list, read, save, and search. There is no overlap in functionality, and the descriptions provide clear context for when to use each.

    Naming Consistency5/5

    All tool names follow a consistent verb_noun pattern using snake_case (e.g., delete_session, list_sessions), making them predictable and easy to differentiate.

    Tool Count5/5

    With 5 tools, the server is well-scoped for its purpose of managing saved sessions. The number is neither too many nor too few, providing essential operations without unnecessary complexity.

    Completeness4/5

    The tool set covers the core CRUD operations (save, read, delete) plus listing and searching. A minor gap is the lack of an update/rename tool, but this is not critical for the domain.

    Maintenance

    ActivityInactive
    ResponsivenessNo recent community issues

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      A
      quality
      D
      maintenance
      An MCP server that enables users to retrieve, filter, and search through Claude Code conversation history stored in local projects. It provides tools for listing projects and sessions, paginating through message history, and searching across conversations with keyword filtering.
      4
      23 npm
      11
      MIT
    • A
      license
      Not graded
      quality
      D
      maintenance
      An MCP server that enables users to transform AI conversations into a structured, searchable knowledge base by saving ideas, code snippets, bookmarks, and reminders. It supports persistent storage through Supabase or PostgreSQL and includes webhook integrations for automating workflows with external tools.
      MIT
    • F
      license
      Not graded
      quality
      D
      maintenance
      A centralized MCP server for internal technical documentation that integrates with IDEs like Claude Code and VS Code, enabling semantic search and management of Markdown documents via natural language.
      -