Index of every page on this site: llms.txt
All skills
axiomhq avatar

/axiom-build-dashboard

@5b11222 official
by Axiom, Inc.axiomhq/skills18 stars
2
Run it yourself

Designs and builds Axiom dashboards via API. Covers chart types, APL and metrics/MPL query patterns, SmartFilters, layout, and configuration options. Use when creating dashboards, migrating from Splunk, or configuring chart options.

Use this Skill: https://skilld.dev/gh/axiomhq/skills/axiom-build-dashboard

Nothing lands on disk. Nothing to clean up.

Fork this Skill

Edit a local copy. It keeps the author and licence.

referencechart-cookbook.md

≈2.9k tokens on demand. Your agent reads this file only when SKILL.md points to it.

Chart Cookbook

Detailed APL patterns for each chart type with real-world examples.

Note: Dashboard panel queries inherit time from the UI picker—no explicit _time filter needed. The examples below show ad-hoc query patterns with time filters for testing in the Query tab. Remove the where _time between (...) line when using these in dashboards.


Statistic

Single-value panels for KPIs and current state.

Error Rate (Percentage)

['http-logs']
| where _time between (ago(5m) .. now())
| where service == "api-gateway"
| summarize 
    total = count(),
    errors = countif(status >= 500)
| extend error_rate = round(100.0 * errors / total, 2)
| project error_rate

Current p95 Latency

['http-logs']
| where _time between (ago(5m) .. now())
| where service == "api-gateway"
| summarize p95 = percentile(duration_ms, 95)

Request Rate (per second)

['http-logs']
| where _time between (ago(5m) .. now())
| where service == "api-gateway"
| summarize requests = count()
| extend rps = round(requests / 300.0, 1)  // 300 seconds = 5 min
| project rps

Active Errors (count)

['http-logs']
| where _time between (ago(5m) .. now())
| where status >= 500
| summarize error_count = count()

Comparison to Baseline

['http-logs']
| where _time between (ago(1h) .. now())
| summarize 
    last_5m = countif(_time >= ago(5m) and status >= 500),
    prev_55m = countif(_time < ago(5m) and status >= 500)
| extend change_pct = round(100.0 * (last_5m - prev_55m/11) / (prev_55m/11 + 0.001), 1)
| project last_5m, change_pct

TimeSeries

Time-based trends with proper binning.

Traffic Over Time

['http-logs']
| where _time between (ago(1h) .. now())
| where service == "api-gateway"
| summarize requests = count() by bin(_time, 1m)

Error Rate Over Time

['http-logs']
| where _time between (ago(1h) .. now())
| where service == "api-gateway"
| summarize 
    total = count(),
    errors = countif(status >= 500)
  by bin(_time, 1m)
| extend error_rate = 100.0 * errors / total
| project _time, error_rate

Latency Percentiles Over Time

['http-logs']
| where _time between (ago(1h) .. now())
| where service == "api-gateway"
| summarize 
    p50 = percentile(duration_ms, 50),
    p95 = percentile(duration_ms, 95),
    p99 = percentile(duration_ms, 99)
  by bin(_time, 1m)

Traffic by Status Class (Stacked)

['http-logs']
| where _time between (ago(1h) .. now())
| extend status_class = case(
    status < 300, "2xx",
    status < 400, "3xx",
    status < 500, "4xx",
    "5xx"
  )
| summarize count() by bin(_time, 1m), status_class

Multi-Service Comparison

['http-logs']
| where _time between (ago(1h) .. now())
| where service in ("api-gateway", "auth-service", "payment-service")
| summarize requests = count() by bin(_time, 1m), service

Several Pipelines on One Chart

When the series cannot come from one pipeline (p95 and p99 from separate histogram aggregations, or two different metrics), give the chart several queries instead of stretching one summarize. Each entry in queries[] is a full pipeline with its own legend name. Shape and jq recipe: chart-config.md § Multiple Queries.


Table

Top-N breakdowns and detailed lists.

Top 10 Failing Routes

['http-logs']
| where _time between (ago(1h) .. now())
| where status >= 500
| summarize errors = count() by route
| top 10 by errors
| project Route = route, Errors = errors

Top Error Messages

['http-logs']
| where _time between (ago(1h) .. now())
| where status >= 500
| summarize count = count() by error_message
| top 10 by count
| project Message = error_message, Count = count

Worst Pods by Error Rate

['http-logs']
| where _time between (ago(1h) .. now())
| summarize 
    total = count(),
    errors = countif(status >= 500)
  by pod = ['kubernetes.pod.name']
| extend error_rate = round(100.0 * errors / total, 2)
| where total >= 100  // minimum sample size
| top 10 by error_rate
| project Pod = pod, "Error Rate %" = error_rate, Total = total, Errors = errors

Latency by Route

