autotel-investigate
Query OpenTelemetry telemetry (traces, metrics, logs, LLM analytics) via the autotel CLI.
Skill by jagreehal
Chalk Labs
Need help deploying autotel-investigate?
Chalk Labs sets up agents like this inside real teams: connected to your tools, tested on your data, with a human in the loop where it matters.
Install
Works with Claude Code, Claude apps, Codex, Cursor, Gemini CLI, GitHub Copilot, VS Code, OpenCode, Goose, Windsurf. Read the repository before you give any tool access to your data.
npx agentmarket install skill/jagreehal-autotel-investigate
Asks which of your tools to add it to (Claude Code, Codex, Cursor, VS Code, Windsurf, Gemini CLI, Claude Desktop) and shows the change first. See https://agentmart.dev/cli.
Get the weekly diff
The weekly diff: one email a week with new agent tools, notable updates and grade changes, plus security alerts for tools you follow. Double opt-in, one-click unsubscribe.
About
Use cases: documents, data, ml
Reviews
Write a reviewNo reviews yet. Installed it? Reviews come from verified installers only. How reviews work
Permissions
What this skill can do and what it asks for, from its SKILL.md and code. Checked Oct 25, 2026.
- Tools
- No tools found
- Secrets
- None asked for
- Install scripts
- None found
Network hosts it talks to 1
codeload.github.com· found in install command
Files it touches
~/.claude/skills/autotel-investigate
What's inside
- Skill name
autotel-investigate- Description
- Query OpenTelemetry telemetry (traces, metrics, logs, LLM analytics) via the autotel CLI. Use when the user asks about a production issue, slow request, error spike, expensive LLM call, or any "what is happening in my service" question. Each command returns one JSON document on stdout — parse it and answer from the data.
- License
- Apache-2.0
- Instructions
- 119 lines in SKILL.md · view on GitHub
Files (1)
- SKILL.md
SKILL.md (first lines)
# autotel-investigate
When the user asks about a production issue or telemetry data, drive the `autotel` CLI. Every command emits one JSON document on stdout. Parse `result.data` on success or `result.error` on failure.
## Core principles
1. **Discover, don't recall.** The CLI publishes its own surface — `autotel commands`, `autotel schema`, `autotel <group> --help`. Use those for exact command names, flags and defaults rather than working from memory or from a list in a skill file; they can't go stale against the installed version, and a list here can.
2. **Read what's there before querying it.** `autotel health` tells you whether the backend is even reachable and which signals it serves; `autotel discover trace-fields` tells you which attributes exist before you filter on one.
3. **Answer from the data.** Never present a conclusion the JSON doesn't support. If a query returns nothing, say so — an empty result is a finding, not a failure to be papered over.
## Discovering the command surface
```bash
autotel commands # compact listing: every command + whether it mutates, needs network, supports JSON
autotel schema # full CLI manifest as JSON (large — prefer `commands` unless you need flag detail)
autotel <group> --help # flags and defaults for one group, e.g. `autotel query --help`
autotel <group> <cmd> --help # flags for one command, e.g. `autotel diagnose slos --help`
autotel examples <command> # copy-pasteable examples
```
`autotel commands` is the cheap default. Reach for `autotel schema` only when you need the full flag surface in one shot.
## Backend selection: required for every query command
Every command that reads telemetry needs a backend. Pick one and reuse it:
| Backend | Flags |
| ----------------------------------- | ------------------------------------------------------------------ |
| Built-in OTLP collector (in-memory) | `--backend collector` |
| Jaeger | `--backend jaeger --jaeger-base-url http://localhost:16686` |
| Tempo | `--backend tempo --tempo-base-url http://localhost:3200` |
| Prometheus | `--backend prometheus --prometheus-base-url http://localhost:9090` |
| Loki | `--backend loki --loki-base-url http://localhost:3100` |
| Tempo + Prom + Loki together | `--backend stack` + the three URL flags |
| Auto-detect localhost | `--backend auto` |
| Local JSON fixture | `--backend fixture --fixture-path ./telemetry.json` |
Hosted vendors (`capabilities` reports which signals each serves; Datadog serves traces, logs and metrics, the others traces):
| Backend | Flags | Credentials (environment only) |
| ---------------- | ------------------------------------------------------------------------ | ------------------------------------------------------------------------ |
| Pydantic Logfire | `--backend logfire [--logfire-base-url https://logfire-eu.pydantic.dev]` | `LOGFIRE_READ_TOKEN` (must be **read**-scope; a write token is rejected) |
| Datadog | `--backend datadog [--datadog-site datadoghq.eu]` | `DD_API_KEY` **and** `DD_APP_KEY` (both required; see below) |
| SigNoz | `--backend signoz --signoz-base-url https://signoz.example.com` | `SIGNOZ_API_KEY` (omit for an unauthenticated self-hosted instance) |
| Cloudflare | `--backend cloudflare --cloudflare-account <account id>` | `CLOUDFLARE_API_TOKEN` (Account Analytics Read) |
Datadog needs two keys because it splits credentials by direction. The API key writes telemetry in; the application key reads it back out, scoped `apm_read`, `logs_read_data`, `metrics_read` and `timeseries_query`. An `.env` copied from a service that exports to Datadog carries the API key alone, so `DD_APP_KEY` is the one that goes missing. `autotel health` names it rather than returning an empty result. A 403 means the keys reached Datadog and it refused them: either `DD_SITE` does not match the org, or the application key lacks `apm_read`.
Credentials are read from the environment and never accepted as flags — argv is visible to anything that can list the process table. Never ask the user to paste a key into the chat; ask them to export it.
Environment variables work for backend selection too (`AUTOTEL_BACKEND`, `JAEGER_BASE_URL`, …). Flags win over env. If you're not sure which backend is configured, run `autotel health` first — a misconfigured vendor backend reports `healthy: false` with the missing variable named, rather than failing the command.
Some commands need no backend at all — semantic-convention lookup, span scoring and collector-config work are all local. `autotel commands` marks which need network.
## Decision tree: pick a command
1. **"Is anything broken?"** → `autotel diagnose errors` (recent error spans grouped by service/operation)
2. **"What's slow?"** → `autotel diagnose anomalies`, or `autotel llm slow` for LLM-heavy services
3. **"Show me trace `<id>`"** → `autotel trace get <id>` for raw, `autotel trace summary <id>` for incident-friendly
4. **"Why did this trace fail?"** → `autotel diagnose root-cause <id>`, then `autotel correlate trace <id>` for the full picture
5. **"Why is service X degraded?"** → `autotel correlate explain-slowdown --service X` (anomalies + root causes + logs)
6. **"How much are we spending on LLMs?"** → `autotel llm usage`, then `autotel llm expensive` for top traces
7. **"What services / ops / fields exist?"** → `autotel discover services` / `autotel topology services` / `autotel discover trace-fields`
8. **"Are we meeting SLOs?"** → `autotel diagnose slos --service X` (thresholds are flags — check `--help`)
9. **"Are we under attack / any security signals?"** → `autotel security summary` (auth events, probes, denied responses)
10. **"Any MCP prompt-injection / tool abuse?"** → `autotel security mcp` (injection verdicts, output-budget breaches, untrusted-content tool calls)
11. **"Is my telemetry even arriving?"** → `autotel health --otlp-endpoint <url>` writes a probe span and reports ingest-to-queryable lag
## Command groups
Use these to know _where_ to look; use `--help` on the group for the exact commands and flags.
| Group | What it answers | Needs a backend |
| ------------------------ | -------------------------------------------------------------------------------- | --------------- |
| `health`, `capabilities` | Is the backend reachable, which signals does it serve, how stale is the data | yes |
| `discover` | Which services exist, which span/log fields exist and their example values | yes |
| `query` | Raw search over traces, spans, metrics, logs | yes |
| `trace` | Fetch or summarise one trace by id | yes |
| `topology` | Services, operations, dependency map | yes |
| `diagnose` | Anomalies, root cause, error grouping, SLO checks | yes |
| `correlate` | One trace across traces + metrics + logs; slowdown explanations | yes |
| `llm` | Token/cost usage, model stats, expensive and slow traces, tool spans | yes |
| `security` | `security.*` events, suspicious requests, denied responses, MCP boundary signals | yes |
| `semconv` | OpenTelemetry semantic-convention lookup | no |
| `score` | Score a span for instrumentation quality (JSON on stdin) | no |
| `collector` | Validate, explain and generate OTLP Collector config | no |
## Measuring ingest lag
`autotel health --otlp-endpoint http://localhost:4318` writes one probe span and polls until it reads back, reporting `freshness.timeToQueryableSeconds`.
This matters before you trust a negative result: backends differ by two orders of magnitude in ingest lag, and on a slow one an agent that writes then immediately reads sees nothing and wrongly concludes the operation produced no telemetry. If a trace you expect is missing, check freshness before concluding it was never emitted. `--freshness-timeout-ms` bounds the wait (default 120000).
Against a hosted endpoint the probe write needs auth, taken from the standard `OTEL_EXPORTER_OTLP_HEADERS` (`Authorization=<token>`) so no token lands in argv. Note this is the **write** credential, which for most vendors is a different token from the read one the query backend uses.
The probe sends OTLP protobuf by default — the encoding every OTLP/HTTP receiver must accept, and the only one some vendors take. The built-in collector parses JSON only and is switched automatically; anything else can be forced with `--otlp-encoding json`. If a receiver rejects the payload, the error says which encoding was sent and which to try.
## Output contract
```json
// success
{ "ok": true, "command": "query traces", "data": { … } }
// failure
{ "ok": false, "error": { "type": "validation"|"runtime", "code": "AUTOTEL_E_*", "message": "…", "retryable": false } }
```
Exit codes: `0` success, `2` validation error, `1` runtime error.
Always parse the JSON; never try to read prose from stdout.
## When to use this vs the MCP server
- Use this skill when: the user just wants an answer, you're driving a one-shot prompt, or no MCP server is configured.
- Prefer `autotel-mcp` when: the session is an extended incident review with many follow-ups against a slow remote backend (the persistent connection wins on repeated queries), or you need its analysis tools: `aggregate_spans` (counts and percentiles grouped by any field), `aggregate_logs` (top message patterns), `what_changed` (version changes with before/after error rate and p95).
Both read the same backends. Pick the one with less ceremony for the situation.From jagreehal/autotel, Apache-2.0.
More from jagreehal/autotel
- 0.631score
find-observability-gaps
jagreehal
Scores the observability of every entry point in a codebase with `autotel map` and closes the gaps it reports.
SkillAFreshness: A★ 8Claude Code +9 - 0.631score
build-audit-trails
jagreehal
Build or review tamper-aware audit trails on top of OpenTelemetry spans using autotel and the autotel-audit package (`withAudit`, `setAuditAttributes`…
SkillAFreshness: A★ 8Claude Code +9 - 0.626score
autotel-testing
jagreehal
Test autotel instrumentation with createTraceCollector() and InMemorySpanExporter.
SkillAFreshness: A★ 8Claude Code +9 - 0.626score
autotel-core
jagreehal
Explains when to reach for trace vs span vs request logger vs events in Autotel, and the package exports each lives behind.
SkillAFreshness: A★ 8Claude Code +9 - 0.626score
migrate-to-autotel
jagreehal
Migrate an existing observability setup to autotel.
SkillAFreshness: A★ 8Claude Code +9 - 0.626score
production-observability
jagreehal
Takes a Node.js or TypeScript service to production-grade observability with autotel, in an existing codebase or a new one, and keeps it there.
SkillAFreshness: A★ 8Claude Code +9 - 0.626score
design-alertable-metrics
jagreehal
Designs metrics an alarm can actually be written against — picking the attributes that let a rule isolate one failing dependency, pinning metric names as a…
SkillAFreshness: A★ 8Claude Code +9 - 0.626score
autotel-anti-patterns
jagreehal
Common autotel mistakes and how to fix them.
SkillAFreshness: A★ 8Claude Code +9 - 0.626score
autotel-framework-setup
jagreehal
Set up autotel in Hono, Fastify, TanStack Start, Cloudflare Workers, Next.js, Express, MCP, and edge runtimes.
SkillAFreshness: A★ 8Claude Code +9 - 0.626score
autotel-request-logging
jagreehal
Accumulates request-scoped context and emits one wide-event snapshot per request with getRequestLogger(), set(), setLevel(), info/warn/error, and emitNow().
SkillAFreshness: A★ 8Claude Code +9 - 0.626score
autotel-structured-errors
jagreehal
Throws and parses errors that explain themselves with message, why, fix, link, and status, including reusable catalogs via defineErrorCatalog.
SkillAFreshness: A★ 8Claude Code +9 - 0.626score
debug-missing-spans
jagreehal
Troubleshoot when expected OpenTelemetry spans don't reach the backend.
SkillAFreshness: A★ 8Claude Code +9
Signals
- Stars
- 8
- Forks
- 3
- Open issues
- 0
- Last commit (this folder)
- Oct 10, 2026 (21 days ago)
- Last release
- Sep 27, 2026 (1 month ago)
From GitHub (fetched Oct 24, 2026).
Details
- License
- Apache-2.0
- Repository
- github.com/jagreehal/autotel
- Website
- jagreehal.github.io/autotel/
- First seen
- Oct 24, 2026
- Last checked
- Oct 24, 2026
- Source
- GitHubgithub-graphql
More from jagreehal
- 0.631score
build-audit-trails
jagreehal
Build or review tamper-aware audit trails on top of OpenTelemetry spans using autotel and the autotel-audit package (`withAudit`, `setAuditAttributes`…
SkillAFreshness: A★ 8Claude Code +9 - 0.631score
find-observability-gaps
jagreehal
Scores the observability of every entry point in a codebase with `autotel map` and closes the gaps it reports.
SkillAFreshness: A★ 8Claude Code +9 - 0.626score
analyze-traces
jagreehal
Analyze OpenTelemetry traces and structured logs from a running autotel service to debug errors, investigate latency, follow requests across services, and…
SkillAFreshness: A★ 8Claude Code +9 - 0.626score
autotel-core
jagreehal
Explains when to reach for trace vs span vs request logger vs events in Autotel, and the package exports each lives behind.
SkillAFreshness: A★ 8Claude Code +9 - 0.626score
autotel-testing
jagreehal
Test autotel instrumentation with createTraceCollector() and InMemorySpanExporter.
SkillAFreshness: A★ 8Claude Code +9 - 0.626score
autotel-anti-patterns
jagreehal
Common autotel mistakes and how to fix them.
SkillAFreshness: A★ 8Claude Code +9
Done for you
Rather not set it up yourself?
Chalk Labs scopes, builds and runs agents for your team: the task audit, the eval harness, the integrations and the weekly ops report. Fixed scope, priced before we start.
See how we build AI agents →Read the case studies
Chalk Labs is a two-founder AI and growth studio. We build AI agents, CRMs and MVPs for Web3 and AI companies, and have shipped 50+ product and token launches.
- launches shipped
- 50+
- launches shipped
- media placements
- 500+
- media placements
- founders on every account
- 2
- founders on every account
Press we've placed: Forbes · CoinDesk · Decrypt · Cointelegraph · The Block
Rahil Jain, Co-founder, Chalk Labs. Ex-Goldman Sachs engineer. You talk to the person who builds it.
Get autotel-investigate running in your business
Tell us what you want to automate. A founder replies within one working day with a plan, not a pitch deck.
Cite this page
autotel-investigate skill. Agent Mart. https://agentmart.dev/skills/jagreehal-autotel-investigate (last updated 2026-10-24)