configure-plugin/skills/configure-instrumentation/SKILL.md
Observability instrumentation: OpenTelemetry traces/metrics, structured logging, Sentry. Use when wiring telemetry, tracing, or logging into a repo.
npx skillsauth add laurigates/claude-plugins configure-instrumentationInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Check and upsert observability instrumentation — OpenTelemetry traces and metrics, structured logging, and error tracking — against project standards.
| Use this skill when... | Use another approach when... |
|------------------------|------------------------------|
| Wiring up observability for a repo (traces, metrics, logs) in one pass | Only Sentry error tracking is needed (use /configure:sentry) |
| Checking what instrumentation a project already has | Debugging a live tracing/metrics pipeline (use the vendor's tools) |
| Adding vendor-neutral OpenTelemetry instead of a vendor-locked SDK | Load-testing performance (use /configure:load-tests) |
| Adding structured logging (pino/winston, structlog/loguru) | Profiling memory (use /configure:memory-profiling) |
| Standardizing OTEL_* env-var configuration and OTLP export | Managing dashboards/alerts in Grafana or the vendor UI |
find . -maxdepth 1 -name 'package.json'find . -maxdepth 1 -name 'pyproject.toml'find . -maxdepth 1 -name '.project-standards.yaml' -type ffind . -maxdepth 1 -name 'package.json' -exec grep -o '"@opentelemetry/[^"]*"' {} +find . -maxdepth 1 -name 'pyproject.toml' -exec grep -o 'opentelemetry-[a-z-]*' {} +find . -maxdepth 2 -type f \( -name 'otel*' -o -name '*telemetry*' -o -name 'tracing*' -o -name 'instrumentation*' \) -not -path '*/node_modules/*'find . -maxdepth 1 \( -name 'package.json' -o -name 'pyproject.toml' \) -exec grep -oE '"(pino|winston)"|structlog|loguru' {} +find . -maxdepth 1 \( -name 'package.json' -o -name 'pyproject.toml' \) -exec grep -oE '@sentry/[a-z-]*|sentry-sdk' {} +Parse these from $ARGUMENTS:
| Flag | Description |
|------|-------------|
| --check-only | Report status without offering fixes |
| --fix | Apply all fixes automatically without prompting |
| --type <type> | Restrict to one signal: otel (traces+metrics SDK), logging, metrics, sentry |
Execute this instrumentation compliance check:
bash "${CLAUDE_SKILL_DIR}/scripts/configure-instrumentation.sh" --project-dir "$(pwd)"
The script emits OTEL_SDK=, OTEL_INIT=, OTEL_ENV=, STRUCTURED_LOGGER=,
METRICS_EXPORTER=, SENTRY_SDK=, and RECOMMENDATION=configured|partial|setup.
Use these booleans as the ground truth for the rest of the check — do not
re-derive detection by hand.
.project-standards.yaml for project_type if presentpackage.json (Express/Fastify/Next.js shape decides the
auto-instrumentation set)pyproject.toml or requirements.txt (Django/Flask/FastAPI decide
the instrumentor packages)Compare the detection output against the compliance tables in REFERENCE.md. The standard posture is:
instrumentation.ts NodeSDK / telemetry.py), OTLP exporter
configured via OTEL_EXPORTER_OTLP_ENDPOINT (never hardcoded endpoints)OTEL_TRACES_SAMPLER set for production (parentbased_traceidratio)/metrics endpointSENTRY_SDK=true, delegate the Sentry compliance
pass to /configure:sentry --check-only via the SlashCommand tool rather
than re-checking it hereIf --type was given, check only that signal.
Print a compliance report: per-signal status (PASS/WARN/FAIL), the
RECOMMENDATION verdict, and missing items. If --check-only, stop here.
Using the templates in REFERENCE.md:
instrumentation.ts NodeSDK;
Python telemetry.py or opentelemetry-instrument entrypoint)OTEL_SERVICE_NAME / OTEL_EXPORTER_OTLP_*
to .env.example and deployment manifests — never commit real endpoints
with credentials/configure:sentry --fix via SlashCommandUpdate or create .project-standards.yaml:
standards_version: "2025.1"
project_type: "<detected>"
last_configured: "<timestamp>"
components:
instrumentation: "2025.1"
| Variable | Description | Required |
|----------|-------------|----------|
| OTEL_SERVICE_NAME | Logical service name on every span/metric | Yes |
| OTEL_EXPORTER_OTLP_ENDPOINT | OTLP collector endpoint | Yes |
| OTEL_EXPORTER_OTLP_HEADERS | Auth headers for a hosted collector | Vendor-dependent |
| OTEL_TRACES_SAMPLER / OTEL_TRACES_SAMPLER_ARG | Production sampling | Recommended |
| OTEL_RESOURCE_ATTRIBUTES | deployment.environment=... etc. | Recommended |
For SDK install commands, init templates, sampling guidance, logger configuration, and metrics-endpoint patterns, see REFERENCE.md.
| Context | Command |
|---------|---------|
| Quick posture check | bash "${CLAUDE_SKILL_DIR}/scripts/configure-instrumentation.sh" --project-dir "$(pwd)" |
| Full compliance check | /configure:instrumentation --check-only |
| Auto-fix everything | /configure:instrumentation --fix |
| Logging only | /configure:instrumentation --type logging |
| Error tracking only | /configure:instrumentation --type sentry |
| Find hardcoded OTLP endpoints | rg -n 'OTEL_EXPORTER_OTLP_ENDPOINT.*https?://' --glob '!.env.example' |
OTEL_INIT=false): FAIL — an
installed-but-unstarted SDK silently exports nothing/configure:sentry - Sentry error-tracking setup (the vendor complement; this skill delegates Sentry fixes there)/configure:all - Run all compliance checks/configure:status - Quick compliance overviewtypescript-plugin:typescript-sentry - Day-to-day Sentry SDK usage patterns for Bun/Node/Next.jsdevelopment
Debug HTTP APIs: trace requests, inspect headers. Use when a request fails: check status first.
documentation
Render architecture diagrams from text sources. Use when documenting system topology.
tools
Inspect JSON payloads and extract nested fields. Use when parsing API responses.
tools
--- name: no-description allowed-tools: Read --- # No Description This skill has no description and must be dropped with a warning.