['http-logs']
| where _time between (ago(1h) .. now())
| summarize 
    requests = count(),
    p50 = percentile(duration_ms, 50),
    p95 = percentile(duration_ms, 95),
    p99 = percentile(duration_ms, 99)
  by route
| top 10 by p95
| project Route = route, Requests = requests, "p50 (ms)" = p50, "p95 (ms)" = p95, "p99 (ms)" = p99

Recent Errors with Details

['http-logs']
| where _time between (ago(15m) .. now())
| where status >= 500
| top 20 by _time
| project Time = _time, Route = route, Status = status, Message = error_message, TraceID = trace_id

Customer Impact Summary

['http-logs']
| where _time between (ago(1h) .. now())
| where status >= 500
| summarize 
    errors = count(),
    affected_requests = dcount(trace_id)
  by customer_id
| top 10 by errors
| project Customer = customer_id, Errors = errors, "Affected Requests" = affected_requests

Pie

Share-of-total for low-cardinality dimensions only.

Status Code Distribution

['http-logs']
| where _time between (ago(1h) .. now())
| extend status_class = case(
    status < 300, "2xx Success",
    status < 400, "3xx Redirect",
    status < 500, "4xx Client Error",
    "5xx Server Error"
  )
| summarize count() by status_class

Traffic by Region

['http-logs']
| where _time between (ago(1h) .. now())
| summarize count() by region
| top 6 by count_  // Limit slices

Error Types Distribution

['http-logs']
| where _time between (ago(1h) .. now())
| where status >= 500
| extend error_type = case(
    status == 500, "Internal Error",
    status == 502, "Bad Gateway",
    status == 503, "Service Unavailable",
    status == 504, "Gateway Timeout",
    "Other 5xx"
  )
| summarize count() by error_type

Request Method Mix

['http-logs']
| where _time between (ago(1h) .. now())
| summarize count() by method

Warning: If dimension has >6 values, use a Table instead.


LogStream

Raw event inspection with focused fields.

The Console adds its own order by _time and limit to every LogStream query and streams the result. Use per-event operators only (where, search, extend, parse, project-keep) and keep _time. A row limit (take, limit, top), an aggregation (summarize, count, distinct), sample, mv-expand, join, or union fails with HTTP 400. Use a Table for top-N lists and aggregates.

Recent Errors

['http-logs']
| where _time between (ago(15m) .. now())
| where status >= 500
| project-keep _time, trace_id, service, route, status, error_message, duration_ms

Slow Requests

['http-logs']
| where _time between (ago(15m) .. now())
| where duration_ms > 5000
| project-keep _time, trace_id, service, route, duration_ms, status

Authentication Failures

['auth-logs']
| where _time between (ago(1h) .. now())
| where event_type == "login_failed"
| project-keep _time, user_id, ip_address, failure_reason, user_agent

Kubernetes Events

['k8s-events']
| where _time between (ago(1h) .. now())
| where type in ("Warning", "Error")
| project-keep _time, type, reason, ['involvedObject.name'], message

Filtered by Trace ID

['http-logs']
| where _time between (ago(24h) .. now())
| where trace_id == "abc123xyz"
| project-keep _time, service, route, status, duration_ms, error_message

SmartFilter

No APL needed—configure these fields for interactive filtering:

Recommended Filter Fields

  • service — Which service to focus on
  • environment — prod/staging/dev
  • region — Geographic region
  • route — API endpoint
  • status — HTTP status code
  • customer_id — For multi-tenant systems
  • kubernetes.namespace — K8s namespace
  • kubernetes.pod.name — Specific pod

Configuration Tips

  • Place SmartFilter at top of dashboard
  • Include 3–5 most useful filter dimensions
  • Avoid high-cardinality fields as primary filters (trace_id, request_id)

Note

Markdown panels for context and navigation. The chart object carries Markdown in a top-level text field. There is no query, and text is not wrapped in an options object — the create API rejects options with Unrecognized key: "options".

{
  "id": "dashboard-header",
  "name": "API Gateway",
  "type": "Note",
  "text": "# API Gateway — Oncall\n\n**Purpose:** Quick triage."
}

