Sentry Integration
Connect Sentry to enable agents to analyze errors, exceptions, and performance issues during investigations. Sentry can also be configured as an alert source to automatically trigger investigations when new issues are created or resolved.
Capabilities
Once connected, agents can:
| Capability | Description |
|---|---|
| View Issues | Browse and search error issues |
| Analyze Events | Examine individual error events and stack traces |
| Check Releases | Review release health and regressions |
| Performance Data | Access transaction performance metrics |
| Webhook Triggers | Automatically start investigations when new Sentry issues appear |
Write tools on this integration (add comments to issues) are available only to agents granted write access to it. A governance policy on write operations pauses each write for a person to approve. Every call is recorded in the Audit Trail.
Prerequisites
- A Sentry account (Cloud or self-hosted)
- An Auth Token with appropriate scopes
- Read access to the projects you want to monitor
Setup
- Log in to Sentry
- Go to Settings → Auth Tokens
- Click Create New Token
- Select the required scopes (see below)
- Copy the generated token
- Go to Integrations in Autoheal
- Click Sentry
- Enter a name (e.g., "Production Sentry")
Enter the following:
- Token: Your Sentry auth token
- Sentry Hostname: Your Sentry instance hostname (e.g.,
mycompany.sentry.iofor Cloud, orsentry.mycompany.netfor self-hosted)
Click Test Connection to check the connection. Then click Save.
Required Scopes
Create your auth token with these scopes:
| Scope | Why It's Needed |
|---|---|
project:read | List and access projects |
event:read | View error events |
issue:read | Browse issues |
org:read | Access organization data |
Webhook Setup (Alert Source)
Sentry can automatically trigger investigations via webhooks when new issues are created or resolved. Alerts flow through the standard alert pipeline. They appear in the Alerts tab and are grouped by Alertmanager. When configured, they can trigger on-call pages and AI investigations.
- Go to your Sentry integration settings in Integrations
- Click the Webhook tab
- Toggle Enable Webhook. Then copy the generated webhook URL
- In Sentry, go to Settings → Developer Settings → Custom Integrations
- Click Create New Integration. Then select Internal Integration
- Under Webhooks, paste the webhook URL from Autoheal
- Under event types, check Issue
- Copy the Client Secret from the Credentials section at the bottom
- Click Save Changes
Back in Autoheal, paste the Client Secret in the Webhook Signing Secret field. This is used to verify webhook signatures (HMAC-SHA256).
Example Queries
Once connected, you can ask an agent:
What are the most frequent errors in the payment service?
Show me the stack trace for the latest NullPointerException
Were there any new errors after yesterday's deployment?
What's the error rate trend for the checkout flow?
Troubleshooting
401 Unauthorized
- Check that the auth token is correct
- Check that the token hasn't been revoked
- Check that the token has the required scopes
Organization Not Found
- Check that the organization slug is correct
- Check for typos (slugs are case-sensitive)
- Check that your token has access to the organization
No Issues Found
- Check that the token has
issue:readscope - Check that there are issues in the specified time range
- Check that project access permissions are correct
Webhook Not Triggering Investigations
- Check that the webhook URL is correctly configured in Sentry's Internal Integration (Settings → Developer Settings → Custom Integrations)
- Check that the Webhook Signing Secret matches the Client Secret from Sentry
- Check that the Issue checkbox is enabled in the Internal Integration's Webhooks section
- Only
issue.createdandissue.resolvedactions trigger the alert pipeline. Other actions (assigned, ignored, archived) and other resource types (error, comment, seer) are discarded automatically - Check the webhook events log in Autoheal for signature verification errors