Skip to main content
Glama

Sentry MCP Server

Official
by getsentry

注意:Sentry Remote-MCP 服务器已基本取代了它,后者支持更多功能(例如身份验证、更强大的工具等)。它作为独立的 MCP 服务器,仅供教学之用;但您很可能需要使用远程服务器。您可以在https://mcp.sentry.dev上实时查看。

Sentry MCP 服务器

用于与 Sentry 交互的模型上下文协议 (MCP) 服务器。该 MCP 服务器提供与 Sentry API 交互的工具,允许 AI 助手检索和分析错误数据、管理项目以及监控应用程序性能。

要求

  • Node.js(v14 或更高版本)
  • npm 或 yarn
  • 具有 API 访问权限的 Sentry 帐户
  • 具有适当权限的 Sentry 身份验证令牌

设置

  1. 安装依赖项:
    npm install

在 IDE 中使用它

该 MCP 已经过验证,可与 Cursor、Codeium Windsurf 和 Claude Desktop 配合使用。

与 Claude 一起使用

要将此 MCP 服务器与 Claude 一起使用,请将以下配置添加到您的 Claude 设置中:

{ "mcpServers": { "sentry": { "command": "npx", "args": ["ts-node", "/Users/<your-user-directory>/sentry-mcp-ts/index.ts"], "env": { "SENTRY_AUTH": "<YOUR_AUTH_TOKEN>" } } } }
  • 使用args字段中的目录路径进行更新。
  • 用您的 Sentry 身份验证令牌替换<YOUR_AUTH_TOKEN>

可用工具

列出项目

列出给定组织的所有可访问的 Sentry 项目。

参数:

  • organization_slug (字符串,必需):列出项目的组织 slug
  • view (字符串,可选):视图类型,可以是“摘要”或“详细”(默认值:“详细”)
  • format (字符串,可选):输出格式,可以是“plain”或“markdown”(默认值:“markdown”)

解析短ID

使用问题的短 ID 检索有关问题的详细信息。

参数:

  • organization_slug (字符串,必需):问题所属组织的 slug
  • short_id (字符串,必需):待解决的问题的简短 ID(例如,PROJECT-123)
  • format (字符串,可选):输出格式,可以是“plain”或“markdown”(默认值:“markdown”)

获取哨兵事件

从问题中检索并分析特定的 Sentry 事件。

参数:

  • issue_id_or_url (字符串,必需):完整的 Sentry 问题 URL 或仅为数字问题 ID
  • event_id (字符串,必需):要检索的特定事件 ID
  • view (字符串,可选):视图类型,可以是“摘要”或“详细”(默认值:“详细”)
  • format (字符串,可选):输出格式,可以是“plain”或“markdown”(默认值:“markdown”)

列出项目中的错误事件

列出来自特定 Sentry 项目的错误事件。

参数:

  • organization_slug (字符串,必需):项目所属组织的 slug
  • project_slug (字符串,必需):列出事件的项目的 slug
  • view (字符串,可选):视图类型,可以是“摘要”或“详细”(默认值:“详细”)
  • format (字符串,可选):输出格式,可以是“plain”或“markdown”(默认值:“markdown”)

创建项目

在 Sentry 中创建一个新项目并检索其客户端密钥。

参数:

  • organization_slug (字符串,必需):创建项目的组织的 slug
  • team_slug (字符串,必需):分配项目的团队的 slug
  • name (字符串,必需):新项目的名称
  • platform (字符串,可选):新项目的平台
  • view (字符串,可选):视图类型,可以是“摘要”或“详细”(默认值:“详细”)
  • format (字符串,可选):输出格式,可以是“plain”或“markdown”(默认值:“markdown”)

列出项目问题

列出特定 Sentry 项目的问题。

参数:

  • organization_slug (字符串,必需):项目所属组织的 slug
  • project_slug (字符串,必需):列出问题的项目的 slug
  • view (字符串,可选):视图类型,可以是“摘要”或“详细”(默认值:“详细”)
  • format (字符串,可选):输出格式,可以是“plain”或“markdown”(默认值:“markdown”)

列出问题事件

