Agent skill
sentry
Sentry API for error tracking. Use when user mentions "Sentry", "error tracking", "crash report", "exceptions", or asks about monitoring errors.
Install this agent skill to your Project
npx add-skill https://github.com/vm0-ai/vm0-skills/tree/main/sentry
SKILL.md
Sentry API
Use the Sentry API via direct curl calls to manage error tracking, issues, projects, and releases.
Official docs:
https://docs.sentry.io/api/
When to Use
Use this skill when you need to:
- List and search issues - find errors and exceptions
- Resolve or ignore issues - manage issue status
- View issue details - get stack traces and event data
- Manage projects - list and configure projects
- Track releases - create and monitor releases
- View events - get detailed error events
Prerequisites
Verify authentication:
curl -s "https://sentry.io/api/0/organizations/" -H "Authorization: Bearer $(printenv SENTRY_TOKEN)" | jq '.[0] | {slug, name}'
Discovering Your Organization Slug
Most endpoints require your organization slug. Get it from the organizations endpoint above — the slug field is what you need.
How to Use
All examples below assume SENTRY_TOKEN is set. Replace my-org with your actual organization slug from the prerequisites step.
Base URL: https://sentry.io/api/0
1. List Organizations
Get all organizations you have access to:
curl -s "https://sentry.io/api/0/organizations/" -H "Authorization: Bearer $(printenv SENTRY_TOKEN)" | jq '.[] | {slug, name, dateCreated}'
2. List Your Projects
Get all projects you have access to:
curl -s "https://sentry.io/api/0/projects/" -H "Authorization: Bearer $(printenv SENTRY_TOKEN)" | jq '.[] | {slug, name, platform, dateCreated}'
3. Get Project Details
Get details for a specific project:
Note: Replace
my-orgwith your organization slug andmy-projectwith your actual project slug from the "List Your Projects" output.
curl -s "https://sentry.io/api/0/projects/my-org/my-project/" -H "Authorization: Bearer $(printenv SENTRY_TOKEN)" | jq '{slug, name, platform, status, dateCreated}'
4. List Organization Issues
Get all issues across the organization:
Note: Replace
my-orgwith your organization slug.
curl -s "https://sentry.io/api/0/organizations/my-org/issues/" -H "Authorization: Bearer $(printenv SENTRY_TOKEN)" | jq '.[] | {id, shortId, title, culprit, status, count, userCount, firstSeen, lastSeen}'
Query parameters:
query=is:unresolved- Filter by statusquery=error.type:TypeError- Filter by error typesort=date- Sort by last seen (default)sort=new- Sort by first seensort=freq- Sort by event count
5. List Project Issues
Get issues for a specific project:
Note: Replace
my-organdmy-projectwith your actual values.
curl -s "https://sentry.io/api/0/projects/my-org/my-project/issues/" -H "Authorization: Bearer $(printenv SENTRY_TOKEN)" | jq '.[] | {id, shortId, title, status, count, lastSeen}'
6. Search Issues
Search issues with query:
Note: Replace
my-orgwith your organization slug.
curl -s -G "https://sentry.io/api/0/organizations/my-org/issues/" -H "Authorization: Bearer $(printenv SENTRY_TOKEN)" --data-urlencode "query=is:unresolved level:error" | jq '.[] | {shortId, title, level, count}'
7. Get Issue Details
Get details for a specific issue:
Note: Replace
my-orgwith your organization slug and123456789with an actual issue ID from the "List Issues" output (use theidfield, notshortId).
curl -s "https://sentry.io/api/0/organizations/my-org/issues/123456789/" -H "Authorization: Bearer $(printenv SENTRY_TOKEN)" | jq '{id, shortId, title, culprit, status, level, count, userCount, firstSeen, lastSeen, assignedTo}'
8. Get Latest Event for Issue
Get the most recent event for an issue:
Note: Replace
my-orgwith your organization slug and123456789with an actual issue ID.
curl -s "https://sentry.io/api/0/organizations/my-org/issues/123456789/events/latest/" -H "Authorization: Bearer $(printenv SENTRY_TOKEN)" | jq '{eventID, message, platform, dateCreated, tags, contexts}'
9. List Issue Events
Get all events for an issue:
Note: Replace
my-orgwith your organization slug and123456789with an actual issue ID.
curl -s "https://sentry.io/api/0/organizations/my-org/issues/123456789/events/" -H "Authorization: Bearer $(printenv SENTRY_TOKEN)" | jq '.[] | {eventID, message, dateCreated}'
10. Resolve Issue
Mark an issue as resolved:
Note: Replace
my-orgwith your organization slug and123456789with an actual issue ID.
curl -s -X PUT "https://sentry.io/api/0/organizations/my-org/issues/123456789/" -H "Authorization: Bearer $(printenv SENTRY_TOKEN)" -H "Content-Type: application/json" -d '{"status":"resolved"}' | jq '{id, shortId, status}'
11. Ignore Issue
Ignore an issue:
Note: Replace
my-orgwith your organization slug and123456789with an actual issue ID.
curl -s -X PUT "https://sentry.io/api/0/organizations/my-org/issues/123456789/" -H "Authorization: Bearer $(printenv SENTRY_TOKEN)" -H "Content-Type: application/json" -d '{"status":"ignored"}' | jq '{id, shortId, status}'
12. Unresolve Issue
Reopen a resolved issue:
Note: Replace
my-orgwith your organization slug and123456789with an actual issue ID.
curl -s -X PUT "https://sentry.io/api/0/organizations/my-org/issues/123456789/" -H "Authorization: Bearer $(printenv SENTRY_TOKEN)" -H "Content-Type: application/json" -d '{"status":"unresolved"}' | jq '{id, shortId, status}'
13. List Releases
Get all releases for the organization:
Note: Replace
my-orgwith your organization slug.
curl -s "https://sentry.io/api/0/organizations/my-org/releases/" -H "Authorization: Bearer $(printenv SENTRY_TOKEN)" | jq '.[] | {version, dateCreated, newGroups, projects: [.projects[].slug]}'
14. Get Release Details
Get details for a specific release:
Note: Replace
my-orgwith your organization slug and1.0.0with an actual release version.
curl -s "https://sentry.io/api/0/organizations/my-org/releases/1.0.0/" -H "Authorization: Bearer $(printenv SENTRY_TOKEN)" | jq '{version, dateCreated, dateReleased, newGroups, lastEvent, projects}'
15. List Project Error Events
Get recent error events for a project:
Note: Replace
my-organdmy-projectwith your actual values.
curl -s "https://sentry.io/api/0/projects/my-org/my-project/events/" -H "Authorization: Bearer $(printenv SENTRY_TOKEN)" | jq '.[] | {eventID, title, message, dateCreated}'
Issue Status Values
| Status | Description |
|---|---|
unresolved |
Active issue (default) |
resolved |
Manually resolved |
resolvedInNextRelease |
Auto-resolve on next release |
ignored |
Ignored (won't alert) |
Guidelines
- Discover org slug first: Call the organizations endpoint to get your org slug before using other endpoints
- Pagination: Use
cursorparameter for paginated results - Query syntax: Use Sentry's query language for powerful filtering
- Rate limits: Sentry has rate limits; implement backoff for 429 responses
- Scopes matter: Ensure your token has required scopes for each operation
Didn't find tool you were looking for?