Skip to content

Commit 2fdfbc3

Browse files
committed
Update docs
1 parent cbc6d03 commit 2fdfbc3

File tree

4 files changed

+15
-1
lines changed

4 files changed

+15
-1
lines changed

website/docs/jsonata.md

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
---
2+
id: jsonata
3+
title: JSONata
4+
---
5+
6+
[JSONata](https://docs.jsonata.org/) is a query and transformation language for JSON data.
7+
8+
If you're new to JSONata, start by looking at some [simple queries](https://docs.jsonata.org/simple).
9+
10+
[Dashboard variables](https://grafana.com/docs/grafana/latest/variables/) are available as JSONata variables, e.g. `$instanceName`. Since dashboard variables can have multiple values, the JSONata variable is always an array. If your variable contains a single value, you can use `$instanceName[0]` to index the first value in the array.

website/docs/query-editor.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ The query editor for the JSON API data source consists of a number of tabs. Each
1313

1414
The **Fields** tab is where you select the data to extract from the JSON document returned by the URL configured in the data source configuration.
1515

16-
- **Field** must contain a valid [JSONPath](./jsonpath.md) expression and can return one or more elements.
16+
- **Field** lets you define a query expression that determines the data to extract from the JSON document. There are two supported query languages: [JSONPath](./jsonpath.md) and [JSONata](./jsonata.md).
1717
- **Type** defines the JSON type of the elements returned by the **Field** expression. By default, Grafana uses the types in the JSON document. If **Type** is set to a different type than the original property type, Grafana tries to parse the value.
1818
- **Alias** overrides the default name of the field.
1919

website/sidebars.js

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,10 @@ module.exports = {
2929
type: 'doc',
3030
id: 'jsonpath',
3131
},
32+
{
33+
type: 'doc',
34+
id: 'jsonata',
35+
},
3236
{
3337
type: 'doc',
3438
id: 'troubleshooting',

website/static/img/editor-fields.png

10.1 KB
Loading

0 commit comments

Comments
 (0)