列出特定 Sentry 问题的事件。

参数:

  • organization_slug (字符串,必需):问题所属组织的 slug
  • issue_id (字符串,必需):列出事件的问题的 ID
  • view (字符串,可选):视图类型,可以是“摘要”或“详细”(默认值:“详细”)
  • format (字符串,可选):输出格式,可以是“plain”或“markdown”(默认值:“markdown”)

获取哨兵问题

检索并分析 Sentry 问题。

参数:

  • issue_id_or_url (字符串,必需):完整的 Sentry 问题 URL 或仅为数字问题 ID
  • view (字符串,可选):视图类型,可以是“摘要”或“详细”(默认值:“详细”)
  • format (字符串,可选):输出格式,可以是“plain”或“markdown”(默认值:“markdown”)

列出组织重播

列出来自特定 Sentry 组织的重放。

参数:

  • organization_slug (字符串,必需):列出重播的组织的 slug
  • project_ids (string[],可选):用于过滤重播的项目 ID 列表
  • environment (字符串,可选):用于过滤重播的环境
  • stats_period (字符串,可选):统计的时间段(例如“24h”,“7d”)
  • start (字符串,可选):过滤重播的开始日期
  • end (字符串,可选):过滤重播的结束日期
  • sort (字符串,可选):对重播进行排序的字段
  • query (字符串,可选):搜索查询以过滤重播
  • per_page (数字,可选):每页重播次数
  • cursor (字符串,可选):分页游标
  • view (字符串,可选):视图类型,可以是“摘要”或“详细”(默认值:“详细”)
  • format (字符串,可选):输出格式,可以是“plain”或“markdown”(默认值:“markdown”)

运行服务器

npx ts-node index.ts

验证

此工具需要具有适当权限的 Sentry 身份验证令牌才能访问 Sentry API。您可以在 Sentry 帐户设置中的“设置”->“用户设置”->“身份验证令牌”下生成令牌。

Install Server
A
security – no known vulnerabilities
F
license - not found
A
quality - confirmed to work

remote-capable server

The server can be hosted and run remotely because it primarily relies on remote services or has no dependency on the local environment.

模型上下文协议服务器,允许 AI 助手与 Sentry API 交互以检索和分析错误数据、管理项目和监控应用程序性能。

  1. 要求
    1. 设置
      1. 在 IDE 中使用它
        1. 与 Claude 一起使用
          1. 可用工具
            1. 列出项目
            2. 解析短ID
            3. 获取哨兵事件
            4. 列出项目中的错误事件
            5. 创建项目
            6. 列出项目问题
            7. 列出问题事件
            8. 获取哨兵问题
            9. 列出组织重播
          2. 运行服务器
            1. 验证

              Related MCP Servers

              • -
                security
                F
                license
                -
                quality
                A Model Context Protocol server that retrieves and analyzes Sentry.io issues, allowing users to inspect error reports, stacktraces, and debugging information from their Sentry account.
                Last updated -
                16
                Python
                • Apple
              • A
                security
                F
                license
                A
                quality
                A Model Context Protocol server that enables AI assistants to interact with Sentry for error tracking and monitoring, allowing retrieval and analysis of error data, project management, and performance monitoring through the Sentry API.
                Last updated -
                10
                3
                TypeScript
              • A
                security
                A
                license
                A
                quality
                A Model Context Protocol server that allows AI assistants to interact with Appwrite's API, providing tools to manage databases, users, functions, teams, and other resources within Appwrite projects.
                Last updated -
                84
                40
                Python
                MIT License
                • Linux
                • Apple
              • -
                security
                F
                license
                -
                quality
                A Model Context Protocol server that provides a comprehensive interface for interacting with the ConnectWise Manage API, simplifying API discovery, execution, and management for both developers and AI assistants.
                Last updated -
                46
                2
                Python
                • Linux
                • Apple

              View all related MCP servers

              MCP directory API

              We provide all the information about MCP servers via our MCP API.

              curl -X GET 'https://glama.ai/api/mcp/v1/servers/getsentry/sentry-mcp-ts'

              If you have feedback or need assistance with the MCP directory API, please join our Discord server