Skip to content

Commit bdbf779

Browse files
[DOCS] Descriptions for SQL APIs (#2264)
* [DOCS] Descriptions for SQL APIs * Update specification/sql/translate/TranslateSqlRequest.ts Co-authored-by: István Zoltán Szabó <[email protected]> * Regenerate output --------- Co-authored-by: István Zoltán Szabó <[email protected]>
1 parent 1ef8d1d commit bdbf779

File tree

7 files changed

+65
-16
lines changed

7 files changed

+65
-16
lines changed

output/schema/schema.json

Lines changed: 26 additions & 13 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

specification/sql/clear_cursor/ClearSqlCursorRequest.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,9 @@ import { RequestBase } from '@_types/Base'
2525
*/
2626
export interface Request extends RequestBase {
2727
body: {
28+
/**
29+
* Cursor to clear.
30+
*/
2831
cursor: string
2932
}
3033
}

specification/sql/delete_async/SqlDeleteAsyncRequest.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,9 @@ import { Id } from '@_types/common'
2626
*/
2727
export interface Request extends RequestBase {
2828
path_parts: {
29+
/**
30+
* Identifier for the search.
31+
*/
2932
id: Id
3033
}
3134
}

specification/sql/get_async/SqlGetAsyncRequest.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,9 @@ import { Id } from '@_types/common'
2727
*/
2828
export interface Request extends RequestBase {
2929
path_parts: {
30+
/**
31+
* Identifier for the search.
32+
*/
3033
id: Id
3134
}
3235
query_parameters: {

specification/sql/get_async_status/SqlGetAsyncStatusRequest.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,9 @@ import { Id } from '@_types/common'
2727
*/
2828
export interface Request extends RequestBase {
2929
path_parts: {
30+
/**
31+
* Identifier for the search.
32+
*/
3033
id: Id
3134
}
3235
}

specification/sql/query/QuerySqlRequest.ts

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,7 @@ import { Duration, TimeZone } from '@_types/Time'
3232
export interface Request extends RequestBase {
3333
query_parameters: {
3434
/**
35+
* Format for the response.
3536
* @doc_id sql-rest-format
3637
*/
3738
format?: string
@@ -46,20 +47,25 @@ export interface Request extends RequestBase {
4647
* @server_default false
4748
*/
4849
columnar?: boolean
50+
/**
51+
* Cursor used to retrieve a set of paginated results.
52+
* If you specify a cursor, the API only uses the `columnar` and `time_zone` request body parameters.
53+
* It ignores other request body parameters.
54+
*/
4955
cursor?: string
5056
/**
5157
* The maximum number of rows (or entries) to return in one response
5258
* @server_default 1000
5359
*/
5460
fetch_size?: integer
5561
/**
56-
* Optional Elasticsearch query DSL for additional filtering.
62+
* Elasticsearch query DSL for additional filtering.
5763
* @doc_id sql-rest-filtering
5864
* @server_default none
5965
*/
6066
filter?: QueryContainer
6167
/**
62-
* SQL query to execute
68+
* SQL query to run.
6369
*/
6470
query?: string
6571
/**
@@ -73,8 +79,9 @@ export interface Request extends RequestBase {
7379
*/
7480
page_timeout?: Duration
7581
/**
76-
* Time-zone in ISO 8601 used for executing the query on the server. More information available here.
82+
* ISO-8601 time zone ID for the search.
7783
* @doc_url https://docs.oracle.com/javase/8/docs/api/java/time/ZoneId.html
84+
* @server_default Z
7885
*/
7986
time_zone?: TimeZone
8087
/**

specification/sql/translate/TranslateSqlRequest.ts

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,9 +28,26 @@ import { TimeZone } from '@_types/Time'
2828
*/
2929
export interface Request extends RequestBase {
3030
body: {
31+
/**
32+
* The maximum number of rows (or entries) to return in one response.
33+
* @server_default 1000
34+
*/
3135
fetch_size?: integer
36+
/**
37+
* Elasticsearch query DSL for additional filtering.
38+
* @doc_id sql-rest-filtering
39+
* @server_default none
40+
*/
3241
filter?: QueryContainer
42+
/**
43+
* SQL query to run.
44+
*/
3345
query: string
46+
/**
47+
* ISO-8601 time zone ID for the search.
48+
* @doc_url https://docs.oracle.com/javase/8/docs/api/java/time/ZoneId.html
49+
* @server_default Z
50+
*/
3451
time_zone?: TimeZone
3552
}
3653
}

0 commit comments

Comments
 (0)