/grafana-templating-json-datasource

Primary LanguageJavaScriptApache License 2.0Apache-2.0

Setup

Clone this repository somewhere. And, edit your grafana.ini config file and add this:

[plugin.templating-json]
path = /home/your/clone/dir/grafana-templating-json-datasource

How to use

  1. Add datasource with JSON url, you want to query
  2. Add templating query in dashboard, set jmespath query

Sample query

If JSON is like following, and specify query like foo.bar, result is baz and qux.

{
  "foo": {
    "bar": [
      "baz",
      "qux"
    ]
  }
}