@dynatrace-sdk/client-query 1.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (108) hide show
  1. package/CHANGELOG.md +9 -0
  2. package/LICENSE +174 -0
  3. package/README.md +54 -0
  4. package/cjs/index.js +1788 -0
  5. package/docs/DOCS.md +2833 -0
  6. package/dynatrace-metadata.json +18 -0
  7. package/esm/index.js +1766 -0
  8. package/package.json +11 -0
  9. package/types/index.d.ts +1 -0
  10. package/types/packages/client/query/src/index.d.ts +1 -0
  11. package/types/packages/client/query/src/lib/apis/index.d.ts +2 -0
  12. package/types/packages/client/query/src/lib/apis/query-assistance-api.d.ts +276 -0
  13. package/types/packages/client/query/src/lib/apis/query-execution-api.d.ts +337 -0
  14. package/types/packages/client/query/src/lib/error-envelopes/api-client-error.d.ts +9 -0
  15. package/types/packages/client/query/src/lib/error-envelopes/client-request-error.d.ts +8 -0
  16. package/types/packages/client/query/src/lib/error-envelopes/error-envelope-error.d.ts +8 -0
  17. package/types/packages/client/query/src/lib/error-envelopes/error-serializer.d.ts +3 -0
  18. package/types/packages/client/query/src/lib/error-envelopes/index.d.ts +3 -0
  19. package/types/packages/client/query/src/lib/error-envelopes/invalid-response-error.d.ts +8 -0
  20. package/types/packages/client/query/src/lib/index.d.ts +3 -0
  21. package/types/packages/client/query/src/lib/models/autocomplete-request.d.ts +26 -0
  22. package/types/packages/client/query/src/lib/models/autocomplete-response.d.ts +28 -0
  23. package/types/packages/client/query/src/lib/models/autocomplete-suggestion-part.d.ts +30 -0
  24. package/types/packages/client/query/src/lib/models/autocomplete-suggestion.d.ts +28 -0
  25. package/types/packages/client/query/src/lib/models/dql-alternative-node.d.ts +18 -0
  26. package/types/packages/client/query/src/lib/models/dql-container-node.d.ts +23 -0
  27. package/types/packages/client/query/src/lib/models/dql-node-node-type.d.ts +14 -0
  28. package/types/packages/client/query/src/lib/models/dql-node.d.ts +29 -0
  29. package/types/packages/client/query/src/lib/models/dql-terminal-node.d.ts +26 -0
  30. package/types/packages/client/query/src/lib/models/error-envelope.d.ts +18 -0
  31. package/types/packages/client/query/src/lib/models/error-response-details.d.ts +50 -0
  32. package/types/packages/client/query/src/lib/models/error-response.d.ts +25 -0
  33. package/types/packages/client/query/src/lib/models/execute-request.d.ts +64 -0
  34. package/types/packages/client/query/src/lib/models/field-type-type.d.ts +21 -0
  35. package/types/packages/client/query/src/lib/models/field-type.d.ts +18 -0
  36. package/types/packages/client/query/src/lib/models/geo-point.d.ts +22 -0
  37. package/types/packages/client/query/src/lib/models/grail-metadata.d.ts +66 -0
  38. package/types/packages/client/query/src/lib/models/index.d.ts +35 -0
  39. package/types/packages/client/query/src/lib/models/metadata-notification.d.ts +45 -0
  40. package/types/packages/client/query/src/lib/models/metadata.d.ts +18 -0
  41. package/types/packages/client/query/src/lib/models/metric-metadata.d.ts +32 -0
  42. package/types/packages/client/query/src/lib/models/parse-request.d.ts +24 -0
  43. package/types/packages/client/query/src/lib/models/position-info.d.ts +27 -0
  44. package/types/packages/client/query/src/lib/models/query-poll-response.d.ts +28 -0
  45. package/types/packages/client/query/src/lib/models/query-result.d.ts +27 -0
  46. package/types/packages/client/query/src/lib/models/query-start-response.d.ts +33 -0
  47. package/types/packages/client/query/src/lib/models/query-state.d.ts +17 -0
  48. package/types/packages/client/query/src/lib/models/ranged-field-types-mappings.d.ts +15 -0
  49. package/types/packages/client/query/src/lib/models/ranged-field-types.d.ts +20 -0
  50. package/types/packages/client/query/src/lib/models/result-record-value.d.ts +13 -0
  51. package/types/packages/client/query/src/lib/models/result-record.d.ts +15 -0
  52. package/types/packages/client/query/src/lib/models/timeframe.d.ts +22 -0
  53. package/types/packages/client/query/src/lib/models/token-position.d.ts +20 -0
  54. package/types/packages/client/query/src/lib/models/token-type.d.ts +48 -0
  55. package/types/packages/client/query/src/lib/models/verify-request.d.ts +24 -0
  56. package/types/packages/client/query/src/lib/models/verify-response.d.ts +23 -0
  57. package/types/packages/client/query/src/lib/utils/url-helpers.d.ts +3 -0
  58. package/types/packages/http-client/src/index.d.ts +2 -0
  59. package/types/packages/http-client/src/lib/platform/abort-controller.d.ts +6 -0
  60. package/types/packages/http-client/src/lib/platform/abort-signal.d.ts +6 -0
  61. package/types/packages/http-client/src/lib/platform/apply-content-type-header.d.ts +2 -0
  62. package/types/packages/http-client/src/lib/platform/base-error.d.ts +5 -0
  63. package/types/packages/http-client/src/lib/platform/binary.d.ts +13 -0
  64. package/types/packages/http-client/src/lib/platform/data-type-error.d.ts +6 -0
  65. package/types/packages/http-client/src/lib/platform/decode-response-body.d.ts +3 -0
  66. package/types/packages/http-client/src/lib/platform/default-status-validator.d.ts +2 -0
  67. package/types/packages/http-client/src/lib/platform/encode-request-body.d.ts +2 -0
  68. package/types/packages/http-client/src/lib/platform/http-client-abort-error.d.ts +7 -0
  69. package/types/packages/http-client/src/lib/platform/http-client-request-error.d.ts +7 -0
  70. package/types/packages/http-client/src/lib/platform/http-client-response-error-serializer.d.ts +1 -0
  71. package/types/packages/http-client/src/lib/platform/http-client-response-error.d.ts +8 -0
  72. package/types/packages/http-client/src/lib/platform/http-client-response.d.ts +10 -0
  73. package/types/packages/http-client/src/lib/platform/http-client.d.ts +5 -0
  74. package/types/packages/http-client/src/lib/platform/index.d.ts +11 -0
  75. package/types/packages/http-client/src/lib/platform/unsupported-operation-error.d.ts +6 -0
  76. package/types/packages/http-client/src/lib/types/abort-controller.d.ts +14 -0
  77. package/types/packages/http-client/src/lib/types/abort-signal.d.ts +15 -0
  78. package/types/packages/http-client/src/lib/types/base-error.d.ts +4 -0
  79. package/types/packages/http-client/src/lib/types/binary.d.ts +15 -0
  80. package/types/packages/http-client/src/lib/types/data-type-error.d.ts +14 -0
  81. package/types/packages/http-client/src/lib/types/data-types.d.ts +36 -0
  82. package/types/packages/http-client/src/lib/types/form-data-request-body.d.ts +83 -0
  83. package/types/packages/http-client/src/lib/types/form-data-response-body.d.ts +15 -0
  84. package/types/packages/http-client/src/lib/types/headers.d.ts +6 -0
  85. package/types/packages/http-client/src/lib/types/http-client-abort-error.d.ts +14 -0
  86. package/types/packages/http-client/src/lib/types/http-client-network-error.d.ts +14 -0
  87. package/types/packages/http-client/src/lib/types/http-client-request-error.d.ts +14 -0
  88. package/types/packages/http-client/src/lib/types/http-client-request-options.d.ts +42 -0
  89. package/types/packages/http-client/src/lib/types/http-client-response-error.d.ts +19 -0
  90. package/types/packages/http-client/src/lib/types/http-client-response.d.ts +33 -0
  91. package/types/packages/http-client/src/lib/types/http-client.d.ts +24 -0
  92. package/types/packages/http-client/src/lib/types/index.d.ts +20 -0
  93. package/types/packages/http-client/src/lib/types/request-body-types.d.ts +26 -0
  94. package/types/packages/http-client/src/lib/types/response-body-types.d.ts +46 -0
  95. package/types/packages/http-client/src/lib/types/status-validator.d.ts +7 -0
  96. package/types/packages/http-client/src/lib/types/unsupported-operation-error.d.ts +14 -0
  97. package/types/packages/platform/error-handlers/src/index.d.ts +2 -0
  98. package/types/packages/platform/error-handlers/src/lib/add-global-error-serializer.d.ts +13 -0
  99. package/types/packages/platform/error-handlers/src/lib/types/common-serialized-error.d.ts +10 -0
  100. package/types/packages/platform/error-handlers/src/lib/types/dt-runtime-error-handlers.d.ts +5 -0
  101. package/types/packages/platform/error-handlers/src/lib/types/error-type.d.ts +9 -0
  102. package/types/packages/platform/error-handlers/src/lib/types/global-dt-runtime-with-error-handlers.d.ts +7 -0
  103. package/types/packages/platform/error-handlers/src/lib/types/global-error-serializer.d.ts +10 -0
  104. package/types/packages/platform/error-handlers/src/lib/types/http-serialized-error.d.ts +11 -0
  105. package/types/packages/platform/error-handlers/src/lib/types/index.d.ts +6 -0
  106. package/types/packages/platform/error-handlers/src/lib/types/serialized-error.d.ts +8 -0
  107. package/types/packages/platform/shared/index.d.ts +1 -0
  108. package/types/packages/platform/shared/utils/get-global-with-dt-runtime.d.ts +1 -0
