Skip to content

Commit 9f8abf3

Browse files
committed
Add more examples
1 parent 3aca1d5 commit 9f8abf3

File tree

15 files changed

+528
-406
lines changed

15 files changed

+528
-406
lines changed

output/openapi/elasticsearch-openapi.json

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

output/openapi/elasticsearch-serverless-openapi.json

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

output/schema/schema.json

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

output/typescript/types.ts

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

specification/_doc_ids/table.csv

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -185,8 +185,6 @@ geo-shape,https://www.elastic.co/guide/en/elasticsearch/reference/{branch}/geo-s
185185
geo-grid-processor,https://www.elastic.co/guide/en/elasticsearch/reference/{branch}/ingest-geo-grid-processor.html
186186
geoip-processor,https://www.elastic.co/guide/en/elasticsearch/reference/{branch}/geoip-processor.html
187187
geoip-stats-api,https://www.elastic.co/guide/en/elasticsearch/reference/{branch}/geoip-stats-api.html
188-
get-async-sql-search-api,https://www.elastic.co/guide/en/elasticsearch/reference/{branch}/get-async-sql-search-api.html
189-
get-async-sql-search-status-api,https://www.elastic.co/guide/en/elasticsearch/reference/{branch}/get-async-sql-search-status-api.html
190188
get-basic-status,https://www.elastic.co/guide/en/elasticsearch/reference/{branch}/get-basic-status.html
191189
get-dfanalytics-stats,https://www.elastic.co/guide/en/elasticsearch/reference/{branch}/get-dfanalytics-stats.html
192190
get-dfanalytics,https://www.elastic.co/guide/en/elasticsearch/reference/{branch}/get-dfanalytics.html
@@ -673,9 +671,13 @@ sort-search-results,https://www.elastic.co/guide/en/elasticsearch/reference/{bra
673671
sort-tiebreaker,https://www.elastic.co/guide/en/elasticsearch/reference/{branch}/eql.html#eql-search-specify-a-sort-tiebreaker
674672
query-dsl-sparse-vector-query,https://www.elastic.co/guide/en/elasticsearch/reference/{branch}/query-dsl-sparse-vector-query.html
675673
split-processor,https://www.elastic.co/guide/en/elasticsearch/reference/{branch}/split-processor.html
674+
sql-async-search-api,https://www.elastic.co/guide/en/elasticsearch/reference/{branch}/get-async-sql-search-api.html
675+
sql-async-status-api,https://www.elastic.co/guide/en/elasticsearch/reference/{branch}/get-async-sql-search-status-api.html
676+
sql-rest-columnar,https://www.elastic.co/guide/en/elasticsearch/reference/{branch}/sql-rest-columnar.html
676677
sql-rest-filtering,https://www.elastic.co/guide/en/elasticsearch/reference/{branch}/sql-rest-filtering.html
677678
sql-rest-format,https://www.elastic.co/guide/en/elasticsearch/reference/{branch}/sql-rest-format.html
678679
sql-search-api,https://www.elastic.co/guide/en/elasticsearch/reference/{branch}/sql-search-api.html
680+
sql-spec,https://www.elastic.co/guide/en/elasticsearch/reference/{branch}/sql-spec.html
679681
sql-translate-api,https://www.elastic.co/guide/en/elasticsearch/reference/{branch}/sql-translate-api.html
680682
start-basic,https://www.elastic.co/guide/en/elasticsearch/reference/{branch}/start-basic.html
681683
start-dfanalytics,https://www.elastic.co/guide/en/elasticsearch/reference/{branch}/start-dfanalytics.html
@@ -690,6 +692,7 @@ tasks,https://www.elastic.co/guide/en/elasticsearch/reference/{branch}/tasks.htm
690692
templating-role-query,https://www.elastic.co/guide/en/elasticsearch/reference/{branch}/field-and-document-access-control.html#templating-role-query
691693
terminate-processor,https://www.elastic.co/guide/en/elasticsearch/reference/{branch}/terminate-processor.html
692694
time-value,https://github.com/elastic/elasticsearch/blob/{branch}/libs/core/src/main/java/org/elasticsearch/core/TimeValue.java
695+
time-zone-id,https://docs.oracle.com/javase/8/docs/api/java/time/ZoneId.html
693696
trim-processor,https://www.elastic.co/guide/en/elasticsearch/reference/{branch}/trim-processor.html
694697
unfreeze-index-api,https://www.elastic.co/guide/en/elasticsearch/reference/{branch}/unfreeze-index-api.html
695698
update-dfanalytics,https://www.elastic.co/guide/en/elasticsearch/reference/{branch}/update-dfanalytics.html
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
# summary:
2+
# method_request: POST _sql/close
3+
description: Run `POST _sql/close` to clear an SQL search cursor.
4+
# type: request
5+
value:
6+
"{\n \"cursor\": \"sDXF1ZXJ5QW5kRmV0Y2gBAAAAAAAAAAEWYUpOYklQMHhRUEtld3RsNnFtYU1hQQ==:BAFmBGRhdGUBZgVsaWtlcwFzB21lc3NhZ2UBZgR1c2Vy9f///w8=\"\
7+
\n}"

