/* tslint:disable */ /* eslint-disable */ /** * Tapis Workflows API * Create and manage pipelines * * The version of the OpenAPI document: 1.6.0 * Contact: cicsupport@tacc.utexas.edu * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech * Do not edit the class manually. */ import * as runtime from '../runtime'; import { ReqCreateETLPipeline, ReqCreateETLPipelineFromJSON, ReqCreateETLPipelineToJSON, RespError, RespErrorFromJSON, RespErrorToJSON, RespResourceURL, RespResourceURLFromJSON, RespResourceURLToJSON, } from '../models'; export interface CreateETLPipelineRequest { groupId: string; reqCreateETLPipeline: ReqCreateETLPipeline; } /** * */ export class ETLApi extends runtime.BaseAPI { /** * Convenience endpoint for create ETL pipelines in the Tapis ecosystem. * Create an ETL pipeline */ async createETLPipelineRaw(requestParameters: CreateETLPipelineRequest, initOverrides?: RequestInit): Promise> { if (requestParameters.groupId === null || requestParameters.groupId === undefined) { throw new runtime.RequiredError('groupId','Required parameter requestParameters.groupId was null or undefined when calling createETLPipeline.'); } if (requestParameters.reqCreateETLPipeline === null || requestParameters.reqCreateETLPipeline === undefined) { throw new runtime.RequiredError('reqCreateETLPipeline','Required parameter requestParameters.reqCreateETLPipeline was null or undefined when calling createETLPipeline.'); } const queryParameters: any = {}; const headerParameters: runtime.HTTPHeaders = {}; headerParameters['Content-Type'] = 'application/json'; if (this.configuration && this.configuration.apiKey) { headerParameters["X-TAPIS-TOKEN"] = this.configuration.apiKey("X-TAPIS-TOKEN"); // TapisJWT authentication } const response = await this.request({ path: `/v3/workflows/beta/groups/{group_id}/etl`.replace(`{${"group_id"}}`, encodeURIComponent(String(requestParameters.groupId))), method: 'POST', headers: headerParameters, query: queryParameters, body: ReqCreateETLPipelineToJSON(requestParameters.reqCreateETLPipeline), }, initOverrides); return new runtime.JSONApiResponse(response, (jsonValue) => RespResourceURLFromJSON(jsonValue)); } /** * Convenience endpoint for create ETL pipelines in the Tapis ecosystem. * Create an ETL pipeline */ async createETLPipeline(requestParameters: CreateETLPipelineRequest, initOverrides?: RequestInit): Promise { const response = await this.createETLPipelineRaw(requestParameters, initOverrides); return await response.value(); } }