Skip to content

Commit f03ec43

Browse files
Update rest-api-spec (#5585)
Co-authored-by: pquentin <[email protected]>
1 parent 0f60d1a commit f03ec43

8 files changed

+69
-21
lines changed

specification/_json_spec/connector.sync_job_list.json

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,8 +29,17 @@
2929
"description": "specifies a max number of results to get (default: 100)"
3030
},
3131
"status": {
32-
"type": "string",
33-
"description": "Sync job status, which sync jobs are fetched for"
32+
"type": "enum",
33+
"description": "A sync job status to fetch connector sync jobs for",
34+
"options": [
35+
"canceling",
36+
"canceled",
37+
"completed",
38+
"error",
39+
"in_progress",
40+
"pending",
41+
"suspended"
42+
]
3443
},
3544
"connector_id": {
3645
"type": "string",

specification/_json_spec/esql.async_query.json

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,8 +20,18 @@
2020
},
2121
"params": {
2222
"format": {
23-
"type": "string",
24-
"description": "a short version of the Accept header, e.g. json, yaml"
23+
"type": "enum",
24+
"description": "A short version of the Accept header, e.g. json, yaml.\n\n`csv`, `tsv`, and `txt` formats will return results in a tabular format, excluding other metadata fields from the response.\n\nFor async requests, nothing will be returned if the async query doesn't finish within the timeout.\nThe query ID and running status are available in the `X-Elasticsearch-Async-Id` and `X-Elasticsearch-Async-Is-Running` HTTP headers of the response, respectively.",
25+
"options": [
26+
"csv",
27+
"json",
28+
"tsv",
29+
"txt",
30+
"yaml",
31+
"cbor",
32+
"smile",
33+
"arrow"
34+
]
2535
},
2636
"delimiter": {
2737
"type": "string",

specification/_json_spec/esql.async_query_get.json

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,18 @@
2525
},
2626
"params": {
2727
"format": {
28-
"type": "string",
29-
"description": "a short version of the Accept header, e.g. json, yaml"
28+
"type": "enum",
29+
"description": "A short version of the Accept header, for example `json` or `yaml`.",
30+
"options": [
31+
"csv",
32+
"json",
33+
"tsv",
34+
"txt",
35+
"yaml",
36+
"cbor",
37+
"smile",
38+
"arrow"
39+
]
3040
},
3141
"wait_for_completion_timeout": {
3242
"type": "time",

specification/_json_spec/esql.query.json

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,8 +20,18 @@
2020
},
2121
"params": {
2222
"format": {
23-
"type": "string",
24-
"description": "a short version of the Accept header, e.g. json, yaml"
23+
"type": "enum",
24+
"description": "A short version of the Accept header, e.g. json, yaml.\n\n`csv`, `tsv`, and `txt` formats will return results in a tabular format, excluding other metadata fields from the response.",
25+
"options": [
26+
"csv",
27+
"json",
28+
"tsv",
29+
"txt",
30+
"yaml",
31+
"cbor",
32+
"smile",
33+
"arrow"
34+
]
2535
},
2636
"delimiter": {
2737
"type": "string",

specification/_json_spec/ml.get_trained_models.json

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,8 +34,15 @@
3434
"default": true
3535
},
3636
"include": {
37-
"type": "string",
38-
"description": "A comma-separate list of fields to optionally include. Valid options are 'definition' and 'total_feature_importance'. Default is none."
37+
"type": "enum",
38+
"description": "A comma delimited string of optional fields to include in the response\nbody.",
39+
"options": [
40+
"definition",
41+
"feature_importance_baseline",
42+
"hyperparameters",
43+
"total_feature_importance",
44+
"definition_status"
45+
]
3946
},
4047
"include_model_definition": {
4148
"type": "boolean",

specification/_json_spec/ml.start_trained_model_deployment.json

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -45,9 +45,9 @@
4545
"default": 1
4646
},
4747
"priority": {
48-
"type": "string",
48+
"type": "enum",
4949
"description": "The deployment priority.",
50-
"default": "normal"
50+
"options": ["normal", "low"]
5151
},
5252
"queue_capacity": {
5353
"type": "int",
@@ -60,9 +60,9 @@
6060
"default": "20s"
6161
},
6262
"wait_for": {
63-
"type": "string",
64-
"description": "The allocation status for which to wait",
65-
"options": ["starting", "started", "fully_allocated"],
63+
"type": "enum",
64+
"description": "Specifies the allocation status to wait for before returning.",
65+
"options": ["started", "starting", "fully_allocated"],
6666
"default": "started"
6767
}
6868
},

specification/_json_spec/text_structure.find_field_structure.json

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -64,9 +64,10 @@
6464
"description": "Optional parameter to specify the Grok pattern that should be used to extract fields from messages in a semi-structured text file"
6565
},
6666
"ecs_compatibility": {
67-
"type": "string",
68-
"default": "disabled",
69-
"description": "Optional parameter to specify the compatibility mode with ECS Grok patterns - may be either 'v1' or 'disabled'"
67+
"type": "enum",
68+
"description": "The mode of compatibility with ECS compliant Grok patterns.\nUse this parameter to specify whether to use ECS Grok patterns instead of legacy ones when the structure finder creates a Grok pattern.\nThis setting primarily has an impact when a whole message Grok pattern such as `%{CATALINALOG}` matches the input.\nIf the structure finder identifies a common structure but has no idea of the meaning then generic field names such as `path`, `ipaddress`, `field1`, and `field2` are used in the `grok_pattern` output.\nThe intention in that situation is that a user who knows the meanings will rename the fields before using them.",
69+
"options": ["disabled", "v1"],
70+
"default": "disabled"
7071
},
7172
"timestamp_field": {
7273
"type": "string",

specification/_json_spec/text_structure.find_message_structure.json

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -50,9 +50,10 @@
5050
"description": "Optional parameter to specify the Grok pattern that should be used to extract fields from messages in a semi-structured text file"
5151
},
5252
"ecs_compatibility": {
53-
"type": "string",
54-
"default": "disabled",
55-
"description": "Optional parameter to specify the compatibility mode with ECS Grok patterns - may be either 'v1' or 'disabled'"
53+
"type": "enum",
54+
"description": "The mode of compatibility with ECS compliant Grok patterns.\nUse this parameter to specify whether to use ECS Grok patterns instead of legacy ones when the structure finder creates a Grok pattern.\nThis setting primarily has an impact when a whole message Grok pattern such as `%{CATALINALOG}` matches the input.\nIf the structure finder identifies a common structure but has no idea of meaning then generic field names such as `path`, `ipaddress`, `field1`, and `field2` are used in the `grok_pattern` output, with the intention that a user who knows the meanings rename these fields before using it.",
55+
"options": ["disabled", "v1"],
56+
"default": "disabled"
5657
},
5758
"timestamp_field": {
5859
"type": "string",

0 commit comments

Comments
 (0)