Skip to content

Latest commit

 

History

History
145 lines (104 loc) · 6.52 KB

File metadata and controls

145 lines (104 loc) · 6.52 KB

Sentry for AI

Important

This is a skill source repository — not something you install directly. The skills here are built from this source into installable plugins for Claude Code, Cursor, Codex, and Grok — install one of those, not this repo. They're also served over HTTP at skills.sentry.dev for agents to fetch directly. In the future we may also publish the skills as a generic, standalone skills repository.

Your AI coding assistant already knows how to write code. This plugin teaches it Sentry — how to set it up, how to find and fix production issues, and how to get the most out of every feature.

Whether you're adding Sentry to a new project, debugging a spike in errors, or configuring alerts, just ask. The plugin gives your assistant the context it needs to do it right.

Supports Claude Code, Cursor, Codex, and Grok.

What You Can Do

Set up Sentry in any project — SDK setup wizards that detect your stack, recommend the right features, and walk through the full installation. No copy-pasting from docs.

Add Sentry to my Next.js app
Set up Sentry in my Rails project
Add error monitoring to my iOS app

Find and fix production issues — Query your Sentry environment, triage errors, and fix them in place.

What are the top errors in the last 24 hours?
Which issues are affecting the most users?
Fix the recent Sentry errors

Review code with Sentry context — Automatically resolve bugs that Sentry or Seer flag in pull request comments.

Review PR #118 and fix the Sentry comments

Configure monitoring — Set up alerts, instrument AI/LLM calls, connect OpenTelemetry pipelines.

Create a Slack alert for new high-priority issues
Monitor my OpenAI calls with Sentry
Set up OTel Collector with Sentry exporter

Distribution

This repository is the single source of truth for all skills, but it is not itself an installable plugin. Each assistant needs the plugin in a slightly different shape, so the per-agent plugins are built from it by the build scripts under plugin-src/<agent>/build.sh. CI runs these on every push and deploys each result to its own distribution repository, whose root is exactly that agent's plugin:

Agent Distribution repository
Claude Code getsentry/plugin-claude
Cursor getsentry/plugin-cursor
Codex getsentry/plugin-codex
Grok getsentry/plugin-grok

These repositories are generated; do not edit them. Each one's README has the install instructions for that agent.

The skill library is also browsable at skills.sentry.dev and available through the skills.sh installer.

Build it yourself

Each plugin-src/<agent>/build.sh takes an output directory and writes that agent's plugin into it (the Codex build moves the plugin under plugins/sentry/ and swaps the skill tree's disable-model-invocation flags for Codex's agents/openai.yaml policy):

git clone https://github.com/getsentry/sentry-for-ai.git
cd sentry-for-ai
plugin-src/codex/build.sh /tmp/sentry-codex   # or plugin-src/{claude,cursor,grok}

To build any target locally, run plugin-src/<agent>/build.sh <output-dir> (claude, cursor, codex, or grok).

Skills

Core

Skill What it does
sentry-get-started Guided entry point — orients to your current Sentry setup and routes to the right skill
sentry-instrument Add Sentry to a project, or wire up any signal — error monitoring, tracing, logging, metrics, profiling, session replay, user feedback, cron check-ins, and AI/LLM monitoring. Detects your platform and pulls the code from the reference library.
sentry-debug-issue Find a Sentry issue, pull full context, optionally run Seer root-cause / autofix, apply the fix, and resolve it

Workflow

Skill What it does
sentry-code-review Resolve sentry[bot] comments on GitHub PRs
sentry-pr-code-review Fix issues flagged by Seer Bug Prediction
sentry-sdk-upgrade Upgrade the Sentry JavaScript SDK across major versions

Feature Setup

Skill What it does
sentry-setup-ai-monitoring Instrument OpenAI, Anthropic, LangChain, Vercel AI, Google GenAI
sentry-otel-exporter-setup Configure OTel Collector with the Sentry exporter for multi-project routing
sentry-create-alert Create alerts via the Sentry workflow engine API
sentry-snapshots-cocoa Set up Sentry Snapshots for Apple/Cocoa projects

Reference Library

sentry-instrument doesn't hard-code platform steps — it pulls them from a shared library that the build hydrates into the skill:

  • references/sdks/<platform>/ — per-platform install and per-signal code, one directory per supported platform.
  • references/concepts/ — per-signal strategy: errors, tracing, logging, metrics, profiling, session replay, user feedback, crons, releases, data scrubbing, and choosing-a-signal.

Superseded per-SDK "wizard" skills are frozen under skills-legacy/, excluded from the plugin build.

Prerequisites

The plugin configures the Sentry MCP server automatically on install. No extra setup needed.

Some workflow skills require the GitHub CLI:

brew install gh    # macOS
gh auth login

Contributing

Skills follow the Agent Skills specification. Each skill is a directory with a SKILL.md file containing YAML frontmatter and markdown instructions. A skill can declare the shared references it needs in a references.yml manifest; the build hydrates the matching files from the shared library at references/ into the skill so the shipped copy is self-contained.

License

MIT