diff --git a/docs/reference.asciidoc b/docs/reference.asciidoc index e1a407bf1..6dea24605 100644 --- a/docs/reference.asciidoc +++ b/docs/reference.asciidoc @@ -4994,6 +4994,9 @@ and its format can change at any time but it can give some insight into the perf of each part of the query. ** *`tables` (Optional, Record>)*: Tables to use with the LOOKUP operation. The top level key is the table name and the next level key is the column name. +** *`include_ccs_metadata` (Optional, boolean)*: When set to `true` and performing a cross-cluster query, the response will include an extra `_clusters` +object with information about the clusters that participated in the search along with info such as shards +count. ** *`delimiter` (Optional, string)*: The character to use between values within a CSV row. It is valid only for the CSV format. ** *`drop_null_columns` (Optional, boolean)*: Indicates whether columns that are entirely `null` will be removed from the `columns` and `values` portion of the results. @@ -5112,6 +5115,9 @@ and its format can change at any time but it can give some insight into the perf of each part of the query. ** *`tables` (Optional, Record>)*: Tables to use with the LOOKUP operation. The top level key is the table name and the next level key is the column name. +** *`include_ccs_metadata` (Optional, boolean)*: When set to `true` and performing a cross-cluster query, the response will include an extra `_clusters` +object with information about the clusters that participated in the search along with info such as shards +count. ** *`format` (Optional, Enum("csv" | "json" | "tsv" | "txt" | "yaml" | "cbor" | "smile" | "arrow"))*: A short version of the Accept header, e.g. json, yaml. ** *`delimiter` (Optional, string)*: The character to use between values within a CSV row. Only valid for the CSV format. ** *`drop_null_columns` (Optional, boolean)*: Should columns that are entirely `null` be removed from the `columns` and `values` portion of the results? diff --git a/src/api/api/esql.ts b/src/api/api/esql.ts index 2c3144cba..df076d3f9 100644 --- a/src/api/api/esql.ts +++ b/src/api/api/esql.ts @@ -53,7 +53,7 @@ export default class Esql { async asyncQuery (this: That, params: T.EsqlAsyncQueryRequest | TB.EsqlAsyncQueryRequest, options?: TransportRequestOptions): Promise async asyncQuery (this: That, params: T.EsqlAsyncQueryRequest | TB.EsqlAsyncQueryRequest, options?: TransportRequestOptions): Promise { const acceptedPath: string[] = [] - const acceptedBody: string[] = ['columnar', 'filter', 'locale', 'params', 'profile', 'query', 'tables'] + const acceptedBody: string[] = ['columnar', 'filter', 'locale', 'params', 'profile', 'query', 'tables', 'include_ccs_metadata'] const querystring: Record = {} // @ts-expect-error const userBody: any = params?.body @@ -190,7 +190,7 @@ export default class Esql { async query (this: That, params: T.EsqlQueryRequest | TB.EsqlQueryRequest, options?: TransportRequestOptions): Promise async query (this: That, params: T.EsqlQueryRequest | TB.EsqlQueryRequest, options?: TransportRequestOptions): Promise { const acceptedPath: string[] = [] - const acceptedBody: string[] = ['columnar', 'filter', 'locale', 'params', 'profile', 'query', 'tables'] + const acceptedBody: string[] = ['columnar', 'filter', 'locale', 'params', 'profile', 'query', 'tables', 'include_ccs_metadata'] const querystring: Record = {} // @ts-expect-error const userBody: any = params?.body diff --git a/src/api/types.ts b/src/api/types.ts index bc7c36d7c..76679df6f 100644 --- a/src/api/types.ts +++ b/src/api/types.ts @@ -10386,6 +10386,7 @@ export interface EsqlAsyncQueryRequest extends RequestBase { profile?: boolean query: string tables?: Record> + include_ccs_metadata?: boolean } export type EsqlAsyncQueryResponse = EsqlResult @@ -10425,6 +10426,7 @@ export interface EsqlQueryRequest extends RequestBase { profile?: boolean query: string tables?: Record> + include_ccs_metadata?: boolean } export type EsqlQueryResponse = EsqlResult @@ -10744,7 +10746,7 @@ export interface IlmExplainLifecycleLifecycleExplainManaged { age?: Duration failed_step?: Name failed_step_retry_count?: integer - index?: IndexName + index: IndexName index_creation_date?: DateTime index_creation_date_millis?: EpochTime is_auto_retryable_error?: boolean @@ -10754,7 +10756,11 @@ export interface IlmExplainLifecycleLifecycleExplainManaged { phase: Name phase_time?: DateTime phase_time_millis?: EpochTime - policy: Name + policy?: Name + previous_step_info?: Record + repository_name?: string + snapshot_name?: string + shrink_index_name?: string step?: Name step_info?: Record step_time?: DateTime @@ -10764,6 +10770,7 @@ export interface IlmExplainLifecycleLifecycleExplainManaged { } export interface IlmExplainLifecycleLifecycleExplainPhaseExecution { + phase_definition?: IlmPhase policy: Name version: VersionNumber modified_date_in_millis: EpochTime @@ -12808,7 +12815,7 @@ export interface InferenceInferenceResult { export interface InferenceRankedDocument { index: integer - score: float + relevance_score: float text?: string } diff --git a/src/api/typesWithBodyKey.ts b/src/api/typesWithBodyKey.ts index 71a07449d..b486bd1eb 100644 --- a/src/api/typesWithBodyKey.ts +++ b/src/api/typesWithBodyKey.ts @@ -10559,6 +10559,7 @@ export interface EsqlAsyncQueryRequest extends RequestBase { profile?: boolean query: string tables?: Record> + include_ccs_metadata?: boolean } } @@ -10601,6 +10602,7 @@ export interface EsqlQueryRequest extends RequestBase { profile?: boolean query: string tables?: Record> + include_ccs_metadata?: boolean } } @@ -10928,7 +10930,7 @@ export interface IlmExplainLifecycleLifecycleExplainManaged { age?: Duration failed_step?: Name failed_step_retry_count?: integer - index?: IndexName + index: IndexName index_creation_date?: DateTime index_creation_date_millis?: EpochTime is_auto_retryable_error?: boolean @@ -10938,7 +10940,11 @@ export interface IlmExplainLifecycleLifecycleExplainManaged { phase: Name phase_time?: DateTime phase_time_millis?: EpochTime - policy: Name + policy?: Name + previous_step_info?: Record + repository_name?: string + snapshot_name?: string + shrink_index_name?: string step?: Name step_info?: Record step_time?: DateTime @@ -10948,6 +10954,7 @@ export interface IlmExplainLifecycleLifecycleExplainManaged { } export interface IlmExplainLifecycleLifecycleExplainPhaseExecution { + phase_definition?: IlmPhase policy: Name version: VersionNumber modified_date_in_millis: EpochTime @@ -13048,7 +13055,7 @@ export interface InferenceInferenceResult { export interface InferenceRankedDocument { index: integer - score: float + relevance_score: float text?: string }