package/docs/DOCS.md ADDED
@@ -0,0 +1,2833 @@
1
+ # Storage – Query Service
2
+
3
+ SDK package version **1.0.0**
4
+
5
+ ```bash
6
+ npm install @dynatrace-sdk/client-query
7
+ ```
8
+
9
+ Exposes an API to fetch records stored in Grail
10
+
11
+ ## queryAssistanceClient
12
+
13
+ ```js
14
+ import { queryAssistanceClient } from '@dynatrace-sdk/client-query';
15
+ ```
16
+
17
+
18
+ ### queryAutocomplete
19
+
20
+ <div class="padding-bottom--md">
21
+ <strong>queryAssistanceClient.queryAutocomplete(config): <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise">Promise</a>&lt;<a href="#autocompleteresponse">AutocompleteResponse</a>&gt;</strong>
22
+
23
+ <div class="padding-left--md">
24
+
25
+ Get a structured list of suggestions for the query at the given position.
26
+
27
+ ## Overview
28
+
29
+ We provide a list of suggestions that may be used after the cursor position. The following queries will all provide the
30
+ same results:
31
+
32
+ * `query: "f"`
33
+ * `query: "f", cursorPosition:1`
34
+ * `query: "fetch ", cursorPosition:1`
35
+
36
+ Available fields:
37
+
38
+ | Field | Description |
39
+ |-------------|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
40
+ | suggestions | a list of suggestions. Each item is a separate possible suggestion, despite they might have the same outputs. |
41
+ | optional | whether the suggestion is optional. If `true`, the query until the cursor position might work. If `false`, the query is definitely incomplete or invalid if cut at the cursor position. |
42
+
43
+ Fields in the `suggestions`
44
+
45
+ | Field | Description |
46
+ |------------------------|------------------------------------------------------------------------------------------------------------|
47
+ | suggestion | a string representing the whole suggestion. This information could also be derived from the parts. |
48
+ | alreadyTypedCharacters | how many characters of this suggestion have already been typed (and will be overridden by the suggestion). |
49
+ | parts | a list of semantically enriched information on what are the parts of a suggestion. |
50
+
51
+ Fields in `parts`
52
+
53
+ | Field | Description |
54
+ |------------|-----------------------------------------------------------|
55
+ | suggestion | a string representing the current part of the suggestion. |
56
+ | type | current types: SPACE, PIPE, COMMAND (may be extended) |
57
+
58
+ The `type` helps to treat specific parts of the suggestion different to others; either by a different visualization,
59
+ a link to docs, etc.
60
+
61
+
62
+ **Parameters**
63
+
64
+ <div class="padding-left--md padding-bottom--md">
65
+ <strong>config</strong>: Object
66
+ <div class="padding-left--md">
67
+
68
+
69
+
70
+ </div>
71
+
72
+
73
+
74
+ </div>
75
+
76
+ <div class="padding-left--md padding-bottom--md">
77
+ <strong>config.abortSignal</strong>: <a href="https://developer.mozilla.org/en-US/docs/Web/API/AbortSignal">AbortSignal</a>
78
+ <div class="padding-left--md">
79
+
80
+
81
+
82
+ </div>
83
+
84
+
85
+
86
+ </div>
87
+
88
+ <div class="padding-left--md padding-bottom--md">
89
+ <strong>config.authorization</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/String">string</a>
90
+ <div class="padding-left--md">
91
+
92
+ The authorization context. Typically start with 'Bearer '.
93
+
94
+ </div>
95
+
96
+
97
+
98
+ </div>
99
+
100
+ <div class="padding-left--md padding-bottom--md">
101
+ <strong>config.body</strong>: <a href="#autocompleterequest">AutocompleteRequest</a>
102
+ <div class="padding-left--md">
103
+
104
+
105
+
106
+ </div>
107
+
108
+
109
+
110
+ </div>
111
+
112
+
113
+
114
+ #### Returns
115
+
116
+ <div class="padding-left--md">
117
+ A list of structured autocomplete suggestions.
118
+
119
+ </div>
120
+
121
+
122
+
123
+
124
+
125
+ </div>
126
+
127
+
128
+
129
+ </div>
130
+
131
+
132
+ ### queryParse
133
+
134
+ <div class="padding-bottom--md">
135
+ <strong>queryAssistanceClient.queryParse(config): <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise">Promise</a>&lt;<a href="#dqlnode">DQLNode</a>&gt;</strong>
136
+
137
+ <div class="padding-left--md">
138
+
139
+ Get a structured tree of the canonical form of the query.
140
+
141
+ ## Overview
142
+
143
+ Returns the parsed query as a tree, containing the structure of the canonical query. Tree-nodes can contain references to
144
+ the token position where they originate from. This may help to provide hover effects, show canonical forms, mark
145
+ optional items, and more.
146
+
147
+ ## Details
148
+
149
+ The query tree consists of nodes that contain different additional information (everything optional):
150
+
151
+ ### General Fields
152
+
153
+ Field | Mandatory | Description
154
+ ----------------------- | --- | ----------------------------------------------------------------------------------------
155
+ tokenPosition | no | optional. If present, it represents the position within the query string where the node refers to.
156
+ isOptional | no | whether this node could be left out and the result would still be the same query (semantically).
157
+
158
+ #### tokenPosition
159
+
160
+ contains `start` (inclusive) and `end` (inclusive), both contain `index` (0 based; fur substrings), `line`
161
+ and `column` (both 1-based; for readability).
162
+
163
+ * If `tokenPosition` is present, it always contains start and end with all fields
164
+ * If `tokenPosition` is not present, there might still be nested nodes that do contain a position
165
+ * If `start == end`, the position refers to a single character
166
+ * If `start &gt; end`, we know for sure that something was inserted.
167
+
168
+ We can always check whether the canonical representation of a node matches the text in the tokenPosition to see whether
169
+ something was inserted, removed, or changed.
170
+
171
+ #### isOptional
172
+
173
+ only present if it is true.
174
+
175
+ Optional nodes can e.g. be optional braces that make a query more readable, but are not necessary. This could be used to
176
+ enter *ghost braces* and *implicit functions* in the user's input field; maybe with different formatting
177
+ (using the tokenPosition of sibling nodes we can also check whether the user wrote these or not).
178
+
179
+ ### Advanced Token Types
180
+
181
+ each node is of one of following types and may contain more fields:
182
+
183
+ * Terminal Node
184
+ * ContainerNode
185
+ * Alternative Node
186
+
187
+ #### Terminal Node
188
+
189
+ can be identified by checking whether `canonicalString` is present
190
+
191
+ Field | Mandatory | Description
192
+ ------------------------ | --- | ---------------------------------------------------------------------------------------
193
+ type | yes | the type of the terminal node - do not confuse with the type of container nodes
194
+ canonicalString | yes | the canonical string representation. Concatenating the canonicalString of all nested terminal nodes provides the canonical form of the query.
195
+ isMandatoryOnUserOrder | no | may only be present if (`type="BRACE_OPEN"` or `type="BRACE_CLOSE"`) and `isOptional=true`. For usage see section [Special node type: PARAMETERS](#special-node-type-parameters)
196
+
197
+ ##### Current types of terminal nodes (list might grow):
198
+
199
+ * SPACE
200
+ * LINEBREAK
201
+ * INDENT
202
+ * PIPE
203
+ * DOT
204
+ * COLON
205
+ * COMMA
206
+ * BRACE_OPEN
207
+ * BRACE_CLOSE
208
+ * BRACKET_OPEN
209
+ * BRACKET_CLOSE
210
+ * PARENTHESIS_OPEN
211
+ * PARENTHESIS_CLOSE
212
+ * QUOTE
213
+ * SLASH
214
+ * BOOLEAN_TRUE
215
+ * BOOLEAN_FALSE
216
+ * NULL
217
+ * COMMAND_NAME
218
+ * PARAMETER_KEY
219
+ * PARAMETER_VALUE_SCOPE
220
+ * FUNCTION_NAME
221
+ * OPERATOR
222
+ * TRAVERSAL_OPERATOR
223
+ * TRAVERSAL_RELATION_NAME
224
+ * TRAVERSAL_HOP_COUNT
225
+ * SIMPLE_IDENTIFIER
226
+ * NUMBER
227
+ * STRING
228
+ * TIME_UNIT
229
+ * TIMESTAMP_VALUE
230
+ * METRIC_KEY
231
+ * VARIABLE
232
+
233
+ #### ContainerNode
234
+
235
+ can be identified by checking whether `children` is present
236
+
237
+ Field | Mandatory | Description
238
+ ----------------------- | --- | ----------------------------------------------------------------------------------------
239
+ type | yes | the type of the container node - do not confuse with the type of terminal nodes
240
+ children | yes | the children for the node. might be of any type
241
+
242
+ ##### Current types of container nodes (list might grow):
243
+
244
+ * QUERY
245
+ * EXECUTION_BLOCK
246
+ * COMMAND
247
+ * COMMAND_SEPARATOR
248
+ * PARAMETER_WITH_KEY
249
+ * GROUP
250
+ * PARAMETERS - check examples further down
251
+ * PARAMETER_NAMING
252
+ * PARAMETER_SEPARATOR
253
+ * FUNCTION
254
+ * FUNCTION_PART - check examples further down
255
+ * EXPRESSION
256
+ * IDENTIFIER
257
+ * SOURCE_ID
258
+ * DURATION
259
+ * TIMESTAMP
260
+ * TIMEFRAME
261
+ * TRAVERSAL_PATH
262
+ * TRAVERSAL_STEP
263
+
264
+ ##### Special node type: PARAMETERS
265
+
266
+ can contain children representing the parameters. Every second child is of type PARAMETER_SEPARATOR.
267
+
268
+ You may reorder the children based on their tokenPosition to get the user order. However, in this case,
269
+ you need to consider `isMandatoryOnUserOrder` to determine whether the grouping braces are mandatory or not.
270
+
271
+ ###### Example
272
+
273
+ For the query `SORT a, {direction:"descending", b}`, the canonical form is:
274
+
275
+ `SORT a, {b, direction:"descending"}`
276
+
277
+ This is the order, in which the parameters are returned in the query tree.
278
+ Parameters are {a} and {{b} and {direction:"descending"}}. In this case, the braces are optional.
279
+
280
+ `SORT a, {b, direction:"descending"}` is equivalent to `SORT a, b, direction:"descending"`
281
+
282
+ However, if you reorder the children by tokenPosition, the braces are not optional, because
283
+
284
+ `SORT a, direction:"descending", b` is interpreted as `SORT {a, direction:"descending"}, b`
285
+
286
+ So, if the children in PARAMETERS are re-ordered by tokenPosition, braces (or in general: TerminalNodes)
287
+ are only optional if `isOptional && !isMandatoryOnUserOrder`.
288
+
289
+ ##### Special node type: FUNCTION_PART
290
+
291
+ A container node of type `FUNCTION` may contain nodes of type `FUNCTION_PART`.
292
+
293
+ If those `FUNCTION_PART`s are marked as optional, this means you have to either include *all* or *none* of these
294
+ optional function parts.
295
+
296
+ *Example*:
297
+
298
+ `filter anyMatch(a.b == 1, input:a)`
299
+
300
+ The optional function parts are `anyMatch(` and `, input:a)`. If you leave out both, the command will still work:
301
+ `filter a.b == 1` and return the same result. Using one of these optional function parts and removing the other will lead
302
+ to an invalid query.
303
+
304
+ #### Alternative Node
305
+
306
+ can be identified by checking whether `alternatives` is present
307
+
308
+ Field | Mandatory | Description
309
+ ----------------------- | --- | ----------------------------------------------------------------------------------------
310
+ alternatives | yes | Type: Map&lt;AlternativeType, DQLNode&gt;
311
+
312
+ When displaying the query, pick one option. You may use the other options for hovering, replacing, and more.
313
+
314
+ ##### Current values of AlternativeType (list might grow):
315
+
316
+ * CANONICAL: This node is the one we will use for our canonical form
317
+ * USER: An alternative that is also valid, but not canonical; and this version was picked by the user.
318
+ * INFO: only if the canonical version is not present
319
+
320
+ *Examples*:
321
+
322
+ * `CANONICAL` is not present, `USER` is present: user's nodes are optional, but not canonical (usually optional nodes
323
+ are still canonical)
324
+ * `CANONICAL` is present, `USER` is not present: same as if the canonical node was optional. If this happens, it is
325
+ likely that there is also an `INFO` node
326
+ * `CANONICAL` is present, `USER` is present: there are different alternatives
327
+ * `INFO` is present: usually if `CANONICAL` is not present (e.g. the parameter key for `FILTER a == 1`), there is an info node
328
+ for `FILTER condition:a == 1`. This `condition:` was neither written by the user nor is it canonical; but it might be
329
+ used to help the user understand what this parameter means.
330
+
331
+
332
+ **Parameters**
333
+
334
+ <div class="padding-left--md padding-bottom--md">
335
+ <strong>config</strong>: Object
336
+ <div class="padding-left--md">
337
+
338
+
339
+
340
+ </div>
341
+
342
+
343
+
344
+ </div>
345
+
346
+ <div class="padding-left--md padding-bottom--md">
347
+ <strong>config.abortSignal</strong>: <a href="https://developer.mozilla.org/en-US/docs/Web/API/AbortSignal">AbortSignal</a>
348
+ <div class="padding-left--md">
349
+
350
+
351
+
352
+ </div>
353
+
354
+
355
+
356
+ </div>
357
+
358
+ <div class="padding-left--md padding-bottom--md">
359
+ <strong>config.authorization</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/String">string</a>
360
+ <div class="padding-left--md">
361
+
362
+ The authorization context. Typically start with 'Bearer '.
363
+
364
+ </div>
365
+
366
+
367
+
368
+ </div>
369
+
370
+ <div class="padding-left--md padding-bottom--md">
371
+ <strong>config.body</strong>: <a href="#parserequest">ParseRequest</a>
372
+ <div class="padding-left--md">
373
+
374
+
375
+
376
+ </div>
377
+
378
+
379
+
380
+ </div>
381
+
382
+
383
+
384
+ #### Returns
385
+
386
+ <div class="padding-left--md">
387
+ A node containing more nodes, a node offering different (semantically equivalent) versions of the query parts, or a terminal node that shows the canonical form.
388
+
389
+ </div>
390
+
391
+
392
+
393
+
394
+
395
+ </div>
396
+
397
+
398
+
399
+ </div>
400
+
401
+
402
+ ### queryVerify
403
+
404
+ <div class="padding-bottom--md">
405
+ <strong>queryAssistanceClient.queryVerify(config): <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise">Promise</a>&lt;<a href="#verifyresponse">VerifyResponse</a>&gt;</strong>
406
+
407
+ <div class="padding-left--md">
408
+
409
+ Verifies a query without executing it.
410
+
411
+ ## Overview
412
+
413
+ Verifies the supplied query string and other query parameters for lack of any errors, but without actually
414
+ submitting the query for execution.
415
+
416
+
417
+ **Parameters**
418
+
419
+ <div class="padding-left--md padding-bottom--md">
420
+ <strong>config</strong>: Object
421
+ <div class="padding-left--md">
422
+
423
+
424
+
425
+ </div>
426
+
427
+
428
+
429
+ </div>
430
+
431
+ <div class="padding-left--md padding-bottom--md">
432
+ <strong>config.abortSignal</strong>: <a href="https://developer.mozilla.org/en-US/docs/Web/API/AbortSignal">AbortSignal</a>
433
+ <div class="padding-left--md">
434
+
435
+
436
+
437
+ </div>
438
+
439
+
440
+
441
+ </div>
442
+
443
+ <div class="padding-left--md padding-bottom--md">
444
+ <strong>config.authorization</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/String">string</a>
445
+ <div class="padding-left--md">
446
+
447
+ The authorization context. Typically start with 'Bearer '.
448
+
449
+ </div>
450
+
451
+
452
+
453
+ </div>
454
+
455
+ <div class="padding-left--md padding-bottom--md">
456
+ <strong>config.body</strong>: <a href="#verifyrequest">VerifyRequest</a>
457
+ <div class="padding-left--md">
458
+
459
+
460
+
461
+ </div>
462
+
463
+
464
+
465
+ </div>
466
+
467
+
468
+
469
+ #### Returns
470
+
471
+ <div class="padding-left--md">
472
+ Supplied query and parameters were verified.
473
+
474
+ </div>
475
+
476
+
477
+
478
+
479
+
480
+ </div>
481
+
482
+
483
+
484
+ </div>
485
+
486
+
487
+
488
+
489
+ ## queryExecutionClient
490
+
491
+ ```js
492
+ import { queryExecutionClient } from '@dynatrace-sdk/client-query';
493
+ ```
494
+
495
+
496
+ ### queryCancel
497
+
498
+ <div class="padding-bottom--md">
499
+ <strong>queryExecutionClient.queryCancel(config): <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise">Promise</a>&lt;void | <a href="#querypollresponse">QueryPollResponse</a>&gt;</strong>
500
+
501
+ <div class="padding-left--md">
502
+
503
+ Cancels the query and returns the result if the query was already finished, otherwise discards it.
504
+
505
+ ### Overview:
506
+
507
+ Cancels a running Grail query and returns a list of records if the query already finished.
508
+
509
+ ### The response format:
510
+
511
+ If the query was already finished, a response body including the result will be returned. Otherwise the response will contain no body.
512
+
513
+ The result has three main sections:
514
+ * the 'records' section contains the individual records, where each record consists of a set of fields and their corresponding values.
515
+ * the 'types' section describes the corresponding data types that a record field has.
516
+ * the 'metadata' section contains information about the query like 'analysisTimeframe', 'timezone' or 'locale'.
517
+
518
+ Every record has an implicit 'index' according to the position in the 'records' JSON array.
519
+ The types section has a list of 1..N possibhttps://dev.deus-dev.internal.dynatracelabs.com/query-frontend/docs/rest/swagger-ui/index.html?urls.primaryName=v0.5#/Query%20Execution/query%3Acancelle type 'buckets'. Each such bucket has an 'indexRange' which indicates which
520
+ records will find their field types in which bucket. The index range has two values start & end and can be thought of as [startIndex, endIndex).
521
+
522
+ A field part of a record with index 'i' will find its corresponding field type by first locating the bucket that satisfies:
523
+
524
+ ```text
525
+ startIndex &lt;= i &lt;= endIndex
526
+ ```
527
+
528
+ Once the bucket is found the 'mappings' object has an entry for all the fields that are part of that record with index 'i'.
529
+
530
+
531
+ Since enforcement of a particular schema is absent at ingestion time, it is possible to have records that share the same
532
+ field name but their values are of a different type. This phenomenon will hence forth be named as a **"collision"**.
533
+ When a collision does occur, we will create a new type 'bucket' that will have a different index range where
534
+ the new record field types will be placed.
535
+ It is guaranteed that every field of every record will have a corresponding type.
536
+ **Clients should always take the included types into account when consuming records!**
537
+
538
+
539
+ As an example, the following response highlights a collision, where a field called "cancelled" was ingested both as a
540
+ boolean but also wrongly as a string. The first record contains the field "cancelled" as a string, but the very next record has the
541
+ field with the same name but of boolean type. The types section has two entries. One corresponds to first record that has
542
+ the field cancelled of type string. The second entry in the types section corresponds to the subsequent records which have
543
+ the boolean field type.
544
+
545
+ ```json
546
+ {
547
+ "state":"SUCCEEDED",
548
+ "ttlSeconds":197,
549
+ "result": {
550
+ "records": [
551
+ {
552
+ "type": "user_event",
553
+ "order_id": "1ea34-2515-1515-fe1g",
554
+ "cancelled": "true"
555
+ },
556
+ {
557
+ "type": "user_event",
558
+ "order_id": "2ea34-2515-1515-fe1g",
559
+ "cancelled": false
560
+ },
561
+ {
562
+ "type": "user_event",
563
+ "order_id": "3ea34-2515-1515-fe1g",
564
+ "cancelled": true
565
+ },
566
+ {
567
+ "type": "user_event",
568
+ "order_id": "4ea34-2515-1515-fe1g",
569
+ "cancelled": false
570
+ }
571
+ ],
572
+ "types": [
573
+ {
574
+ "indexRange": [
575
+ 0,
576
+ 1
577
+ ],
578
+ "mappings": {
579
+ "type": {
580
+ "type": "string"
581
+ },
582
+ "order_id": {
583
+ "type": "string"
584
+ },
585
+ "cancelled": {
586
+ "type": "string"
587
+ }
588
+ }
589
+ },
590
+ {
591
+ "indexRange": [
592
+ 1,
593
+ 4
594
+ ],
595
+ "mappings": {
596
+ "type": {
597
+ "type": "string"
598
+ },
599
+ "order_id": {
600
+ "type": "string"
601
+ },
602
+ "cancelled": {
603
+ "type": "boolean"
604
+ }
605
+ }
606
+ }
607
+ ],
608
+ "metadata": {
609
+ "query": "fetch events | ...",
610
+ "dqlVersion": "V0_3",
611
+ "appliedTimeframe": {
612
+ "start": 1657624357056,
613
+ "end": 1657631557056
614
+ },
615
+ "timezone": "Z",
616
+ "locale": ""
617
+ }
618
+ }
619
+ }
620
+ ```
621
+
622
+ ### Field data types
623
+
624
+ The possible Grail types encountered in the "types" section is limited to a list of well-defined types:
625
+ ```
626
+ BOOLEAN
627
+ STRING
628
+ DOUBLE
629
+ LONG
630
+ TIMESTAMP
631
+ TIMEFRAME
632
+ DURATION
633
+ BINARY
634
+ IP_ADDRESS
635
+ GEO_POINT
636
+ ARRAY
637
+ RECORD
638
+ ```
639
+
640
+
641
+ **Parameters**
642
+
643
+ <div class="padding-left--md padding-bottom--md">
644
+ <strong>config</strong>: Object
645
+ <div class="padding-left--md">
646
+
647
+
648
+
649
+ </div>
650
+
651
+
652
+
653
+ </div>
654
+
655
+ <div class="padding-left--md padding-bottom--md">
656
+ <strong>config.abortSignal</strong>: <a href="https://developer.mozilla.org/en-US/docs/Web/API/AbortSignal">AbortSignal</a>
657
+ <div class="padding-left--md">
658
+
659
+
660
+
661
+ </div>
662
+
663
+
664
+
665
+ </div>
666
+
667
+ <div class="padding-left--md padding-bottom--md">
668
+ <strong>config.requestToken</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/String">string</a>
669
+ <div class="padding-left--md">
670
+
671
+ The request-token of the query.
672
+
673
+ </div>
674
+
675
+
676
+
677
+ </div>
678
+
679
+
680
+
681
+ #### Returns
682
+
683
+ <div class="padding-left--md">
684
+ The query already finished.
685
+
686
+ </div>
687
+
688
+
689
+
690
+
691
+
692
+ </div>
693
+
694
+
695
+
696
+ </div>
697
+
698
+
699
+ ### queryExecute
700
+
701
+ <div class="padding-bottom--md">
702
+ <strong>queryExecutionClient.queryExecute(config): <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise">Promise</a>&lt;<a href="#querystartresponse">QueryStartResponse</a>&gt;</strong>
703
+
704
+ <div class="padding-left--md">
705
+
706
+ Starts a Grail query.
707
+
708
+ ### Overview:
709
+
710
+ Executes a query and returns a list of records.
711
+
712
+ For details about the query language see the [Dynatrace Query Language documentation](https://dt-url.net/bv03yk8).
713
+
714
+ ### The response format:
715
+
716
+ The json response will contain the state of the started query and a request token to reference it in future polling requests:
717
+
718
+ ```json
719
+ {
720
+ "state":"RUNNING",
721
+ "requestToken":"5tCm27WbTHmyi+749/wGsw==",
722
+ "ttlSeconds":197
723
+ }
724
+ ```
725
+
726
+
727
+ **Parameters**
728
+
729
+ <div class="padding-left--md padding-bottom--md">
730
+ <strong>config</strong>: Object
731
+ <div class="padding-left--md">
732
+
733
+
734
+
735
+ </div>
736
+
737
+
738
+
739
+ </div>
740
+
741
+ <div class="padding-left--md padding-bottom--md">
742
+ <strong>config.abortSignal</strong>: <a href="https://developer.mozilla.org/en-US/docs/Web/API/AbortSignal">AbortSignal</a>
743
+ <div class="padding-left--md">
744
+
745
+
746
+
747
+ </div>
748
+
749
+
750
+
751
+ </div>
752
+
753
+ <div class="padding-left--md padding-bottom--md">
754
+ <strong>config.authorization</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/String">string</a>
755
+ <div class="padding-left--md">
756
+
757
+ The authorization context. Typically start with 'Bearer '.
758
+
759
+ </div>
760
+
761
+
762
+
763
+ </div>
764
+
765
+ <div class="padding-left--md padding-bottom--md">
766
+ <strong>config.body</strong>: <a href="#executerequest">ExecuteRequest</a>
767
+ <div class="padding-left--md">
768
+
769
+
770
+
771
+ </div>
772
+
773
+
774
+
775
+ </div>
776
+
777
+ <div class="padding-left--md padding-bottom--md">
778
+ <strong>config.enrich</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/String">string</a>
779
+ <div class="padding-left--md">
780
+
781
+ If set additional data will be available in the metadata section.
782
+
783
+ </div>
784
+
785
+
786
+
787
+ </div>
788
+
789
+
790
+
791
+ #### Returns
792
+
793
+ <div class="padding-left--md">
794
+ The final status and results of the supplied query if it finished within a supplied request-timeout-milliseconds. | The status of the query to start.
795
+
796
+ </div>
797
+
798
+
799
+
800
+
801
+
802
+ </div>
803
+
804
+
805
+
806
+ </div>
807
+
808
+
809
+ ### queryPoll
810
+
811
+ <div class="padding-bottom--md">
812
+ <strong>queryExecutionClient.queryPoll(config): <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise">Promise</a>&lt;<a href="#querypollresponse">QueryPollResponse</a>&gt;</strong>
813
+
814
+ <div class="padding-left--md">
815
+
816
+ Retrieves query status and final result from Grail.
817
+
818
+ ### Overview:
819
+
820
+ Polls the status of a Grail query. Returns the status of the query, including the result if the query finished.
821
+
822
+ ### The response format:
823
+ The response consists of:
824
+ * The state of the query.
825
+ * ttlSeconds until the query will be wiped
826
+ * If the query succeeded, also a result
827
+
828
+ ```json
829
+ {
830
+ "state":"RUNNING",
831
+ "ttlSeconds":197
832
+ }
833
+ ```
834
+
835
+ The result has two main sections:
836
+ * The 'records' section contains the individual records, where each record consists of a set of fields and their corresponding values.
837
+ * The 'types' section describes the corresponding data types that a record field has.
838
+
839
+ Every record has an implicit 'index' according to the position in the 'records' JSON array.
840
+ The types section has a list of 1..N possible type 'buckets'. Each such bucket has an 'indexRange' which indicates which
841
+ records will find their field types in which bucket. The index range has two values start & end and can be thought of as [startIndex, endIndex).
842
+
843
+ A field part of a record with index 'i' will find its corresponding field type by first locating the bucket that satisfies:
844
+
845
+ ```text
846
+ startIndex &lt;= i &lt;= endIndex
847
+ ```
848
+
849
+ Once the bucket is found the 'mappings' object has an entry for all the fields that are part of that record with index 'i'.
850
+
851
+
852
+ Since enforcement of a particular schema is absent at ingestion time, it is possible to have records that share the same
853
+ field name but their values are of a different type. This phenomenon will hence forth be named as a **"collision"**.
854
+ When a collision does occur, we will create a new type 'bucket' that will have a different index range where
855
+ the new record field types will be placed.
856
+ It is guaranteed that every field of every record will have a corresponding type.
857
+ **Clients should always take the included types into account when consuming records!**
858
+
859
+ As an example, the following response highlights a collision, where a field called "cancelled" was ingested both as a
860
+ boolean but also wrongly as a string. The first record contains the field "cancelled" as a string, but the very next record has the
861
+ field with the same name but of boolean type. The types section has two entries. One corresponds to first record that has
862
+ the field cancelled of type string. The second entry in the types section corresponds to the subsequent records which have
863
+ the boolean field type.
864
+
865
+ ```json
866
+ {
867
+ "state":"SUCCEEDED",
868
+ "result": {
869
+ "records": [
870
+ {
871
+ "type": "user_event",
872
+ "order_id": "1ea34-2515-1515-fe1g",
873
+ "cancelled": "true"
874
+ },
875
+ {
876
+ "type": "user_event",
877
+ "order_id": "2ea34-2515-1515-fe1g",
878
+ "cancelled": false
879
+ },
880
+ {
881
+ "type": "user_event",
882
+ "order_id": "3ea34-2515-1515-fe1g",
883
+ "cancelled": true
884
+ },
885
+ {
886
+ "type": "user_event",
887
+ "order_id": "4ea34-2515-1515-fe1g",
888
+ "cancelled": false
889
+ }
890
+ ],
891
+ "types": [
892
+ {
893
+ "indexRange": [
894
+ 0,
895
+ 1
896
+ ],
897
+ "mappings": {
898
+ "type": {
899
+ "type": "string"
900
+ },
901
+ "order_id": {
902
+ "type": "string"
903
+ },
904
+ "cancelled": {
905
+ "type": "string"
906
+ }
907
+ }
908
+ },
909
+ {
910
+ "indexRange": [
911
+ 1,
912
+ 4
913
+ ],
914
+ "mappings": {
915
+ "type": {
916
+ "type": "string"
917
+ },
918
+ "order_id": {
919
+ "type": "string"
920
+ },
921
+ "cancelled": {
922
+ "type": "boolean"
923
+ }
924
+ }
925
+ }
926
+ ],
927
+ "metadata": {
928
+ "query": "fetch events | ...",
929
+ "dqlVersion": "V0_3",
930
+ "appliedTimeframe": {
931
+ "start": 1657624357056,
932
+ "end": 1657631557056
933
+ },
934
+ "timezone": "Z",
935
+ "locale": ""
936
+ }
937
+ }
938
+ }
939
+ ```
940
+
941
+ The possible Grail types ened in the "types" section is limited to a list of well-defined types:
942
+ ```
943
+ BOOLEAN
944
+ STRING
945
+ DOUBLE
946
+ LONG
947
+ TIMESTAMP
948
+ TIMEFRAME
949
+ DURATION
950
+ BINARY
951
+ IP_ADDRESS
952
+ GEO_POINT
953
+ ARRAY
954
+ RECORD
955
+ ```
956
+
957
+
958
+ **Parameters**
959
+
960
+ <div class="padding-left--md padding-bottom--md">
961
+ <strong>config</strong>: Object
962
+ <div class="padding-left--md">
963
+
964
+
965
+
966
+ </div>
967
+
968
+
969
+
970
+ </div>
971
+
972
+ <div class="padding-left--md padding-bottom--md">
973
+ <strong>config.abortSignal</strong>: <a href="https://developer.mozilla.org/en-US/docs/Web/API/AbortSignal">AbortSignal</a>
974
+ <div class="padding-left--md">
975
+
976
+
977
+
978
+ </div>
979
+
980
+
981
+
982
+ </div>
983
+
984
+ <div class="padding-left--md padding-bottom--md">
985
+ <strong>config.enrich</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/String">string</a>
986
+ <div class="padding-left--md">
987
+
988
+ If set additional data will be available in the metadata section.
989
+
990
+ </div>
991
+
992
+
993
+
994
+ </div>
995
+
996
+ <div class="padding-left--md padding-bottom--md">
997
+ <strong>config.requestTimeoutMilliseconds</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/Number">number</a>
998
+ <div class="padding-left--md">
999
+
1000
+ The request timeout in milliseconds. The response will be delayed for up to the specified time in milliseconds to wait for the result of the query.
1001
+
1002
+ </div>
1003
+
1004
+
1005
+
1006
+ </div>
1007
+
1008
+ <div class="padding-left--md padding-bottom--md">
1009
+ <strong>config.requestToken</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/String">string</a>
1010
+ <div class="padding-left--md">
1011
+
1012
+ The request-token of the query.
1013
+
1014
+ </div>
1015
+
1016
+
1017
+
1018
+ </div>
1019
+
1020
+
1021
+
1022
+ #### Returns
1023
+
1024
+ <div class="padding-left--md">
1025
+ The current status and results of the supplied query.
1026
+
1027
+ </div>
1028
+
1029
+
1030
+
1031
+
1032
+
1033
+ </div>
1034
+
1035
+
1036
+
1037
+ </div>
1038
+
1039
+
1040
+
1041
+
1042
+ ## Types
1043
+
1044
+ ### AutocompleteRequest
1045
+ <div class="padding-left--md">
1046
+
1047
+
1048
+
1049
+
1050
+
1051
+ <div class="padding-left--md padding-bottom--md">
1052
+ <strong>cursorPosition</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/Number">number</a>
1053
+ <div class="padding-left--md">
1054
+
1055
+
1056
+
1057
+ </div>
1058
+
1059
+
1060
+
1061
+ </div>
1062
+
1063
+ <div class="padding-left--md padding-bottom--md">
1064
+ <strong>locale</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/String">string</a>
1065
+ <div class="padding-left--md">
1066
+
1067
+ The query locale. If none specified, then a language/country neutral locale is chosen. The input values take the ISO-639 Language code with an optional ISO-3166 country code appended to it with an underscore. For instance, both values are valid 'en' or 'en_US'.
1068
+
1069
+ </div>
1070
+
1071
+
1072
+
1073
+ </div>
1074
+
1075
+ <div class="padding-left--md padding-bottom--md">
1076
+ <strong>query</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/String">string</a>
1077
+ <div class="padding-left--md">
1078
+
1079
+ The full query string.
1080
+
1081
+ </div>
1082
+
1083
+
1084
+
1085
+ </div>
1086
+
1087
+ <div class="padding-left--md padding-bottom--md">
1088
+ <strong>timezone</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/String">string</a>
1089
+ <div class="padding-left--md">
1090
+
1091
+ The query timezone. If none is specified, UTC is used as fallback. The list of valid input values matches that of the IANA Time Zone Database (TZDB). It accepts values in their canonical names like 'Europe/Paris', the abbreviated version like CET or the UTC offset format like '+01:00'
1092
+
1093
+ </div>
1094
+
1095
+
1096
+
1097
+ </div>
1098
+
1099
+
1100
+ </div>
1101
+
1102
+
1103
+
1104
+ ### AutocompleteResponse
1105
+ <div class="padding-left--md">
1106
+
1107
+
1108
+
1109
+ The response of the autocomplete call.
1110
+
1111
+ <div class="padding-left--md padding-bottom--md">
1112
+ <strong>optional</strong>: boolean
1113
+ <div class="padding-left--md">
1114
+
1115
+ True if the suggestions are optional.
1116
+
1117
+ </div>
1118
+
1119
+
1120
+
1121
+ </div>
1122
+
1123
+ <div class="padding-left--md padding-bottom--md">
1124
+ <strong>suggestedTtlSeconds</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/Number">number</a>
1125
+ <div class="padding-left--md">
1126
+
1127
+ Suggested duration in seconds, for how long the response may be cached and reused by the client. It is derived from the volatility of the suggestions on the server (if the suggestions are static, how long the server will cache the volatile suggestions, ...). If not provided, then the result may be cached for long time. Value below 1 means that the result should not be cached.
1128
+
1129
+ </div>
1130
+
1131
+
1132
+
1133
+ </div>
1134
+
1135
+ <div class="padding-left--md padding-bottom--md">
1136
+ <strong>suggestions</strong>: Array&lt;<a href="#autocompletesuggestion">AutocompleteSuggestion</a>&gt;
1137
+ <div class="padding-left--md">
1138
+
1139
+ The list of suggestions.
1140
+
1141
+ </div>
1142
+
1143
+
1144
+
1145
+ </div>
1146
+
1147
+
1148
+ </div>
1149
+
1150
+
1151
+
1152
+ ### AutocompleteSuggestion
1153
+ <div class="padding-left--md">
1154
+
1155
+
1156
+
1157
+ Single suggestion for completion of the query.
1158
+
1159
+ <div class="padding-left--md padding-bottom--md">
1160
+ <strong>alreadyTypedCharacters</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/Number">number</a>
1161
+ <div class="padding-left--md">
1162
+
1163
+ Number of characters that the user user already typed for this suggestion.
1164
+
1165
+ </div>
1166
+
1167
+
1168
+
1169
+ </div>
1170
+
1171
+ <div class="padding-left--md padding-bottom--md">
1172
+ <strong>parts</strong>: Array&lt;<a href="#autocompletesuggestionpart">AutocompleteSuggestionPart</a>&gt;
1173
+ <div class="padding-left--md">
1174
+
1175
+ List of suggestion parts.
1176
+
1177
+ </div>
1178
+
1179
+
1180
+
1181
+ </div>
1182
+
1183
+ <div class="padding-left--md padding-bottom--md">
1184
+ <strong>suggestion</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/String">string</a>
1185
+ <div class="padding-left--md">
1186
+
1187
+ The suggested continuation of the query.
1188
+
1189
+ </div>
1190
+
1191
+
1192
+
1193
+ </div>
1194
+
1195
+
1196
+ </div>
1197
+
1198
+
1199
+
1200
+ ### AutocompleteSuggestionPart
1201
+ <div class="padding-left--md">
1202
+
1203
+
1204
+
1205
+ Part of the suggestion.
1206
+
1207
+ <div class="padding-left--md padding-bottom--md">
1208
+ <strong>info</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/String">string</a>
1209
+ <div class="padding-left--md">
1210
+
1211
+ The type of the suggestion.
1212
+
1213
+ </div>
1214
+
1215
+
1216
+
1217
+ </div>
1218
+
1219
+ <div class="padding-left--md padding-bottom--md">
1220
+ <strong>suggestion</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/String">string</a>
1221
+ <div class="padding-left--md">
1222
+
1223
+ The suggested continuation of the query.
1224
+
1225
+ </div>
1226
+
1227
+
1228
+
1229
+ </div>
1230
+
1231
+ <div class="padding-left--md padding-bottom--md">
1232
+ <strong>synopsis</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/String">string</a>
1233
+ <div class="padding-left--md">
1234
+
1235
+ The synopsis of the suggestion.
1236
+
1237
+ </div>
1238
+
1239
+
1240
+
1241
+ </div>
1242
+
1243
+ <div class="padding-left--md padding-bottom--md">
1244
+ <strong>type</strong>: <a href="#tokentype">TokenType</a>
1245
+ <div class="padding-left--md">
1246
+
1247
+
1248
+
1249
+ </div>
1250
+
1251
+
1252
+
1253
+ </div>
1254
+
1255
+
1256
+ </div>
1257
+
1258
+
1259
+
1260
+ ### DQLAlternativeNode
1261
+ <div class="padding-left--md">
1262
+
1263
+
1264
+
1265
+ The DQL node that has alternatives.
1266
+
1267
+ <div class="padding-left--md padding-bottom--md">
1268
+ <strong>alternatives</strong>: object
1269
+ <div class="padding-left--md">
1270
+
1271
+ The different alternatives.
1272
+
1273
+ </div>
1274
+
1275
+
1276
+
1277
+ </div>
1278
+
1279
+ <div class="padding-left--md padding-bottom--md">
1280
+ <strong>isOptional</strong>: boolean
1281
+ <div class="padding-left--md">
1282
+
1283
+ True if the node is optional.
1284
+
1285
+ </div>
1286
+
1287
+
1288
+
1289
+ </div>
1290
+
1291
+ <div class="padding-left--md padding-bottom--md">
1292
+ <strong>nodeType</strong>: <a href="#dqlnodenodetype">DQLNodeNodeType</a>
1293
+ <div class="padding-left--md">
1294
+
1295
+
1296
+
1297
+ </div>
1298
+
1299
+
1300
+
1301
+ </div>
1302
+
1303
+ <div class="padding-left--md padding-bottom--md">
1304
+ <strong>tokenPosition</strong>: <a href="#tokenposition">TokenPosition</a>
1305
+ <div class="padding-left--md">
1306
+
1307
+
1308
+
1309
+ </div>
1310
+
1311
+
1312
+
1313
+ </div>
1314
+
1315
+
1316
+ </div>
1317
+
1318
+
1319
+
1320
+ ### DQLContainerNode
1321
+ <div class="padding-left--md">
1322
+
1323
+
1324
+
1325
+ The DQL node that contains other nodes.
1326
+
1327
+ <div class="padding-left--md padding-bottom--md">
1328
+ <strong>children</strong>: Array&lt;<a href="#dqlnode">DQLNode</a>&gt;
1329
+ <div class="padding-left--md">
1330
+
1331
+ The list of children nodes.
1332
+
1333
+ </div>
1334
+
1335
+
1336
+
1337
+ </div>
1338
+
1339
+ <div class="padding-left--md padding-bottom--md">
1340
+ <strong>isOptional</strong>: boolean
1341
+ <div class="padding-left--md">
1342
+
1343
+ True if the node is optional.
1344
+
1345
+ </div>
1346
+
1347
+
1348
+
1349
+ </div>
1350
+
1351
+ <div class="padding-left--md padding-bottom--md">
1352
+ <strong>nodeType</strong>: <a href="#dqlnodenodetype">DQLNodeNodeType</a>
1353
+ <div class="padding-left--md">
1354
+
1355
+
1356
+
1357
+ </div>
1358
+
1359
+
1360
+
1361
+ </div>
1362
+
1363
+ <div class="padding-left--md padding-bottom--md">
1364
+ <strong>tokenPosition</strong>: <a href="#tokenposition">TokenPosition</a>
1365
+ <div class="padding-left--md">
1366
+
1367
+
1368
+
1369
+ </div>
1370
+
1371
+
1372
+
1373
+ </div>
1374
+
1375
+ <div class="padding-left--md padding-bottom--md">
1376
+ <strong>type</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/String">string</a>
1377
+ <div class="padding-left--md">
1378
+
1379
+ The type of the node.
1380
+
1381
+ </div>
1382
+
1383
+
1384
+
1385
+ </div>
1386
+
1387
+
1388
+ </div>
1389
+
1390
+
1391
+
1392
+ ### DQLNode
1393
+ <div class="padding-left--md">
1394
+
1395
+
1396
+
1397
+ General Node in the DQL query.
1398
+
1399
+ <div class="padding-left--md padding-bottom--md">
1400
+ <strong>isOptional</strong>: boolean
1401
+ <div class="padding-left--md">
1402
+
1403
+ True if the node is optional.
1404
+
1405
+ </div>
1406
+
1407
+
1408
+
1409
+ </div>
1410
+
1411
+ <div class="padding-left--md padding-bottom--md">
1412
+ <strong>nodeType</strong>: <a href="#dqlnodenodetype">DQLNodeNodeType</a>
1413
+ <div class="padding-left--md">
1414
+
1415
+
1416
+
1417
+ </div>
1418
+
1419
+
1420
+
1421
+ </div>
1422
+
1423
+ <div class="padding-left--md padding-bottom--md">
1424
+ <strong>tokenPosition</strong>: <a href="#tokenposition">TokenPosition</a>
1425
+ <div class="padding-left--md">
1426
+
1427
+
1428
+
1429
+ </div>
1430
+
1431
+
1432
+
1433
+ </div>
1434
+
1435
+
1436
+ </div>
1437
+
1438
+
1439
+
1440
+ ### DQLTerminalNode
1441
+ <div class="padding-left--md">
1442
+
1443
+
1444
+
1445
+ Node that represents single token.
1446
+
1447
+ <div class="padding-left--md padding-bottom--md">
1448
+ <strong>canonicalString</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/String">string</a>
1449
+ <div class="padding-left--md">
1450
+
1451
+ Canonical form.
1452
+
1453
+ </div>
1454
+
1455
+
1456
+
1457
+ </div>
1458
+
1459
+ <div class="padding-left--md padding-bottom--md">
1460
+ <strong>isMandatoryOnUserOrder</strong>: boolean
1461
+ <div class="padding-left--md">
1462
+
1463
+ For optional items only: whether this node becomes mandatory when user order is used. True only for some optional 'ghost braces'
1464
+
1465
+ </div>
1466
+
1467
+
1468
+
1469
+ </div>
1470
+
1471
+ <div class="padding-left--md padding-bottom--md">
1472
+ <strong>isOptional</strong>: boolean
1473
+ <div class="padding-left--md">
1474
+
1475
+ True if the node is optional.
1476
+
1477
+ </div>
1478
+
1479
+
1480
+
1481
+ </div>
1482
+
1483
+ <div class="padding-left--md padding-bottom--md">
1484
+ <strong>nodeType</strong>: <a href="#dqlnodenodetype">DQLNodeNodeType</a>
1485
+ <div class="padding-left--md">
1486
+
1487
+
1488
+
1489
+ </div>
1490
+
1491
+
1492
+
1493
+ </div>
1494
+
1495
+ <div class="padding-left--md padding-bottom--md">
1496
+ <strong>tokenPosition</strong>: <a href="#tokenposition">TokenPosition</a>
1497
+ <div class="padding-left--md">
1498
+
1499
+
1500
+
1501
+ </div>
1502
+
1503
+
1504
+
1505
+ </div>
1506
+
1507
+ <div class="padding-left--md padding-bottom--md">
1508
+ <strong>type</strong>: <a href="#tokentype">TokenType</a>
1509
+ <div class="padding-left--md">
1510
+
1511
+
1512
+
1513
+ </div>
1514
+
1515
+
1516
+
1517
+ </div>
1518
+
1519
+
1520
+ </div>
1521
+
1522
+
1523
+
1524
+ ### ErrorEnvelope
1525
+ <div class="padding-left--md">
1526
+
1527
+
1528
+
1529
+ An 'envelope' error object that has the mandatory error object.
1530
+
1531
+ <div class="padding-left--md padding-bottom--md">
1532
+ <strong>error</strong>: <a href="#errorresponse">ErrorResponse</a>
1533
+ <div class="padding-left--md">
1534
+
1535
+
1536
+
1537
+ </div>
1538
+
1539
+
1540
+
1541
+ </div>
1542
+
1543
+
1544
+ </div>
1545
+
1546
+
1547
+
1548
+ ### ErrorResponse
1549
+ <div class="padding-left--md">
1550
+
1551
+
1552
+
1553
+ The response for error state
1554
+
1555
+ <div class="padding-left--md padding-bottom--md">
1556
+ <strong>code</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/Number">number</a>
1557
+ <div class="padding-left--md">
1558
+
1559
+ Error code, which normally matches the HTTP error code.
1560
+
1561
+ </div>
1562
+
1563
+
1564
+
1565
+ </div>
1566
+
1567
+ <div class="padding-left--md padding-bottom--md">
1568
+ <strong>details</strong>: <a href="#errorresponsedetails">ErrorResponseDetails</a>
1569
+ <div class="padding-left--md">
1570
+
1571
+
1572
+
1573
+ </div>
1574
+
1575
+
1576
+
1577
+ </div>
1578
+
1579
+ <div class="padding-left--md padding-bottom--md">
1580
+ <strong>message</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/String">string</a>
1581
+ <div class="padding-left--md">
1582
+
1583
+ A short, clear error message without details
1584
+
1585
+ </div>
1586
+
1587
+
1588
+
1589
+ </div>
1590
+
1591
+
1592
+ </div>
1593
+
1594
+
1595
+
1596
+ ### ErrorResponseDetails
1597
+ <div class="padding-left--md">
1598
+
1599
+
1600
+
1601
+ Detailed information about the error.
1602
+
1603
+ <div class="padding-left--md padding-bottom--md">
1604
+ <strong>arguments</strong>: Array&lt;<a href="https://developer.mozilla.org/en-US/docs/Glossary/String">string</a>&gt;
1605
+ <div class="padding-left--md">
1606
+
1607
+ The arguments for the message format.
1608
+
1609
+ </div>
1610
+
1611
+
1612
+
1613
+ </div>
1614
+
1615
+ <div class="padding-left--md padding-bottom--md">
1616
+ <strong>errorMessage</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/String">string</a>
1617
+ <div class="padding-left--md">
1618
+
1619
+ Complete error message.
1620
+
1621
+ </div>
1622
+
1623
+
1624
+
1625
+ </div>
1626
+
1627
+ <div class="padding-left--md padding-bottom--md">
1628
+ <strong>errorMessageFormat</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/String">string</a>
1629
+ <div class="padding-left--md">
1630
+
1631
+ The message format of the error message, string.format based.
1632
+
1633
+ </div>
1634
+
1635
+
1636
+
1637
+ </div>
1638
+
1639
+ <div class="padding-left--md padding-bottom--md">
1640
+ <strong>errorMessageFormatSpecifierTypes</strong>: Array&lt;<a href="https://developer.mozilla.org/en-US/docs/Glossary/String">string</a>&gt;
1641
+ <div class="padding-left--md">
1642
+
1643
+ The corresponding DQL format specifier types for each format specifier used in the error message format.
1644
+
1645
+ </div>
1646
+
1647
+
1648
+
1649
+ </div>
1650
+
1651
+ <div class="padding-left--md padding-bottom--md">
1652
+ <strong>errorType</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/String">string</a>
1653
+ <div class="padding-left--md">
1654
+
1655
+ The error type, e.g. COMMAND_NAME_MISSING
1656
+
1657
+ </div>
1658
+
1659
+
1660
+
1661
+ </div>
1662
+
1663
+ <div class="padding-left--md padding-bottom--md">
1664
+ <strong>exceptionType</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/String">string</a>
1665
+ <div class="padding-left--md">
1666
+
1667
+ The exception type.
1668
+
1669
+ </div>
1670
+
1671
+
1672
+
1673
+ </div>
1674
+
1675
+ <div class="padding-left--md padding-bottom--md">
1676
+ <strong>queryString</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/String">string</a>
1677
+ <div class="padding-left--md">
1678
+
1679
+ Submitted query string.
1680
+
1681
+ </div>
1682
+
1683
+
1684
+
1685
+ </div>
1686
+
1687
+ <div class="padding-left--md padding-bottom--md">
1688
+ <strong>syntaxErrorPosition</strong>: <a href="#tokenposition">TokenPosition</a>
1689
+ <div class="padding-left--md">
1690
+
1691
+
1692
+
1693
+ </div>
1694
+
1695
+
1696
+
1697
+ </div>
1698
+
1699
+
1700
+ </div>
1701
+
1702
+
1703
+
1704
+ ### ExecuteRequest
1705
+ <div class="padding-left--md">
1706
+
1707
+
1708
+
1709
+
1710
+
1711
+ <div class="padding-left--md padding-bottom--md">
1712
+ <strong>defaultSamplingRatio</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/Number">number</a>
1713
+ <div class="padding-left--md">
1714
+
1715
+ In case not specified in the DQL string, the sampling ratio defined here is applied. Note that this is only applicable to log queries.
1716
+
1717
+ </div>
1718
+
1719
+
1720
+
1721
+ </div>
1722
+
1723
+ <div class="padding-left--md padding-bottom--md">
1724
+ <strong>defaultScanLimitGbytes</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/Number">number</a>
1725
+ <div class="padding-left--md">
1726
+
1727
+ Limit in gigabytes for the amount data that will be scanned during read.
1728
+
1729
+ </div>
1730
+
1731
+
1732
+
1733
+ </div>
1734
+
1735
+ <div class="padding-left--md padding-bottom--md">
1736
+ <strong>defaultTimeframeEnd</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/String">string</a>
1737
+ <div class="padding-left--md">
1738
+
1739
+ The query timeframe 'end' timestamp in ISO-8601 or RFC399 format. If the timeframe 'start' parameter is missing, the whole timeframe is ignored. &lt;em&gt;Note that if a timeframe is specified within the query string (query) then it has precedence over this query request parameter.&lt;/em&gt;
1740
+
1741
+ </div>
1742
+
1743
+
1744
+
1745
+ </div>
1746
+
1747
+ <div class="padding-left--md padding-bottom--md">
1748
+ <strong>defaultTimeframeStart</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/String">string</a>
1749
+ <div class="padding-left--md">
1750
+
1751
+ The query timeframe 'start' timestamp in ISO-8601 or RFC399 format. If the timeframe 'end' parameter is missing, the whole timeframe is ignored. &lt;em&gt;Note that if a timeframe is specified within the query string (query) then it has precedence over this query request parameter.&lt;/em&gt;
1752
+
1753
+ </div>
1754
+
1755
+
1756
+
1757
+ </div>
1758
+
1759
+ <div class="padding-left--md padding-bottom--md">
1760
+ <strong>enablePreview</strong>: boolean
1761
+ <div class="padding-left--md">
1762
+
1763
+ Request preview results. If a preview is available within the request-timeout-milliseconds, then it will be returned as part of the response.
1764
+
1765
+ </div>
1766
+
1767
+
1768
+
1769
+ </div>
1770
+
1771
+ <div class="padding-left--md padding-bottom--md">
1772
+ <strong>fetchTimeoutSeconds</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/Number">number</a>
1773
+ <div class="padding-left--md">
1774
+
1775
+ The query will stop after reaching the fetch-timeout.
1776
+
1777
+ </div>
1778
+
1779
+
1780
+
1781
+ </div>
1782
+
1783
+ <div class="padding-left--md padding-bottom--md">
1784
+ <strong>locale</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/String">string</a>
1785
+ <div class="padding-left--md">
1786
+
1787
+ The query locale. If none specified, then a language/country neutral locale is chosen. The input values take the ISO-639 Language code with an optional ISO-3166 country code appended to it with an underscore. For instance, both values are valid 'en' or 'en_US'.
1788
+
1789
+ </div>
1790
+
1791
+
1792
+
1793
+ </div>
1794
+
1795
+ <div class="padding-left--md padding-bottom--md">
1796
+ <strong>maxResultRecords</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/Number">number</a>
1797
+ <div class="padding-left--md">
1798
+
1799
+ The maximum number of result records that this query will return.
1800
+
1801
+ </div>
1802
+
1803
+
1804
+
1805
+ </div>
1806
+
1807
+ <div class="padding-left--md padding-bottom--md">
1808
+ <strong>query</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/String">string</a>
1809
+ <div class="padding-left--md">
1810
+
1811
+ The full query string.
1812
+
1813
+ </div>
1814
+
1815
+
1816
+
1817
+ </div>
1818
+
1819
+ <div class="padding-left--md padding-bottom--md">
1820
+ <strong>requestTimeoutMilliseconds</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/Number">number</a>
1821
+ <div class="padding-left--md">
1822
+
1823
+ The time a client is willing to wait for the query result. In case the query finishes within the specified timeout, the query result is returned. Otherwise, the requestToken is returned, allowing polling for the result.
1824
+
1825
+ </div>
1826
+
1827
+
1828
+
1829
+ </div>
1830
+
1831
+ <div class="padding-left--md padding-bottom--md">
1832
+ <strong>timezone</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/String">string</a>
1833
+ <div class="padding-left--md">
1834
+
1835
+ The query timezone. If none is specified, UTC is used as fallback. The list of valid input values matches that of the IANA Time Zone Database (TZDB). It accepts values in their canonical names like 'Europe/Paris', the abbreviated version like CET or the UTC offset format like '+01:00'
1836
+
1837
+ </div>
1838
+
1839
+
1840
+
1841
+ </div>
1842
+
1843
+
1844
+ </div>
1845
+
1846
+
1847
+
1848
+ ### FieldType
1849
+ <div class="padding-left--md">
1850
+
1851
+
1852
+
1853
+ The possible type of a field in DQL.
1854
+
1855
+ <div class="padding-left--md padding-bottom--md">
1856
+ <strong>type</strong>: <a href="#fieldtypetype">FieldTypeType</a>
1857
+ <div class="padding-left--md">
1858
+
1859
+
1860
+
1861
+ </div>
1862
+
1863
+
1864
+
1865
+ </div>
1866
+
1867
+ <div class="padding-left--md padding-bottom--md">
1868
+ <strong>types</strong>: Array&lt;<a href="#rangedfieldtypes">RangedFieldTypes</a>&gt;
1869
+ <div class="padding-left--md">
1870
+
1871
+
1872
+
1873
+ </div>
1874
+
1875
+
1876
+
1877
+ </div>
1878
+
1879
+
1880
+ </div>
1881
+
1882
+
1883
+
1884
+ ### GeoPoint
1885
+ <div class="padding-left--md">
1886
+
1887
+
1888
+
1889
+ DQL data type representing a geolocation point.
1890
+
1891
+ <div class="padding-left--md padding-bottom--md">
1892
+ <strong>latitude</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/Number">number</a>
1893
+ <div class="padding-left--md">
1894
+
1895
+ The coordinate that specifies the north–south position of a point on the surface of the earth.
1896
+
1897
+ </div>
1898
+
1899
+
1900
+
1901
+ </div>
1902
+
1903
+ <div class="padding-left--md padding-bottom--md">
1904
+ <strong>longitude</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/Number">number</a>
1905
+ <div class="padding-left--md">
1906
+
1907
+ The coordinate that specifies the east–west position of a point on the surface of the earth.
1908
+
1909
+ </div>
1910
+
1911
+
1912
+
1913
+ </div>
1914
+
1915
+
1916
+ </div>
1917
+
1918
+
1919
+
1920
+ ### GrailMetadata
1921
+ <div class="padding-left--md">
1922
+
1923
+
1924
+
1925
+ Collects various bits of metadata information.
1926
+
1927
+ <div class="padding-left--md padding-bottom--md">
1928
+ <strong>analysisTimeframe</strong>: <a href="#timeframe">Timeframe</a>
1929
+ <div class="padding-left--md">
1930
+
1931
+
1932
+
1933
+ </div>
1934
+
1935
+
1936
+
1937
+ </div>
1938
+
1939
+ <div class="padding-left--md padding-bottom--md">
1940
+ <strong>canonicalQuery</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/String">string</a>
1941
+ <div class="padding-left--md">
1942
+
1943
+ The canonical form of the query. It has normalized spaces and canonical constructs.
1944
+
1945
+ </div>
1946
+
1947
+
1948
+
1949
+ </div>
1950
+
1951
+ <div class="padding-left--md padding-bottom--md">
1952
+ <strong>dqlVersion</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/String">string</a>
1953
+ <div class="padding-left--md">
1954
+
1955
+ The version of DQL that was used to process the query request.
1956
+
1957
+ </div>
1958
+
1959
+
1960
+
1961
+ </div>
1962
+
1963
+ <div class="padding-left--md padding-bottom--md">
1964
+ <strong>executionTimeMilliseconds</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/Number">number</a>
1965
+ <div class="padding-left--md">
1966
+
1967
+ The time it took to execute the query.
1968
+
1969
+ </div>
1970
+
1971
+
1972
+
1973
+ </div>
1974
+
1975
+ <div class="padding-left--md padding-bottom--md">
1976
+ <strong>locale</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/String">string</a>
1977
+ <div class="padding-left--md">
1978
+
1979
+ Effective locale for the query.
1980
+
1981
+ </div>
1982
+
1983
+
1984
+
1985
+ </div>
1986
+
1987
+ <div class="padding-left--md padding-bottom--md">
1988
+ <strong>notifications</strong>: Array&lt;<a href="#metadatanotification">MetadataNotification</a>&gt;
1989
+ <div class="padding-left--md">
1990
+
1991
+ Collected messages during the execution of the query.
1992
+
1993
+ </div>
1994
+
1995
+
1996
+
1997
+ </div>
1998
+
1999
+ <div class="padding-left--md padding-bottom--md">
2000
+ <strong>query</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/String">string</a>
2001
+ <div class="padding-left--md">
2002
+
2003
+ The submitted query.
2004
+
2005
+ </div>
2006
+
2007
+
2008
+
2009
+ </div>
2010
+
2011
+ <div class="padding-left--md padding-bottom--md">
2012
+ <strong>queryId</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/String">string</a>
2013
+ <div class="padding-left--md">
2014
+
2015
+ The id of the query
2016
+
2017
+ </div>
2018
+
2019
+
2020
+
2021
+ </div>
2022
+
2023
+ <div class="padding-left--md padding-bottom--md">
2024
+ <strong>scannedBytes</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/Number">number</a>
2025
+ <div class="padding-left--md">
2026
+
2027
+ Number of scanned bytes during the query execution.
2028
+
2029
+ </div>
2030
+
2031
+
2032
+
2033
+ </div>
2034
+
2035
+ <div class="padding-left--md padding-bottom--md">
2036
+ <strong>scannedRecords</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/Number">number</a>
2037
+ <div class="padding-left--md">
2038
+
2039
+ Number of scanned records during the query execution.
2040
+
2041
+ </div>
2042
+
2043
+
2044
+
2045
+ </div>
2046
+
2047
+ <div class="padding-left--md padding-bottom--md">
2048
+ <strong>timezone</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/String">string</a>
2049
+ <div class="padding-left--md">
2050
+
2051
+ Effective timezone for the query.
2052
+
2053
+ </div>
2054
+
2055
+
2056
+
2057
+ </div>
2058
+
2059
+
2060
+ </div>
2061
+
2062
+
2063
+
2064
+ ### Metadata
2065
+ <div class="padding-left--md">
2066
+
2067
+
2068
+
2069
+ Collects various bits of metadata information.
2070
+
2071
+ <div class="padding-left--md padding-bottom--md">
2072
+ <strong>grail</strong>: <a href="#grailmetadata">GrailMetadata</a>
2073
+ <div class="padding-left--md">
2074
+
2075
+
2076
+
2077
+ </div>
2078
+
2079
+
2080
+
2081
+ </div>
2082
+
2083
+ <div class="padding-left--md padding-bottom--md">
2084
+ <strong>metrics</strong>: Array&lt;<a href="#metricmetadata">MetricMetadata</a>&gt;
2085
+ <div class="padding-left--md">
2086
+
2087
+
2088
+
2089
+ </div>
2090
+
2091
+
2092
+
2093
+ </div>
2094
+
2095
+
2096
+ </div>
2097
+
2098
+
2099
+
2100
+ ### MetadataNotification
2101
+ <div class="padding-left--md">
2102
+
2103
+
2104
+
2105
+ The message that provides additional information about the execution of the query.
2106
+
2107
+ <div class="padding-left--md padding-bottom--md">
2108
+ <strong>arguments</strong>: Array&lt;<a href="https://developer.mozilla.org/en-US/docs/Glossary/String">string</a>&gt;
2109
+ <div class="padding-left--md">
2110
+
2111
+ The arguments for the message format.
2112
+
2113
+ </div>
2114
+
2115
+
2116
+
2117
+ </div>
2118
+
2119
+ <div class="padding-left--md padding-bottom--md">
2120
+ <strong>message</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/String">string</a>
2121
+ <div class="padding-left--md">
2122
+
2123
+ The complete message of the notification.
2124
+
2125
+ </div>
2126
+
2127
+
2128
+
2129
+ </div>
2130
+
2131
+ <div class="padding-left--md padding-bottom--md">
2132
+ <strong>messageFormat</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/String">string</a>
2133
+ <div class="padding-left--md">
2134
+
2135
+ The message format of the notification, string.format based
2136
+
2137
+ </div>
2138
+
2139
+
2140
+
2141
+ </div>
2142
+
2143
+ <div class="padding-left--md padding-bottom--md">
2144
+ <strong>messageFormatSpecifierTypes</strong>: Array&lt;<a href="https://developer.mozilla.org/en-US/docs/Glossary/String">string</a>&gt;
2145
+ <div class="padding-left--md">
2146
+
2147
+ The corresponding DQL format specifier types for each format specifier used in the error message format.
2148
+
2149
+ </div>
2150
+
2151
+
2152
+
2153
+ </div>
2154
+
2155
+ <div class="padding-left--md padding-bottom--md">
2156
+ <strong>notificationType</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/String">string</a>
2157
+ <div class="padding-left--md">
2158
+
2159
+ The notification type, e.g. LIMIT_ADDED.
2160
+
2161
+ </div>
2162
+
2163
+
2164
+
2165
+ </div>
2166
+
2167
+ <div class="padding-left--md padding-bottom--md">
2168
+ <strong>severity</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/String">string</a>
2169
+ <div class="padding-left--md">
2170
+
2171
+ The severity of the notification, currently: INFO, WARN, ERROR.
2172
+
2173
+ </div>
2174
+
2175
+
2176
+
2177
+ </div>
2178
+
2179
+ <div class="padding-left--md padding-bottom--md">
2180
+ <strong>syntaxPosition</strong>: <a href="#tokenposition">TokenPosition</a>
2181
+ <div class="padding-left--md">
2182
+
2183
+
2184
+
2185
+ </div>
2186
+
2187
+
2188
+
2189
+ </div>
2190
+
2191
+
2192
+ </div>
2193
+
2194
+
2195
+
2196
+ ### MetricMetadata
2197
+ <div class="padding-left--md">
2198
+
2199
+
2200
+
2201
+ An object that defines additional metric metadata.
2202
+
2203
+ <div class="padding-left--md padding-bottom--md">
2204
+ <strong>description</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/String">string</a>
2205
+ <div class="padding-left--md">
2206
+
2207
+ The description of the metadata.
2208
+
2209
+ </div>
2210
+
2211
+
2212
+
2213
+ </div>
2214
+
2215
+ <div class="padding-left--md padding-bottom--md">
2216
+ <strong>displayName</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/String">string</a>
2217
+ <div class="padding-left--md">
2218
+
2219
+ The display name of the metadata.
2220
+
2221
+ </div>
2222
+
2223
+
2224
+
2225
+ </div>
2226
+
2227
+ <div class="padding-left--md padding-bottom--md">
2228
+ <strong>metric.key</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/String">string</a>
2229
+ <div class="padding-left--md">
2230
+
2231
+ The metric key.
2232
+
2233
+ </div>
2234
+
2235
+
2236
+
2237
+ </div>
2238
+
2239
+ <div class="padding-left--md padding-bottom--md">
2240
+ <strong>unit</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/String">string</a>
2241
+ <div class="padding-left--md">
2242
+
2243
+ The unit used.
2244
+
2245
+ </div>
2246
+
2247
+
2248
+
2249
+ </div>
2250
+
2251
+
2252
+ </div>
2253
+
2254
+
2255
+
2256
+ ### ParseRequest
2257
+ <div class="padding-left--md">
2258
+
2259
+
2260
+
2261
+
2262
+
2263
+ <div class="padding-left--md padding-bottom--md">
2264
+ <strong>locale</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/String">string</a>
2265
+ <div class="padding-left--md">
2266
+
2267
+ The query locale. If none specified, then a language/country neutral locale is chosen. The input values take the ISO-639 Language code with an optional ISO-3166 country code appended to it with an underscore. For instance, both values are valid 'en' or 'en_US'.
2268
+
2269
+ </div>
2270
+
2271
+
2272
+
2273
+ </div>
2274
+
2275
+ <div class="padding-left--md padding-bottom--md">
2276
+ <strong>query</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/String">string</a>
2277
+ <div class="padding-left--md">
2278
+
2279
+ The full query string.
2280
+
2281
+ </div>
2282
+
2283
+
2284
+
2285
+ </div>
2286
+
2287
+ <div class="padding-left--md padding-bottom--md">
2288
+ <strong>timezone</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/String">string</a>
2289
+ <div class="padding-left--md">
2290
+
2291
+ The query timezone. If none is specified, UTC is used as fallback. The list of valid input values matches that of the IANA Time Zone Database (TZDB). It accepts values in their canonical names like 'Europe/Paris', the abbreviated version like CET or the UTC offset format like '+01:00'
2292
+
2293
+ </div>
2294
+
2295
+
2296
+
2297
+ </div>
2298
+
2299
+
2300
+ </div>
2301
+
2302
+
2303
+
2304
+ ### PositionInfo
2305
+ <div class="padding-left--md">
2306
+
2307
+
2308
+
2309
+ The exact position in the query string.
2310
+
2311
+ <div class="padding-left--md padding-bottom--md">
2312
+ <strong>column</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/Number">number</a>
2313
+ <div class="padding-left--md">
2314
+
2315
+ Query position column zero based index.
2316
+
2317
+ </div>
2318
+
2319
+
2320
+
2321
+ </div>
2322
+
2323
+ <div class="padding-left--md padding-bottom--md">
2324
+ <strong>index</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/Number">number</a>
2325
+ <div class="padding-left--md">
2326
+
2327
+ Query position index.
2328
+
2329
+ </div>
2330
+
2331
+
2332
+
2333
+ </div>
2334
+
2335
+ <div class="padding-left--md padding-bottom--md">
2336
+ <strong>line</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/Number">number</a>
2337
+ <div class="padding-left--md">
2338
+
2339
+ Query position line zero based index.
2340
+
2341
+ </div>
2342
+
2343
+
2344
+
2345
+ </div>
2346
+
2347
+
2348
+ </div>
2349
+
2350
+
2351
+
2352
+ ### QueryPollResponse
2353
+ <div class="padding-left--md">
2354
+
2355
+
2356
+
2357
+ The response of GET query:execute call.
2358
+
2359
+ <div class="padding-left--md padding-bottom--md">
2360
+ <strong>progress</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/Number">number</a>
2361
+ <div class="padding-left--md">
2362
+
2363
+ The progress of the query from 0 to 100.
2364
+
2365
+ </div>
2366
+
2367
+
2368
+
2369
+ </div>
2370
+
2371
+ <div class="padding-left--md padding-bottom--md">
2372
+ <strong>result</strong>: <a href="#queryresult">QueryResult</a>
2373
+ <div class="padding-left--md">
2374
+
2375
+
2376
+
2377
+ </div>
2378
+
2379
+
2380
+
2381
+ </div>
2382
+
2383
+ <div class="padding-left--md padding-bottom--md">
2384
+ <strong>state</strong>: <a href="#querystate">QueryState</a>
2385
+ <div class="padding-left--md">
2386
+
2387
+
2388
+
2389
+ </div>
2390
+
2391
+
2392
+
2393
+ </div>
2394
+
2395
+ <div class="padding-left--md padding-bottom--md">
2396
+ <strong>ttlSeconds</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/Number">number</a>
2397
+ <div class="padding-left--md">
2398
+
2399
+ Time to live in seconds.
2400
+
2401
+ </div>
2402
+
2403
+
2404
+
2405
+ </div>
2406
+
2407
+
2408
+ </div>
2409
+
2410
+
2411
+
2412
+ ### QueryResult
2413
+ <div class="padding-left--md">
2414
+
2415
+
2416
+
2417
+ The result of the DQL query.
2418
+
2419
+ <div class="padding-left--md padding-bottom--md">
2420
+ <strong>metadata</strong>: <a href="#metadata">Metadata</a>
2421
+ <div class="padding-left--md">
2422
+
2423
+
2424
+
2425
+ </div>
2426
+
2427
+
2428
+
2429
+ </div>
2430
+
2431
+ <div class="padding-left--md padding-bottom--md">
2432
+ <strong>records</strong>: Array&lt;null | <a href="#resultrecord">ResultRecord</a>&gt;
2433
+ <div class="padding-left--md">
2434
+
2435
+ List of records containing the result fields data.
2436
+
2437
+ </div>
2438
+
2439
+
2440
+
2441
+ </div>
2442
+
2443
+ <div class="padding-left--md padding-bottom--md">
2444
+ <strong>types</strong>: Array&lt;<a href="#rangedfieldtypes">RangedFieldTypes</a>&gt;
2445
+ <div class="padding-left--md">
2446
+
2447
+ The data types for the result records.
2448
+
2449
+ </div>
2450
+
2451
+
2452
+
2453
+ </div>
2454
+
2455
+
2456
+ </div>
2457
+
2458
+
2459
+
2460
+ ### QueryStartResponse
2461
+ <div class="padding-left--md">
2462
+
2463
+
2464
+
2465
+ The response when starting a query.
2466
+
2467
+ <div class="padding-left--md padding-bottom--md">
2468
+ <strong>progress</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/Number">number</a>
2469
+ <div class="padding-left--md">
2470
+
2471
+ The progress of the query from 0 to 100.
2472
+
2473
+ </div>
2474
+
2475
+
2476
+
2477
+ </div>
2478
+
2479
+ <div class="padding-left--md padding-bottom--md">
2480
+ <strong>requestToken</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/String">string</a>
2481
+ <div class="padding-left--md">
2482
+
2483
+ The token returned by the POST query:execute call.
2484
+
2485
+ </div>
2486
+
2487
+
2488
+
2489
+ </div>
2490
+
2491
+ <div class="padding-left--md padding-bottom--md">
2492
+ <strong>result</strong>: <a href="#queryresult">QueryResult</a>
2493
+ <div class="padding-left--md">
2494
+
2495
+
2496
+
2497
+ </div>
2498
+
2499
+
2500
+
2501
+ </div>
2502
+
2503
+ <div class="padding-left--md padding-bottom--md">
2504
+ <strong>state</strong>: <a href="#querystate">QueryState</a>
2505
+ <div class="padding-left--md">
2506
+
2507
+
2508
+
2509
+ </div>
2510
+
2511
+
2512
+
2513
+ </div>
2514
+
2515
+ <div class="padding-left--md padding-bottom--md">
2516
+ <strong>ttlSeconds</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/Number">number</a>
2517
+ <div class="padding-left--md">
2518
+
2519
+ Time to live in seconds.
2520
+
2521
+ </div>
2522
+
2523
+
2524
+
2525
+ </div>
2526
+
2527
+
2528
+ </div>
2529
+
2530
+
2531
+
2532
+ ### RangedFieldTypes
2533
+ <div class="padding-left--md">
2534
+
2535
+
2536
+
2537
+ The field type in range.
2538
+
2539
+ <div class="padding-left--md padding-bottom--md">
2540
+ <strong>indexRange</strong>: Array&lt;<a href="https://developer.mozilla.org/en-US/docs/Glossary/Number">number</a>&gt;
2541
+ <div class="padding-left--md">
2542
+
2543
+ The range of elements at use this type in arrays (null for records).
2544
+
2545
+ </div>
2546
+
2547
+
2548
+
2549
+ </div>
2550
+
2551
+ <div class="padding-left--md padding-bottom--md">
2552
+ <strong>mappings</strong>: <a href="#rangedfieldtypesmappings">RangedFieldTypesMappings</a>
2553
+ <div class="padding-left--md">
2554
+
2555
+
2556
+
2557
+ </div>
2558
+
2559
+
2560
+
2561
+ </div>
2562
+
2563
+
2564
+ </div>
2565
+
2566
+
2567
+
2568
+ ### RangedFieldTypesMappings
2569
+ <div class="padding-left--md">
2570
+
2571
+
2572
+
2573
+ The mapping between the field name and data type.
2574
+
2575
+
2576
+
2577
+ </div>
2578
+
2579
+
2580
+
2581
+ ### ResultRecord
2582
+ <div class="padding-left--md">
2583
+
2584
+
2585
+
2586
+ Single record that contains the result fields.
2587
+
2588
+
2589
+
2590
+ </div>
2591
+
2592
+
2593
+
2594
+ ### Timeframe
2595
+ <div class="padding-left--md">
2596
+
2597
+
2598
+
2599
+ DQL data type timeframe.
2600
+
2601
+ <div class="padding-left--md padding-bottom--md">
2602
+ <strong>end</strong>: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date">Date</a>
2603
+ <div class="padding-left--md">
2604
+
2605
+ The end time of the timeframe.
2606
+
2607
+ </div>
2608
+
2609
+
2610
+
2611
+ </div>
2612
+
2613
+ <div class="padding-left--md padding-bottom--md">
2614
+ <strong>start</strong>: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date">Date</a>
2615
+ <div class="padding-left--md">
2616
+
2617
+ The start time of the timeframe.
2618
+
2619
+ </div>
2620
+
2621
+
2622
+
2623
+ </div>
2624
+
2625
+
2626
+ </div>
2627
+
2628
+
2629
+
2630
+ ### TokenPosition
2631
+ <div class="padding-left--md">
2632
+
2633
+
2634
+
2635
+ The position of a token in a query string used for errors and notification to map the message to a specific part of the query.
2636
+
2637
+ <div class="padding-left--md padding-bottom--md">
2638
+ <strong>end</strong>: <a href="#positioninfo">PositionInfo</a>
2639
+ <div class="padding-left--md">
2640
+
2641
+
2642
+
2643
+ </div>
2644
+
2645
+
2646
+
2647
+ </div>
2648
+
2649
+ <div class="padding-left--md padding-bottom--md">
2650
+ <strong>start</strong>: <a href="#positioninfo">PositionInfo</a>
2651
+ <div class="padding-left--md">
2652
+
2653
+
2654
+
2655
+ </div>
2656
+
2657
+
2658
+
2659
+ </div>
2660
+
2661
+
2662
+ </div>
2663
+
2664
+
2665
+
2666
+ ### VerifyRequest
2667
+ <div class="padding-left--md">
2668
+
2669
+
2670
+
2671
+
2672
+
2673
+ <div class="padding-left--md padding-bottom--md">
2674
+ <strong>locale</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/String">string</a>
2675
+ <div class="padding-left--md">
2676
+
2677
+ The query locale. If none specified, then a language/country neutral locale is chosen. The input values take the ISO-639 Language code with an optional ISO-3166 country code appended to it with an underscore. For instance, both values are valid 'en' or 'en_US'.
2678
+
2679
+ </div>
2680
+
2681
+
2682
+
2683
+ </div>
2684
+
2685
+ <div class="padding-left--md padding-bottom--md">
2686
+ <strong>query</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/String">string</a>
2687
+ <div class="padding-left--md">
2688
+
2689
+ The full query string.
2690
+
2691
+ </div>
2692
+
2693
+
2694
+
2695
+ </div>
2696
+
2697
+ <div class="padding-left--md padding-bottom--md">
2698
+ <strong>timezone</strong>: <a href="https://developer.mozilla.org/en-US/docs/Glossary/String">string</a>
2699
+ <div class="padding-left--md">
2700
+
2701
+ The query timezone. If none is specified, UTC is used as fallback. The list of valid input values matches that of the IANA Time Zone Database (TZDB). It accepts values in their canonical names like 'Europe/Paris', the abbreviated version like CET or the UTC offset format like '+01:00'
2702
+
2703
+ </div>
2704
+
2705
+
2706
+
2707
+ </div>
2708
+
2709
+
2710
+ </div>
2711
+
2712
+
2713
+
2714
+ ### VerifyResponse
2715
+ <div class="padding-left--md">
2716
+
2717
+
2718
+
2719
+ Verify response.
2720
+
2721
+ <div class="padding-left--md padding-bottom--md">
2722
+ <strong>notifications</strong>: Array&lt;<a href="#metadatanotification">MetadataNotification</a>&gt;
2723
+ <div class="padding-left--md">
2724
+
2725
+ The notifications related to the supplied DQL query string.
2726
+
2727
+ </div>
2728
+
2729
+
2730
+
2731
+ </div>
2732
+
2733
+ <div class="padding-left--md padding-bottom--md">
2734
+ <strong>valid</strong>: boolean
2735
+ <div class="padding-left--md">
2736
+
2737
+ True if the supplied DQL query string is valid.
2738
+
2739
+ </div>
2740
+
2741
+
2742
+
2743
+ </div>
2744
+
2745
+
2746
+ </div>
2747
+
2748
+
2749
+
2750
+
2751
+ ## Enums
2752
+
2753
+
2754
+ ### DQLNodeNodeType
2755
+
2756
+ <div class="padding-left--md">
2757
+
2758
+ The type of the node.
2759
+
2760
+ #### Enum keys
2761
+
2762
+ <div class="padding-left--md">
2763
+
2764
+ `Alternative` | `Container` | `Terminal`
2765
+
2766
+ </div>
2767
+
2768
+
2769
+ </div>
2770
+
2771
+
2772
+
2773
+
2774
+ ### FieldTypeType
2775
+
2776
+ <div class="padding-left--md">
2777
+
2778
+
2779
+
2780
+ #### Enum keys
2781
+
2782
+ <div class="padding-left--md">
2783
+
2784
+ `Array` | `Binary` | `Boolean` | `Double` | `Duration` | `GeoPoint` | `IpAddress` | `Long` | `Record` | `String` | `Timeframe` | `Timestamp` | `Undefined`
2785
+
2786
+ </div>
2787
+
2788
+
2789
+ </div>
2790
+
2791
+
2792
+
2793
+
2794
+ ### QueryState
2795
+
2796
+ <div class="padding-left--md">
2797
+
2798
+ Possible state of the query.
2799
+
2800
+ #### Enum keys
2801
+
2802
+ <div class="padding-left--md">
2803
+
2804
+ `Cancelled` | `Failed` | `NotStarted` | `ResultGone` | `Running` | `Succeeded`
2805
+
2806
+ </div>
2807
+
2808
+
2809
+ </div>
2810
+
2811
+
2812
+
2813
+
2814
+ ### TokenType
2815
+
2816
+ <div class="padding-left--md">
2817
+
2818
+ The type of the autocomplete token.
2819
+
2820
+ #### Enum keys
2821
+
2822
+ <div class="padding-left--md">
2823
+
2824
+ `Assignment` | `BooleanFalse` | `BooleanTrue` | `BraceClose` | `BraceOpen` | `BracketClose` | `BracketOpen` | `Colon` | `Comma` | `CommandName` | `Dot` | `EndComment` | `FunctionName` | `Indent` | `Linebreak` | `MetricKey` | `Null` | `Number` | `Operator` | `ParameterKey` | `ParameterValueScope` | `ParenthesisClose` | `ParenthesisOpen` | `Pipe` | `Quote` | `SimpleIdentifier` | `SingleQuote` | `Slash` | `Space` | `String` | `TimeUnit` | `TimeseriesAggregation` | `TimestampValue` | `TraversalHopCount` | `TraversalOperator` | `TraversalRelationName` | `Variable`
2825
+
2826
+ </div>
2827
+
2828
+
2829
+ </div>
2830
+
2831
+
2832
+
2833
+