import { Transport , TransportRequestOptions , TransportRequestOptionsWithMeta , TransportRequestOptionsWithOutMeta , TransportResult } from '@elastic/transport' ; import * as T from '../types' ; import * as TB from '../typesWithBodyKey' ; interface That { transport : Transport ; } export default class License { transport : Transport ; constructor ( transport ) { this . transport = transport ; } async delete ( this , params ? , options ? ) ; async delete ( this , params ? , options ? ) ; async delete ( this , params ? , options ? ) ; async delete ( this , params ? , options ? ) { const acceptedPath = [ ] ; const querystring = { } ; 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 = 'DELETE' ; const path = '/_license' ; return await this . transport . request ( { path , method , querystring , body } , options ) ; } async get ( this , params ? , options ? ) ; async get ( this , params ? , options ? ) ; async get ( this , params ? , options ? ) ; async get ( this , params ? , options ? ) { const acceptedPath = [ ] ; const querystring = { } ; 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 = 'GET' ; const path = '/_license' ; return await this . transport . request ( { path , method , querystring , body } , options ) ; } async getBasicStatus ( this , params ? , options ? ) ; async getBasicStatus ( this , params ? , options ? ) ; async getBasicStatus ( this , params ? , options ? ) ; async getBasicStatus ( this , params ? , options ? ) { const acceptedPath = [ ] ; const querystring = { } ; 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 = 'GET' ; const path = '/_license/basic_status' ; return await this . transport . request ( { path , method , querystring , body } , options ) ; } async getTrialStatus ( this , params ? , options ? ) ; async getTrialStatus ( this , params ? , options ? ) ; async getTrialStatus ( this , params ? , options ? ) ; async getTrialStatus ( this , params ? , options ? ) { const acceptedPath = [ ] ; const querystring = { } ; 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 = 'GET' ; const path = '/_license/trial_status' ; return await this . transport . request ( { path , method , querystring , body } , options ) ; } async post ( this , params , options ? ) ; async post ( this , params , options ? ) ; async post ( this , params , options ? ) ; async post ( this , params , options ? ) { const acceptedPath = [ ] ; const acceptedBody = [ 'license' , 'licenses' ] ; const querystring = { } ; const userBody = params ?. body ; let body ; if ( typeof userBody === 'string' ) { body = userBody ; } else { body = userBody != null ? { ... userBody } : undefined ; } for ( const key in params ) { if ( acceptedBody . includes ( key ) ) { body = body ?? { } ; body [ key ] = params [ key ] ; } else if ( acceptedPath . includes ( key ) ) { continue ; } else if ( key !== 'body' ) { querystring [ key ] = params [ key ] ; } } const method = 'PUT' ; const path = '/_license' ; return await this . transport . request ( { path , method , querystring , body } , options ) ; } async postStartBasic ( this , params ? , options ? ) ; async postStartBasic ( this , params ? , options ? ) ; async postStartBasic ( this , params ? , options ? ) ; async postStartBasic ( this , params ? , options ? ) { const acceptedPath = [ ] ; const querystring = { } ; 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 = '/_license/start_basic' ; return await this . transport . request ( { path , method , querystring , body } , options ) ; } async postStartTrial ( this , params ? , options ? ) ; async postStartTrial ( this , params ? , options ? ) ; async postStartTrial ( this , params ? , options ? ) ; async postStartTrial ( this , params ? , options ? ) { const acceptedPath = [ ] ; const querystring = { } ; 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 = '/_license/start_trial' ; return await this . transport . request ( { path , method , querystring , body } , options ) ; } }