The recipes below are the Markdown that goes inside text. JSON-escape the content (newlines as \n, quotes as \") when embedding it as the chart's text value.

Dashboard Header

# API Gateway - Oncall Dashboard

**Purpose:** Quick triage for API-related incidents.

**Escalation:** If error rate > 5%, page #platform-oncall.

**Runbook:** [API Incident Response](https://wiki.example.com/api-runbook)

Section Divider

---
## Error Analysis

Instructions

### How to Use This Dashboard

1. Check the error rate stat (top-left)
2. If elevated, check the "Top Failing Routes" table
3. Click a route to filter logs below
4. Copy trace_id for detailed investigation

Heatmap

Visualize distributions and density patterns.

Latency Distribution Over Time

['http-logs']
| where _time between (ago(1h) .. now())
| summarize histogram(duration_ms, 20) by bin_auto(_time)

Response Size Distribution

['http-logs']
| where _time between (ago(1h) .. now())
| summarize histogram(resp_body_size_bytes, 15) by bin_auto(_time)

Request Rate by Hour of Day

['http-logs']
| where _time between (ago(7d) .. now())
| extend hour = hourofday(_time), day = dayofweek(_time)
| summarize count() by hour, day

Scatter Plot

Identify correlations between metrics.

Latency vs Response Size

['http-logs']
| where _time between (ago(1h) .. now())
| summarize avg(duration_ms), avg(resp_body_size_bytes) by route

Request Rate vs Error Rate by Route

['http-logs']
| where _time between (ago(1h) .. now())
| summarize 
    requests = count(),
    error_rate = round(100.0 * countif(status >= 500) / count(), 2)
  by route
| where requests >= 10

CPU vs Memory by Pod

['metrics']
| where _time between (ago(1h) .. now())
| summarize avg(cpu_percent), avg(memory_percent) by pod

Filter Bar

Interactive filters for dashboard-wide filtering.

Dynamic Country Filter Query

['http-logs']
| where _time between (ago(1h) .. now())
| distinct ['geo.country']
| project key=['geo.country'], value=['geo.country']
| sort by key asc

Panel Using Filters

declare query_parameters (_country:string = "", _status:string = "");
['http-logs']
| where _time between (ago(1h) .. now())
| where isempty(_country) or ['geo.country'] == _country
| where isempty(_status) or tostring(status) == _status
| summarize count() by bin_auto(_time)

Dependent City Filter (depends on country)

declare query_parameters (_country:string = "");
['http-logs']
| where _time between (ago(1h) .. now())
| where isnotempty(['geo.country']) and isnotempty(['geo.city'])
| where ['geo.country'] == _country
| distinct ['geo.city']
| project key=['geo.city'], value=['geo.city']
| sort by key asc

Dataset Selector Filter

For multi-dataset dashboards, let users choose which dataset to view:

declare query_parameters (_dataset:string = "http-logs");
table(_dataset)
| where _time between (ago(1h) .. now())
| summarize count() by bin_auto(_time)

Source: SKILL.md on GitHub

skilld matched fixed text patterns in SKILL.md and file names. Patterns miss obfuscated code.

skilld run checks every file with the same patterns. It asks for approval before it loads a Skill with a behavior marked Needs approval.

2 warnings5d3 checks · Risk SAFE
  • Gen Agent Trust Hub7d

    The skill provides a comprehensive toolkit for designing, building, and managing Axiom dashboards via the official API. It adheres to security best practices for secret management and network operations. No malicious patterns such as prompt injection, obfuscation, or unauthorized data exfiltration were detected.

  • Socket5d

    1 alert: gptAnomaly

  • Snyk7d

    Risk: MEDIUM · 1 issue

Signed by skilld at 5b11222. This ties the file your Agent reads to that commit on GitHub. It does not review the instructions.

Last checked against GitHub 2 hours ago.

Activeupdated 3 weeks ago
  • axiom
  • dashboards
  • apl
  • mpl
  • metrics
  • monitoring
  • visualization
  • queries
  • logs
  • timeseries

README badge

README badge for axiomhq/skills/axiom-build-dashboard

Builds and configures Axiom dashboards via API, covering APL and metrics/MPL queries, SmartFilters, chart types, and layout composition. Targets Axiom users designing new dashboards, migrating from Splunk or Grafana, or configuring chart options for observability and incident response.

Generated from the current SKILL.md.

Does this skill work with both metrics and events/logs datasets?
Yes. The skill covers two separate blueprints: APL for events/logs datasets and MPL for metrics datasets. Use `scripts/metrics/datasets` to check the dataset kind first.
Can I migrate dashboards from Splunk or Grafana?
Yes. The skill includes workflows for both: extract SPL and translate via spl-to-apl for Splunk, or project the canonical panel spec and translate PromQL for Grafana.
What happens if a requested panel can't be computed?
Replace it with a Note panel documenting the blocker. Substituting a different quantity is never acceptable, even with a disclaimer.
Do I need to include _time filters in dashboard chart queries?
No. Dashboard chart queries inherit the time range from the picker, so _time filters should be omitted. Only ad-hoc queries (Axiom Query tab, axiom-sre) need explicit `where _time between` clauses.
What tools do I use to build and deploy dashboards?
The skill provides scripts including `chart-add` (emit individual charts), `layout-pack` (compose layout), and `dashboard-assemble` (validate and emit the final dashboard JSON).

Generated from the current SKILL.md. These answers refresh after source changes.