RR

rollbar/rollbar-mcp-server

开发工具

本页由 AI 翻译,技术细节请以原文为准。 查看原文

28 stars 11 forks 质量 78 趋势 31MIT

Rollbar 模型上下文协议服务器

概览

一个用于Rollbar的模型上下文协议(MCP)服务器。 这个MCP服务器实现了stdio服务器类型,这意味着你的AI工具(比如Claude、Cursor)会直接运行它;你不需要运行独立进程或通过http连接。 要以自己身份查看物品历史和评论,请用ROLLBAR_USER_ACCESS_TOKEN配置滚动条,或者使用配置文件: 使用范围来读取,或者发布评论。MCP通过GET /projects(读取范围)解析你的项目,然后用写权限发布帖子。你的Rollbar用户还需要权限才能阅读历史记录并在该项目中发布。项目令牌和普通账户令牌不能发布评论。 用户模式发送所有请求时都包含配置用户的令牌,包括当每个项目的令牌同时存在时。评论作者身份来自该令牌;你不能提供不同的作者。后端标记发布带有 via_api: true 的评论,并处理普通订阅和通知。

概述(AI 翻译)

一个用于Rollbar的模型上下文协议(MCP)服务器。

特色

这个MCP服务器实现了stdio服务器类型,这意味着你的AI工具(例如Claude、光标)会直接运行它;你不需要运行单独进程或通过HTTP连接。

配置

用户访问令牌

要以自己身份查看物品历史并发表评论,请设置一个带有ROLLBAR_USER_ACCESS_TOKEN的用户范围账户访问令牌**滚动栏,或使用配置文件:

使用read范围进行读取,或read and write来发布评论。MCP通过GET /projects(读取范围)解析你的项目,然后用写权限发布。你的Rollbar用户还需要view权限才能阅读历史和评论权限才能在该项目中发布。项目令牌和普通账户令牌不能发布评论。

用户模式发送所有请求时都包含配置用户的令牌,包括当每个项目的令牌同时存在时。评论作者身份来自该令牌;你不能提供不同的作者。后端标记以 via_api: true 发布评论,并处理正常订阅和通知。

本页由 AI 翻译,技术细节请以原文为准。

README

以下为原文 README 节选,完整内容请查看原文。

rollbar-mcp-server

A Model Context Protocol (MCP) server for Rollbar.

Features

This MCP server implements the stdio server type, which means your AI tool (e.g. Claude, Cursor) will run it directly; you don’t run a separate process or connect over http.

Configuration

User access token

To read item history and post comments as yourself, configure a Rollbar user-scoped account access token with ROLLBAR_USER_ACCESS_TOKEN, or use a config file:

{ "userToken": "" }

Use read scope for reads, or read and write to post comments. The MCP resolves your project through GET /projects (read scope), then posts with write scope. Your Rollbar user also needs view permission to read history and comment permission to post in that project. Project tokens and ordinary account tokens cannot post comments.

User mode sends every request with the configured user’s token, including when per-project tokens are also present. Comment authorship comes from that token; you cannot supply a different author. The backend marks posted comments with via_api: true and handles normal subscriptions and notifications.

Configure exactly one of userToken / ROLLBAR_USER_ACCESS_TOKEN or accountToken / ROLLBAR_ACCOUNT_ACCESS_TOKEN. Configuring both fails at startup, including when one comes from a file and the other from the environment. A file value overrides the environment value for the same token type. apiBase in a file or ROLLBAR_API_BASE in environment-only configuration selects a custom API endpoint.

Use list-projects to find the project name or numeric ID for the tools’ project argument. It is optional when your user token can see exactly one enabled project. A token supplied only through the legacy ROLLBAR_ACCESS_TOKEN setting is not inferred to be a user token; set ROLLBAR_USER_ACCESS_TOKEN explicitly for posting.

Account access token

Configure a single Rollbar Account Access Token to read and update items across projects in that account. Posting comments requires user mode above:

  • ROLLBAR_ACCOUNT_ACCESS_TOKEN (env var), or
  • accountToken (a top-level key in .rollbar-mcp.json, alongside projects/token/apiBase)

To create one: in Rollbar, go to your account settings → Account Access Tokens, create a new named, enabled token, and choose read (or read and write, if you plan to use update-item) scope. Copy the full generated secret right away, Rollbar only shows it once, and store it securely (a secrets manager or your shell’s env config, not committed to source control).

{
  "accountToken": "acct_tok_abc123"
}
在 GitHub 查看完整 README

安装

npx -y @rollbar/mcp-server@latest
新手?先看 mcpskill.org 教程 →

配置

{ "mcpServers": { "rollbar": { "type": "stdio", "command": "npx", "args": ["-y", "@rollbar/mcp-server@latest"], "env": { "ROLLBAR_ACCESS_TOKEN": "<project read/write access token>" } } } }