Skip to content

Instantly share code, notes, and snippets.

@mprokopov
Created March 29, 2026 04:43
Show Gist options
  • Select an option

  • Save mprokopov/56a0b7a94550e843dacbb075e48f8e36 to your computer and use it in GitHub Desktop.

Select an option

Save mprokopov/56a0b7a94550e843dacbb075e48f8e36 to your computer and use it in GitHub Desktop.
OpenClaw Gateway Grafana Dashboard (Mimir + Tempo)
{
"panels": [
{
"datasource": {
"uid": "mCUDBhx4z"
},
"fieldConfig": {
"defaults": {
"thresholds": {
"steps": [
{
"color": "green",
"value": null
},
{
"color": "yellow",
"value": 500000
},
{
"color": "red",
"value": 2000000
}
]
},
"unit": "short"
}
},
"gridPos": {
"h": 4,
"w": 6,
"x": 0,
"y": 0
},
"id": 1,
"targets": [
{
"expr": "sum(increase(openclaw_tokens_total{openclaw_channel=~\"$channel\", openclaw_model=~\"$model\"}[$__range]))",
"legendFormat": "tokens"
}
],
"title": "Total Tokens (input + output)",
"type": "stat"
},
{
"datasource": {
"uid": "mCUDBhx4z"
},
"fieldConfig": {
"defaults": {
"decimals": 2,
"thresholds": {
"steps": [
{
"color": "green",
"value": null
},
{
"color": "yellow",
"value": 5
},
{
"color": "red",
"value": 20
}
]
},
"unit": "currencyUSD"
}
},
"gridPos": {
"h": 4,
"w": 6,
"x": 6,
"y": 0
},
"id": 2,
"targets": [
{
"expr": "sum(increase(openclaw_cost_usd_total{openclaw_channel=~\"$channel\", openclaw_model=~\"$model\"}[$__range]))",
"legendFormat": "cost"
}
],
"title": "Total Cost (USD)",
"type": "stat"
},
{
"datasource": {
"uid": "mCUDBhx4z"
},
"fieldConfig": {
"defaults": {
"thresholds": {
"steps": [
{
"color": "blue",
"value": null
}
]
},
"unit": "short"
}
},
"gridPos": {
"h": 4,
"w": 6,
"x": 12,
"y": 0
},
"id": 3,
"targets": [
{
"expr": "sum(increase(openclaw_message_processed_total{openclaw_channel=~\"$channel\"}[$__range]))",
"legendFormat": "messages"
}
],
"title": "Messages Processed",
"type": "stat"
},
{
"datasource": {
"uid": "mCUDBhx4z"
},
"fieldConfig": {
"defaults": {
"thresholds": {
"steps": [
{
"color": "green",
"value": null
},
{
"color": "yellow",
"value": 30000
},
{
"color": "red",
"value": 60000
}
]
},
"unit": "ms"
}
},
"gridPos": {
"h": 4,
"w": 6,
"x": 18,
"y": 0
},
"id": 4,
"targets": [
{
"expr": "sum(rate(openclaw_run_duration_ms_milliseconds_sum{openclaw_model=~\"$model\"}[5m])) / sum(rate(openclaw_run_duration_ms_milliseconds_count{openclaw_model=~\"$model\"}[5m]))",
"legendFormat": "avg"
}
],
"title": "Avg Run Duration",
"type": "stat"
},
{
"datasource": {
"uid": "mCUDBhx4z"
},
"fieldConfig": {
"defaults": {
"custom": {
"drawStyle": "bars",
"fillOpacity": 30,
"stacking": {
"mode": "normal"
}
},
"unit": "short"
}
},
"gridPos": {
"h": 8,
"w": 12,
"x": 0,
"y": 4
},
"id": 10,
"targets": [
{
"expr": "sum by (openclaw_token) (rate(openclaw_tokens_total{openclaw_channel=~\"$channel\", openclaw_model=~\"$model\"}[5m]) * 300)",
"legendFormat": "{{openclaw_token}}"
}
],
"title": "Token Usage Over Time",
"type": "timeseries"
},
{
"datasource": {
"uid": "mCUDBhx4z"
},
"fieldConfig": {
"defaults": {
"custom": {
"drawStyle": "line",
"fillOpacity": 20,
"pointSize": 5
},
"unit": "currencyUSD"
}
},
"gridPos": {
"h": 8,
"w": 12,
"x": 12,
"y": 4
},
"id": 11,
"targets": [
{
"expr": "sum by (openclaw_model) (rate(openclaw_cost_usd_total{openclaw_channel=~\"$channel\"}[5m]) * 300)",
"legendFormat": "{{openclaw_model}}"
}
],
"title": "Cost Over Time (USD)",
"type": "timeseries"
},
{
"datasource": {
"uid": "mCUDBhx4z"
},
"fieldConfig": {
"defaults": {
"custom": {
"drawStyle": "bars",
"fillOpacity": 40,
"stacking": {
"mode": "normal"
}
},
"unit": "short"
}
},
"gridPos": {
"h": 8,
"w": 12,
"x": 0,
"y": 12
},
"id": 20,
"targets": [
{
"expr": "sum by (openclaw_channel) (rate(openclaw_message_processed_total{openclaw_channel=~\"$channel\"}[5m]) * 300)",
"legendFormat": "{{openclaw_channel}}"
}
],
"title": "Messages by Channel",
"type": "timeseries"
},
{
"datasource": {
"uid": "mCUDBhx4z"
},
"fieldConfig": {
"defaults": {
"custom": {
"drawStyle": "line",
"fillOpacity": 10
},
"unit": "ms"
}
},
"gridPos": {
"h": 8,
"w": 12,
"x": 12,
"y": 12
},
"id": 21,
"targets": [
{
"expr": "histogram_quantile(0.50, sum by (le) (rate(openclaw_message_duration_ms_milliseconds_bucket{openclaw_channel=~\"$channel\"}[5m])))",
"legendFormat": "p50"
},
{
"expr": "histogram_quantile(0.95, sum by (le) (rate(openclaw_message_duration_ms_milliseconds_bucket{openclaw_channel=~\"$channel\"}[5m])))",
"legendFormat": "p95"
},
{
"expr": "histogram_quantile(0.99, sum by (le) (rate(openclaw_message_duration_ms_milliseconds_bucket{openclaw_channel=~\"$channel\"}[5m])))",
"legendFormat": "p99"
}
],
"title": "Message Processing Duration (p50 / p95 / p99)",
"type": "timeseries"
},
{
"datasource": {
"uid": "mCUDBhx4z"
},
"fieldConfig": {
"defaults": {
"custom": {
"drawStyle": "line",
"fillOpacity": 10
},
"unit": "ms"
}
},
"gridPos": {
"h": 8,
"w": 12,
"x": 0,
"y": 20
},
"id": 30,
"targets": [
{
"expr": "histogram_quantile(0.50, sum by (le, openclaw_model) (rate(openclaw_run_duration_ms_milliseconds_bucket{openclaw_model=~\"$model\"}[5m])))",
"legendFormat": "p50 {{openclaw_model}}"
},
{
"expr": "histogram_quantile(0.95, sum by (le, openclaw_model) (rate(openclaw_run_duration_ms_milliseconds_bucket{openclaw_model=~\"$model\"}[5m])))",
"legendFormat": "p95 {{openclaw_model}}"
}
],
"title": "Run Duration (p50 / p95)",
"type": "timeseries"
},
{
"datasource": {
"uid": "mCUDBhx4z"
},
"fieldConfig": {
"defaults": {
"custom": {
"drawStyle": "line",
"fillOpacity": 10
},
"unit": "short"
}
},
"gridPos": {
"h": 8,
"w": 12,
"x": 12,
"y": 20
},
"id": 31,
"targets": [
{
"expr": "histogram_quantile(0.50, sum by (le) (rate(openclaw_context_tokens_bucket{openclaw_context=\"used\", openclaw_model=~\"$model\"}[5m])))",
"legendFormat": "p50 used"
},
{
"expr": "histogram_quantile(0.95, sum by (le) (rate(openclaw_context_tokens_bucket{openclaw_context=\"used\", openclaw_model=~\"$model\"}[5m])))",
"legendFormat": "p95 used"
}
],
"title": "Context Window Usage",
"type": "timeseries"
},
{
"datasource": {
"uid": "mCUDBhx4z"
},
"fieldConfig": {
"defaults": {
"custom": {
"drawStyle": "line",
"fillOpacity": 15
},
"unit": "short"
}
},
"gridPos": {
"h": 7,
"w": 8,
"x": 0,
"y": 28
},
"id": 40,
"targets": [
{
"expr": "histogram_quantile(0.95, sum by (le) (rate(openclaw_queue_depth_bucket[5m])))",
"legendFormat": "p95 depth"
}
],
"title": "Queue Depth",
"type": "timeseries"
},
{
"datasource": {
"uid": "mCUDBhx4z"
},
"fieldConfig": {
"defaults": {
"custom": {
"drawStyle": "line",
"fillOpacity": 15
},
"unit": "ms"
}
},
"gridPos": {
"h": 7,
"w": 8,
"x": 8,
"y": 28
},
"id": 41,
"targets": [
{
"expr": "histogram_quantile(0.95, sum by (le) (rate(openclaw_queue_wait_ms_milliseconds_bucket[5m])))",
"legendFormat": "p95 wait"
}
],
"title": "Queue Wait Time",
"type": "timeseries"
},
{
"datasource": {
"uid": "mCUDBhx4z"
},
"fieldConfig": {
"defaults": {
"custom": {
"drawStyle": "bars",
"fillOpacity": 40,
"stacking": {
"mode": "normal"
}
},
"unit": "short"
}
},
"gridPos": {
"h": 7,
"w": 8,
"x": 16,
"y": 28
},
"id": 42,
"targets": [
{
"expr": "sum by (openclaw_state) (rate(openclaw_session_state_total[5m]) * 300)",
"legendFormat": "{{openclaw_state}}"
}
],
"title": "Session State Changes",
"type": "timeseries"
},
{
"datasource": {
"type": "tempo",
"uid": "tempo"
},
"gridPos": {
"h": 8,
"w": 24,
"x": 0,
"y": 35
},
"id": 50,
"targets": [
{
"limit": 20,
"queryType": "nativeSearch",
"serviceName": "openclaw-gateway"
}
],
"title": "Recent Traces",
"type": "table"
}
],
"refresh": "30s",
"schemaVersion": 39,
"tags": [
"openclaw",
"ai",
"observability"
],
"templating": {
"list": [
{
"current": {
"text": "All",
"value": "$__all"
},
"datasource": {
"type": "prometheus",
"uid": "mCUDBhx4z"
},
"includeAll": true,
"multi": true,
"name": "channel",
"query": "label_values(openclaw_tokens_total, openclaw_channel)",
"refresh": 2,
"type": "query"
},
{
"current": {
"text": "All",
"value": "$__all"
},
"datasource": {
"type": "prometheus",
"uid": "mCUDBhx4z"
},
"includeAll": true,
"multi": true,
"name": "model",
"query": "label_values(openclaw_tokens_total, openclaw_model)",
"refresh": 2,
"type": "query"
}
]
},
"time": {
"from": "now-6h",
"to": "now"
},
"timezone": "browser",
"title": "OpenClaw Gateway",
"uid": "openclaw-gateway"
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment