{
  "apiVersion": "dashboard.grafana.app/v2",
  "kind": "Dashboard",
  "metadata": {
    "name": "adk2xp7",
    "generation": 16,
    "creationTimestamp": "2026-06-19T18:34:58Z",
    "labels": {},
    "annotations": {}
  },
  "spec": {
    "annotations": [
      {
        "kind": "AnnotationQuery",
        "spec": {
          "query": {
            "kind": "DataQuery",
            "group": "grafana",
            "version": "v0",
            "spec": {},
            "labels": {
              "grafana.app/export-label": "grafana-1"
            }
          },
          "enable": true,
          "hide": true,
          "iconColor": "rgba(0, 211, 255, 1)",
          "name": "Annotations & Alerts",
          "builtIn": true
        }
      }
    ],
    "cursorSync": "Off",
    "editable": true,
    "elements": {
      "panel-5": {
        "kind": "Panel",
        "spec": {
          "id": 5,
          "title": "Average Latency | Locations: $location | Tests: $included_tests | Networks: $ssid",
          "description": "",
          "links": [],
          "data": {
            "kind": "QueryGroup",
            "spec": {
              "queries": [
                {
                  "kind": "PanelQuery",
                  "spec": {
                    "query": {
                      "kind": "DataQuery",
                      "group": "prometheus",
                      "version": "v0",
                      "spec": {
                        "editorMode": "code",
                        "exemplar": false,
                        "expr": "avg by($group_by) (\n  avg_over_time({__name__=~\"$included_tests\", status=\"SUCCESS\", location_name=~\"$location\", sensor_name=~\"$sensor\", ssid=~\"$ssid\"}[$avg_over])\n)",
                        "instant": false,
                        "legendFormat": "__auto",
                        "range": true
                      },
                      "labels": {
                        "grafana.app/export-label": "prometheus-1"
                      }
                    },
                    "refId": "A",
                    "hidden": false
                  }
                }
              ],
              "transformations": [],
              "queryOptions": {
                "interval": "5m"
              }
            }
          },
          "vizConfig": {
            "kind": "VizConfig",
            "group": "heatmap",
            "version": "13.0.2",
            "spec": {
              "options": {
                "annotations": {
                  "clustering": -1,
                  "multiLane": false
                },
                "calculate": false,
                "calculation": {
                  "xBuckets": {
                    "mode": "size",
                    "value": ""
                  },
                  "yBuckets": {
                    "mode": "size",
                    "value": ""
                  }
                },
                "cellGap": 1,
                "cellValues": {
                  "unit": "ms"
                },
                "color": {
                  "exponent": 0.5,
                  "fill": "dark-blue",
                  "mode": "scheme",
                  "reverse": false,
                  "scale": "exponential",
                  "scheme": "RdYlGn",
                  "steps": 64
                },
                "exemplars": {
                  "color": "rgba(255,0,255,0.7)"
                },
                "filterValues": {
                  "le": 1e-9
                },
                "legend": {
                  "show": true
                },
                "rowsFrame": {
                  "layout": "auto"
                },
                "tooltip": {
                  "mode": "single",
                  "showColorScale": false,
                  "yHistogram": false
                },
                "yAxis": {
                  "axisPlacement": "left",
                  "reverse": false,
                  "unit": ""
                }
              },
              "fieldConfig": {
                "defaults": {
                  "custom": {
                    "hideFrom": {
                      "legend": false,
                      "tooltip": false,
                      "viz": false
                    },
                    "scaleDistribution": {
                      "type": "linear"
                    }
                  }
                },
                "overrides": []
              }
            }
          },
          "transparent": true
        }
      }
    },
    "layout": {
      "kind": "AutoGridLayout",
      "spec": {
        "maxColumnCount": 3,
        "columnWidthMode": "standard",
        "rowHeightMode": "standard",
        "fillScreen": true,
        "items": [
          {
            "kind": "AutoGridLayoutItem",
            "spec": {
              "element": {
                "kind": "ElementReference",
                "name": "panel-5"
              }
            }
          }
        ]
      }
    },
    "links": [],
    "liveNow": false,
    "preload": true,
    "tags": [
      "overview"
    ],
    "timeSettings": {
      "timezone": "browser",
      "from": "now-24h",
      "to": "now",
      "autoRefresh": "5m",
      "autoRefreshIntervals": [
        "5s",
        "10s",
        "30s",
        "1m",
        "5m",
        "15m",
        "30m",
        "1h",
        "2h",
        "1d"
      ],
      "hideTimepicker": false,
      "fiscalYearStartMonth": 0
    },
    "title": "Average Test Response Time",
    "variables": [
      {
        "kind": "QueryVariable",
        "spec": {
          "name": "location",
          "current": {
            "text": "",
            "value": ""
          },
          "label": "Location",
          "hide": "dontHide",
          "refresh": "onTimeRangeChanged",
          "skipUrlSync": false,
          "query": {
            "kind": "DataQuery",
            "group": "prometheus",
            "version": "v0",
            "spec": {
              "qryType": 1,
              "query": "label_values(location_name)",
              "refId": "PrometheusVariableQueryEditor-VariableQuery"
            },
            "labels": {
              "grafana.app/export-label": "prometheus-1"
            }
          },
          "regex": "",
          "regexApplyTo": "value",
          "sort": "disabled",
          "definition": "label_values(location_name)",
          "options": [],
          "multi": true,
          "includeAll": true,
          "allowCustomValue": false
        }
      },
      {
        "kind": "QueryVariable",
        "spec": {
          "name": "sensor",
          "current": {
            "text": "",
            "value": ""
          },
          "label": "Sensor",
          "hide": "dontHide",
          "refresh": "onTimeRangeChanged",
          "skipUrlSync": false,
          "query": {
            "kind": "DataQuery",
            "group": "prometheus",
            "version": "v0",
            "spec": {
              "qryType": 1,
              "query": "label_values({location_name=~\"$location\", ssid=~\"$ssid\"},sensor_name)",
              "refId": "PrometheusVariableQueryEditor-VariableQuery"
            },
            "labels": {
              "grafana.app/export-label": "prometheus-1"
            }
          },
          "regex": "",
          "regexApplyTo": "value",
          "sort": "disabled",
          "definition": "label_values({location_name=~\"$location\", ssid=~\"$ssid\"},sensor_name)",
          "options": [],
          "multi": true,
          "includeAll": true,
          "allowCustomValue": false
        }
      },
      {
        "kind": "QueryVariable",
        "spec": {
          "name": "ssid",
          "current": {
            "text": "",
            "value": ""
          },
          "label": "Network",
          "hide": "dontHide",
          "refresh": "onTimeRangeChanged",
          "skipUrlSync": false,
          "query": {
            "kind": "DataQuery",
            "group": "prometheus",
            "version": "v0",
            "spec": {
              "qryType": 1,
              "query": "label_values(wyebot_connections_dhcp_status{location_name=~\"$location\"},ssid)",
              "refId": "PrometheusVariableQueryEditor-VariableQuery"
            },
            "labels": {
              "grafana.app/export-label": "prometheus-1"
            }
          },
          "regex": "",
          "regexApplyTo": "value",
          "sort": "disabled",
          "definition": "label_values(wyebot_connections_dhcp_status{location_name=~\"$location\"},ssid)",
          "options": [],
          "multi": true,
          "includeAll": true,
          "allowCustomValue": false
        }
      },
      {
        "kind": "CustomVariable",
        "spec": {
          "name": "group_by",
          "query": "location_name, sensor_name, ap_name, ssid",
          "current": {
            "text": "location_name",
            "value": "location_name"
          },
          "options": [],
          "multi": false,
          "includeAll": false,
          "label": "Group By",
          "hide": "dontHide",
          "skipUrlSync": false,
          "allowCustomValue": false,
          "valuesFormat": "csv"
        }
      },
      {
        "kind": "CustomVariable",
        "spec": {
          "name": "included_tests",
          "query": "[\n  {\"text\": \"Ping\", \"value\": \"wyebot_tests_ping_rtt_avg\"},\n  {\"text\": \"Link Doctor\", \"value\": \"wyebot_tests_link_doctor_rtt_avg\"},\n  {\"text\": \"Application\", \"value\": \"wyebot_tests_application_time\"},\n  {\"text\": \"DNS Performance\", \"value\": \"wyebot_tests_dns_performance\"},\n  {\"text\": \"Speedtest\", \"value\": \"wyebot_tests_speedtest_latency\"},\n  {\"text\": \"Video Conferencing\", \"value\": \"wyebot_tests_video_latency_.*\"},\n  {\"text\": \"Voice\", \"value\": \"wyebot_tests_voice_latency_.*\"}\n]",
          "current": {
            "text": "All",
            "value": [
              "$__all"
            ]
          },
          "options": [],
          "multi": true,
          "includeAll": true,
          "label": "Included Tests",
          "hide": "dontHide",
          "skipUrlSync": false,
          "allowCustomValue": false,
          "valuesFormat": "json"
        }
      },
      {
        "kind": "IntervalVariable",
        "spec": {
          "name": "avg_over",
          "query": "10m,20m,30m,1h,6h,12h,1d,7d,14d,30d",
          "current": {
            "text": "30m",
            "value": "30m"
          },
          "options": [
            {
              "selected": false,
              "text": "10m",
              "value": "10m"
            },
            {
              "selected": false,
              "text": "20m",
              "value": "20m"
            },
            {
              "selected": true,
              "text": "30m",
              "value": "30m"
            },
            {
              "selected": false,
              "text": "1h",
              "value": "1h"
            },
            {
              "selected": false,
              "text": "6h",
              "value": "6h"
            },
            {
              "selected": false,
              "text": "12h",
              "value": "12h"
            },
            {
              "selected": false,
              "text": "1d",
              "value": "1d"
            },
            {
              "selected": false,
              "text": "7d",
              "value": "7d"
            },
            {
              "selected": false,
              "text": "14d",
              "value": "14d"
            },
            {
              "selected": false,
              "text": "30d",
              "value": "30d"
            }
          ],
          "auto": false,
          "auto_min": "10s",
          "auto_count": 30,
          "refresh": "onTimeRangeChanged",
          "label": "Average Over",
          "hide": "dontHide",
          "skipUrlSync": false
        }
      }
    ],
    "preferences": {
      "layout": {
        "kind": "AutoGridLayout",
        "spec": {
          "maxColumnCount": 3,
          "columnWidthMode": "standard",
          "rowHeightMode": "standard",
          "items": []
        }
      }
    }
  }
}