OpenReplay Session Analysis MCP Server

OpenReplay Session Analysis MCP Server

Enables AI assistants to analyze OpenReplay session recordings for user behavior patterns, problem detection, and actionable insights through session search, journey analysis, and AI-powered summaries.

Category
访问服务器

README

OpenReplay Session Analysis MCP Server

A Model Context Protocol (MCP) server for analyzing OpenReplay session recordings and user behavior patterns. This server enables AI assistants to analyze user sessions, detect problems, and provide actionable insights from OpenReplay data.

🔥 Features

  • 🔍 Session Search & Filtering - Find sessions by date, user, errors, duration
  • 📊 User Journey Analysis - Track page flows and navigation patterns
  • 🐛 Problem Detection - Identify rage clicks, form abandonment, errors
  • 🤖 AI-Powered Insights - Generate intelligent session summaries
  • 👥 User Behavior Analysis - Analyze patterns across multiple sessions
  • 🔗 Similar Session Finding - Discover sessions with comparable issues

🚀 Quick Start

  1. Clone and setup:

    git clone https://github.com/rsp2k/openreplay-mcp-server.git
    cd openreplay-mcp-server
    python -m venv venv
    source venv/bin/activate  # On Windows: venv\Scripts\activate
    pip install -r requirements.txt
    
  2. Configure OpenReplay credentials:

    cp .env.example .env
    # Edit .env with your OpenReplay API credentials
    
  3. Run the server:

    python run_server.py
    

⚙️ Configuration

Set these environment variables in your .env file:

OPENREPLAY_API_URL=https://api.openreplay.com
OPENREPLAY_API_KEY=your_api_key_here
OPENREPLAY_PROJECT_ID=your_project_id_here

To get your OpenReplay API credentials:

  1. Go to your OpenReplay dashboard
  2. Navigate to Settings → API Keys
  3. Generate a new API key
  4. Copy your Project ID from the URL or project settings

🛠️ Available Tools

Session Management

  • search_sessions - Search sessions with advanced filters
  • get_session_details - Get detailed session information
  • get_user_session_history - View all sessions for a specific user

Analysis Tools

  • analyze_user_journey - Map user navigation patterns and page flows
  • detect_problem_patterns - Find rage clicks, form issues, and errors
  • generate_session_summary - AI-powered session insights and recommendations
  • find_similar_sessions - Discover related problematic sessions

📋 Usage with Claude Desktop

Add to your Claude Desktop MCP configuration (claude_desktop_config.json):

{
  "mcpServers": {
    "openreplay-analysis": {
      "command": "python",
      "args": ["/path/to/openreplay-mcp-server/run_server.py"],
      "env": {
        "OPENREPLAY_API_KEY": "your_api_key_here",
        "OPENREPLAY_PROJECT_ID": "your_project_id_here"
      }
    }
  }
}

💬 Example Queries

Once connected to Claude Desktop or another MCP client, you can ask:

  • "Find sessions with errors from the last week"
  • "Analyze user journey for session ABC123"
  • "Generate a summary of problematic sessions today"
  • "Show me all sessions for user john@example.com"
  • "Find sessions similar to XYZ456 that had form abandonment"
  • "Debug session DEF789 and tell me what went wrong"

🐳 Docker Usage

For containerized deployment:

# Set environment variables in .env file
docker-compose up

Or build and run manually:

docker build -t openreplay-mcp .
docker run -e OPENREPLAY_API_KEY=your_key -e OPENREPLAY_PROJECT_ID=your_project openreplay-mcp

🔧 Development

The server is built with:

  • FastMCP - Official Python MCP SDK for server implementation
  • httpx - Async HTTP client for OpenReplay API
  • asyncio - Async/await support

Project Structure

openreplay-mcp-server/
├── openreplay_session_analyzer.py  # OpenReplay client and analysis logic
├── run_server.py                   # FastMCP server with tools
├── mcp.py                          # Django MCP configuration (optional)
├── settings.py                     # Django settings (optional)
├── requirements.txt                # Python dependencies
├── .env.example                    # Environment variables template
├── Dockerfile                      # Container configuration
├── docker-compose.yml              # Docker Compose setup
└── README.md                       # This file

Adding New Analysis Features

  1. Add new methods to the SessionAnalyzer class in openreplay_session_analyzer.py
  2. Create corresponding @mcp.tool() decorated functions in run_server.py
  3. Test with your OpenReplay data

📊 Session Analysis Capabilities

Problem Detection

  • Rage Clicks: Multiple rapid clicks indicating frustration
  • Form Abandonment: Users starting but not completing forms
  • Dead Clicks: Clicks on non-interactive elements
  • Error Tracking: JavaScript errors and exceptions

Journey Analysis

  • Page Flow Mapping: Track user navigation through your site
  • Duration Analysis: Understand time spent on each page
  • Bounce Rate: Identify single-page sessions
  • Action Breakdown: Analyze user interactions (clicks, scrolls, inputs)

AI Insights

  • Automated Summaries: Natural language session descriptions
  • Problem Identification: Highlight potential UX issues
  • Performance Analysis: Identify slow-loading content
  • Behavioral Patterns: Recognize user intent and goals

🔗 Integration Examples

Debugging Workflow

# Search for recent error sessions
sessions = await search_sessions(has_errors=True, start_date="2024-06-01")

# Analyze specific problematic session
summary = await generate_session_summary(session_id="abc123")
problems = await detect_problem_patterns(session_id="abc123")

# Find similar issues
similar = await find_similar_sessions(reference_session_id="abc123", criteria="errors")

UX Research Workflow

# Analyze user behavior over time
user_history = await get_user_session_history(user_id="user123")

# Study navigation patterns
for session in user_sessions:
    journey = await analyze_user_journey(session_id=session.id)
    # Analyze patterns...

📝 API Requirements

This server requires:

  • OpenReplay account with API access
  • Valid API key and project ID
  • Network access to OpenReplay API endpoints
  • Python 3.8+ environment

🤝 Contributing

Contributions are welcome! Please feel free to submit a Pull Request. For major changes, please open an issue first to discuss what you would like to change.

  1. Fork the repository
  2. Create your feature branch (git checkout -b feature/amazing-feature)
  3. Commit your changes (git commit -m 'Add amazing feature')
  4. Push to the branch (git push origin feature/amazing-feature)
  5. Open a Pull Request

📄 License

This project is licensed under the MIT License - see the LICENSE file for details.

🙏 Acknowledgments

📞 Support

If you encounter any issues or have questions:

  1. Check the Issues page
  2. Create a new issue with detailed information
  3. Join the discussion in existing issues

Built with ❤️ for better user experience analysis

推荐服务器

Baidu Map

Baidu Map

百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。

官方
精选
JavaScript
Playwright MCP Server

Playwright MCP Server

一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。

官方
精选
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。

官方
精选
本地
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。

官方
精选
本地
TypeScript
VeyraX

VeyraX

一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。

官方
精选
本地
graphlit-mcp-server

graphlit-mcp-server

模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。

官方
精选
TypeScript
Kagi MCP Server

Kagi MCP Server

一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。

官方
精选
Python
e2b-mcp-server

e2b-mcp-server

使用 MCP 通过 e2b 运行代码。

官方
精选
Neon MCP Server

Neon MCP Server

用于与 Neon 管理 API 和数据库交互的 MCP 服务器

官方
精选
Exa MCP Server

Exa MCP Server

模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。

官方
精选