agentsclimarketplace

Otel cli

Skill hrntknr/otel-cli/skills/otel-cli

Inspects OpenTelemetry traces, logs, and metrics from a local OTLP server. Use when the user needs to debug distributed traces, inspect application logs, check metrics, or troubleshoot observability issues during development.From its SKILL.md

Install
npx -y skills add hrntknr/otel-cli --skill otel-cli

Assembled from the repository path, not quoted from the project. Check it against their README if it does not work.

One thing to look at

  • 4 stars4 stars. Stars are a popularity signal and not a quality one, but at this level it is likely that nobody has read this closely except its author, and you would be relying on your own review.

SKILL.md

3.0 KB, as published. Nobody here has run it

otel-cli

An in-memory OTLP server with SQL querying. Start a local collector, ingest traces/logs/metrics, and query with standard SQL.

Quick Start

# 1. Start server (background)
otel-cli server --no-tui &

# 2. App exports to localhost:4317 (gRPC) or localhost:4318 (HTTP)

# 3. Query
otel-cli sql "SELECT span_name, duration_ns FROM traces WHERE service_name = 'myapp'"

# 4. Cleanup
otel-cli shutdown

SQL Queries (Primary Interface)

Use otel-cli sql for all querying. Powered by DataFusion (standard SQL). Use --format jsonl for programmatic processing.

otel-cli sql "SELECT * FROM traces WHERE service_name = 'myapp'" --format jsonl
otel-cli sql "SELECT * FROM traces WHERE attributes['http.method'] = 'GET'"
otel-cli sql "SELECT service_name, COUNT(*), AVG(duration_ns) FROM traces GROUP BY service_name"
otel-cli sql "SELECT * FROM logs WHERE severity = 'ERROR'"
otel-cli sql "SELECT * FROM metrics WHERE metric_name = 'http.duration'"
otel-cli sql -f "SELECT * FROM traces"   # Follow mode (real-time)

Convenience Subcommands

Shorthand wrappers around SQL. Use otel-cli sql for anything beyond simple filtering.

otel-cli traces --service myapp --limit 50
otel-cli traces -f --service myapp              # Follow
otel-cli logs --severity ERROR --since 5m
otel-cli metrics --name http_requests_total

Server Management

otel-cli status                                  # Show counts
otel-cli clear --traces --logs --metrics         # Reset state
otel-cli shutdown                                # Stop server

SQL Schema

traces

ColumnType
trace_id, span_id, parent_span_idUtf8
span_name, service_name, status_messageUtf8
kind, status_codeInt32
start_time, end_time, duration_nsUInt64
attributes, resourceMap<Utf8, Utf8>

logs

ColumnType
timestampUInt64
severityUtf8
severity_numberInt32
body, service_name, trace_id, span_idUtf8
attributes, resourceMap<Utf8, Utf8>

metrics

ColumnType
timestampUInt64
metric_name, metric_type, service_nameUtf8
value, sumFloat64
countUInt64
attributes, resourceMap<Utf8, Utf8>

Agent Tips

  • Always use --no-tui when starting the server
  • Use --format jsonl for programmatic processing
  • Use otel-cli clear between test runs to reset state
  • Prefer otel-cli sql over convenience subcommands — it supports full SQL (aggregation, joins, subqueries)
  • Access map columns with bracket syntax: attributes['http.method'], resource['service.name']
  • Store capacity: --max-traces (default 1000), --max-spans, --max-logs, --max-metrics

Keep looking

Skills are one crate of 627,801. Ordering is by how many stacks a row turns up in, so the top of any crate is what has actually been picked rather than what has the most stars.