specification/sql/get_async/SqlGetAsyncRequest.ts

Lines changed: 13 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -24,36 +24,41 @@ import { Duration } from '@_types/Time'
2424
/**
2525
* Get async SQL search results.
2626
* Get the current status and available results for an async SQL search or stored synchronous SQL search.
27+
*
28+
* If the Elasticsearch security features are enabled, only the user who first submitted the SQL search can retrieve the search using this API.
2729
* @rest_spec_name sql.get_async
2830
* @availability stack since=7.15.0 stability=stable
2931
* @availability serverless stability=stable visibility=public
32+
* @doc_id sql-async-search-api
3033
*/
3134
export interface Request extends RequestBase {
3235
path_parts: {
3336
/**
34-
* Identifier for the search.
37+
* The identifier for the search.
3538
*/
3639
id: Id
3740
}
3841
query_parameters: {
3942
/**
40-
* Separator for CSV results. The API only supports this parameter for CSV responses.
43+
* The separator for CSV results.
44+
* The API supports this parameter only for CSV responses.
4145
* @server_default ,
4246
*/
4347
delimiter?: string
4448
/**
45-
* Format for the response. You must specify a format using this parameter or the
46-
* Accept HTTP header. If you specify both, the API uses this parameter.
49+
* The format for the response.
50+
* You must specify a format using this parameter or the `Accept` HTTP header.
51+
* If you specify both, the API uses this parameter.
4752
*/
4853
format?: string
4954
/**
50-
* Retention period for the search and its results. Defaults
51-
* to the `keep_alive` period for the original SQL search.
55+
* The retention period for the search and its results.
56+
* It defaults to the `keep_alive` period for the original SQL search.
5257
*/
5358
keep_alive?: Duration
5459
/**
55-
* Period to wait for complete results. Defaults to no timeout,
56-
* meaning the request waits for complete search results.
60+
* The period to wait for complete results.
61+
* It defaults to no timeout, meaning the request waits for complete search results.
5762
*/
5863
wait_for_completion_timeout?: Duration
5964
}

specification/sql/get_async/SqlGetAsyncResponse.ts

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -23,23 +23,23 @@ import { Column, Row } from '../types'
2323
export class Response {
2424
body: {
2525
/**
26-
* Identifier for the search. This value is only returned for async and saved
27-
* synchronous searches. For CSV, TSV, and TXT responses, this value is returned
28-
* in the `Async-ID` HTTP header.
26+
* Identifier for the search.
27+
* This value is returned only for async and saved synchronous searches.
28+
* For CSV, TSV, and TXT responses, this value is returned in the `Async-ID` HTTP header.
2929
*/
3030
id: Id
3131
/**
32-
* If `true`, the search is still running. If false, the search has finished.
33-
* This value is only returned for async and saved synchronous searches. For
34-
* CSV, TSV, and TXT responses, this value is returned in the `Async-partial`
35-
* HTTP header.
32+
* If `true`, the search is still running.
33+
* If `false`, the search has finished.
34+
* This value is returned only for async and saved synchronous searches.
35+
* For CSV, TSV, and TXT responses, this value is returned in the `Async-partial` HTTP header.
3636
*/
3737
is_running: boolean
3838
/**
39-
* If `true`, the response does not contain complete search results. If `is_partial`
40-
* is `true` and `is_running` is `true`, the search is still running. If `is_partial`
41-
* is `true` but `is_running` is `false`, the results are partial due to a failure or
42-
* timeout. This value is only returned for async and saved synchronous searches.
39+
* If `true`, the response does not contain complete search results.
40+
* If `is_partial` is `true` and `is_running` is `true`, the search is still running.
41+
* If `is_partial` is `true` but `is_running` is `false`, the results are partial due to a failure or timeout.
42+
* This value is returned only for async and saved synchronous searches.
4343
* For CSV, TSV, and TXT responses, this value is returned in the `Async-partial` HTTP header.
4444
*/
4545
is_partial: boolean
@@ -48,12 +48,12 @@ export class Response {
4848
*/
4949
columns?: Column[]
5050
/**
51-
* Cursor for the next set of paginated results. For CSV, TSV, and
52-
* TXT responses, this value is returned in the `Cursor` HTTP header.
51+
* The cursor for the next set of paginated results.
52+
* For CSV, TSV, and TXT responses, this value is returned in the `Cursor` HTTP header.
5353
*/
5454
cursor?: string
5555
/**
56-
* Values for the search results.
56+
* The values for the search results.
5757
*/
5858
rows: Row[]
5959
}

specification/sql/get_async_status/SqlGetAsyncStatusRequest.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,11 +26,13 @@ import { Id } from '@_types/common'
2626
* @rest_spec_name sql.get_async_status
2727
* @availability stack since=7.15.0 stability=stable
2828
* @availability serverless stability=stable visibility=public
29+
* @cluster_privileges monitor
30+
* @doc_id sql-async-status-api
2931
*/
3032
export interface Request extends RequestBase {
3133
path_parts: {
3234
/**
33-
* Identifier for the search.
35+
* The identifier for the search.
3436
*/
3537
id: Id
3638
}

specification/sql/get_async_status/SqlGetAsyncStatusResponse.ts

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -23,32 +23,32 @@ import { EpochTime, UnitMillis } from '@_types/Time'
2323
export class Response {
2424
body: {
2525
/**
26-
* Identifier for the search.
26+
* The timestamp, in milliseconds since the Unix epoch, when Elasticsearch will delete the search and its results, even if the search is still running.
27+
*/
28+
expiration_time_in_millis: EpochTime<UnitMillis>
29+
/**
30+
* The identifier for the search.
2731
*/
2832
id: string
2933
/**
30-
* If `true`, the search is still running. If `false`, the search has finished.
34+
* If `true`, the search is still running.
35+
* If `false`, the search has finished.
3136
*/
3237
is_running: boolean
3338
/**
34-
* If `true`, the response does not contain complete search results. If `is_partial`
35-
* is `true` and `is_running` is `true`, the search is still running. If `is_partial`
36-
* is `true` but `is_running` is `false`, the results are partial due to a failure or
37-
* timeout.
39+
* If `true`, the response does not contain complete search results.
40+
* If `is_partial` is `true` and `is_running` is `true`, the search is still running.
41+
* If `is_partial` is `true` but `is_running` is `false`, the results are partial due to a failure or timeout.
3842
*/
3943
is_partial: boolean
4044
/**
41-
* Timestamp, in milliseconds since the Unix epoch, when the search started.
42-
* The API only returns this property for running searches.
45+
* The timestamp, in milliseconds since the Unix epoch, when the search started.
46+
* The API returns this property only for running searches.
4347
*/
4448
start_time_in_millis: EpochTime<UnitMillis>
4549
/**
46-
* Timestamp, in milliseconds since the Unix epoch, when Elasticsearch will delete
47-
* the search and its results, even if the search is still running.
48-
*/
49-
expiration_time_in_millis: EpochTime<UnitMillis>
50-
/**
51-
* HTTP status code for the search. The API only returns this property for completed searches.
50+
* The HTTP status code for the search.
51+
* The API returns this property only for completed searches.
5252
*/
5353
completion_status?: uint
5454
}

0 commit comments

Comments
 (0)