Sentry Issues MCP server

Integrates with Sentry error tracking to retrieve detailed event and issue data for analyzing application exceptions and errors in development workflows.
Back to servers
Provider
Leee62
Release date
Apr 16, 2025
Language
TypeScript
Package
Stats
328 downloads
5 stars

The Sentry Issue MCP server allows you to access and analyze Sentry issues directly from your LLM interface. It provides tools for retrieving individual issues or lists of issues from your Sentry projects, enabling you to analyze error data and get recommendations for fixes.

Installation

To use the Sentry Issue MCP server, you'll need to configure it in your MCP-enabled LLM system. The server runs via Node.js using npx.

Prerequisites

  • Node.js installed on your system
  • Access to a Sentry account with API tokens
  • An MCP-enabled LLM interface

Configuration

Add the following configuration to your MCP server setup:

"mcpServers": {
  "sentry-issue-mcp": {
    "type": "stdio",
    "command": "npx",
    "args": [
      "-y",
      "sentry-issues-mcp@latest"
    ],
    "env": {
      "SENTRY_HOST": "<your_sentry_host>",
      "SENTRY_ORG": "<your_sentry_org>",
      "SENTRY_PROJ": "<your_sentry_proj>",
      "SENTRY_USER_TOKEN": "<your_sentry_user_token>"
    }
  }
}

Replace the placeholder values with your actual Sentry credentials:

  • <your_sentry_host>: Your Sentry host URL
  • <your_sentry_org>: Your Sentry organization ID or slug
  • <your_sentry_proj>: Your Sentry project ID or slug
  • <your_sentry_user_token>: Your Sentry API token

Available Tools

The MCP server provides two main tools for interacting with Sentry:

Get-Issue Tool

This tool retrieves a single Sentry issue by URL or ID.

Inputs:

  • url_or_id: Sentry issue URL or Sentry issue ID
  • organization_id_or_slug: (Optional) Sentry organization ID or slug

Get-Issues Tool

This tool retrieves a list of issues from a specific Sentry project.

Inputs:

  • project_id_or_slug: Sentry project ID or slug
  • organization_id_or_slug: (Optional) Sentry organization ID or slug

Usage Examples

Here are some practical examples of how to use the Sentry Issue MCP with your LLM:

Analyzing a Single Issue

To analyze a specific Sentry issue, you can prompt your LLM with:

Analysis the issue, and give me the reason of it, and tell me how to fix it, {sentry_issue_url}

Replace {sentry_issue_url} with the actual URL of the Sentry issue you want to analyze.

Finding Critical Issues

To find and analyze the most critical issues from the past 24 hours:

Find today most dangerous issue, and give me the reason of it, and tell me how to fix it

The LLM will use the get-issues tool to retrieve recent issues and then analyze the most severe one.

Troubleshooting

If the MCP server doesn't respond as expected:

  • Verify your Sentry credentials are correctly configured
  • Ensure your API token has appropriate permissions
  • Check that the Sentry host URL is accessible from your environment

How to add this MCP server to Cursor

There are two ways to add an MCP server to Cursor. The most common way is to add the server globally in the ~/.cursor/mcp.json file so that it is available in all of your projects.

If you only need the server in a single project, you can add it to the project instead by creating or adding it to the .cursor/mcp.json file.

Adding an MCP server to Cursor globally

To add a global MCP server go to Cursor Settings > MCP and click "Add new global MCP server".

When you click that button the ~/.cursor/mcp.json file will be opened and you can add your server like this:

{
    "mcpServers": {
        "cursor-rules-mcp": {
            "command": "npx",
            "args": [
                "-y",
                "cursor-rules-mcp"
            ]
        }
    }
}

Adding an MCP server to a project

To add an MCP server to a project you can create a new .cursor/mcp.json file or add it to the existing one. This will look exactly the same as the global MCP server example above.

How to use the MCP server

Once the server is installed, you might need to head back to Settings > MCP and click the refresh button.

The Cursor agent will then be able to see the available tools the added MCP server has available and will call them when it needs to.

You can also explictly ask the agent to use the tool by mentioning the tool name and describing what the function does.

Want to 10x your AI skills?

Get a free account and learn to code + market your apps using AI (with or without vibes!).

Nah, maybe later