From 947a1eaa08c00dd3e4444e44df087f2a6fca1e31 Mon Sep 17 00:00:00 2001 From: Nik Everett Date: Wed, 17 Apr 2024 08:27:21 -0400 Subject: [PATCH] Add esql version (#2512) Adds a `version` parameter to the ESQL `_query` request endpoint. We'll do some work to give this a default value in the generated clients soon, but for 8.14+ this'll be a required parameter. --------- Co-authored-by: Alexander Spies --- output/schema/schema.json | 28 ++++++++++++++++++++- output/typescript/types.ts | 3 +++ specification/esql/_types/Version.ts | 31 ++++++++++++++++++++++++ specification/esql/query/QueryRequest.ts | 5 ++++ 4 files changed, 66 insertions(+), 1 deletion(-) create mode 100644 specification/esql/_types/Version.ts diff --git a/output/schema/schema.json b/output/schema/schema.json index 77baf17a59..24d817da3b 100644 --- a/output/schema/schema.json +++ b/output/schema/schema.json @@ -111014,6 +111014,20 @@ }, "specLocation": "eql/search/types.ts#L20-L32" }, + { + "kind": "enum", + "members": [ + { + "description": "Run against the first version of ES|QL.", + "name": "2024.04.01" + } + ], + "name": { + "name": "Version", + "namespace": "esql._types" + }, + "specLocation": "esql/_types/Version.ts#L23-L31" + }, { "attachedBehaviors": [ "CommonQueryParameters" @@ -111084,6 +111098,18 @@ "namespace": "_builtins" } } + }, + { + "description": "The version of the ES|QL language in which the \"query\" field was written.", + "name": "version", + "required": true, + "type": { + "kind": "instance_of", + "type": { + "name": "Version", + "namespace": "esql._types" + } + } } ] }, @@ -111126,7 +111152,7 @@ } } ], - "specLocation": "esql/query/QueryRequest.ts#L24-L64" + "specLocation": "esql/query/QueryRequest.ts#L25-L69" }, { "body": { diff --git a/output/typescript/types.ts b/output/typescript/types.ts index bb907d07b7..4df4a986fa 100644 --- a/output/typescript/types.ts +++ b/output/typescript/types.ts @@ -9688,6 +9688,8 @@ export type EqlSearchResponse = EqlEqlSearchResponseBase