Agent skill · data analytics · jeremylongshore
sentry-error-capture
Implement advanced error capture and context enrichment with Sentry.
Why this skill is useful
Provides specific implementation patterns for error capturing and context enrichment using Sentry that the AI wouldn't reliably generate on its own.
What it needs
Requires @sentry/node, sentry-sdk installed locally. Requires sentry account access. About 5k tokens when loaded. Last updated 2026-08-07. 2,604 stars on the source repository.
What this skill does
Sentry Error Capture Overview Capture errors and enrich them with structured context so your team can diagnose production issues in seconds instead of hours. Covers captureException, captureMessage, scoped context (withScope / pushscope), breadcrumbs, custom fingerprinting, and beforeSend filtering using @sentry/node v8 and sentry-sdk v2 APIs. Prerequisites Sentry SDK installed and initialized (@sentry/node v8+ or sentry-sdk v2+) A valid DSN configured via environment variable (SENTRYDSN) Understanding of try/catch (JS) or try/except (Python) error handling A Sentry project created at sentry.io Instructions Step 1 -- Capture Exceptions with Full Stack Traces Always pass real Error objects (or Python exception instances), never plain strings. Plain strings lose the stack trace, making debugging far harder. TypeScript (@sentry/node) Python (sentry-sdk) Step 2 -- Capture Messages for Non-Exception Events Use captureMessage for events that are not exceptions but still worth tracking: deprecation warnings, capacity thresholds, business logic anomalies. TypeScript Python Step 3 -- Enrich Events with Scoped Context Use withScope (TypeScript) or pushscope (Python) to attach context to a single event without polluting the global scope. Context is automatically cleaned up when the scope exits. TypeScript -- withScope Python -- pushscope Breadcrumbs Breadcrumbs create a trail of events leading up to an error. Sentry auto-captures some (console logs, HTTP requests, DOM events), but manual breadcrumbs add domain-specific context. TypeScript Python Custom Fingerprinting Override Sentry's default grouping to control how errors are merged into issues. Without custom fingerprints, Sentry groups by stack trace, which can split logically identical errors or merge unrelated ones. Global Filtering with beforeSend Configure beforeSend during initialization to filter noise, scrub sensitive data, or enrich all events globally. …
How to use it
Reference it in AdaL, Claude Code, Cursor or any coding agent — nothing to install:
@skills jeremylongshore/sentry-error-capture--9ee5fe