Agent skill
error-tracking
Set up error tracking with actionable context. Use when configuring error capture or error boundaries.
Install this agent skill to your Project
npx add-skill https://github.com/nexus-labs-automation/web-observability/tree/main/skills/error-tracking
SKILL.md
Error Tracking
Capture errors with the context needed to debug them.
Core Principle
An error without context is useless. Every error should include:
| Context | Why | Example |
|---|---|---|
route |
Where it happened | "/checkout" |
job_name |
What user was doing | "checkout" |
job_step |
Where in the flow | "payment" |
user_segment |
Who's affected | "premium" |
app_version |
Release correlation | "1.2.3" |
Error Types to Capture
| Type | Capture Method |
|---|---|
| Unhandled exceptions | window.onerror, SDK auto-capture |
| Promise rejections | window.onunhandledrejection |
| Component errors | Error boundaries |
| Async/await errors | try/catch with context |
| API errors | Fetch/axios interceptors |
What NOT to Include
| Don't | Why |
|---|---|
| Passwords | Security |
| Email/phone | PII |
| Full request bodies | PII, size limits |
| Entire app state | Unbounded |
| Localized messages | Breaks grouping |
Implementation
See templates/error-boundary.tsx for React error boundary with telemetry.
Use Read tool to load template when generating implementation.
Anti-Patterns
See references/anti-patterns.md for common error tracking mistakes.
Related
skills/source-map-setup- Readable stack tracesskills/api-tracing- API error correlationreferences/frameworks/*.md- Framework-specific error handling
Recommended Agent Skills
Expand your agent's capabilities with these related and highly-rated skills.
user-journey-tracking
Track user journeys with intent context and friction signals. Use when instrumenting funnels or multi-step flows.
bundle-performance
Monitor JavaScript bundle size and execution performance. Use when tracking bundle size, identifying large chunks, or optimizing load performance.
hydration-performance
Measure SSR hydration timing and issues. Use when tracking hydration performance, debugging hydration mismatches, or optimizing SSR/SSG applications.
source-map-setup
Configure source maps for readable stack traces. Use when setting up error tracking, debugging production issues, or configuring build tools.
route-transition-tracking
Measure time from navigation to page fully loaded and interactive. Use when tracking SPA navigation, route changes, or slow page transitions.
synthetic-monitoring
Set up synthetic monitoring with Lighthouse CI and Playwright. Use when implementing automated performance testing, CI/CD performance gates, or proactive monitoring.
Didn't find tool you were looking for?