Vélib'
Dashboard to track my Vélib rides.
Work with: https://github.com/qselle/velib-exporter
{
  "__inputs": [
    {
      "name": "DS_PROMETHEUS",
      "label": "Prometheus",
      "description": "",
      "type": "datasource",
      "pluginId": "prometheus",
      "pluginName": "Prometheus"
    }
  ],
  "__elements": [],
  "__requires": [
    {
      "type": "grafana",
      "id": "grafana",
      "name": "Grafana",
      "version": "8.4.1"
    },
    {
      "type": "panel",
      "id": "piechart",
      "name": "Pie chart",
      "version": ""
    },
    {
      "type": "datasource",
      "id": "prometheus",
      "name": "Prometheus",
      "version": "1.0.0"
    },
    {
      "type": "panel",
      "id": "stat",
      "name": "Stat",
      "version": ""
    },
    {
      "type": "panel",
      "id": "table",
      "name": "Table",
      "version": ""
    },
    {
      "type": "panel",
      "id": "timeseries",
      "name": "Time series",
      "version": ""
    }
  ],
  "annotations": {
    "list": [
      {
        "builtIn": 1,
        "datasource": "-- Grafana --",
        "enable": true,
        "hide": true,
        "iconColor": "rgba(0, 211, 255, 1)",
        "name": "Annotations & Alerts",
        "target": {
          "limit": 100,
          "matchAny": false,
          "tags": [],
          "type": "dashboard"
        },
        "type": "dashboard"
      }
    ]
  },
  "editable": true,
  "fiscalYearStartMonth": 0,
  "graphTooltip": 0,
  "id": null,
  "links": [],
  "liveNow": false,
  "panels": [
    {
      "fieldConfig": {
        "defaults": {
          "color": {
            "mode": "thresholds"
          },
          "mappings": [],
          "thresholds": {
            "mode": "absolute",
            "steps": [
              {
                "color": "dark-blue",
                "value": null
              }
            ]
          },
          "unit": "lengthm"
        },
        "overrides": []
      },
      "gridPos": {
        "h": 5,
        "w": 8,
        "x": 0,
        "y": 0
      },
      "id": 10,
      "options": {
        "colorMode": "value",
        "graphMode": "area",
        "justifyMode": "auto",
        "orientation": "auto",
        "reduceOptions": {
          "calcs": [
            "lastNotNull"
          ],
          "fields": "",
          "values": false
        },
        "text": {},
        "textMode": "auto"
      },
      "pluginVersion": "8.4.1",
      "targets": [
        {
          "exemplar": true,
          "expr": "velib_distance_total",
          "interval": "",
          "legendFormat": "",
          "refId": "A"
        }
      ],
      "title": "🗺 Total Distance",
      "type": "stat"
    },
    {
      "fieldConfig": {
        "defaults": {
          "color": {
            "mode": "thresholds"
          },
          "mappings": [],
          "thresholds": {
            "mode": "absolute",
            "steps": [
              {
                "color": "dark-purple",
                "value": null
              }
            ]
          },
          "unit": "short"
        },
        "overrides": []
      },
      "gridPos": {
        "h": 5,
        "w": 8,
        "x": 8,
        "y": 0
      },
      "id": 2,
      "options": {
        "colorMode": "value",
        "graphMode": "area",
        "justifyMode": "auto",
        "orientation": "auto",
        "reduceOptions": {
          "calcs": [
            "lastNotNull"
          ],
          "fields": "",
          "values": false
        },
        "text": {},
        "textMode": "auto"
      },
      "pluginVersion": "8.4.1",
      "targets": [
        {
          "exemplar": true,
          "expr": "velib_trip_number",
          "interval": "",
          "legendFormat": "Trip",
          "refId": "A"
        }
      ],
      "title": "📈 Trips Number",
      "type": "stat"
    },
    {
      "fieldConfig": {
        "defaults": {
          "color": {
            "mode": "thresholds"
          },
          "mappings": [],
          "thresholds": {
            "mode": "absolute",
            "steps": [
              {
                "color": "dark-green",
                "value": null
              }
            ]
          },
          "unit": "massg"
        },
        "overrides": []
      },
      "gridPos": {
        "h": 5,
        "w": 8,
        "x": 16,
        "y": 0
      },
      "id": 6,
      "options": {
        "colorMode": "value",
        "graphMode": "area",
        "justifyMode": "auto",
        "orientation": "auto",
        "reduceOptions": {
          "calcs": [
            "lastNotNull"
          ],
          "fields": "",
          "values": false
        },
        "text": {},
        "textMode": "auto"
      },
      "pluginVersion": "8.4.1",
      "targets": [
        {
          "exemplar": true,
          "expr": "velib_co2_total_saved",
          "interval": "",
          "legendFormat": "",
          "refId": "A"
        }
      ],
      "title": "🌍 CO2 Saved",
      "type": "stat"
    },
    {
      "fieldConfig": {
        "defaults": {
          "color": {
            "mode": "thresholds"
          },
          "mappings": [],
          "thresholds": {
            "mode": "absolute",
            "steps": [
              {
                "color": "dark-blue",
                "value": null
              }
            ]
          },
          "unit": "lengthm"
        },
        "overrides": []
      },
      "gridPos": {
        "h": 5,
        "w": 8,
        "x": 0,
        "y": 5
      },
      "id": 14,
      "options": {
        "colorMode": "value",
        "graphMode": "area",
        "justifyMode": "auto",
        "orientation": "auto",
        "reduceOptions": {
          "calcs": [
            "lastNotNull"
          ],
          "fields": "",
          "values": false
        },
        "text": {},
        "textMode": "auto"
      },
      "pluginVersion": "8.4.1",
      "targets": [
        {
          "exemplar": true,
          "expr": "velib_distance_total / velib_trip_number",
          "interval": "",
          "legendFormat": "",
          "refId": "A"
        }
      ],
      "title": "🚴 Average Trip Distance",
      "type": "stat"
    },
    {
      "fieldConfig": {
        "defaults": {
          "color": {
            "mode": "thresholds"
          },
          "mappings": [],
          "thresholds": {
            "mode": "absolute",
            "steps": [
              {
                "color": "dark-orange",
                "value": null
              }
            ]
          },
          "unit": "m"
        },
        "overrides": []
      },
      "gridPos": {
        "h": 5,
        "w": 8,
        "x": 8,
        "y": 5
      },
      "id": 8,
      "options": {
        "colorMode": "value",
        "graphMode": "area",
        "justifyMode": "auto",
        "orientation": "auto",
        "reduceOptions": {
          "calcs": [
            "lastNotNull"
          ],
          "fields": "",
          "values": false
        },
        "text": {},
        "textMode": "auto"
      },
      "pluginVersion": "8.4.1",
      "targets": [
        {
          "exemplar": true,
          "expr": "velib_trip_average_duration",
          "interval": "",
          "legendFormat": "Average duration",
          "refId": "A"
        }
      ],
      "title": "⏱ Average Trip Duration",
      "type": "stat"
    },
    {
      "fieldConfig": {
        "defaults": {
          "color": {
            "mode": "thresholds"
          },
          "mappings": [],
          "thresholds": {
            "mode": "absolute",
            "steps": [
              {
                "color": "dark-yellow",
                "value": null
              }
            ]
          },
          "unit": "lengthm"
        },
        "overrides": []
      },
      "gridPos": {
        "h": 5,
        "w": 8,
        "x": 16,
        "y": 5
      },
      "id": 12,
      "options": {
        "colorMode": "value",
        "graphMode": "area",
        "justifyMode": "auto",
        "orientation": "auto",
        "reduceOptions": {
          "calcs": [
            "lastNotNull"
          ],
          "fields": "",
          "values": false
        },
        "text": {},
        "textMode": "auto"
      },
      "pluginVersion": "8.4.1",
      "targets": [
        {
          "exemplar": true,
          "expr": "velib_trip_highest_distance",
          "interval": "",
          "legendFormat": "",
          "refId": "A"
        }
      ],
      "title": "🏆 Personal Record",
      "type": "stat"
    },
    {
      "fieldConfig": {
        "defaults": {
          "color": {
            "mode": "palette-classic"
          },
          "custom": {
            "hideFrom": {
              "legend": false,
              "tooltip": false,
              "viz": false
            }
          },
          "mappings": [],
          "unit": "lengthm"
        },
        "overrides": [
          {
            "matcher": {
              "id": "byName",
              "options": "electric"
            },
            "properties": [
              {
                "id": "color",
                "value": {
                  "fixedColor": "blue",
                  "mode": "fixed"
                }
              }
            ]
          },
          {
            "matcher": {
              "id": "byName",
              "options": "mechanic"
            },
            "properties": [
              {
                "id": "color",
                "value": {
                  "fixedColor": "green",
                  "mode": "fixed"
                }
              }
            ]
          }
        ]
      },
      "gridPos": {
        "h": 12,
        "w": 11,
        "x": 0,
        "y": 10
      },
      "id": 4,
      "options": {
        "displayLabels": [],
        "legend": {
          "displayMode": "table",
          "placement": "bottom",
          "values": [
            "percent",
            "value"
          ]
        },
        "pieType": "pie",
        "reduceOptions": {
          "calcs": [
            "lastNotNull"
          ],
          "fields": "",
          "values": false
        },
        "text": {},
        "tooltip": {
          "mode": "single",
          "sort": "none"
        }
      },
      "pluginVersion": "7.5.6",
      "targets": [
        {
          "exemplar": true,
          "expr": "velib_distance_electrical",
          "interval": "",
          "legendFormat": "electric",
          "refId": "A"
        },
        {
          "exemplar": true,
          "expr": "velib_distance_mechanical",
          "hide": false,
          "interval": "",
          "legendFormat": "mechanic",
          "refId": "B"
        }
      ],
      "title": "🔌 Blue VS Green 💪",
      "type": "piechart"
    },
    {
      "fieldConfig": {
        "defaults": {
          "color": {
            "mode": "palette-classic"
          },
          "custom": {
            "axisLabel": "",
            "axisPlacement": "auto",
            "barAlignment": 0,
            "drawStyle": "line",
            "fillOpacity": 10,
            "gradientMode": "none",
            "hideFrom": {
              "graph": false,
              "legend": false,
              "tooltip": false,
              "viz": false
            },
            "lineInterpolation": "linear",
            "lineWidth": 1,
            "pointSize": 5,
            "scaleDistribution": {
              "type": "linear"
            },
            "showPoints": "never",
            "spanNulls": true,
            "stacking": {
              "group": "A",
              "mode": "none"
            },
            "thresholdsStyle": {
              "mode": "off"
            }
          },
          "mappings": [],
          "thresholds": {
            "mode": "absolute",
            "steps": [
              {
                "color": "green",
                "value": null
              }
            ]
          },
          "unit": "lengthm"
        },
        "overrides": [
          {
            "matcher": {
              "id": "byName",
              "options": "electric"
            },
            "properties": [
              {
                "id": "color",
                "value": {
                  "fixedColor": "blue",
                  "mode": "fixed"
                }
              }
            ]
          },
          {
            "matcher": {
              "id": "byName",
              "options": "mechanic"
            },
            "properties": [
              {
                "id": "color",
                "value": {
                  "fixedColor": "green",
                  "mode": "fixed"
                }
              }
            ]
          }
        ]
      },
      "gridPos": {
        "h": 12,
        "w": 13,
        "x": 11,
        "y": 10
      },
      "id": 13,
      "options": {
        "graph": {},
        "legend": {
          "calcs": [
            "last"
          ],
          "displayMode": "table",
          "placement": "bottom"
        },
        "tooltip": {
          "mode": "single",
          "sort": "none"
        }
      },
      "pluginVersion": "7.5.6",
      "targets": [
        {
          "exemplar": true,
          "expr": "velib_distance_electrical",
          "interval": "",
          "legendFormat": "electric",
          "refId": "A"
        },
        {
          "exemplar": true,
          "expr": "velib_distance_mechanical",
          "hide": false,
          "interval": "",
          "legendFormat": "mechanic",
          "refId": "B"
        }
      ],
      "title": "🔌 Blue VS Green 💪",
      "type": "timeseries"
    },
    {
      "fieldConfig": {
        "defaults": {
          "color": {
            "mode": "thresholds"
          },
          "custom": {
            "align": "auto",
            "displayMode": "auto"
          },
          "mappings": [],
          "thresholds": {
            "mode": "absolute",
            "steps": [
              {
                "color": "green",
                "value": null
              }
            ]
          }
        },
        "overrides": [
          {
            "matcher": {
              "id": "byName",
              "options": "__name__"
            },
            "properties": [
              {
                "id": "custom.hidden",
                "value": true
              }
            ]
          },
          {
            "matcher": {
              "id": "byName",
              "options": "Time"
            },
            "properties": [
              {
                "id": "custom.hidden",
                "value": true
              }
            ]
          },
          {
            "matcher": {
              "id": "byName",
              "options": "average_speed"
            },
            "properties": [
              {
                "id": "unit",
                "value": "velocitykmh"
              }
            ]
          },
          {
            "matcher": {
              "id": "byName",
              "options": "start_date"
            },
            "properties": [
              {
                "id": "unit",
                "value": "dateTimeAsSystem"
              }
            ]
          },
          {
            "matcher": {
              "id": "byName",
              "options": "end_date"
            },
            "properties": [
              {
                "id": "unit",
                "value": "dateTimeAsSystem"
              }
            ]
          },
          {
            "matcher": {
              "id": "byName",
              "options": "instance"
            },
            "properties": [
              {
                "id": "custom.hidden",
                "value": true
              }
            ]
          },
          {
            "matcher": {
              "id": "byName",
              "options": "Value"
            },
            "properties": [
              {
                "id": "unit",
                "value": "lengthm"
              }
            ]
          },
          {
            "matcher": {
              "id": "byName",
              "options": "job"
            },
            "properties": [
              {
                "id": "custom.hidden",
                "value": true
              }
            ]
          },
          {
            "matcher": {
              "id": "byName",
              "options": "co2_saved_total"
            },
            "properties": [
              {
                "id": "unit",
                "value": "massg"
              }
            ]
          },
          {
            "matcher": {
              "id": "byName",
              "options": "Duration"
            },
            "properties": [
              {
                "id": "unit",
                "value": "dtdurationms"
              }
            ]
          }
        ]
      },
      "gridPos": {
        "h": 18,
        "w": 24,
        "x": 0,
        "y": 22
      },
      "id": 16,
      "options": {
        "footer": {
          "fields": "",
          "reducer": [
            "sum"
          ],
          "show": true
        },
        "showHeader": true,
        "sortBy": [
          {
            "desc": true,
            "displayName": "Start"
          }
        ]
      },
      "pluginVersion": "8.4.1",
      "targets": [
        {
          "datasource": {
            "type": "prometheus",
            "uid": "${DS_PROMETHEUS}"
          },
          "exemplar": false,
          "expr": "velib_trip",
          "format": "table",
          "instant": true,
          "interval": "",
          "legendFormat": "",
          "refId": "A"
        }
      ],
      "title": "Last 20 Rides",
      "transformations": [
        {
          "id": "organize",
          "options": {
            "excludeByName": {},
            "indexByName": {
              "Time": 0,
              "Value": 8,
              "__name__": 1,
              "average_speed": 5,
              "co2_saved_total": 6,
              "end_date": 4,
              "instance": 2,
              "job": 7,
              "start_date": 3
            },
            "renameByName": {
              "Value": "Distance",
              "average_speed": "Average Speed",
              "co2_saved_total": "CO2 Saved",
              "end_date": "End",
              "job": "",
              "start_date": "Start"
            }
          }
        },
        {
          "id": "calculateField",
          "options": {
            "alias": "Duration",
            "binary": {
              "left": "End",
              "operator": "-",
              "reducer": "sum",
              "right": "Start"
            },
            "mode": "binary",
            "reduce": {
              "include": [
                "Start",
                "End"
              ],
              "reducer": "delta"
            },
            "replaceFields": false
          }
        }
      ],
      "type": "table"
    }
  ],
  "schemaVersion": 35,
  "style": "dark",
  "tags": [],
  "templating": {
    "list": []
  },
  "time": {
    "from": "now-30m",
    "to": "now"
  },
  "timepicker": {},
  "timezone": "",
  "title": "Vélib'",
  "uid": "ltM0VoBnz",
  "version": 11,
  "weekStart": "",
  "gnetId": 15787,
  "description": "Dashboard to track my Vélib rides."
}