API generation

This commit is contained in:
delvedor
2019-10-24 09:54:18 +02:00
parent 7ab5894331
commit e098f77a23
41 changed files with 1881 additions and 88 deletions

View File

@ -14,7 +14,6 @@ function buildCatAliases (opts) {
const acceptedQuerystring = [
'format',
'local',
'master_timeout',
'h',
'help',
's',
@ -27,7 +26,6 @@ function buildCatAliases (opts) {
]
const snakeCase = {
masterTimeout: 'master_timeout',
errorTrace: 'error_trace',
filterPath: 'filter_path'
}

View File

@ -13,8 +13,6 @@ function buildCatCount (opts) {
const acceptedQuerystring = [
'format',
'local',
'master_timeout',
'h',
'help',
's',
@ -27,7 +25,6 @@ function buildCatCount (opts) {
]
const snakeCase = {
masterTimeout: 'master_timeout',
errorTrace: 'error_trace',
filterPath: 'filter_path'
}

View File

@ -14,8 +14,6 @@ function buildCatFielddata (opts) {
const acceptedQuerystring = [
'format',
'bytes',
'local',
'master_timeout',
'h',
'help',
's',
@ -29,7 +27,6 @@ function buildCatFielddata (opts) {
]
const snakeCase = {
masterTimeout: 'master_timeout',
errorTrace: 'error_trace',
filterPath: 'filter_path'
}

View File

@ -13,11 +13,10 @@ function buildCatHealth (opts) {
const acceptedQuerystring = [
'format',
'local',
'master_timeout',
'h',
'help',
's',
'time',
'ts',
'v',
'pretty',
@ -28,7 +27,6 @@ function buildCatHealth (opts) {
]
const snakeCase = {
masterTimeout: 'master_timeout',
errorTrace: 'error_trace',
filterPath: 'filter_path'
}

View File

@ -21,6 +21,7 @@ function buildCatIndices (opts) {
'help',
'pri',
's',
'time',
'v',
'include_unloaded_segments',
'pretty',

View File

@ -12,6 +12,7 @@ function buildCatNodes (opts) {
const { makeRequest, ConfigurationError, handleError, snakeCaseKeys } = opts
const acceptedQuerystring = [
'bytes',
'format',
'full_id',
'local',
@ -19,6 +20,7 @@ function buildCatNodes (opts) {
'h',
'help',
's',
'time',
'v',
'pretty',
'human',

View File

@ -18,6 +18,7 @@ function buildCatPendingTasks (opts) {
'h',
'help',
's',
'time',
'v',
'pretty',
'human',

View File

@ -16,11 +16,11 @@ function buildCatRecovery (opts) {
'active_only',
'bytes',
'detailed',
'master_timeout',
'h',
'help',
'index',
's',
'time',
'v',
'pretty',
'human',
@ -31,7 +31,6 @@ function buildCatRecovery (opts) {
const snakeCase = {
activeOnly: 'active_only',
masterTimeout: 'master_timeout',
errorTrace: 'error_trace',
filterPath: 'filter_path'
}

View File

@ -19,6 +19,7 @@ function buildCatShards (opts) {
'h',
'help',
's',
'time',
'v',
'pretty',
'human',

View File

@ -18,6 +18,7 @@ function buildCatSnapshots (opts) {
'h',
'help',
's',
'time',
'v',
'pretty',
'human',

View File

@ -20,6 +20,7 @@ function buildCatTasks (opts) {
'h',
'help',
's',
'time',
'v',
'pretty',
'human',

View File

@ -0,0 +1,77 @@
// Licensed to Elasticsearch B.V under one or more agreements.
// Elasticsearch B.V licenses this file to you under the Apache 2.0 License.
// See the LICENSE file in the project root for more information
'use strict'
/* eslint camelcase: 0 */
/* eslint no-unused-vars: 0 */
function buildCcrPauseAutoFollowPattern (opts) {
// eslint-disable-next-line no-unused-vars
const { makeRequest, ConfigurationError, handleError, snakeCaseKeys } = opts
const acceptedQuerystring = [
]
const snakeCase = {
}
/**
* Perform a ccr.pause_auto_follow_pattern request
* https://www.elastic.co/guide/en/elasticsearch/reference/current/ccr-pause-auto-follow-pattern.html
*/
return function ccrPauseAutoFollowPattern (params, options, callback) {
options = options || {}
if (typeof options === 'function') {
callback = options
options = {}
}
if (typeof params === 'function' || params == null) {
callback = params
params = {}
options = {}
}
// check required parameters
if (params['name'] == null) {
const err = new ConfigurationError('Missing required parameter: name')
return handleError(err, callback)
}
// validate headers object
if (options.headers != null && typeof options.headers !== 'object') {
const err = new ConfigurationError(`Headers should be an object, instead got: ${typeof options.headers}`)
return handleError(err, callback)
}
var warnings = []
var { method, body, name, ...querystring } = params
querystring = snakeCaseKeys(acceptedQuerystring, snakeCase, querystring, warnings)
var ignore = options.ignore
if (typeof ignore === 'number') {
options.ignore = [ignore]
}
var path = ''
if (method == null) method = 'POST'
path = '/' + '_ccr' + '/' + 'auto_follow' + '/' + encodeURIComponent(name) + '/' + 'pause'
// build request object
const request = {
method,
path,
body: body || '',
querystring
}
options.warnings = warnings.length === 0 ? null : warnings
return makeRequest(request, options, callback)
}
}
module.exports = buildCcrPauseAutoFollowPattern

View File

@ -0,0 +1,77 @@
// Licensed to Elasticsearch B.V under one or more agreements.
// Elasticsearch B.V licenses this file to you under the Apache 2.0 License.
// See the LICENSE file in the project root for more information
'use strict'
/* eslint camelcase: 0 */
/* eslint no-unused-vars: 0 */
function buildCcrResumeAutoFollowPattern (opts) {
// eslint-disable-next-line no-unused-vars
const { makeRequest, ConfigurationError, handleError, snakeCaseKeys } = opts
const acceptedQuerystring = [
]
const snakeCase = {
}
/**
* Perform a ccr.resume_auto_follow_pattern request
* https://www.elastic.co/guide/en/elasticsearch/reference/current/ccr-resume-auto-follow-pattern.html
*/
return function ccrResumeAutoFollowPattern (params, options, callback) {
options = options || {}
if (typeof options === 'function') {
callback = options
options = {}
}
if (typeof params === 'function' || params == null) {
callback = params
params = {}
options = {}
}
// check required parameters
if (params['name'] == null) {
const err = new ConfigurationError('Missing required parameter: name')
return handleError(err, callback)
}
// validate headers object
if (options.headers != null && typeof options.headers !== 'object') {
const err = new ConfigurationError(`Headers should be an object, instead got: ${typeof options.headers}`)
return handleError(err, callback)
}
var warnings = []
var { method, body, name, ...querystring } = params
querystring = snakeCaseKeys(acceptedQuerystring, snakeCase, querystring, warnings)
var ignore = options.ignore
if (typeof ignore === 'number') {
options.ignore = [ignore]
}
var path = ''
if (method == null) method = 'POST'
path = '/' + '_ccr' + '/' + 'auto_follow' + '/' + encodeURIComponent(name) + '/' + 'resume'
// build request object
const request = {
method,
path,
body: body || '',
querystring
}
options.warnings = warnings.length === 0 ? null : warnings
return makeRequest(request, options, callback)
}
}
module.exports = buildCcrResumeAutoFollowPattern

View File

@ -0,0 +1,77 @@
// Licensed to Elasticsearch B.V under one or more agreements.
// Elasticsearch B.V licenses this file to you under the Apache 2.0 License.
// See the LICENSE file in the project root for more information
'use strict'
/* eslint camelcase: 0 */
/* eslint no-unused-vars: 0 */
function buildDataFrameTransformDeprecatedDeleteTransform (opts) {
// eslint-disable-next-line no-unused-vars
const { makeRequest, ConfigurationError, handleError, snakeCaseKeys } = opts
const acceptedQuerystring = [
'force'
]
const snakeCase = {
}
/**
* Perform a data_frame_transform_deprecated.delete_transform request
* https://www.elastic.co/guide/en/elasticsearch/reference/current/delete-transform.html
*/
return function dataFrameTransformDeprecatedDeleteTransform (params, options, callback) {
options = options || {}
if (typeof options === 'function') {
callback = options
options = {}
}
if (typeof params === 'function' || params == null) {
callback = params
params = {}
options = {}
}
// check required parameters
if (params['transform_id'] == null && params['transformId'] == null) {
const err = new ConfigurationError('Missing required parameter: transform_id or transformId')
return handleError(err, callback)
}
// validate headers object
if (options.headers != null && typeof options.headers !== 'object') {
const err = new ConfigurationError(`Headers should be an object, instead got: ${typeof options.headers}`)
return handleError(err, callback)
}
var warnings = []
var { method, body, transformId, transform_id, ...querystring } = params
querystring = snakeCaseKeys(acceptedQuerystring, snakeCase, querystring, warnings)
var ignore = options.ignore
if (typeof ignore === 'number') {
options.ignore = [ignore]
}
var path = ''
if (method == null) method = 'DELETE'
path = '/' + '_data_frame' + '/' + 'transforms' + '/' + encodeURIComponent(transform_id || transformId)
// build request object
const request = {
method,
path,
body: body || '',
querystring
}
options.warnings = warnings.length === 0 ? null : warnings
return makeRequest(request, options, callback)
}
}
module.exports = buildDataFrameTransformDeprecatedDeleteTransform

View File

@ -0,0 +1,73 @@
// Licensed to Elasticsearch B.V under one or more agreements.
// Elasticsearch B.V licenses this file to you under the Apache 2.0 License.
// See the LICENSE file in the project root for more information
'use strict'
/* eslint camelcase: 0 */
/* eslint no-unused-vars: 0 */
function buildDataFrameTransformDeprecatedGetTransform (opts) {
// eslint-disable-next-line no-unused-vars
const { makeRequest, ConfigurationError, handleError, snakeCaseKeys } = opts
const acceptedQuerystring = [
'from',
'size',
'allow_no_match'
]
const snakeCase = {
allowNoMatch: 'allow_no_match'
}
/**
* Perform a data_frame_transform_deprecated.get_transform request
* https://www.elastic.co/guide/en/elasticsearch/reference/current/get-transform.html
*/
return function dataFrameTransformDeprecatedGetTransform (params, options, callback) {
options = options || {}
if (typeof options === 'function') {
callback = options
options = {}
}
if (typeof params === 'function' || params == null) {
callback = params
params = {}
options = {}
}
// validate headers object
if (options.headers != null && typeof options.headers !== 'object') {
const err = new ConfigurationError(`Headers should be an object, instead got: ${typeof options.headers}`)
return handleError(err, callback)
}
var warnings = []
var { method, body, transformId, transform_id, ...querystring } = params
querystring = snakeCaseKeys(acceptedQuerystring, snakeCase, querystring, warnings)
var ignore = options.ignore
if (typeof ignore === 'number') {
options.ignore = [ignore]
}
var path = ''
if (method == null) method = 'GET'
path = '/' + '_data_frame' + '/' + 'transforms' + '/' + encodeURIComponent(transform_id || transformId)
// build request object
const request = {
method,
path,
body: null,
querystring
}
options.warnings = warnings.length === 0 ? null : warnings
return makeRequest(request, options, callback)
}
}
module.exports = buildDataFrameTransformDeprecatedGetTransform

View File

@ -0,0 +1,79 @@
// Licensed to Elasticsearch B.V under one or more agreements.
// Elasticsearch B.V licenses this file to you under the Apache 2.0 License.
// See the LICENSE file in the project root for more information
'use strict'
/* eslint camelcase: 0 */
/* eslint no-unused-vars: 0 */
function buildDataFrameTransformDeprecatedGetTransformStats (opts) {
// eslint-disable-next-line no-unused-vars
const { makeRequest, ConfigurationError, handleError, snakeCaseKeys } = opts
const acceptedQuerystring = [
'from',
'size',
'allow_no_match'
]
const snakeCase = {
allowNoMatch: 'allow_no_match'
}
/**
* Perform a data_frame_transform_deprecated.get_transform_stats request
* https://www.elastic.co/guide/en/elasticsearch/reference/current/get-transform-stats.html
*/
return function dataFrameTransformDeprecatedGetTransformStats (params, options, callback) {
options = options || {}
if (typeof options === 'function') {
callback = options
options = {}
}
if (typeof params === 'function' || params == null) {
callback = params
params = {}
options = {}
}
// check required parameters
if (params['transform_id'] == null && params['transformId'] == null) {
const err = new ConfigurationError('Missing required parameter: transform_id or transformId')
return handleError(err, callback)
}
// validate headers object
if (options.headers != null && typeof options.headers !== 'object') {
const err = new ConfigurationError(`Headers should be an object, instead got: ${typeof options.headers}`)
return handleError(err, callback)
}
var warnings = []
var { method, body, transformId, transform_id, ...querystring } = params
querystring = snakeCaseKeys(acceptedQuerystring, snakeCase, querystring, warnings)
var ignore = options.ignore
if (typeof ignore === 'number') {
options.ignore = [ignore]
}
var path = ''
if (method == null) method = 'GET'
path = '/' + '_data_frame' + '/' + 'transforms' + '/' + encodeURIComponent(transform_id || transformId) + '/' + '_stats'
// build request object
const request = {
method,
path,
body: null,
querystring
}
options.warnings = warnings.length === 0 ? null : warnings
return makeRequest(request, options, callback)
}
}
module.exports = buildDataFrameTransformDeprecatedGetTransformStats

View File

@ -0,0 +1,74 @@
// Licensed to Elasticsearch B.V under one or more agreements.
// Elasticsearch B.V licenses this file to you under the Apache 2.0 License.
// See the LICENSE file in the project root for more information
'use strict'
/* eslint camelcase: 0 */
/* eslint no-unused-vars: 0 */
function buildDataFrameTransformDeprecatedPreviewTransform (opts) {
// eslint-disable-next-line no-unused-vars
const { makeRequest, ConfigurationError, handleError, snakeCaseKeys } = opts
const acceptedQuerystring = [
]
const snakeCase = {
}
/**
* Perform a data_frame_transform_deprecated.preview_transform request
* https://www.elastic.co/guide/en/elasticsearch/reference/current/preview-transform.html
*/
return function dataFrameTransformDeprecatedPreviewTransform (params, options, callback) {
options = options || {}
if (typeof options === 'function') {
callback = options
options = {}
}
if (typeof params === 'function' || params == null) {
callback = params
params = {}
options = {}
}
// check required parameters
if (params['body'] == null) {
const err = new ConfigurationError('Missing required parameter: body')
return handleError(err, callback)
}
// validate headers object
if (options.headers != null && typeof options.headers !== 'object') {
const err = new ConfigurationError(`Headers should be an object, instead got: ${typeof options.headers}`)
return handleError(err, callback)
}
var warnings = []
var { method, body, ...querystring } = params
querystring = snakeCaseKeys(acceptedQuerystring, snakeCase, querystring, warnings)
var ignore = options.ignore
if (typeof ignore === 'number') {
options.ignore = [ignore]
}
var path = ''
// build request object
const request = {
method,
path,
body: body || '',
querystring
}
options.warnings = warnings.length === 0 ? null : warnings
return makeRequest(request, options, callback)
}
}
module.exports = buildDataFrameTransformDeprecatedPreviewTransform

View File

@ -0,0 +1,81 @@
// Licensed to Elasticsearch B.V under one or more agreements.
// Elasticsearch B.V licenses this file to you under the Apache 2.0 License.
// See the LICENSE file in the project root for more information
'use strict'
/* eslint camelcase: 0 */
/* eslint no-unused-vars: 0 */
function buildDataFrameTransformDeprecatedPutTransform (opts) {
// eslint-disable-next-line no-unused-vars
const { makeRequest, ConfigurationError, handleError, snakeCaseKeys } = opts
const acceptedQuerystring = [
'defer_validation'
]
const snakeCase = {
deferValidation: 'defer_validation'
}
/**
* Perform a data_frame_transform_deprecated.put_transform request
* https://www.elastic.co/guide/en/elasticsearch/reference/current/put-transform.html
*/
return function dataFrameTransformDeprecatedPutTransform (params, options, callback) {
options = options || {}
if (typeof options === 'function') {
callback = options
options = {}
}
if (typeof params === 'function' || params == null) {
callback = params
params = {}
options = {}
}
// check required parameters
if (params['transform_id'] == null && params['transformId'] == null) {
const err = new ConfigurationError('Missing required parameter: transform_id or transformId')
return handleError(err, callback)
}
if (params['body'] == null) {
const err = new ConfigurationError('Missing required parameter: body')
return handleError(err, callback)
}
// validate headers object
if (options.headers != null && typeof options.headers !== 'object') {
const err = new ConfigurationError(`Headers should be an object, instead got: ${typeof options.headers}`)
return handleError(err, callback)
}
var warnings = []
var { method, body, transformId, transform_id, ...querystring } = params
querystring = snakeCaseKeys(acceptedQuerystring, snakeCase, querystring, warnings)
var ignore = options.ignore
if (typeof ignore === 'number') {
options.ignore = [ignore]
}
var path = ''
if (method == null) method = 'PUT'
path = '/' + '_data_frame' + '/' + 'transforms' + '/' + encodeURIComponent(transform_id || transformId)
// build request object
const request = {
method,
path,
body: body || '',
querystring
}
options.warnings = warnings.length === 0 ? null : warnings
return makeRequest(request, options, callback)
}
}
module.exports = buildDataFrameTransformDeprecatedPutTransform

View File

@ -0,0 +1,77 @@
// Licensed to Elasticsearch B.V under one or more agreements.
// Elasticsearch B.V licenses this file to you under the Apache 2.0 License.
// See the LICENSE file in the project root for more information
'use strict'
/* eslint camelcase: 0 */
/* eslint no-unused-vars: 0 */
function buildDataFrameTransformDeprecatedStartTransform (opts) {
// eslint-disable-next-line no-unused-vars
const { makeRequest, ConfigurationError, handleError, snakeCaseKeys } = opts
const acceptedQuerystring = [
'timeout'
]
const snakeCase = {
}
/**
* Perform a data_frame_transform_deprecated.start_transform request
* https://www.elastic.co/guide/en/elasticsearch/reference/current/start-transform.html
*/
return function dataFrameTransformDeprecatedStartTransform (params, options, callback) {
options = options || {}
if (typeof options === 'function') {
callback = options
options = {}
}
if (typeof params === 'function' || params == null) {
callback = params
params = {}
options = {}
}
// check required parameters
if (params['transform_id'] == null && params['transformId'] == null) {
const err = new ConfigurationError('Missing required parameter: transform_id or transformId')
return handleError(err, callback)
}
// validate headers object
if (options.headers != null && typeof options.headers !== 'object') {
const err = new ConfigurationError(`Headers should be an object, instead got: ${typeof options.headers}`)
return handleError(err, callback)
}
var warnings = []
var { method, body, transformId, transform_id, ...querystring } = params
querystring = snakeCaseKeys(acceptedQuerystring, snakeCase, querystring, warnings)
var ignore = options.ignore
if (typeof ignore === 'number') {
options.ignore = [ignore]
}
var path = ''
if (method == null) method = 'POST'
path = '/' + '_data_frame' + '/' + 'transforms' + '/' + encodeURIComponent(transform_id || transformId) + '/' + '_start'
// build request object
const request = {
method,
path,
body: body || '',
querystring
}
options.warnings = warnings.length === 0 ? null : warnings
return makeRequest(request, options, callback)
}
}
module.exports = buildDataFrameTransformDeprecatedStartTransform

View File

@ -0,0 +1,80 @@
// Licensed to Elasticsearch B.V under one or more agreements.
// Elasticsearch B.V licenses this file to you under the Apache 2.0 License.
// See the LICENSE file in the project root for more information
'use strict'
/* eslint camelcase: 0 */
/* eslint no-unused-vars: 0 */
function buildDataFrameTransformDeprecatedStopTransform (opts) {
// eslint-disable-next-line no-unused-vars
const { makeRequest, ConfigurationError, handleError, snakeCaseKeys } = opts
const acceptedQuerystring = [
'wait_for_completion',
'timeout',
'allow_no_match'
]
const snakeCase = {
waitForCompletion: 'wait_for_completion',
allowNoMatch: 'allow_no_match'
}
/**
* Perform a data_frame_transform_deprecated.stop_transform request
* https://www.elastic.co/guide/en/elasticsearch/reference/current/stop-transform.html
*/
return function dataFrameTransformDeprecatedStopTransform (params, options, callback) {
options = options || {}
if (typeof options === 'function') {
callback = options
options = {}
}
if (typeof params === 'function' || params == null) {
callback = params
params = {}
options = {}
}
// check required parameters
if (params['transform_id'] == null && params['transformId'] == null) {
const err = new ConfigurationError('Missing required parameter: transform_id or transformId')
return handleError(err, callback)
}
// validate headers object
if (options.headers != null && typeof options.headers !== 'object') {
const err = new ConfigurationError(`Headers should be an object, instead got: ${typeof options.headers}`)
return handleError(err, callback)
}
var warnings = []
var { method, body, transformId, transform_id, ...querystring } = params
querystring = snakeCaseKeys(acceptedQuerystring, snakeCase, querystring, warnings)
var ignore = options.ignore
if (typeof ignore === 'number') {
options.ignore = [ignore]
}
var path = ''
if (method == null) method = 'POST'
path = '/' + '_data_frame' + '/' + 'transforms' + '/' + encodeURIComponent(transform_id || transformId) + '/' + '_stop'
// build request object
const request = {
method,
path,
body: body || '',
querystring
}
options.warnings = warnings.length === 0 ? null : warnings
return makeRequest(request, options, callback)
}
}
module.exports = buildDataFrameTransformDeprecatedStopTransform

View File

@ -0,0 +1,81 @@
// Licensed to Elasticsearch B.V under one or more agreements.
// Elasticsearch B.V licenses this file to you under the Apache 2.0 License.
// See the LICENSE file in the project root for more information
'use strict'
/* eslint camelcase: 0 */
/* eslint no-unused-vars: 0 */
function buildDataFrameTransformDeprecatedUpdateTransform (opts) {
// eslint-disable-next-line no-unused-vars
const { makeRequest, ConfigurationError, handleError, snakeCaseKeys } = opts
const acceptedQuerystring = [
'defer_validation'
]
const snakeCase = {
deferValidation: 'defer_validation'
}
/**
* Perform a data_frame_transform_deprecated.update_transform request
* https://www.elastic.co/guide/en/elasticsearch/reference/current/update-transform.html
*/
return function dataFrameTransformDeprecatedUpdateTransform (params, options, callback) {
options = options || {}
if (typeof options === 'function') {
callback = options
options = {}
}
if (typeof params === 'function' || params == null) {
callback = params
params = {}
options = {}
}
// check required parameters
if (params['transform_id'] == null && params['transformId'] == null) {
const err = new ConfigurationError('Missing required parameter: transform_id or transformId')
return handleError(err, callback)
}
if (params['body'] == null) {
const err = new ConfigurationError('Missing required parameter: body')
return handleError(err, callback)
}
// validate headers object
if (options.headers != null && typeof options.headers !== 'object') {
const err = new ConfigurationError(`Headers should be an object, instead got: ${typeof options.headers}`)
return handleError(err, callback)
}
var warnings = []
var { method, body, transformId, transform_id, ...querystring } = params
querystring = snakeCaseKeys(acceptedQuerystring, snakeCase, querystring, warnings)
var ignore = options.ignore
if (typeof ignore === 'number') {
options.ignore = [ignore]
}
var path = ''
if (method == null) method = 'POST'
path = '/' + '_data_frame' + '/' + 'transforms' + '/' + encodeURIComponent(transform_id || transformId) + '/' + '_update'
// build request object
const request = {
method,
path,
body: body || '',
querystring
}
options.warnings = warnings.length === 0 ? null : warnings
return makeRequest(request, options, callback)
}
}
module.exports = buildDataFrameTransformDeprecatedUpdateTransform

View File

@ -0,0 +1,76 @@
// Licensed to Elasticsearch B.V under one or more agreements.
// Elasticsearch B.V licenses this file to you under the Apache 2.0 License.
// See the LICENSE file in the project root for more information
'use strict'
/* eslint camelcase: 0 */
/* eslint no-unused-vars: 0 */
function buildEnrichDeletePolicy (opts) {
// eslint-disable-next-line no-unused-vars
const { makeRequest, ConfigurationError, handleError, snakeCaseKeys } = opts
const acceptedQuerystring = [
]
const snakeCase = {
}
/**
* Perform a enrich.delete_policy request
*/
return function enrichDeletePolicy (params, options, callback) {
options = options || {}
if (typeof options === 'function') {
callback = options
options = {}
}
if (typeof params === 'function' || params == null) {
callback = params
params = {}
options = {}
}
// check required parameters
if (params['name'] == null) {
const err = new ConfigurationError('Missing required parameter: name')
return handleError(err, callback)
}
// validate headers object
if (options.headers != null && typeof options.headers !== 'object') {
const err = new ConfigurationError(`Headers should be an object, instead got: ${typeof options.headers}`)
return handleError(err, callback)
}
var warnings = []
var { method, body, name, ...querystring } = params
querystring = snakeCaseKeys(acceptedQuerystring, snakeCase, querystring, warnings)
var ignore = options.ignore
if (typeof ignore === 'number') {
options.ignore = [ignore]
}
var path = ''
if (method == null) method = 'DELETE'
path = '/' + '_enrich' + '/' + 'policy' + '/' + encodeURIComponent(name)
// build request object
const request = {
method,
path,
body: body || '',
querystring
}
options.warnings = warnings.length === 0 ? null : warnings
return makeRequest(request, options, callback)
}
}
module.exports = buildEnrichDeletePolicy

View File

@ -0,0 +1,76 @@
// Licensed to Elasticsearch B.V under one or more agreements.
// Elasticsearch B.V licenses this file to you under the Apache 2.0 License.
// See the LICENSE file in the project root for more information
'use strict'
/* eslint camelcase: 0 */
/* eslint no-unused-vars: 0 */
function buildEnrichExecutePolicy (opts) {
// eslint-disable-next-line no-unused-vars
const { makeRequest, ConfigurationError, handleError, snakeCaseKeys } = opts
const acceptedQuerystring = [
'wait_for_completion'
]
const snakeCase = {
waitForCompletion: 'wait_for_completion'
}
/**
* Perform a enrich.execute_policy request
*/
return function enrichExecutePolicy (params, options, callback) {
options = options || {}
if (typeof options === 'function') {
callback = options
options = {}
}
if (typeof params === 'function' || params == null) {
callback = params
params = {}
options = {}
}
// check required parameters
if (params['name'] == null) {
const err = new ConfigurationError('Missing required parameter: name')
return handleError(err, callback)
}
// validate headers object
if (options.headers != null && typeof options.headers !== 'object') {
const err = new ConfigurationError(`Headers should be an object, instead got: ${typeof options.headers}`)
return handleError(err, callback)
}
var warnings = []
var { method, body, name, ...querystring } = params
querystring = snakeCaseKeys(acceptedQuerystring, snakeCase, querystring, warnings)
var ignore = options.ignore
if (typeof ignore === 'number') {
options.ignore = [ignore]
}
var path = ''
if (method == null) method = 'PUT'
path = '/' + '_enrich' + '/' + 'policy' + '/' + encodeURIComponent(name) + '/' + '_execute'
// build request object
const request = {
method,
path,
body: body || '',
querystring
}
options.warnings = warnings.length === 0 ? null : warnings
return makeRequest(request, options, callback)
}
}
module.exports = buildEnrichExecutePolicy

View File

@ -0,0 +1,75 @@
// Licensed to Elasticsearch B.V under one or more agreements.
// Elasticsearch B.V licenses this file to you under the Apache 2.0 License.
// See the LICENSE file in the project root for more information
'use strict'
/* eslint camelcase: 0 */
/* eslint no-unused-vars: 0 */
function buildEnrichGetPolicy (opts) {
// eslint-disable-next-line no-unused-vars
const { makeRequest, ConfigurationError, handleError, snakeCaseKeys } = opts
const acceptedQuerystring = [
]
const snakeCase = {
}
/**
* Perform a enrich.get_policy request
*/
return function enrichGetPolicy (params, options, callback) {
options = options || {}
if (typeof options === 'function') {
callback = options
options = {}
}
if (typeof params === 'function' || params == null) {
callback = params
params = {}
options = {}
}
// validate headers object
if (options.headers != null && typeof options.headers !== 'object') {
const err = new ConfigurationError(`Headers should be an object, instead got: ${typeof options.headers}`)
return handleError(err, callback)
}
var warnings = []
var { method, body, name, ...querystring } = params
querystring = snakeCaseKeys(acceptedQuerystring, snakeCase, querystring, warnings)
var ignore = options.ignore
if (typeof ignore === 'number') {
options.ignore = [ignore]
}
var path = ''
if ((name) != null) {
if (method == null) method = 'GET'
path = '/' + '_enrich' + '/' + 'policy' + '/' + encodeURIComponent(name)
} else {
if (method == null) method = 'GET'
path = '/' + '_enrich' + '/' + 'policy'
}
// build request object
const request = {
method,
path,
body: null,
querystring
}
options.warnings = warnings.length === 0 ? null : warnings
return makeRequest(request, options, callback)
}
}
module.exports = buildEnrichGetPolicy

View File

@ -0,0 +1,80 @@
// Licensed to Elasticsearch B.V under one or more agreements.
// Elasticsearch B.V licenses this file to you under the Apache 2.0 License.
// See the LICENSE file in the project root for more information
'use strict'
/* eslint camelcase: 0 */
/* eslint no-unused-vars: 0 */
function buildEnrichPutPolicy (opts) {
// eslint-disable-next-line no-unused-vars
const { makeRequest, ConfigurationError, handleError, snakeCaseKeys } = opts
const acceptedQuerystring = [
]
const snakeCase = {
}
/**
* Perform a enrich.put_policy request
*/
return function enrichPutPolicy (params, options, callback) {
options = options || {}
if (typeof options === 'function') {
callback = options
options = {}
}
if (typeof params === 'function' || params == null) {
callback = params
params = {}
options = {}
}
// check required parameters
if (params['name'] == null) {
const err = new ConfigurationError('Missing required parameter: name')
return handleError(err, callback)
}
if (params['body'] == null) {
const err = new ConfigurationError('Missing required parameter: body')
return handleError(err, callback)
}
// validate headers object
if (options.headers != null && typeof options.headers !== 'object') {
const err = new ConfigurationError(`Headers should be an object, instead got: ${typeof options.headers}`)
return handleError(err, callback)
}
var warnings = []
var { method, body, name, ...querystring } = params
querystring = snakeCaseKeys(acceptedQuerystring, snakeCase, querystring, warnings)
var ignore = options.ignore
if (typeof ignore === 'number') {
options.ignore = [ignore]
}
var path = ''
if (method == null) method = 'PUT'
path = '/' + '_enrich' + '/' + 'policy' + '/' + encodeURIComponent(name)
// build request object
const request = {
method,
path,
body: body || '',
querystring
}
options.warnings = warnings.length === 0 ? null : warnings
return makeRequest(request, options, callback)
}
}
module.exports = buildEnrichPutPolicy

70
api/api/enrich.stats.js Normal file
View File

@ -0,0 +1,70 @@
// Licensed to Elasticsearch B.V under one or more agreements.
// Elasticsearch B.V licenses this file to you under the Apache 2.0 License.
// See the LICENSE file in the project root for more information
'use strict'
/* eslint camelcase: 0 */
/* eslint no-unused-vars: 0 */
function buildEnrichStats (opts) {
// eslint-disable-next-line no-unused-vars
const { makeRequest, ConfigurationError, handleError, snakeCaseKeys } = opts
const acceptedQuerystring = [
]
const snakeCase = {
}
/**
* Perform a enrich.stats request
*/
return function enrichStats (params, options, callback) {
options = options || {}
if (typeof options === 'function') {
callback = options
options = {}
}
if (typeof params === 'function' || params == null) {
callback = params
params = {}
options = {}
}
// validate headers object
if (options.headers != null && typeof options.headers !== 'object') {
const err = new ConfigurationError(`Headers should be an object, instead got: ${typeof options.headers}`)
return handleError(err, callback)
}
var warnings = []
var { method, body, ...querystring } = params
querystring = snakeCaseKeys(acceptedQuerystring, snakeCase, querystring, warnings)
var ignore = options.ignore
if (typeof ignore === 'number') {
options.ignore = [ignore]
}
var path = ''
if (method == null) method = 'GET'
path = '/' + '_enrich' + '/' + '_stats'
// build request object
const request = {
method,
path,
body: null,
querystring
}
options.warnings = warnings.length === 0 ? null : warnings
return makeRequest(request, options, callback)
}
}
module.exports = buildEnrichStats

View File

@ -0,0 +1,76 @@
// Licensed to Elasticsearch B.V under one or more agreements.
// Elasticsearch B.V licenses this file to you under the Apache 2.0 License.
// See the LICENSE file in the project root for more information
'use strict'
/* eslint camelcase: 0 */
/* eslint no-unused-vars: 0 */
function buildGetScriptContext (opts) {
// eslint-disable-next-line no-unused-vars
const { makeRequest, ConfigurationError, handleError, snakeCaseKeys } = opts
const acceptedQuerystring = [
'pretty',
'human',
'error_trace',
'source',
'filter_path'
]
const snakeCase = {
errorTrace: 'error_trace',
filterPath: 'filter_path'
}
/**
* Perform a get_script_context request
* Returns all script contexts.
*/
return function getScriptContext (params, options, callback) {
options = options || {}
if (typeof options === 'function') {
callback = options
options = {}
}
if (typeof params === 'function' || params == null) {
callback = params
params = {}
options = {}
}
// validate headers object
if (options.headers != null && typeof options.headers !== 'object') {
const err = new ConfigurationError(`Headers should be an object, instead got: ${typeof options.headers}`)
return handleError(err, callback)
}
var warnings = []
var { method, body, ...querystring } = params
querystring = snakeCaseKeys(acceptedQuerystring, snakeCase, querystring, warnings)
var ignore = options.ignore
if (typeof ignore === 'number') {
options.ignore = [ignore]
}
var path = ''
if (method == null) method = 'GET'
path = '/' + '_script_context'
// build request object
const request = {
method,
path,
body: null,
querystring
}
options.warnings = warnings.length === 0 ? null : warnings
return makeRequest(request, options, callback)
}
}
module.exports = buildGetScriptContext

View File

@ -73,7 +73,7 @@ function buildIndex (opts) {
}
var warnings = []
var { method, body, id, index, type, ...querystring } = params
var { method, body, id, index, ...querystring } = params
querystring = snakeCaseKeys(acceptedQuerystring, snakeCase, querystring, warnings)
var ignore = options.ignore
@ -83,15 +83,9 @@ function buildIndex (opts) {
var path = ''
if ((index) != null && (type) != null && (id) != null) {
if (method == null) method = 'PUT'
path = '/' + encodeURIComponent(index) + '/' + encodeURIComponent(type) + '/' + encodeURIComponent(id)
} else if ((index) != null && (id) != null) {
if ((index) != null && (id) != null) {
if (method == null) method = 'PUT'
path = '/' + encodeURIComponent(index) + '/' + '_doc' + '/' + encodeURIComponent(id)
} else if ((index) != null && (type) != null) {
if (method == null) method = 'POST'
path = '/' + encodeURIComponent(index) + '/' + encodeURIComponent(type)
} else {
if (method == null) method = 'POST'
path = '/' + encodeURIComponent(index) + '/' + '_doc'

View File

@ -0,0 +1,71 @@
// Licensed to Elasticsearch B.V under one or more agreements.
// Elasticsearch B.V licenses this file to you under the Apache 2.0 License.
// See the LICENSE file in the project root for more information
'use strict'
/* eslint camelcase: 0 */
/* eslint no-unused-vars: 0 */
function buildSlmExecuteRetention (opts) {
// eslint-disable-next-line no-unused-vars
const { makeRequest, ConfigurationError, handleError, snakeCaseKeys } = opts
const acceptedQuerystring = [
]
const snakeCase = {
}
/**
* Perform a slm.execute_retention request
* https://www.elastic.co/guide/en/elasticsearch/reference/current/slm-api-execute-retention.html
*/
return function slmExecuteRetention (params, options, callback) {
options = options || {}
if (typeof options === 'function') {
callback = options
options = {}
}
if (typeof params === 'function' || params == null) {
callback = params
params = {}
options = {}
}
// validate headers object
if (options.headers != null && typeof options.headers !== 'object') {
const err = new ConfigurationError(`Headers should be an object, instead got: ${typeof options.headers}`)
return handleError(err, callback)
}
var warnings = []
var { method, body, ...querystring } = params
querystring = snakeCaseKeys(acceptedQuerystring, snakeCase, querystring, warnings)
var ignore = options.ignore
if (typeof ignore === 'number') {
options.ignore = [ignore]
}
var path = ''
if (method == null) method = 'POST'
path = '/' + '_slm' + '/' + '_execute_retention'
// build request object
const request = {
method,
path,
body: body || '',
querystring
}
options.warnings = warnings.length === 0 ? null : warnings
return makeRequest(request, options, callback)
}
}
module.exports = buildSlmExecuteRetention

View File

@ -59,7 +59,7 @@ function buildTransformDeleteTransform (opts) {
var path = ''
if (method == null) method = 'DELETE'
path = '/' + '_data_frame' + '/' + 'transforms' + '/' + encodeURIComponent(transform_id || transformId)
path = '/' + '_transform' + '/' + encodeURIComponent(transform_id || transformId)
// build request object
const request = {

View File

@ -56,10 +56,10 @@ function buildTransformGetTransform (opts) {
if ((transform_id || transformId) != null) {
if (method == null) method = 'GET'
path = '/' + '_data_frame' + '/' + 'transforms' + '/' + encodeURIComponent(transform_id || transformId)
path = '/' + '_transform' + '/' + encodeURIComponent(transform_id || transformId)
} else {
if (method == null) method = 'GET'
path = '/' + '_data_frame' + '/' + 'transforms'
path = '/' + '_transform'
}
// build request object

View File

@ -61,7 +61,7 @@ function buildTransformGetTransformStats (opts) {
var path = ''
if (method == null) method = 'GET'
path = '/' + '_data_frame' + '/' + 'transforms' + '/' + encodeURIComponent(transform_id || transformId) + '/' + '_stats'
path = '/' + '_transform' + '/' + encodeURIComponent(transform_id || transformId) + '/' + '_stats'
// build request object
const request = {

View File

@ -59,7 +59,7 @@ function buildTransformPreviewTransform (opts) {
var path = ''
if (method == null) method = 'POST'
path = '/' + '_data_frame' + '/' + 'transforms' + '/' + '_preview'
path = '/' + '_transform' + '/' + '_preview'
// build request object
const request = {

View File

@ -63,7 +63,7 @@ function buildTransformPutTransform (opts) {
var path = ''
if (method == null) method = 'PUT'
path = '/' + '_data_frame' + '/' + 'transforms' + '/' + encodeURIComponent(transform_id || transformId)
path = '/' + '_transform' + '/' + encodeURIComponent(transform_id || transformId)
// build request object
const request = {

View File

@ -59,7 +59,7 @@ function buildTransformStartTransform (opts) {
var path = ''
if (method == null) method = 'POST'
path = '/' + '_data_frame' + '/' + 'transforms' + '/' + encodeURIComponent(transform_id || transformId) + '/' + '_start'
path = '/' + '_transform' + '/' + encodeURIComponent(transform_id || transformId) + '/' + '_start'
// build request object
const request = {

View File

@ -62,7 +62,7 @@ function buildTransformStopTransform (opts) {
var path = ''
if (method == null) method = 'POST'
path = '/' + '_data_frame' + '/' + 'transforms' + '/' + encodeURIComponent(transform_id || transformId) + '/' + '_stop'
path = '/' + '_transform' + '/' + encodeURIComponent(transform_id || transformId) + '/' + '_stop'
// build request object
const request = {

View File

@ -63,7 +63,7 @@ function buildTransformUpdateTransform (opts) {
var path = ''
if (method == null) method = 'POST'
path = '/' + '_data_frame' + '/' + 'transforms' + '/' + encodeURIComponent(transform_id || transformId) + '/' + '_update'
path = '/' + '_transform' + '/' + encodeURIComponent(transform_id || transformId) + '/' + '_update'
// build request object
const request = {

View File

@ -53,10 +53,14 @@ function ESAPI (opts) {
forgetFollower: lazyLoad('ccr.forget_follower', opts),
get_auto_follow_pattern: lazyLoad('ccr.get_auto_follow_pattern', opts),
getAutoFollowPattern: lazyLoad('ccr.get_auto_follow_pattern', opts),
pause_auto_follow_pattern: lazyLoad('ccr.pause_auto_follow_pattern', opts),
pauseAutoFollowPattern: lazyLoad('ccr.pause_auto_follow_pattern', opts),
pause_follow: lazyLoad('ccr.pause_follow', opts),
pauseFollow: lazyLoad('ccr.pause_follow', opts),
put_auto_follow_pattern: lazyLoad('ccr.put_auto_follow_pattern', opts),
putAutoFollowPattern: lazyLoad('ccr.put_auto_follow_pattern', opts),
resume_auto_follow_pattern: lazyLoad('ccr.resume_auto_follow_pattern', opts),
resumeAutoFollowPattern: lazyLoad('ccr.resume_auto_follow_pattern', opts),
resume_follow: lazyLoad('ccr.resume_follow', opts),
resumeFollow: lazyLoad('ccr.resume_follow', opts),
stats: lazyLoad('ccr.stats', opts),
@ -82,6 +86,42 @@ function ESAPI (opts) {
},
count: lazyLoad('count', opts),
create: lazyLoad('create', opts),
data_frame_transform_deprecated: {
delete_transform: lazyLoad('data_frame_transform_deprecated.delete_transform', opts),
deleteTransform: lazyLoad('data_frame_transform_deprecated.delete_transform', opts),
get_transform: lazyLoad('data_frame_transform_deprecated.get_transform', opts),
getTransform: lazyLoad('data_frame_transform_deprecated.get_transform', opts),
get_transform_stats: lazyLoad('data_frame_transform_deprecated.get_transform_stats', opts),
getTransformStats: lazyLoad('data_frame_transform_deprecated.get_transform_stats', opts),
preview_transform: lazyLoad('data_frame_transform_deprecated.preview_transform', opts),
previewTransform: lazyLoad('data_frame_transform_deprecated.preview_transform', opts),
put_transform: lazyLoad('data_frame_transform_deprecated.put_transform', opts),
putTransform: lazyLoad('data_frame_transform_deprecated.put_transform', opts),
start_transform: lazyLoad('data_frame_transform_deprecated.start_transform', opts),
startTransform: lazyLoad('data_frame_transform_deprecated.start_transform', opts),
stop_transform: lazyLoad('data_frame_transform_deprecated.stop_transform', opts),
stopTransform: lazyLoad('data_frame_transform_deprecated.stop_transform', opts),
update_transform: lazyLoad('data_frame_transform_deprecated.update_transform', opts),
updateTransform: lazyLoad('data_frame_transform_deprecated.update_transform', opts)
},
dataFrameTransformDeprecated: {
delete_transform: lazyLoad('data_frame_transform_deprecated.delete_transform', opts),
deleteTransform: lazyLoad('data_frame_transform_deprecated.delete_transform', opts),
get_transform: lazyLoad('data_frame_transform_deprecated.get_transform', opts),
getTransform: lazyLoad('data_frame_transform_deprecated.get_transform', opts),
get_transform_stats: lazyLoad('data_frame_transform_deprecated.get_transform_stats', opts),
getTransformStats: lazyLoad('data_frame_transform_deprecated.get_transform_stats', opts),
preview_transform: lazyLoad('data_frame_transform_deprecated.preview_transform', opts),
previewTransform: lazyLoad('data_frame_transform_deprecated.preview_transform', opts),
put_transform: lazyLoad('data_frame_transform_deprecated.put_transform', opts),
putTransform: lazyLoad('data_frame_transform_deprecated.put_transform', opts),
start_transform: lazyLoad('data_frame_transform_deprecated.start_transform', opts),
startTransform: lazyLoad('data_frame_transform_deprecated.start_transform', opts),
stop_transform: lazyLoad('data_frame_transform_deprecated.stop_transform', opts),
stopTransform: lazyLoad('data_frame_transform_deprecated.stop_transform', opts),
update_transform: lazyLoad('data_frame_transform_deprecated.update_transform', opts),
updateTransform: lazyLoad('data_frame_transform_deprecated.update_transform', opts)
},
delete: lazyLoad('delete', opts),
delete_by_query: lazyLoad('delete_by_query', opts),
deleteByQuery: lazyLoad('delete_by_query', opts),
@ -89,6 +129,17 @@ function ESAPI (opts) {
deleteByQueryRethrottle: lazyLoad('delete_by_query_rethrottle', opts),
delete_script: lazyLoad('delete_script', opts),
deleteScript: lazyLoad('delete_script', opts),
enrich: {
delete_policy: lazyLoad('enrich.delete_policy', opts),
deletePolicy: lazyLoad('enrich.delete_policy', opts),
execute_policy: lazyLoad('enrich.execute_policy', opts),
executePolicy: lazyLoad('enrich.execute_policy', opts),
get_policy: lazyLoad('enrich.get_policy', opts),
getPolicy: lazyLoad('enrich.get_policy', opts),
put_policy: lazyLoad('enrich.put_policy', opts),
putPolicy: lazyLoad('enrich.put_policy', opts),
stats: lazyLoad('enrich.stats', opts)
},
exists: lazyLoad('exists', opts),
exists_source: lazyLoad('exists_source', opts),
existsSource: lazyLoad('exists_source', opts),
@ -98,6 +149,8 @@ function ESAPI (opts) {
get: lazyLoad('get', opts),
get_script: lazyLoad('get_script', opts),
getScript: lazyLoad('get_script', opts),
get_script_context: lazyLoad('get_script_context', opts),
getScriptContext: lazyLoad('get_script_context', opts),
get_source: lazyLoad('get_source', opts),
getSource: lazyLoad('get_source', opts),
graph: {
@ -433,6 +486,8 @@ function ESAPI (opts) {
deleteLifecycle: lazyLoad('slm.delete_lifecycle', opts),
execute_lifecycle: lazyLoad('slm.execute_lifecycle', opts),
executeLifecycle: lazyLoad('slm.execute_lifecycle', opts),
execute_retention: lazyLoad('slm.execute_retention', opts),
executeRetention: lazyLoad('slm.execute_retention', opts),
get_lifecycle: lazyLoad('slm.get_lifecycle', opts),
getLifecycle: lazyLoad('slm.get_lifecycle', opts),
get_stats: lazyLoad('slm.get_stats', opts),

106
api/requestParams.d.ts vendored
View File

@ -32,7 +32,6 @@ export interface CatAliases extends Generic {
name?: string | string[];
format?: string;
local?: boolean;
master_timeout?: string;
h?: string | string[];
help?: boolean;
s?: string | string[];
@ -54,8 +53,6 @@ export interface CatAllocation extends Generic {
export interface CatCount extends Generic {
index?: string | string[];
format?: string;
local?: boolean;
master_timeout?: string;
h?: string | string[];
help?: boolean;
s?: string | string[];
@ -66,8 +63,6 @@ export interface CatFielddata extends Generic {
fields?: string | string[];
format?: string;
bytes?: 'b' | 'k' | 'kb' | 'm' | 'mb' | 'g' | 'gb' | 't' | 'tb' | 'p' | 'pb';
local?: boolean;
master_timeout?: string;
h?: string | string[];
help?: boolean;
s?: string | string[];
@ -76,11 +71,10 @@ export interface CatFielddata extends Generic {
export interface CatHealth extends Generic {
format?: string;
local?: boolean;
master_timeout?: string;
h?: string | string[];
help?: boolean;
s?: string | string[];
time?: 'd (Days)' | 'h (Hours)' | 'm (Minutes)' | 's (Seconds)' | 'ms (Milliseconds)' | 'micros (Microseconds)' | 'nanos (Nanoseconds)';
ts?: boolean;
v?: boolean;
}
@ -101,6 +95,7 @@ export interface CatIndices extends Generic {
help?: boolean;
pri?: boolean;
s?: string | string[];
time?: 'd (Days)' | 'h (Hours)' | 'm (Minutes)' | 's (Seconds)' | 'ms (Milliseconds)' | 'micros (Microseconds)' | 'nanos (Nanoseconds)';
v?: boolean;
include_unloaded_segments?: boolean;
}
@ -126,6 +121,7 @@ export interface CatNodeattrs extends Generic {
}
export interface CatNodes extends Generic {
bytes?: 'b' | 'k' | 'kb' | 'm' | 'mb' | 'g' | 'gb' | 't' | 'tb' | 'p' | 'pb';
format?: string;
full_id?: boolean;
local?: boolean;
@ -133,6 +129,7 @@ export interface CatNodes extends Generic {
h?: string | string[];
help?: boolean;
s?: string | string[];
time?: 'd (Days)' | 'h (Hours)' | 'm (Minutes)' | 's (Seconds)' | 'ms (Milliseconds)' | 'micros (Microseconds)' | 'nanos (Nanoseconds)';
v?: boolean;
}
@ -143,6 +140,7 @@ export interface CatPendingTasks extends Generic {
h?: string | string[];
help?: boolean;
s?: string | string[];
time?: 'd (Days)' | 'h (Hours)' | 'm (Minutes)' | 's (Seconds)' | 'ms (Milliseconds)' | 'micros (Microseconds)' | 'nanos (Nanoseconds)';
v?: boolean;
}
@ -162,10 +160,10 @@ export interface CatRecovery extends Generic {
active_only?: boolean;
bytes?: 'b' | 'k' | 'kb' | 'm' | 'mb' | 'g' | 'gb' | 't' | 'tb' | 'p' | 'pb';
detailed?: boolean;
master_timeout?: string;
h?: string | string[];
help?: boolean;
s?: string | string[];
time?: 'd (Days)' | 'h (Hours)' | 'm (Minutes)' | 's (Seconds)' | 'ms (Milliseconds)' | 'micros (Microseconds)' | 'nanos (Nanoseconds)';
v?: boolean;
}
@ -198,6 +196,7 @@ export interface CatShards extends Generic {
h?: string | string[];
help?: boolean;
s?: string | string[];
time?: 'd (Days)' | 'h (Hours)' | 'm (Minutes)' | 's (Seconds)' | 'ms (Milliseconds)' | 'micros (Microseconds)' | 'nanos (Nanoseconds)';
v?: boolean;
}
@ -209,6 +208,7 @@ export interface CatSnapshots extends Generic {
h?: string | string[];
help?: boolean;
s?: string | string[];
time?: 'd (Days)' | 'h (Hours)' | 'm (Minutes)' | 's (Seconds)' | 'ms (Milliseconds)' | 'micros (Microseconds)' | 'nanos (Nanoseconds)';
v?: boolean;
}
@ -221,6 +221,7 @@ export interface CatTasks extends Generic {
h?: string | string[];
help?: boolean;
s?: string | string[];
time?: 'd (Days)' | 'h (Hours)' | 'm (Minutes)' | 's (Seconds)' | 'ms (Milliseconds)' | 'micros (Microseconds)' | 'nanos (Nanoseconds)';
v?: boolean;
}
@ -352,7 +353,7 @@ export interface Create<T = any> extends Generic {
routing?: string;
timeout?: string;
version?: number;
version_type?: 'internal' | 'external' | 'external_gte' | 'force';
version_type?: 'internal' | 'external' | 'external_gte';
pipeline?: string;
body: T;
}
@ -506,6 +507,9 @@ export interface GetScript extends Generic {
master_timeout?: string;
}
export interface GetScriptContext extends Generic {
}
export interface GetSource extends Generic {
id: string;
index: string;
@ -525,14 +529,13 @@ export interface GetSource extends Generic {
export interface Index<T = any> extends Generic {
id?: string;
index: string;
type?: string;
wait_for_active_shards?: string;
op_type?: 'index' | 'create';
refresh?: 'true' | 'false' | 'wait_for';
routing?: string;
timeout?: string;
version?: number;
version_type?: 'internal' | 'external' | 'external_gte' | 'force';
version_type?: 'internal' | 'external' | 'external_gte';
if_seq_no?: number;
if_primary_term?: number;
pipeline?: string;
@ -1349,6 +1352,10 @@ export interface CcrGetAutoFollowPattern extends Generic {
name?: string;
}
export interface CcrPauseAutoFollowPattern extends Generic {
name: string;
}
export interface CcrPauseFollow extends Generic {
index: string;
}
@ -1358,6 +1365,10 @@ export interface CcrPutAutoFollowPattern<T = any> extends Generic {
body: T;
}
export interface CcrResumeAutoFollowPattern extends Generic {
name: string;
}
export interface CcrResumeFollow<T = any> extends Generic {
index: string;
body?: T;
@ -1370,6 +1381,74 @@ export interface CcrUnfollow extends Generic {
index: string;
}
export interface DataFrameTransformDeprecatedDeleteTransform extends Generic {
transform_id: string;
force?: boolean;
}
export interface DataFrameTransformDeprecatedGetTransform extends Generic {
transform_id?: string;
from?: number;
size?: number;
allow_no_match?: boolean;
}
export interface DataFrameTransformDeprecatedGetTransformStats extends Generic {
transform_id: string;
from?: number;
size?: number;
allow_no_match?: boolean;
}
export interface DataFrameTransformDeprecatedPreviewTransform<T = any> extends Generic {
body: T;
}
export interface DataFrameTransformDeprecatedPutTransform<T = any> extends Generic {
transform_id: string;
defer_validation?: boolean;
body: T;
}
export interface DataFrameTransformDeprecatedStartTransform extends Generic {
transform_id: string;
timeout?: string;
}
export interface DataFrameTransformDeprecatedStopTransform extends Generic {
transform_id: string;
wait_for_completion?: boolean;
timeout?: string;
allow_no_match?: boolean;
}
export interface DataFrameTransformDeprecatedUpdateTransform<T = any> extends Generic {
transform_id: string;
defer_validation?: boolean;
body: T;
}
export interface EnrichDeletePolicy extends Generic {
name: string;
}
export interface EnrichExecutePolicy extends Generic {
name: string;
wait_for_completion?: boolean;
}
export interface EnrichGetPolicy extends Generic {
name?: string;
}
export interface EnrichPutPolicy<T = any> extends Generic {
name: string;
body: T;
}
export interface EnrichStats extends Generic {
}
export interface GraphExplore<T = any> extends Generic {
index: string | string[];
routing?: string;
@ -2005,8 +2084,11 @@ export interface SlmExecuteLifecycle extends Generic {
policy_id: string;
}
export interface SlmExecuteRetention extends Generic {
}
export interface SlmGetLifecycle extends Generic {
policy_id?: string;
policy_id?: string | string[];
}
export interface SlmGetStats extends Generic {

View File

@ -133,7 +133,6 @@ client.cat.aliases({
name: string | string[],
format: string,
local: boolean,
master_timeout: string,
h: string | string[],
help: boolean,
s: string | string[],
@ -152,9 +151,6 @@ link:{ref}/cat-alias.html[Reference]
|`local`
|`boolean` - Return local information, do not retrieve the state from master node (default: false)
|`master_timeout` or `masterTimeout`
|`string` - Explicit operation timeout for connection to master node
|`h`
|`string \| string[]` - Comma-separated list of column names to display
@ -224,8 +220,6 @@ link:{ref}/cat-allocation.html[Reference]
client.cat.count({
index: string | string[],
format: string,
local: boolean,
master_timeout: string,
h: string | string[],
help: boolean,
s: string | string[],
@ -241,12 +235,6 @@ link:{ref}/cat-count.html[Reference]
|`format`
|`string` - a short version of the Accept header, e.g. json, yaml
|`local`
|`boolean` - Return local information, do not retrieve the state from master node (default: false)
|`master_timeout` or `masterTimeout`
|`string` - Explicit operation timeout for connection to master node
|`h`
|`string \| string[]` - Comma-separated list of column names to display
@ -269,8 +257,6 @@ client.cat.fielddata({
fields: string | string[],
format: string,
bytes: 'b' | 'k' | 'kb' | 'm' | 'mb' | 'g' | 'gb' | 't' | 'tb' | 'p' | 'pb',
local: boolean,
master_timeout: string,
h: string | string[],
help: boolean,
s: string | string[],
@ -289,12 +275,6 @@ link:{ref}/cat-fielddata.html[Reference]
|`bytes`
|`'b' \| 'k' \| 'kb' \| 'm' \| 'mb' \| 'g' \| 'gb' \| 't' \| 'tb' \| 'p' \| 'pb'` - The unit in which to display byte values
|`local`
|`boolean` - Return local information, do not retrieve the state from master node (default: false)
|`master_timeout` or `masterTimeout`
|`string` - Explicit operation timeout for connection to master node
|`h`
|`string \| string[]` - Comma-separated list of column names to display
@ -315,11 +295,10 @@ link:{ref}/cat-fielddata.html[Reference]
----
client.cat.health({
format: string,
local: boolean,
master_timeout: string,
h: string | string[],
help: boolean,
s: string | string[],
time: 'd (Days)' | 'h (Hours)' | 'm (Minutes)' | 's (Seconds)' | 'ms (Milliseconds)' | 'micros (Microseconds)' | 'nanos (Nanoseconds)',
ts: boolean,
v: boolean
})
@ -330,12 +309,6 @@ link:{ref}/cat-health.html[Reference]
|`format`
|`string` - a short version of the Accept header, e.g. json, yaml
|`local`
|`boolean` - Return local information, do not retrieve the state from master node (default: false)
|`master_timeout` or `masterTimeout`
|`string` - Explicit operation timeout for connection to master node
|`h`
|`string \| string[]` - Comma-separated list of column names to display
@ -345,6 +318,9 @@ link:{ref}/cat-health.html[Reference]
|`s`
|`string \| string[]` - Comma-separated list of column names or column aliases to sort by
|`time`
|`'d (Days)' \| 'h (Hours)' \| 'm (Minutes)' \| 's (Seconds)' \| 'ms (Milliseconds)' \| 'micros (Microseconds)' \| 'nanos (Nanoseconds)'` - The unit in which to display time values
|`ts`
|`boolean` - Set to false to disable timestamping +
_Default:_ `true`
@ -389,6 +365,7 @@ client.cat.indices({
help: boolean,
pri: boolean,
s: string | string[],
time: 'd (Days)' | 'h (Hours)' | 'm (Minutes)' | 's (Seconds)' | 'ms (Milliseconds)' | 'micros (Microseconds)' | 'nanos (Nanoseconds)',
v: boolean,
include_unloaded_segments: boolean
})
@ -426,6 +403,9 @@ link:{ref}/cat-indices.html[Reference]
|`s`
|`string \| string[]` - Comma-separated list of column names or column aliases to sort by
|`time`
|`'d (Days)' \| 'h (Hours)' \| 'm (Minutes)' \| 's (Seconds)' \| 'ms (Milliseconds)' \| 'micros (Microseconds)' \| 'nanos (Nanoseconds)'` - The unit in which to display time values
|`v`
|`boolean` - Verbose mode. Display column headers
@ -519,6 +499,7 @@ link:{ref}/cat-nodeattrs.html[Reference]
[source,ts]
----
client.cat.nodes({
bytes: 'b' | 'k' | 'kb' | 'm' | 'mb' | 'g' | 'gb' | 't' | 'tb' | 'p' | 'pb',
format: string,
full_id: boolean,
local: boolean,
@ -526,12 +507,16 @@ client.cat.nodes({
h: string | string[],
help: boolean,
s: string | string[],
time: 'd (Days)' | 'h (Hours)' | 'm (Minutes)' | 's (Seconds)' | 'ms (Milliseconds)' | 'micros (Microseconds)' | 'nanos (Nanoseconds)',
v: boolean
})
----
link:{ref}/cat-nodes.html[Reference]
[cols=2*]
|===
|`bytes`
|`'b' \| 'k' \| 'kb' \| 'm' \| 'mb' \| 'g' \| 'gb' \| 't' \| 'tb' \| 'p' \| 'pb'` - The unit in which to display byte values
|`format`
|`string` - a short version of the Accept header, e.g. json, yaml
@ -553,6 +538,9 @@ link:{ref}/cat-nodes.html[Reference]
|`s`
|`string \| string[]` - Comma-separated list of column names or column aliases to sort by
|`time`
|`'d (Days)' \| 'h (Hours)' \| 'm (Minutes)' \| 's (Seconds)' \| 'ms (Milliseconds)' \| 'micros (Microseconds)' \| 'nanos (Nanoseconds)'` - The unit in which to display time values
|`v`
|`boolean` - Verbose mode. Display column headers
@ -569,6 +557,7 @@ client.cat.pendingTasks({
h: string | string[],
help: boolean,
s: string | string[],
time: 'd (Days)' | 'h (Hours)' | 'm (Minutes)' | 's (Seconds)' | 'ms (Milliseconds)' | 'micros (Microseconds)' | 'nanos (Nanoseconds)',
v: boolean
})
----
@ -593,6 +582,9 @@ link:{ref}/cat-pending-tasks.html[Reference]
|`s`
|`string \| string[]` - Comma-separated list of column names or column aliases to sort by
|`time`
|`'d (Days)' \| 'h (Hours)' \| 'm (Minutes)' \| 's (Seconds)' \| 'ms (Milliseconds)' \| 'micros (Microseconds)' \| 'nanos (Nanoseconds)'` - The unit in which to display time values
|`v`
|`boolean` - Verbose mode. Display column headers
@ -648,10 +640,10 @@ client.cat.recovery({
active_only: boolean,
bytes: 'b' | 'k' | 'kb' | 'm' | 'mb' | 'g' | 'gb' | 't' | 'tb' | 'p' | 'pb',
detailed: boolean,
master_timeout: string,
h: string | string[],
help: boolean,
s: string | string[],
time: 'd (Days)' | 'h (Hours)' | 'm (Minutes)' | 's (Seconds)' | 'ms (Milliseconds)' | 'micros (Microseconds)' | 'nanos (Nanoseconds)',
v: boolean
})
----
@ -673,9 +665,6 @@ link:{ref}/cat-recovery.html[Reference]
|`detailed`
|`boolean` - If `true`, the response includes detailed information about shard recoveries
|`master_timeout` or `masterTimeout`
|`string` - Explicit operation timeout for connection to master node
|`h`
|`string \| string[]` - Comma-separated list of column names to display
@ -685,6 +674,9 @@ link:{ref}/cat-recovery.html[Reference]
|`s`
|`string \| string[]` - Comma-separated list of column names or column aliases to sort by
|`time`
|`'d (Days)' \| 'h (Hours)' \| 'm (Minutes)' \| 's (Seconds)' \| 'ms (Milliseconds)' \| 'micros (Microseconds)' \| 'nanos (Nanoseconds)'` - The unit in which to display time values
|`v`
|`boolean` - Verbose mode. Display column headers
@ -783,6 +775,7 @@ client.cat.shards({
h: string | string[],
help: boolean,
s: string | string[],
time: 'd (Days)' | 'h (Hours)' | 'm (Minutes)' | 's (Seconds)' | 'ms (Milliseconds)' | 'micros (Microseconds)' | 'nanos (Nanoseconds)',
v: boolean
})
----
@ -813,6 +806,9 @@ link:{ref}/cat-shards.html[Reference]
|`s`
|`string \| string[]` - Comma-separated list of column names or column aliases to sort by
|`time`
|`'d (Days)' \| 'h (Hours)' \| 'm (Minutes)' \| 's (Seconds)' \| 'ms (Milliseconds)' \| 'micros (Microseconds)' \| 'nanos (Nanoseconds)'` - The unit in which to display time values
|`v`
|`boolean` - Verbose mode. Display column headers
@ -830,6 +826,7 @@ client.cat.snapshots({
h: string | string[],
help: boolean,
s: string | string[],
time: 'd (Days)' | 'h (Hours)' | 'm (Minutes)' | 's (Seconds)' | 'ms (Milliseconds)' | 'micros (Microseconds)' | 'nanos (Nanoseconds)',
v: boolean
})
----
@ -857,6 +854,9 @@ link:{ref}/cat-snapshots.html[Reference]
|`s`
|`string \| string[]` - Comma-separated list of column names or column aliases to sort by
|`time`
|`'d (Days)' \| 'h (Hours)' \| 'm (Minutes)' \| 's (Seconds)' \| 'ms (Milliseconds)' \| 'micros (Microseconds)' \| 'nanos (Nanoseconds)'` - The unit in which to display time values
|`v`
|`boolean` - Verbose mode. Display column headers
@ -875,6 +875,7 @@ client.cat.tasks({
h: string | string[],
help: boolean,
s: string | string[],
time: 'd (Days)' | 'h (Hours)' | 'm (Minutes)' | 's (Seconds)' | 'ms (Milliseconds)' | 'micros (Microseconds)' | 'nanos (Nanoseconds)',
v: boolean
})
----
@ -905,6 +906,9 @@ link:{ref}/tasks.html[Reference]
|`s`
|`string \| string[]` - Comma-separated list of column names or column aliases to sort by
|`time`
|`'d (Days)' \| 'h (Hours)' \| 'm (Minutes)' \| 's (Seconds)' \| 'ms (Milliseconds)' \| 'micros (Microseconds)' \| 'nanos (Nanoseconds)'` - The unit in which to display time values
|`v`
|`boolean` - Verbose mode. Display column headers
@ -1403,7 +1407,7 @@ client.create({
routing: string,
timeout: string,
version: number,
version_type: 'internal' | 'external' | 'external_gte' | 'force',
version_type: 'internal' | 'external' | 'external_gte',
pipeline: string,
body: object
})
@ -1438,7 +1442,7 @@ WARNING: This parameter has been deprecated.
|`number` - Explicit version number for concurrency control
|`version_type` or `versionType`
|`'internal' \| 'external' \| 'external_gte' \| 'force'` - Specific version type
|`'internal' \| 'external' \| 'external_gte'` - Specific version type
|`pipeline`
|`string` - The pipeline id to preprocess incoming documents with
@ -2016,6 +2020,14 @@ link:{ref}/modules-scripting.html[Reference]
|===
=== getScriptContext
*Stability:* experimental
[source,ts]
----
client.getScriptContext()
----
=== getSource
[source,ts]
@ -2079,14 +2091,13 @@ link:{ref}/docs-get.html[Reference]
client.index({
id: string,
index: string,
type: string,
wait_for_active_shards: string,
op_type: 'index' | 'create',
refresh: 'true' | 'false' | 'wait_for',
routing: string,
timeout: string,
version: number,
version_type: 'internal' | 'external' | 'external_gte' | 'force',
version_type: 'internal' | 'external' | 'external_gte',
if_seq_no: number,
if_primary_term: number,
pipeline: string,
@ -2102,17 +2113,11 @@ link:{ref}/docs-index_.html[Reference]
|`index`
|`string` - The name of the index
|`type`
|`string` - The type of the document +
WARNING: This parameter has been deprecated.
|`wait_for_active_shards` or `waitForActiveShards`
|`string` - Sets the number of shard copies that must be active before proceeding with the index operation. Defaults to 1, meaning the primary shard only. Set to `all` for all shard copies, otherwise set to any non-negative value less than or equal to the total number of copies for the shard (number of replicas + 1)
|`op_type` or `opType`
|`'index' \| 'create'` - Explicit operation type +
_Default:_ `index`
|`'index' \| 'create'` - Explicit operation type. Defaults to `index` for requests with an explicit document ID, and to `create`for requests without an explicit document ID
|`refresh`
|`'true' \| 'false' \| 'wait_for'` - If `true` then refresh the affected shards to make this operation visible to search, if `wait_for` then wait for a refresh to make this operation visible to search, if `false` (the default) then do nothing with refreshes.
@ -2127,7 +2132,7 @@ _Default:_ `index`
|`number` - Explicit version number for concurrency control
|`version_type` or `versionType`
|`'internal' \| 'external' \| 'external_gte' \| 'force'` - Specific version type
|`'internal' \| 'external' \| 'external_gte'` - Specific version type
|`if_seq_no` or `ifSeqNo`
|`number` - only perform the index operation if the last operation that has changed the document has the specified sequence number
@ -5412,6 +5417,22 @@ link:{ref}/ccr-get-auto-follow-pattern.html[Reference]
|===
=== ccr.pauseAutoFollowPattern
[source,ts]
----
client.ccr.pauseAutoFollowPattern({
name: string
})
----
link:{ref}/ccr-pause-auto-follow-pattern.html[Reference]
[cols=2*]
|===
|`name`
|`string` - The name of the auto follow pattern that should pause discovering new indices to follow.
|===
=== ccr.pauseFollow
[source,ts]
@ -5448,6 +5469,22 @@ link:{ref}/ccr-put-auto-follow-pattern.html[Reference]
|===
=== ccr.resumeAutoFollowPattern
[source,ts]
----
client.ccr.resumeAutoFollowPattern({
name: string
})
----
link:{ref}/ccr-resume-auto-follow-pattern.html[Reference]
[cols=2*]
|===
|`name`
|`string` - The name of the auto follow pattern to resume discovering new indices to follow.
|===
=== ccr.resumeFollow
[source,ts]
@ -5493,6 +5530,271 @@ link:http://www.elastic.co/guide/en/elasticsearch/reference/current[Reference]
|===
=== dataFrameTransformDeprecated.deleteTransform
*Stability:* beta
[source,ts]
----
client.dataFrameTransformDeprecated.deleteTransform({
transform_id: string,
force: boolean
})
----
link:{ref}/delete-transform.html[Reference]
[cols=2*]
|===
|`transform_id` or `transformId`
|`string` - The id of the transform to delete
|`force`
|`boolean` - When `true`, the transform is deleted regardless of its current state. The default value is `false`, meaning that the transform must be `stopped` before it can be deleted.
|===
=== dataFrameTransformDeprecated.getTransform
*Stability:* beta
[source,ts]
----
client.dataFrameTransformDeprecated.getTransform({
transform_id: string,
from: number,
size: number,
allow_no_match: boolean
})
----
link:{ref}/get-transform.html[Reference]
[cols=2*]
|===
|`transform_id` or `transformId`
|`string` - The id or comma delimited list of id expressions of the transforms to get, '_all' or '*' implies get all transforms
|`from`
|`number` - skips a number of transform configs, defaults to 0
|`size`
|`number` - specifies a max number of transforms to get, defaults to 100
|`allow_no_match` or `allowNoMatch`
|`boolean` - Whether to ignore if a wildcard expression matches no transforms. (This includes `_all` string or when no transforms have been specified)
|===
=== dataFrameTransformDeprecated.getTransformStats
*Stability:* beta
[source,ts]
----
client.dataFrameTransformDeprecated.getTransformStats({
transform_id: string,
from: number,
size: number,
allow_no_match: boolean
})
----
link:{ref}/get-transform-stats.html[Reference]
[cols=2*]
|===
|`transform_id` or `transformId`
|`string` - The id of the transform for which to get stats. '_all' or '*' implies all transforms
|`from`
|`number` - skips a number of transform stats, defaults to 0
|`size`
|`number` - specifies a max number of transform stats to get, defaults to 100
|`allow_no_match` or `allowNoMatch`
|`boolean` - Whether to ignore if a wildcard expression matches no transforms. (This includes `_all` string or when no transforms have been specified)
|===
=== dataFrameTransformDeprecated.previewTransform
*Stability:* beta
[source,ts]
----
client.dataFrameTransformDeprecated.previewTransform({
body: object
})
----
link:{ref}/preview-transform.html[Reference]
[cols=2*]
|===
|`body`
|`object` - The definition for the transform to preview
|===
=== dataFrameTransformDeprecated.putTransform
*Stability:* beta
[source,ts]
----
client.dataFrameTransformDeprecated.putTransform({
transform_id: string,
defer_validation: boolean,
body: object
})
----
link:{ref}/put-transform.html[Reference]
[cols=2*]
|===
|`transform_id` or `transformId`
|`string` - The id of the new transform.
|`defer_validation` or `deferValidation`
|`boolean` - If validations should be deferred until transform starts, defaults to false.
|`body`
|`object` - The transform definition
|===
=== dataFrameTransformDeprecated.startTransform
*Stability:* beta
[source,ts]
----
client.dataFrameTransformDeprecated.startTransform({
transform_id: string,
timeout: string
})
----
link:{ref}/start-transform.html[Reference]
[cols=2*]
|===
|`transform_id` or `transformId`
|`string` - The id of the transform to start
|`timeout`
|`string` - Controls the time to wait for the transform to start
|===
=== dataFrameTransformDeprecated.stopTransform
*Stability:* beta
[source,ts]
----
client.dataFrameTransformDeprecated.stopTransform({
transform_id: string,
wait_for_completion: boolean,
timeout: string,
allow_no_match: boolean
})
----
link:{ref}/stop-transform.html[Reference]
[cols=2*]
|===
|`transform_id` or `transformId`
|`string` - The id of the transform to stop
|`wait_for_completion` or `waitForCompletion`
|`boolean` - Whether to wait for the transform to fully stop before returning or not. Default to false
|`timeout`
|`string` - Controls the time to wait until the transform has stopped. Default to 30 seconds
|`allow_no_match` or `allowNoMatch`
|`boolean` - Whether to ignore if a wildcard expression matches no transforms. (This includes `_all` string or when no transforms have been specified)
|===
=== dataFrameTransformDeprecated.updateTransform
*Stability:* beta
[source,ts]
----
client.dataFrameTransformDeprecated.updateTransform({
transform_id: string,
defer_validation: boolean,
body: object
})
----
link:{ref}/update-transform.html[Reference]
[cols=2*]
|===
|`transform_id` or `transformId`
|`string` - The id of the transform.
|`defer_validation` or `deferValidation`
|`boolean` - If validations should be deferred until transform starts, defaults to false.
|`body`
|`object` - The update transform definition
|===
=== enrich.deletePolicy
[source,ts]
----
client.enrich.deletePolicy({
name: string
})
----
[cols=2*]
|===
|`name`
|`string` - The name of the enrich policy
|===
=== enrich.executePolicy
[source,ts]
----
client.enrich.executePolicy({
name: string,
wait_for_completion: boolean
})
----
[cols=2*]
|===
|`name`
|`string` - The name of the enrich policy
|`wait_for_completion` or `waitForCompletion`
|`boolean` - Should the request should block until the execution is complete. +
_Default:_ `true`
|===
=== enrich.getPolicy
[source,ts]
----
client.enrich.getPolicy({
name: string
})
----
[cols=2*]
|===
|`name`
|`string` - The name of the enrich policy
|===
=== enrich.putPolicy
[source,ts]
----
client.enrich.putPolicy({
name: string,
body: object
})
----
[cols=2*]
|===
|`name`
|`string` - The name of the enrich policy
|`body`
|`object` - The enrich policy to register
|===
=== enrich.stats
[source,ts]
----
client.enrich.stats()
----
=== graph.explore
[source,ts]
@ -7990,19 +8292,28 @@ link:{ref}/slm-api-execute.html[Reference]
|===
=== slm.executeRetention
[source,ts]
----
client.slm.executeRetention()
----
link:{ref}/slm-api-execute-retention.html[Reference]
=== slm.getLifecycle
[source,ts]
----
client.slm.getLifecycle({
policy_id: string
policy_id: string | string[]
})
----
link:{ref}/slm-api-get.html[Reference]
[cols=2*]
|===
|`policy_id` or `policyId`
|`string` - Comma-separated list of snapshot lifecycle policies to retrieve
|`string \| string[]` - Comma-separated list of snapshot lifecycle policies to retrieve
|===

55
index.d.ts vendored
View File

@ -151,10 +151,14 @@ declare class Client extends EventEmitter {
forgetFollower: ApiMethod<RequestParams.CcrForgetFollower>
get_auto_follow_pattern: ApiMethod<RequestParams.CcrGetAutoFollowPattern>
getAutoFollowPattern: ApiMethod<RequestParams.CcrGetAutoFollowPattern>
pause_auto_follow_pattern: ApiMethod<RequestParams.CcrPauseAutoFollowPattern>
pauseAutoFollowPattern: ApiMethod<RequestParams.CcrPauseAutoFollowPattern>
pause_follow: ApiMethod<RequestParams.CcrPauseFollow>
pauseFollow: ApiMethod<RequestParams.CcrPauseFollow>
put_auto_follow_pattern: ApiMethod<RequestParams.CcrPutAutoFollowPattern>
putAutoFollowPattern: ApiMethod<RequestParams.CcrPutAutoFollowPattern>
resume_auto_follow_pattern: ApiMethod<RequestParams.CcrResumeAutoFollowPattern>
resumeAutoFollowPattern: ApiMethod<RequestParams.CcrResumeAutoFollowPattern>
resume_follow: ApiMethod<RequestParams.CcrResumeFollow>
resumeFollow: ApiMethod<RequestParams.CcrResumeFollow>
stats: ApiMethod<RequestParams.CcrStats>
@ -180,6 +184,42 @@ declare class Client extends EventEmitter {
}
count: ApiMethod<RequestParams.Count>
create: ApiMethod<RequestParams.Create>
data_frame_transform_deprecated: {
delete_transform: ApiMethod<RequestParams.DataFrameTransformDeprecatedDeleteTransform>
deleteTransform: ApiMethod<RequestParams.DataFrameTransformDeprecatedDeleteTransform>
get_transform: ApiMethod<RequestParams.DataFrameTransformDeprecatedGetTransform>
getTransform: ApiMethod<RequestParams.DataFrameTransformDeprecatedGetTransform>
get_transform_stats: ApiMethod<RequestParams.DataFrameTransformDeprecatedGetTransformStats>
getTransformStats: ApiMethod<RequestParams.DataFrameTransformDeprecatedGetTransformStats>
preview_transform: ApiMethod<RequestParams.DataFrameTransformDeprecatedPreviewTransform>
previewTransform: ApiMethod<RequestParams.DataFrameTransformDeprecatedPreviewTransform>
put_transform: ApiMethod<RequestParams.DataFrameTransformDeprecatedPutTransform>
putTransform: ApiMethod<RequestParams.DataFrameTransformDeprecatedPutTransform>
start_transform: ApiMethod<RequestParams.DataFrameTransformDeprecatedStartTransform>
startTransform: ApiMethod<RequestParams.DataFrameTransformDeprecatedStartTransform>
stop_transform: ApiMethod<RequestParams.DataFrameTransformDeprecatedStopTransform>
stopTransform: ApiMethod<RequestParams.DataFrameTransformDeprecatedStopTransform>
update_transform: ApiMethod<RequestParams.DataFrameTransformDeprecatedUpdateTransform>
updateTransform: ApiMethod<RequestParams.DataFrameTransformDeprecatedUpdateTransform>
}
dataFrameTransformDeprecated: {
delete_transform: ApiMethod<RequestParams.DataFrameTransformDeprecatedDeleteTransform>
deleteTransform: ApiMethod<RequestParams.DataFrameTransformDeprecatedDeleteTransform>
get_transform: ApiMethod<RequestParams.DataFrameTransformDeprecatedGetTransform>
getTransform: ApiMethod<RequestParams.DataFrameTransformDeprecatedGetTransform>
get_transform_stats: ApiMethod<RequestParams.DataFrameTransformDeprecatedGetTransformStats>
getTransformStats: ApiMethod<RequestParams.DataFrameTransformDeprecatedGetTransformStats>
preview_transform: ApiMethod<RequestParams.DataFrameTransformDeprecatedPreviewTransform>
previewTransform: ApiMethod<RequestParams.DataFrameTransformDeprecatedPreviewTransform>
put_transform: ApiMethod<RequestParams.DataFrameTransformDeprecatedPutTransform>
putTransform: ApiMethod<RequestParams.DataFrameTransformDeprecatedPutTransform>
start_transform: ApiMethod<RequestParams.DataFrameTransformDeprecatedStartTransform>
startTransform: ApiMethod<RequestParams.DataFrameTransformDeprecatedStartTransform>
stop_transform: ApiMethod<RequestParams.DataFrameTransformDeprecatedStopTransform>
stopTransform: ApiMethod<RequestParams.DataFrameTransformDeprecatedStopTransform>
update_transform: ApiMethod<RequestParams.DataFrameTransformDeprecatedUpdateTransform>
updateTransform: ApiMethod<RequestParams.DataFrameTransformDeprecatedUpdateTransform>
}
delete: ApiMethod<RequestParams.Delete>
delete_by_query: ApiMethod<RequestParams.DeleteByQuery>
deleteByQuery: ApiMethod<RequestParams.DeleteByQuery>
@ -187,6 +227,17 @@ declare class Client extends EventEmitter {
deleteByQueryRethrottle: ApiMethod<RequestParams.DeleteByQueryRethrottle>
delete_script: ApiMethod<RequestParams.DeleteScript>
deleteScript: ApiMethod<RequestParams.DeleteScript>
enrich: {
delete_policy: ApiMethod<RequestParams.EnrichDeletePolicy>
deletePolicy: ApiMethod<RequestParams.EnrichDeletePolicy>
execute_policy: ApiMethod<RequestParams.EnrichExecutePolicy>
executePolicy: ApiMethod<RequestParams.EnrichExecutePolicy>
get_policy: ApiMethod<RequestParams.EnrichGetPolicy>
getPolicy: ApiMethod<RequestParams.EnrichGetPolicy>
put_policy: ApiMethod<RequestParams.EnrichPutPolicy>
putPolicy: ApiMethod<RequestParams.EnrichPutPolicy>
stats: ApiMethod<RequestParams.EnrichStats>
}
exists: ApiMethod<RequestParams.Exists>
exists_source: ApiMethod<RequestParams.ExistsSource>
existsSource: ApiMethod<RequestParams.ExistsSource>
@ -196,6 +247,8 @@ declare class Client extends EventEmitter {
get: ApiMethod<RequestParams.Get>
get_script: ApiMethod<RequestParams.GetScript>
getScript: ApiMethod<RequestParams.GetScript>
get_script_context: ApiMethod<RequestParams.GetScriptContext>
getScriptContext: ApiMethod<RequestParams.GetScriptContext>
get_source: ApiMethod<RequestParams.GetSource>
getSource: ApiMethod<RequestParams.GetSource>
graph: {
@ -531,6 +584,8 @@ declare class Client extends EventEmitter {
deleteLifecycle: ApiMethod<RequestParams.SlmDeleteLifecycle>
execute_lifecycle: ApiMethod<RequestParams.SlmExecuteLifecycle>
executeLifecycle: ApiMethod<RequestParams.SlmExecuteLifecycle>
execute_retention: ApiMethod<RequestParams.SlmExecuteRetention>
executeRetention: ApiMethod<RequestParams.SlmExecuteRetention>
get_lifecycle: ApiMethod<RequestParams.SlmGetLifecycle>
getLifecycle: ApiMethod<RequestParams.SlmGetLifecycle>
get_stats: ApiMethod<RequestParams.SlmGetStats>