Compare commits
5 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 41ab991791 | |||
| 32bee1e17e | |||
| fb4a3c1471 | |||
| 2af0ce8165 | |||
| c3bcf707b4 |
@ -1,6 +1,6 @@
|
||||
---
|
||||
STACK_VERSION:
|
||||
- "8.6.0-SNAPSHOT"
|
||||
- "8.4.2-SNAPSHOT"
|
||||
|
||||
NODE_JS_VERSION:
|
||||
- 18
|
||||
|
||||
@ -1,39 +1,6 @@
|
||||
[[changelog-client]]
|
||||
== Release notes
|
||||
|
||||
[discrete]
|
||||
=== 8.6.0
|
||||
|
||||
[discrete]
|
||||
===== Bump @elastic/transport to 8.3.1+ https://github.com/elastic/elasticsearch-js/pull/1802[#1802]
|
||||
|
||||
The `@elastic/transport` dependency has been bumped to `~8.3.1` to ensure
|
||||
fixes to the `maxResponseSize` option are available in the client.
|
||||
|
||||
[discrete]
|
||||
===== Support for Elasticsearch `v8.6.0`
|
||||
|
||||
You can find all the API changes
|
||||
https://www.elastic.co/guide/en/elasticsearch/reference/8.6/release-notes-8.6.0.html[here].
|
||||
|
||||
[discrete]
|
||||
=== 8.5.0
|
||||
|
||||
[discrete]
|
||||
===== Support for Elasticsearch `v8.5.0`
|
||||
|
||||
You can find all the API changes
|
||||
https://www.elastic.co/guide/en/elasticsearch/reference/8.5/release-notes-8.5.0.html[here].
|
||||
|
||||
[discrete]
|
||||
=== 8.4.0
|
||||
|
||||
[discrete]
|
||||
===== Support for Elasticsearch `v8.4.0`
|
||||
|
||||
You can find all the API changes
|
||||
https://www.elastic.co/guide/en/elasticsearch/reference/8.4/release-notes-8.4.0.html[here].
|
||||
|
||||
[discrete]
|
||||
=== 8.2.1
|
||||
|
||||
|
||||
@ -155,7 +155,7 @@ request: {
|
||||
The event order is described in the following graph, in some edge cases, the
|
||||
order is not guaranteed.
|
||||
You can find in
|
||||
https://github.com/elastic/elasticsearch-js/blob/main/test/acceptance/events-order.test.js[`test/acceptance/events-order.test.js`]
|
||||
https://github.com/elastic/elasticsearch-js/blob/master/test/acceptance/events-order.test.js[`test/acceptance/events-order.test.js`]
|
||||
how the order changes based on the situation.
|
||||
|
||||
[source]
|
||||
@ -377,9 +377,9 @@ child.search({
|
||||
To improve observability, the client offers an easy way to configure the
|
||||
`X-Opaque-Id` header. If you set the `X-Opaque-Id` in a specific request, this
|
||||
allows you to discover this identifier in the
|
||||
https://www.elastic.co/guide/en/elasticsearch/reference/current/logging.html#deprecation-logging[deprecation logs],
|
||||
helps you with https://www.elastic.co/guide/en/elasticsearch/reference/current/index-modules-slowlog.html#_identifying_search_slow_log_origin[identifying search slow log origin]
|
||||
as well as https://www.elastic.co/guide/en/elasticsearch/reference/current/tasks.html#_identifying_running_tasks[identifying running tasks].
|
||||
https://www.elastic.co/guide/en/elasticsearch/reference/master/logging.html#deprecation-logging[deprecation logs],
|
||||
helps you with https://www.elastic.co/guide/en/elasticsearch/reference/master/index-modules-slowlog.html#_identifying_search_slow_log_origin[identifying search slow log origin]
|
||||
as well as https://www.elastic.co/guide/en/elasticsearch/reference/master/tasks.html#_identifying_running_tasks[identifying running tasks].
|
||||
|
||||
The `X-Opaque-Id` should be configured in each request, for doing that you can
|
||||
use the `opaqueId` option, as you can see in the following example. The
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@ -1,7 +1,7 @@
|
||||
{
|
||||
"name": "@elastic/elasticsearch",
|
||||
"version": "8.6.0",
|
||||
"versionCanary": "8.6.0-canary.0",
|
||||
"version": "8.4.0",
|
||||
"versionCanary": "8.4.0-canary.2",
|
||||
"description": "The official Elasticsearch client for Node.js",
|
||||
"main": "index.js",
|
||||
"types": "index.d.ts",
|
||||
@ -81,7 +81,7 @@
|
||||
"zx": "^6.1.0"
|
||||
},
|
||||
"dependencies": {
|
||||
"@elastic/transport": "^8.3.1",
|
||||
"@elastic/transport": "^8.2.0",
|
||||
"tslib": "^2.4.0"
|
||||
},
|
||||
"tap": {
|
||||
|
||||
@ -418,33 +418,6 @@ export default class Indices {
|
||||
return await this.transport.request({ path, method, querystring, body }, options)
|
||||
}
|
||||
|
||||
async downsample (this: That, params: T.IndicesDownsampleRequest | TB.IndicesDownsampleRequest, options?: TransportRequestOptionsWithOutMeta): Promise<T.IndicesDownsampleResponse>
|
||||
async downsample (this: That, params: T.IndicesDownsampleRequest | TB.IndicesDownsampleRequest, options?: TransportRequestOptionsWithMeta): Promise<TransportResult<T.IndicesDownsampleResponse, unknown>>
|
||||
async downsample (this: That, params: T.IndicesDownsampleRequest | TB.IndicesDownsampleRequest, options?: TransportRequestOptions): Promise<T.IndicesDownsampleResponse>
|
||||
async downsample (this: That, params: T.IndicesDownsampleRequest | TB.IndicesDownsampleRequest, options?: TransportRequestOptions): Promise<any> {
|
||||
const acceptedPath: string[] = ['index', 'target_index']
|
||||
const acceptedBody: string[] = ['config']
|
||||
const querystring: Record<string, any> = {}
|
||||
// @ts-expect-error
|
||||
let body: any = params.body ?? undefined
|
||||
|
||||
for (const key in params) {
|
||||
if (acceptedBody.includes(key)) {
|
||||
// @ts-expect-error
|
||||
body = params[key]
|
||||
} else if (acceptedPath.includes(key)) {
|
||||
continue
|
||||
} else if (key !== 'body') {
|
||||
// @ts-expect-error
|
||||
querystring[key] = params[key]
|
||||
}
|
||||
}
|
||||
|
||||
const method = 'POST'
|
||||
const path = `/${encodeURIComponent(params.index.toString())}/_downsample/${encodeURIComponent(params.target_index.toString())}`
|
||||
return await this.transport.request({ path, method, querystring, body }, options)
|
||||
}
|
||||
|
||||
async exists (this: That, params: T.IndicesExistsRequest | TB.IndicesExistsRequest, options?: TransportRequestOptionsWithOutMeta): Promise<T.IndicesExistsResponse>
|
||||
async exists (this: That, params: T.IndicesExistsRequest | TB.IndicesExistsRequest, options?: TransportRequestOptionsWithMeta): Promise<TransportResult<T.IndicesExistsResponse, unknown>>
|
||||
async exists (this: That, params: T.IndicesExistsRequest | TB.IndicesExistsRequest, options?: TransportRequestOptions): Promise<T.IndicesExistsResponse>
|
||||
|
||||
@ -43,28 +43,6 @@ export default class Ml {
|
||||
this.transport = transport
|
||||
}
|
||||
|
||||
async clearTrainedModelDeploymentCache (this: That, params?: T.TODO | TB.TODO, options?: TransportRequestOptionsWithOutMeta): Promise<T.TODO>
|
||||
async clearTrainedModelDeploymentCache (this: That, params?: T.TODO | TB.TODO, options?: TransportRequestOptionsWithMeta): Promise<TransportResult<T.TODO, unknown>>
|
||||
async clearTrainedModelDeploymentCache (this: That, params?: T.TODO | TB.TODO, options?: TransportRequestOptions): Promise<T.TODO>
|
||||
async clearTrainedModelDeploymentCache (this: That, params?: T.TODO | TB.TODO, options?: TransportRequestOptions): Promise<any> {
|
||||
const acceptedPath: string[] = ['model_id']
|
||||
const querystring: Record<string, any> = {}
|
||||
const body = undefined
|
||||
|
||||
params = params ?? {}
|
||||
for (const key in params) {
|
||||
if (acceptedPath.includes(key)) {
|
||||
continue
|
||||
} else if (key !== 'body') {
|
||||
querystring[key] = params[key]
|
||||
}
|
||||
}
|
||||
|
||||
const method = 'POST'
|
||||
const path = `/_ml/trained_models/${encodeURIComponent(params.model_id.toString())}/deployment/cache/_clear`
|
||||
return await this.transport.request({ path, method, querystring, body }, options)
|
||||
}
|
||||
|
||||
async closeJob (this: That, params: T.MlCloseJobRequest | TB.MlCloseJobRequest, options?: TransportRequestOptionsWithOutMeta): Promise<T.MlCloseJobResponse>
|
||||
async closeJob (this: That, params: T.MlCloseJobRequest | TB.MlCloseJobRequest, options?: TransportRequestOptionsWithMeta): Promise<TransportResult<T.MlCloseJobResponse, unknown>>
|
||||
async closeJob (this: That, params: T.MlCloseJobRequest | TB.MlCloseJobRequest, options?: TransportRequestOptions): Promise<T.MlCloseJobResponse>
|
||||
|
||||
@ -181,6 +181,33 @@ export default class Rollup {
|
||||
return await this.transport.request({ path, method, querystring, body }, options)
|
||||
}
|
||||
|
||||
async rollup (this: That, params: T.RollupRollupRequest | TB.RollupRollupRequest, options?: TransportRequestOptionsWithOutMeta): Promise<T.RollupRollupResponse>
|
||||
async rollup (this: That, params: T.RollupRollupRequest | TB.RollupRollupRequest, options?: TransportRequestOptionsWithMeta): Promise<TransportResult<T.RollupRollupResponse, unknown>>
|
||||
async rollup (this: That, params: T.RollupRollupRequest | TB.RollupRollupRequest, options?: TransportRequestOptions): Promise<T.RollupRollupResponse>
|
||||
async rollup (this: That, params: T.RollupRollupRequest | TB.RollupRollupRequest, options?: TransportRequestOptions): Promise<any> {
|
||||
const acceptedPath: string[] = ['index', 'rollup_index']
|
||||
const acceptedBody: string[] = ['config']
|
||||
const querystring: Record<string, any> = {}
|
||||
// @ts-expect-error
|
||||
let body: any = params.body ?? undefined
|
||||
|
||||
for (const key in params) {
|
||||
if (acceptedBody.includes(key)) {
|
||||
// @ts-expect-error
|
||||
body = params[key]
|
||||
} else if (acceptedPath.includes(key)) {
|
||||
continue
|
||||
} else if (key !== 'body') {
|
||||
// @ts-expect-error
|
||||
querystring[key] = params[key]
|
||||
}
|
||||
}
|
||||
|
||||
const method = 'POST'
|
||||
const path = `/${encodeURIComponent(params.index.toString())}/_rollup/${encodeURIComponent(params.rollup_index.toString())}`
|
||||
return await this.transport.request({ path, method, querystring, body }, options)
|
||||
}
|
||||
|
||||
async rollupSearch<TDocument = unknown, TAggregations = Record<T.AggregateName, T.AggregationsAggregate>> (this: That, params: T.RollupRollupSearchRequest | TB.RollupRollupSearchRequest, options?: TransportRequestOptionsWithOutMeta): Promise<T.RollupRollupSearchResponse<TDocument, TAggregations>>
|
||||
async rollupSearch<TDocument = unknown, TAggregations = Record<T.AggregateName, T.AggregationsAggregate>> (this: That, params: T.RollupRollupSearchRequest | TB.RollupRollupSearchRequest, options?: TransportRequestOptionsWithMeta): Promise<TransportResult<T.RollupRollupSearchResponse<TDocument, TAggregations>, unknown>>
|
||||
async rollupSearch<TDocument = unknown, TAggregations = Record<T.AggregateName, T.AggregationsAggregate>> (this: That, params: T.RollupRollupSearchRequest | TB.RollupRollupSearchRequest, options?: TransportRequestOptions): Promise<T.RollupRollupSearchResponse<TDocument, TAggregations>>
|
||||
|
||||
@ -100,28 +100,6 @@ export default class Security {
|
||||
return await this.transport.request({ path, method, querystring, body }, options)
|
||||
}
|
||||
|
||||
async bulkUpdateApiKeys (this: That, params?: T.TODO | TB.TODO, options?: TransportRequestOptionsWithOutMeta): Promise<T.TODO>
|
||||
async bulkUpdateApiKeys (this: That, params?: T.TODO | TB.TODO, options?: TransportRequestOptionsWithMeta): Promise<TransportResult<T.TODO, unknown>>
|
||||
async bulkUpdateApiKeys (this: That, params?: T.TODO | TB.TODO, options?: TransportRequestOptions): Promise<T.TODO>
|
||||
async bulkUpdateApiKeys (this: That, params?: T.TODO | TB.TODO, options?: TransportRequestOptions): Promise<any> {
|
||||
const acceptedPath: string[] = []
|
||||
const querystring: Record<string, any> = {}
|
||||
const body = undefined
|
||||
|
||||
params = params ?? {}
|
||||
for (const key in params) {
|
||||
if (acceptedPath.includes(key)) {
|
||||
continue
|
||||
} else if (key !== 'body') {
|
||||
querystring[key] = params[key]
|
||||
}
|
||||
}
|
||||
|
||||
const method = 'POST'
|
||||
const path = '/_security/api_key/_bulk_update'
|
||||
return await this.transport.request({ path, method, querystring, body }, options)
|
||||
}
|
||||
|
||||
async changePassword (this: That, params?: T.SecurityChangePasswordRequest | TB.SecurityChangePasswordRequest, options?: TransportRequestOptionsWithOutMeta): Promise<T.SecurityChangePasswordResponse>
|
||||
async changePassword (this: That, params?: T.SecurityChangePasswordRequest | TB.SecurityChangePasswordRequest, options?: TransportRequestOptionsWithMeta): Promise<TransportResult<T.SecurityChangePasswordResponse, unknown>>
|
||||
async changePassword (this: That, params?: T.SecurityChangePasswordRequest | TB.SecurityChangePasswordRequest, options?: TransportRequestOptions): Promise<T.SecurityChangePasswordResponse>
|
||||
@ -891,7 +869,7 @@ export default class Security {
|
||||
async grantApiKey (this: That, params: T.SecurityGrantApiKeyRequest | TB.SecurityGrantApiKeyRequest, options?: TransportRequestOptions): Promise<T.SecurityGrantApiKeyResponse>
|
||||
async grantApiKey (this: That, params: T.SecurityGrantApiKeyRequest | TB.SecurityGrantApiKeyRequest, options?: TransportRequestOptions): Promise<any> {
|
||||
const acceptedPath: string[] = []
|
||||
const acceptedBody: string[] = ['api_key', 'grant_type', 'access_token', 'username', 'password', 'run_as']
|
||||
const acceptedBody: string[] = ['api_key', 'grant_type', 'access_token', 'username', 'password']
|
||||
const querystring: Record<string, any> = {}
|
||||
// @ts-expect-error
|
||||
const userBody: any = params?.body
|
||||
|
||||
@ -433,7 +433,7 @@ export interface GetScriptLanguagesResponse {
|
||||
types_allowed: string[]
|
||||
}
|
||||
|
||||
export interface GetSourceRequest extends RequestBase {
|
||||
export interface GetSourceRequest {
|
||||
id: Id
|
||||
index: IndexName
|
||||
preference?: string
|
||||
@ -1920,7 +1920,7 @@ export interface FieldSort {
|
||||
|
||||
export type FieldSortNumericType = 'long' | 'double' | 'date' | 'date_nanos'
|
||||
|
||||
export type FieldValue = long | double | string | boolean | any
|
||||
export type FieldValue = long | double | string | boolean
|
||||
|
||||
export interface FielddataStats {
|
||||
evictions?: long
|
||||
@ -3998,7 +3998,7 @@ export type AnalysisIcuTransformDirection = 'forward' | 'reverse'
|
||||
|
||||
export interface AnalysisIcuTransformTokenFilter extends AnalysisTokenFilterBase {
|
||||
type: 'icu_transform'
|
||||
dir?: AnalysisIcuTransformDirection
|
||||
dir: AnalysisIcuTransformDirection
|
||||
id: string
|
||||
}
|
||||
|
||||
@ -9569,7 +9569,7 @@ export interface IndicesAnalyzeAnalyzeDetail {
|
||||
export interface IndicesAnalyzeAnalyzeToken {
|
||||
end_offset: long
|
||||
position: long
|
||||
positionLength?: long
|
||||
position_length?: long
|
||||
start_offset: long
|
||||
token: string
|
||||
type: string
|
||||
@ -9776,14 +9776,6 @@ export interface IndicesDiskUsageRequest extends RequestBase {
|
||||
|
||||
export type IndicesDiskUsageResponse = any
|
||||
|
||||
export interface IndicesDownsampleRequest extends RequestBase {
|
||||
index: IndexName
|
||||
target_index: IndexName
|
||||
config?: any
|
||||
}
|
||||
|
||||
export type IndicesDownsampleResponse = any
|
||||
|
||||
export interface IndicesExistsRequest extends RequestBase {
|
||||
index: Indices
|
||||
allow_no_indices?: boolean
|
||||
@ -14764,6 +14756,14 @@ export interface RollupPutJobRequest extends RequestBase {
|
||||
|
||||
export type RollupPutJobResponse = AcknowledgedResponseBase
|
||||
|
||||
export interface RollupRollupRequest extends RequestBase {
|
||||
index: IndexName
|
||||
rollup_index: IndexName
|
||||
config?: any
|
||||
}
|
||||
|
||||
export type RollupRollupResponse = any
|
||||
|
||||
export interface RollupRollupSearchRequest extends RequestBase {
|
||||
index: Indices
|
||||
rest_total_hits_as_int?: boolean
|
||||
@ -14879,9 +14879,6 @@ export interface SecurityApiKey {
|
||||
realm?: string
|
||||
username?: Username
|
||||
metadata?: Metadata
|
||||
role_descriptors?: Record<string, SecurityRoleDescriptor>
|
||||
limited_by?: Record<string, SecurityRoleDescriptor>[]
|
||||
_sort?: SortResults
|
||||
}
|
||||
|
||||
export interface SecurityApplicationGlobalUserPrivileges {
|
||||
@ -15008,7 +15005,6 @@ export interface SecurityUser {
|
||||
roles: string[]
|
||||
username: Username
|
||||
enabled: boolean
|
||||
profile_uid?: SecurityUserProfileId
|
||||
}
|
||||
|
||||
export interface SecurityUserProfile {
|
||||
@ -15278,7 +15274,6 @@ export interface SecurityGetApiKeyRequest extends RequestBase {
|
||||
owner?: boolean
|
||||
realm_name?: Name
|
||||
username?: Username
|
||||
with_limited_by?: boolean
|
||||
}
|
||||
|
||||
export interface SecurityGetApiKeyResponse {
|
||||
@ -15402,7 +15397,6 @@ export interface SecurityGetTokenUserRealm {
|
||||
|
||||
export interface SecurityGetUserRequest extends RequestBase {
|
||||
username?: Username | Username[]
|
||||
with_profile_uid?: boolean
|
||||
}
|
||||
|
||||
export type SecurityGetUserResponse = Record<string, SecurityUser>
|
||||
@ -15421,28 +15415,19 @@ export interface SecurityGetUserPrivilegesResponse {
|
||||
run_as: string[]
|
||||
}
|
||||
|
||||
export interface SecurityGetUserProfileGetUserProfileErrors {
|
||||
count: long
|
||||
details: Record<SecurityUserProfileId, ErrorCause>
|
||||
}
|
||||
|
||||
export interface SecurityGetUserProfileRequest extends RequestBase {
|
||||
uid: SecurityUserProfileId | SecurityUserProfileId[]
|
||||
uid: SecurityUserProfileId
|
||||
data?: string | string[]
|
||||
}
|
||||
|
||||
export interface SecurityGetUserProfileResponse {
|
||||
profiles: SecurityUserProfileWithMetadata[]
|
||||
errors?: SecurityGetUserProfileGetUserProfileErrors
|
||||
}
|
||||
export type SecurityGetUserProfileResponse = Record<string, SecurityUserProfileWithMetadata>
|
||||
|
||||
export type SecurityGrantApiKeyApiKeyGrantType = 'access_token' | 'password'
|
||||
|
||||
export interface SecurityGrantApiKeyGrantApiKey {
|
||||
name: Name
|
||||
expiration?: DurationLarge
|
||||
role_descriptors?: Record<string, SecurityRoleDescriptor> | Record<string, SecurityRoleDescriptor>[]
|
||||
metadata?: Metadata
|
||||
expiration?: Duration
|
||||
role_descriptors?: Record<string, any>[]
|
||||
}
|
||||
|
||||
export interface SecurityGrantApiKeyRequest extends RequestBase {
|
||||
@ -15451,7 +15436,6 @@ export interface SecurityGrantApiKeyRequest extends RequestBase {
|
||||
access_token?: string
|
||||
username?: Username
|
||||
password?: Password
|
||||
run_as?: Username
|
||||
}
|
||||
|
||||
export interface SecurityGrantApiKeyResponse {
|
||||
@ -15459,7 +15443,6 @@ export interface SecurityGrantApiKeyResponse {
|
||||
id: Id
|
||||
name: Name
|
||||
expiration?: EpochTime<UnitMillis>
|
||||
encoded: string
|
||||
}
|
||||
|
||||
export interface SecurityHasPrivilegesApplicationPrivilegesCheck {
|
||||
@ -15495,11 +15478,6 @@ export interface SecurityHasPrivilegesResponse {
|
||||
username: Username
|
||||
}
|
||||
|
||||
export interface SecurityHasPrivilegesUserProfileHasPrivilegesUserProfileErrors {
|
||||
count: long
|
||||
details: Record<SecurityUserProfileId, ErrorCause>
|
||||
}
|
||||
|
||||
export interface SecurityHasPrivilegesUserProfilePrivilegesCheck {
|
||||
application?: SecurityHasPrivilegesApplicationPrivilegesCheck[]
|
||||
cluster?: SecurityClusterPrivilege[]
|
||||
@ -15513,7 +15491,7 @@ export interface SecurityHasPrivilegesUserProfileRequest extends RequestBase {
|
||||
|
||||
export interface SecurityHasPrivilegesUserProfileResponse {
|
||||
has_privilege_uids: SecurityUserProfileId[]
|
||||
errors?: SecurityHasPrivilegesUserProfileHasPrivilegesUserProfileErrors
|
||||
error_uids?: SecurityUserProfileId[]
|
||||
}
|
||||
|
||||
export interface SecurityInvalidateApiKeyRequest extends RequestBase {
|
||||
@ -15608,7 +15586,6 @@ export interface SecurityPutUserResponse {
|
||||
}
|
||||
|
||||
export interface SecurityQueryApiKeysRequest extends RequestBase {
|
||||
with_limited_by?: boolean
|
||||
query?: QueryDslQueryContainer
|
||||
from?: integer
|
||||
sort?: Sort
|
||||
@ -16336,7 +16313,6 @@ export interface TasksParentTaskInfo extends TasksTaskInfo {
|
||||
|
||||
export interface TasksTaskInfo {
|
||||
action: string
|
||||
cancelled?: boolean
|
||||
cancellable: boolean
|
||||
description?: string
|
||||
headers: Record<string, string>
|
||||
@ -16792,31 +16768,42 @@ export interface WatcherActivationStatus {
|
||||
export interface WatcherAlwaysCondition {
|
||||
}
|
||||
|
||||
export interface WatcherArrayCompareConditionKeys {
|
||||
export interface WatcherArrayCompareCondition {
|
||||
array_path: string
|
||||
comparison: string
|
||||
path: string
|
||||
}
|
||||
export type WatcherArrayCompareCondition = WatcherArrayCompareConditionKeys
|
||||
& { [property: string]: WatcherArrayCompareOpParams | string }
|
||||
|
||||
export interface WatcherArrayCompareOpParams {
|
||||
quantifier: WatcherQuantifier
|
||||
value: FieldValue
|
||||
value: any
|
||||
}
|
||||
|
||||
export interface WatcherChainInput {
|
||||
inputs: Partial<Record<string, WatcherInputContainer>>[]
|
||||
inputs: WatcherInputContainer[]
|
||||
}
|
||||
|
||||
export interface WatcherCompareCondition {
|
||||
comparison?: string
|
||||
path?: string
|
||||
value?: any
|
||||
'ctx.payload.match'?: WatcherCompareContextPayloadCondition
|
||||
'ctx.payload.value'?: WatcherCompareContextPayloadCondition
|
||||
}
|
||||
|
||||
export interface WatcherCompareContextPayloadCondition {
|
||||
eq?: any
|
||||
lt?: any
|
||||
gt?: any
|
||||
lte?: any
|
||||
gte?: any
|
||||
}
|
||||
|
||||
export interface WatcherConditionContainer {
|
||||
always?: WatcherAlwaysCondition
|
||||
array_compare?: Partial<Record<string, WatcherArrayCompareCondition>>
|
||||
compare?: Partial<Record<string, Partial<Record<WatcherConditionOp, FieldValue>>>>
|
||||
array_compare?: WatcherArrayCompareCondition
|
||||
compare?: WatcherCompareCondition
|
||||
never?: WatcherNeverCondition
|
||||
script?: WatcherScriptCondition
|
||||
}
|
||||
|
||||
export type WatcherConditionOp = 'not_eq' | 'eq' | 'lt' | 'gt' | 'lte' | 'gte'
|
||||
|
||||
export type WatcherConditionType = 'always' | 'never' | 'script' | 'compare' | 'array_compare'
|
||||
|
||||
export type WatcherConnectionScheme = 'http' | 'https'
|
||||
@ -16936,6 +16923,7 @@ export interface WatcherHttpEmailAttachment {
|
||||
}
|
||||
|
||||
export interface WatcherHttpInput {
|
||||
http?: WatcherHttpInput
|
||||
extract?: string[]
|
||||
request?: WatcherHttpInputRequestDefinition
|
||||
response_content_type?: WatcherResponseContentType
|
||||
|
||||
@ -454,7 +454,7 @@ export interface GetScriptLanguagesResponse {
|
||||
types_allowed: string[]
|
||||
}
|
||||
|
||||
export interface GetSourceRequest extends RequestBase {
|
||||
export interface GetSourceRequest {
|
||||
id: Id
|
||||
index: IndexName
|
||||
preference?: string
|
||||
@ -1993,7 +1993,7 @@ export interface FieldSort {
|
||||
|
||||
export type FieldSortNumericType = 'long' | 'double' | 'date' | 'date_nanos'
|
||||
|
||||
export type FieldValue = long | double | string | boolean | any
|
||||
export type FieldValue = long | double | string | boolean
|
||||
|
||||
export interface FielddataStats {
|
||||
evictions?: long
|
||||
@ -4071,7 +4071,7 @@ export type AnalysisIcuTransformDirection = 'forward' | 'reverse'
|
||||
|
||||
export interface AnalysisIcuTransformTokenFilter extends AnalysisTokenFilterBase {
|
||||
type: 'icu_transform'
|
||||
dir?: AnalysisIcuTransformDirection
|
||||
dir: AnalysisIcuTransformDirection
|
||||
id: string
|
||||
}
|
||||
|
||||
@ -9692,7 +9692,7 @@ export interface IndicesAnalyzeAnalyzeDetail {
|
||||
export interface IndicesAnalyzeAnalyzeToken {
|
||||
end_offset: long
|
||||
position: long
|
||||
positionLength?: long
|
||||
position_length?: long
|
||||
start_offset: long
|
||||
token: string
|
||||
type: string
|
||||
@ -9908,15 +9908,6 @@ export interface IndicesDiskUsageRequest extends RequestBase {
|
||||
|
||||
export type IndicesDiskUsageResponse = any
|
||||
|
||||
export interface IndicesDownsampleRequest extends RequestBase {
|
||||
index: IndexName
|
||||
target_index: IndexName
|
||||
/** @deprecated The use of the 'body' key has been deprecated, use 'config' instead. */
|
||||
body?: any
|
||||
}
|
||||
|
||||
export type IndicesDownsampleResponse = any
|
||||
|
||||
export interface IndicesExistsRequest extends RequestBase {
|
||||
index: Indices
|
||||
allow_no_indices?: boolean
|
||||
@ -15059,6 +15050,15 @@ export interface RollupPutJobRequest extends RequestBase {
|
||||
|
||||
export type RollupPutJobResponse = AcknowledgedResponseBase
|
||||
|
||||
export interface RollupRollupRequest extends RequestBase {
|
||||
index: IndexName
|
||||
rollup_index: IndexName
|
||||
/** @deprecated The use of the 'body' key has been deprecated, use 'config' instead. */
|
||||
body?: any
|
||||
}
|
||||
|
||||
export type RollupRollupResponse = any
|
||||
|
||||
export interface RollupRollupSearchRequest extends RequestBase {
|
||||
index: Indices
|
||||
rest_total_hits_as_int?: boolean
|
||||
@ -15180,9 +15180,6 @@ export interface SecurityApiKey {
|
||||
realm?: string
|
||||
username?: Username
|
||||
metadata?: Metadata
|
||||
role_descriptors?: Record<string, SecurityRoleDescriptor>
|
||||
limited_by?: Record<string, SecurityRoleDescriptor>[]
|
||||
_sort?: SortResults
|
||||
}
|
||||
|
||||
export interface SecurityApplicationGlobalUserPrivileges {
|
||||
@ -15309,7 +15306,6 @@ export interface SecurityUser {
|
||||
roles: string[]
|
||||
username: Username
|
||||
enabled: boolean
|
||||
profile_uid?: SecurityUserProfileId
|
||||
}
|
||||
|
||||
export interface SecurityUserProfile {
|
||||
@ -15588,7 +15584,6 @@ export interface SecurityGetApiKeyRequest extends RequestBase {
|
||||
owner?: boolean
|
||||
realm_name?: Name
|
||||
username?: Username
|
||||
with_limited_by?: boolean
|
||||
}
|
||||
|
||||
export interface SecurityGetApiKeyResponse {
|
||||
@ -15715,7 +15710,6 @@ export interface SecurityGetTokenUserRealm {
|
||||
|
||||
export interface SecurityGetUserRequest extends RequestBase {
|
||||
username?: Username | Username[]
|
||||
with_profile_uid?: boolean
|
||||
}
|
||||
|
||||
export type SecurityGetUserResponse = Record<string, SecurityUser>
|
||||
@ -15734,28 +15728,19 @@ export interface SecurityGetUserPrivilegesResponse {
|
||||
run_as: string[]
|
||||
}
|
||||
|
||||
export interface SecurityGetUserProfileGetUserProfileErrors {
|
||||
count: long
|
||||
details: Record<SecurityUserProfileId, ErrorCause>
|
||||
}
|
||||
|
||||
export interface SecurityGetUserProfileRequest extends RequestBase {
|
||||
uid: SecurityUserProfileId | SecurityUserProfileId[]
|
||||
uid: SecurityUserProfileId
|
||||
data?: string | string[]
|
||||
}
|
||||
|
||||
export interface SecurityGetUserProfileResponse {
|
||||
profiles: SecurityUserProfileWithMetadata[]
|
||||
errors?: SecurityGetUserProfileGetUserProfileErrors
|
||||
}
|
||||
export type SecurityGetUserProfileResponse = Record<string, SecurityUserProfileWithMetadata>
|
||||
|
||||
export type SecurityGrantApiKeyApiKeyGrantType = 'access_token' | 'password'
|
||||
|
||||
export interface SecurityGrantApiKeyGrantApiKey {
|
||||
name: Name
|
||||
expiration?: DurationLarge
|
||||
role_descriptors?: Record<string, SecurityRoleDescriptor> | Record<string, SecurityRoleDescriptor>[]
|
||||
metadata?: Metadata
|
||||
expiration?: Duration
|
||||
role_descriptors?: Record<string, any>[]
|
||||
}
|
||||
|
||||
export interface SecurityGrantApiKeyRequest extends RequestBase {
|
||||
@ -15766,7 +15751,6 @@ export interface SecurityGrantApiKeyRequest extends RequestBase {
|
||||
access_token?: string
|
||||
username?: Username
|
||||
password?: Password
|
||||
run_as?: Username
|
||||
}
|
||||
}
|
||||
|
||||
@ -15775,7 +15759,6 @@ export interface SecurityGrantApiKeyResponse {
|
||||
id: Id
|
||||
name: Name
|
||||
expiration?: EpochTime<UnitMillis>
|
||||
encoded: string
|
||||
}
|
||||
|
||||
export interface SecurityHasPrivilegesApplicationPrivilegesCheck {
|
||||
@ -15814,11 +15797,6 @@ export interface SecurityHasPrivilegesResponse {
|
||||
username: Username
|
||||
}
|
||||
|
||||
export interface SecurityHasPrivilegesUserProfileHasPrivilegesUserProfileErrors {
|
||||
count: long
|
||||
details: Record<SecurityUserProfileId, ErrorCause>
|
||||
}
|
||||
|
||||
export interface SecurityHasPrivilegesUserProfilePrivilegesCheck {
|
||||
application?: SecurityHasPrivilegesApplicationPrivilegesCheck[]
|
||||
cluster?: SecurityClusterPrivilege[]
|
||||
@ -15835,7 +15813,7 @@ export interface SecurityHasPrivilegesUserProfileRequest extends RequestBase {
|
||||
|
||||
export interface SecurityHasPrivilegesUserProfileResponse {
|
||||
has_privilege_uids: SecurityUserProfileId[]
|
||||
errors?: SecurityHasPrivilegesUserProfileHasPrivilegesUserProfileErrors
|
||||
error_uids?: SecurityUserProfileId[]
|
||||
}
|
||||
|
||||
export interface SecurityInvalidateApiKeyRequest extends RequestBase {
|
||||
@ -15947,7 +15925,6 @@ export interface SecurityPutUserResponse {
|
||||
}
|
||||
|
||||
export interface SecurityQueryApiKeysRequest extends RequestBase {
|
||||
with_limited_by?: boolean
|
||||
/** @deprecated The use of the 'body' key has been deprecated, move the nested keys to the top level object. */
|
||||
body?: {
|
||||
query?: QueryDslQueryContainer
|
||||
@ -16729,7 +16706,6 @@ export interface TasksParentTaskInfo extends TasksTaskInfo {
|
||||
|
||||
export interface TasksTaskInfo {
|
||||
action: string
|
||||
cancelled?: boolean
|
||||
cancellable: boolean
|
||||
description?: string
|
||||
headers: Record<string, string>
|
||||
@ -17195,31 +17171,42 @@ export interface WatcherActivationStatus {
|
||||
export interface WatcherAlwaysCondition {
|
||||
}
|
||||
|
||||
export interface WatcherArrayCompareConditionKeys {
|
||||
export interface WatcherArrayCompareCondition {
|
||||
array_path: string
|
||||
comparison: string
|
||||
path: string
|
||||
}
|
||||
export type WatcherArrayCompareCondition = WatcherArrayCompareConditionKeys
|
||||
& { [property: string]: WatcherArrayCompareOpParams | string }
|
||||
|
||||
export interface WatcherArrayCompareOpParams {
|
||||
quantifier: WatcherQuantifier
|
||||
value: FieldValue
|
||||
value: any
|
||||
}
|
||||
|
||||
export interface WatcherChainInput {
|
||||
inputs: Partial<Record<string, WatcherInputContainer>>[]
|
||||
inputs: WatcherInputContainer[]
|
||||
}
|
||||
|
||||
export interface WatcherCompareCondition {
|
||||
comparison?: string
|
||||
path?: string
|
||||
value?: any
|
||||
'ctx.payload.match'?: WatcherCompareContextPayloadCondition
|
||||
'ctx.payload.value'?: WatcherCompareContextPayloadCondition
|
||||
}
|
||||
|
||||
export interface WatcherCompareContextPayloadCondition {
|
||||
eq?: any
|
||||
lt?: any
|
||||
gt?: any
|
||||
lte?: any
|
||||
gte?: any
|
||||
}
|
||||
|
||||
export interface WatcherConditionContainer {
|
||||
always?: WatcherAlwaysCondition
|
||||
array_compare?: Partial<Record<string, WatcherArrayCompareCondition>>
|
||||
compare?: Partial<Record<string, Partial<Record<WatcherConditionOp, FieldValue>>>>
|
||||
array_compare?: WatcherArrayCompareCondition
|
||||
compare?: WatcherCompareCondition
|
||||
never?: WatcherNeverCondition
|
||||
script?: WatcherScriptCondition
|
||||
}
|
||||
|
||||
export type WatcherConditionOp = 'not_eq' | 'eq' | 'lt' | 'gt' | 'lte' | 'gte'
|
||||
|
||||
export type WatcherConditionType = 'always' | 'never' | 'script' | 'compare' | 'array_compare'
|
||||
|
||||
export type WatcherConnectionScheme = 'http' | 'https'
|
||||
@ -17339,6 +17326,7 @@ export interface WatcherHttpEmailAttachment {
|
||||
}
|
||||
|
||||
export interface WatcherHttpInput {
|
||||
http?: WatcherHttpInput
|
||||
extract?: string[]
|
||||
request?: WatcherHttpInputRequestDefinition
|
||||
response_content_type?: WatcherResponseContentType
|
||||
|
||||
@ -229,6 +229,7 @@ export default class Helpers {
|
||||
rest_total_hits_as_int: params.rest_total_hits_as_int,
|
||||
scroll_id
|
||||
}, options as TransportRequestOptionsWithMeta)
|
||||
// @ts-expect-error
|
||||
response = r as TransportResult<T.ScrollResponse<TDocument, TAggregations>, unknown>
|
||||
assert(response !== undefined, 'The response is undefined, please file a bug report')
|
||||
if (response.statusCode !== 429) break
|
||||
|
||||
Reference in New Issue
Block a user