MCP HubMCP Hub
modelcontextprotocol

sentry

by: modelcontextprotocol

A Model Context Protocol server for retrieving and analyzing issues from Sentry.io. This server provides tools to inspect error reports, stacktraces, and other debugging information from your Sentry account.

0created 19/11/2024
Visit
Sentry
debugging

📌Overview

Purpose: The framework serves as a Model Context Protocol server to facilitate the retrieval and analysis of issues from Sentry.io.

Overview: The mcp-server-sentry provides essential tools for inspecting error reports, stack traces, and debugging information related to Sentry issues, enabling developers to effectively diagnose problems in their applications.

Key Features:

  • Issue Retrieval and Analysis: The get_sentry_issue tool allows users to fetch and analyze Sentry issues by either ID or URL, offering comprehensive details such as issue title, status, timestamps, event count, and full stack trace for improved debugging.

  • Formatted Conversation Context: The sentry-issue prompt retrieves formatted issue details that can be used as context in conversations, streamlining support and troubleshooting processes.


mcp-server-sentry: A Sentry MCP server

Overview

A Model Context Protocol server for retrieving and analyzing issues from Sentry.io. This server provides tools to inspect error reports, stack traces, and other debugging information from your Sentry account.

Tools

  1. get_sentry_issue
    • Retrieve and analyze a Sentry issue by ID or URL
    • Input:
      • issue_id_or_url (string): Sentry issue ID or URL to analyze
    • Returns: Issue details including:
      • Title
      • Issue ID
      • Status
      • Level
      • First seen timestamp
      • Last seen timestamp
      • Event count
      • Full stacktrace

Prompts

  1. sentry-issue
    • Retrieve issue details from Sentry
    • Input:
      • issue_id_or_url (string): Sentry issue ID or URL
    • Returns: Formatted issue details as conversation context

Installation

Using uv (recommended)

When using uv no specific installation is needed. Use uvx to directly run mcp-server-sentry.

Using PIP

Alternatively, you can install mcp-server-sentry via pip:

pip install mcp-server-sentry

After installation, run it as a script using:

python -m mcp_server_sentry

Configuration

Usage with Claude Desktop

Add this to your claude_desktop_config.json:

Using uvx
"mcpServers": {
  "sentry": {
    "command": "uvx",
    "args": ["mcp-server-sentry", "--auth-token", "YOUR_SENTRY_TOKEN"]
  }
}
Using docker
"mcpServers": {
  "sentry": {
    "command": "docker",
    "args": ["run", "-i", "--rm", "mcp/sentry", "--auth-token", "YOUR_SENTRY_TOKEN"]
  }
}
Using pip installation
"mcpServers": {
  "sentry": {
    "command": "python",
    "args": ["-m", "mcp_server_sentry", "--auth-token", "YOUR_SENTRY_TOKEN"]
  }
}

Usage with Zed

Add to your Zed settings.json:

Using uvx
"context_servers": [
  "mcp-server-sentry": {
    "command": {
      "path": "uvx",
      "args": ["mcp-server-sentry", "--auth-token", "YOUR_SENTRY_TOKEN"]
    }
  }
],
Using pip installation
"context_servers": {
  "mcp-server-sentry": {
    "command": "python",
    "args": ["-m", "mcp_server_sentry", "--auth-token", "YOUR_SENTRY_TOKEN"]
  }
},

Debugging

You can use the MCP inspector to debug the server. For uvx installations:

npx @modelcontextprotocol/inspector uvx mcp-server-sentry --auth-token YOUR_SENTRY_TOKEN

Or if developing locally:

cd path/to/servers/src/sentry
npx @modelcontextprotocol/inspector uv run mcp-server-sentry --auth-token YOUR_SENTRY_TOKEN

License

This MCP server is licensed under the MIT License. You are free to use, modify, and distribute the software under the terms of the MIT License. See the LICENSE file for details.