API generation
This commit is contained in:
@ -524,7 +524,9 @@ MlApi.prototype.findFileStructure = function mlFindFileStructureApi (params, opt
|
||||
let { method, body, ...querystring } = params
|
||||
querystring = snakeCaseKeys(acceptedQuerystring, snakeCase, querystring)
|
||||
|
||||
const path = ''
|
||||
let path = ''
|
||||
if (method == null) method = 'POST'
|
||||
path = '/' + '_ml' + '/' + 'find_file_structure'
|
||||
|
||||
// build request object
|
||||
const request = {
|
||||
@ -1176,7 +1178,7 @@ MlApi.prototype.postData = function mlPostDataApi (params, options, callback) {
|
||||
const request = {
|
||||
method,
|
||||
path,
|
||||
body: body || '',
|
||||
bulkBody: body,
|
||||
querystring
|
||||
}
|
||||
|
||||
|
||||
@ -56,7 +56,7 @@ MonitoringApi.prototype.bulk = function monitoringBulkApi (params, options, call
|
||||
const request = {
|
||||
method,
|
||||
path,
|
||||
bulkBody: body,
|
||||
body: body || '',
|
||||
querystring
|
||||
}
|
||||
|
||||
|
||||
@ -51,7 +51,7 @@ TextStructureApi.prototype.findStructure = function textStructureFindStructureAp
|
||||
const request = {
|
||||
method,
|
||||
path,
|
||||
body: body || '',
|
||||
bulkBody: body,
|
||||
querystring
|
||||
}
|
||||
|
||||
|
||||
6
api/requestParams.d.ts
vendored
6
api/requestParams.d.ts
vendored
@ -1786,7 +1786,7 @@ export interface MlPostCalendarEvents<T = RequestBody> extends Generic {
|
||||
body: T;
|
||||
}
|
||||
|
||||
export interface MlPostData<T = RequestBody> extends Generic {
|
||||
export interface MlPostData<T = RequestNDBody> extends Generic {
|
||||
job_id: string;
|
||||
reset_start?: string;
|
||||
reset_end?: string;
|
||||
@ -1936,7 +1936,7 @@ export interface MlValidateDetector<T = RequestBody> extends Generic {
|
||||
body: T;
|
||||
}
|
||||
|
||||
export interface MonitoringBulk<T = RequestNDBody> extends Generic {
|
||||
export interface MonitoringBulk<T = RequestBody> extends Generic {
|
||||
type?: string;
|
||||
system_id?: string;
|
||||
system_api_version?: string;
|
||||
@ -2560,7 +2560,7 @@ export interface Termvectors<T = RequestBody> extends Generic {
|
||||
body?: T;
|
||||
}
|
||||
|
||||
export interface TextStructureFindStructure<T = RequestBody> extends Generic {
|
||||
export interface TextStructureFindStructure<T = RequestNDBody> extends Generic {
|
||||
lines_to_sample?: number;
|
||||
line_merge_size_limit?: number;
|
||||
timeout?: string;
|
||||
|
||||
Reference in New Issue
Block a user