Sentry MCP
Sentry
Sentry's official MCP — LLM browses your org's issues, events, releases, performance. Most common use: auto-analysing production error stack traces and suggesting fixes.
Token required5-min install
Why client-side
A Sentry auth token can read (and depending on scope, write) your entire org's error data — including user PII and code snippets in stack traces. High-sensitivity credential. twinkle-hub does not store it.
Prerequisites
- Node.js ≥ 18
- Sentry account with org admin (or have admin issue you a token)
- MCP-capable client
Get a token
- 1Log in at https://sentry.io
- 2User settings → Auth Tokens → Create New Token
- 3Name it (e.g. "claude-mcp")
- 4Scopes — read: event:read / project:read / org:read / team:read. Write (be careful): event:write / project:write / team:write
- 5Copy the token (starts with sntryu_)
- 6For teams, prefer an Organization token: org settings → Developer Settings → Custom Integrations → create an internal integration
Install
Claude Desktop (macOS)
~/Library/Application Support/Claude/claude_desktop_config.json
SENTRY_HOST: for SaaS use sentry.io; for self-hosted use your host (without https://)
{
"mcpServers": {
"sentry": {
"command": "npx",
"args": ["-y", "@sentry/mcp-server"],
"env": {
"SENTRY_AUTH_TOKEN": "<your_sentry_token>",
"SENTRY_ORG": "<your_org_slug>",
"SENTRY_HOST": "sentry.io"
}
}
}
}First run
Try this prompt
List unresolved critical issues on Sentry
Common tools
list_organization_projects(organization_slug)— list projectslist_issues(project_slug, query="is:unresolved")— find unresolved issuesget_issue_details(issueId)— full stack trace + breadcrumbslist_events(issueId)— every occurrence of an issueupdate_issue(issueId, status="resolved")— mark resolved (needs write scope)
Troubleshooting
| Symptom | Fix |
|---|---|
| 401 Unauthorized | Token expired or scope insufficient |
| Project missing | Token scope doesn't cover that project, or account lacks permission |
| Organization not found | SENTRY_ORG must be the slug, not the display name |
| Self-hosted unreachable | SENTRY_HOST correct? Does your reverse proxy expose /api/0? |
Security notes
- Treat the token like a password — never commit to git
- Start with read-only scope, watch behaviour, then expand if needed
- Don't grant member:admin / org:admin / project:admin to the LLM token
- Revoke immediately when no longer needed