From dba729f6b657ba08606930ed2e6042080238f90f Mon Sep 17 00:00:00 2001 From: showuon <43372967+showuon@users.noreply.github.com> Date: Tue, 1 Sep 2020 16:37:09 +0800 Subject: [PATCH] Referring to configuration.md, to have a Generic placeholders definition section (#7875) Signed-off-by: Luke Chen --- docs/querying/api.md | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) diff --git a/docs/querying/api.md b/docs/querying/api.md index e389a59ae..c97c1047f 100644 --- a/docs/querying/api.md +++ b/docs/querying/api.md @@ -46,21 +46,20 @@ The JSON response envelope format is as follows: } ``` -Input timestamps may be provided either in +Generic placeholders are defined as follows: + +* ``: Input timestamps may be provided either in [RFC3339](https://www.ietf.org/rfc/rfc3339.txt) format or as a Unix timestamp in seconds, with optional decimal places for sub-second precision. Output timestamps are always represented as Unix timestamps in seconds. - -Names of query parameters that may be repeated end with `[]`. - -`` placeholders refer to Prometheus [time series +* ``: Prometheus [time series selectors](basics.md#time-series-selectors) like `http_requests_total` or `http_requests_total{method=~"(GET|POST)"}` and need to be URL-encoded. - -`` placeholders refer to [Prometheus duration strings](basics.md#time_durations). +* ``: [Prometheus duration strings](basics.md#time_durations). For example, `5m` refers to a duration of 5 minutes. +* ``: boolean values (strings `true` and `false`). -`` placeholders refer to boolean values (strings `true` and `false`). +Note: Names of query parameters that may be repeated end with `[]`. ## Expression queries