diff --git a/modules/openapi-generator/src/main/resources/typescript-angular/api.service.mustache b/modules/openapi-generator/src/main/resources/typescript-angular/api.service.mustache index 9e070e3616bb..8d3e07949f5e 100644 --- a/modules/openapi-generator/src/main/resources/typescript-angular/api.service.mustache +++ b/modules/openapi-generator/src/main/resources/typescript-angular/api.service.mustache @@ -334,9 +334,17 @@ export class {{classname}} { } {{/isResponseFile}} - return this.httpClient.{{httpMethod}}{{^isResponseFile}}<{{#returnType}}{{{returnType}}}{{#isResponseTypeFile}}|undefined{{/isResponseTypeFile}}{{/returnType}}{{^returnType}}any{{/returnType}}>{{/isResponseFile}}(`${this.configuration.basePath}{{{path}}}`,{{#isBodyAllowed}} - {{#bodyParam}}{{paramName}}{{/bodyParam}}{{^bodyParam}}{{#hasFormParams}}convertFormParamsToString ? formParams.toString() : formParams{{/hasFormParams}}{{^hasFormParams}}null{{/hasFormParams}}{{/bodyParam}},{{/isBodyAllowed}} + return this.httpClient.request{{^isResponseFile}}<{{#returnType}}{{{returnType}}}{{#isResponseTypeFile}}|undefined{{/isResponseTypeFile}}{{/returnType}}{{^returnType}}any{{/returnType}}>{{/isResponseFile}}('{{httpMethod}}', + `${this.configuration.basePath}{{{path}}}`, { + {{#hasBodyParam}} + body: {{#bodyParam}}{{paramName}}{{/bodyParam}}, + {{/hasBodyParam}} + {{^hasBodyParam}} + {{#hasFormParams}} + body: convertFormParamsToString ? formParams.toString() : formParams, + {{/hasFormParams}} + {{/hasBodyParam}} {{#hasQueryParams}} params: queryParameters, {{/hasQueryParams}} diff --git a/samples/client/petstore/typescript-angular-v10-provided-in-root/builds/default/api/pet.service.ts b/samples/client/petstore/typescript-angular-v10-provided-in-root/builds/default/api/pet.service.ts index 46fef0be89fe..0c3bc22a4f25 100644 --- a/samples/client/petstore/typescript-angular-v10-provided-in-root/builds/default/api/pet.service.ts +++ b/samples/client/petstore/typescript-angular-v10-provided-in-root/builds/default/api/pet.service.ts @@ -148,9 +148,10 @@ export class PetService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/pet`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/pet`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -204,7 +205,8 @@ export class PetService { responseType = 'text'; } - return this.httpClient.delete(`${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, + return this.httpClient.request('delete', + `${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -264,7 +266,8 @@ export class PetService { responseType = 'text'; } - return this.httpClient.get>(`${this.configuration.basePath}/pet/findByStatus`, + return this.httpClient.request>('get', + `${this.configuration.basePath}/pet/findByStatus`, { params: queryParameters, responseType: responseType, @@ -326,7 +329,8 @@ export class PetService { responseType = 'text'; } - return this.httpClient.get>(`${this.configuration.basePath}/pet/findByTags`, + return this.httpClient.request>('get', + `${this.configuration.basePath}/pet/findByTags`, { params: queryParameters, responseType: responseType, @@ -381,7 +385,8 @@ export class PetService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, + return this.httpClient.request('get', + `${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -442,9 +447,10 @@ export class PetService { responseType = 'text'; } - return this.httpClient.put(`${this.configuration.basePath}/pet`, - body, + return this.httpClient.request('put', + `${this.configuration.basePath}/pet`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -518,9 +524,10 @@ export class PetService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, - convertFormParamsToString ? formParams.toString() : formParams, + return this.httpClient.request('post', + `${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, { + body: convertFormParamsToString ? formParams.toString() : formParams, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -598,9 +605,10 @@ export class PetService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}/uploadImage`, - convertFormParamsToString ? formParams.toString() : formParams, + return this.httpClient.request('post', + `${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}/uploadImage`, { + body: convertFormParamsToString ? formParams.toString() : formParams, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, diff --git a/samples/client/petstore/typescript-angular-v10-provided-in-root/builds/default/api/store.service.ts b/samples/client/petstore/typescript-angular-v10-provided-in-root/builds/default/api/store.service.ts index d5d08ab3adc3..ef2a1d848b03 100644 --- a/samples/client/petstore/typescript-angular-v10-provided-in-root/builds/default/api/store.service.ts +++ b/samples/client/petstore/typescript-angular-v10-provided-in-root/builds/default/api/store.service.ts @@ -118,7 +118,8 @@ export class StoreService { responseType = 'text'; } - return this.httpClient.delete(`${this.configuration.basePath}/store/order/${encodeURIComponent(String(orderId))}`, + return this.httpClient.request('delete', + `${this.configuration.basePath}/store/order/${encodeURIComponent(String(orderId))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -167,7 +168,8 @@ export class StoreService { responseType = 'text'; } - return this.httpClient.get<{ [key: string]: number; }>(`${this.configuration.basePath}/store/inventory`, + return this.httpClient.request<{ [key: string]: number; }>('get', + `${this.configuration.basePath}/store/inventory`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -214,7 +216,8 @@ export class StoreService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/store/order/${encodeURIComponent(String(orderId))}`, + return this.httpClient.request('get', + `${this.configuration.basePath}/store/order/${encodeURIComponent(String(orderId))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -268,9 +271,10 @@ export class StoreService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/store/order`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/store/order`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, diff --git a/samples/client/petstore/typescript-angular-v10-provided-in-root/builds/default/api/user.service.ts b/samples/client/petstore/typescript-angular-v10-provided-in-root/builds/default/api/user.service.ts index 399676219054..9cd1a2482604 100644 --- a/samples/client/petstore/typescript-angular-v10-provided-in-root/builds/default/api/user.service.ts +++ b/samples/client/petstore/typescript-angular-v10-provided-in-root/builds/default/api/user.service.ts @@ -126,9 +126,10 @@ export class UserService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/user`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/user`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -179,9 +180,10 @@ export class UserService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/user/createWithArray`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/user/createWithArray`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -232,9 +234,10 @@ export class UserService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/user/createWithList`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/user/createWithList`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -278,7 +281,8 @@ export class UserService { responseType = 'text'; } - return this.httpClient.delete(`${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, + return this.httpClient.request('delete', + `${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -324,7 +328,8 @@ export class UserService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, + return this.httpClient.request('get', + `${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -384,7 +389,8 @@ export class UserService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/user/login`, + return this.httpClient.request('get', + `${this.configuration.basePath}/user/login`, { params: queryParameters, responseType: responseType, @@ -425,7 +431,8 @@ export class UserService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/user/logout`, + return this.httpClient.request('get', + `${this.configuration.basePath}/user/logout`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -482,9 +489,10 @@ export class UserService { responseType = 'text'; } - return this.httpClient.put(`${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, - body, + return this.httpClient.request('put', + `${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, diff --git a/samples/client/petstore/typescript-angular-v10-provided-in-root/builds/with-npm/api/pet.service.ts b/samples/client/petstore/typescript-angular-v10-provided-in-root/builds/with-npm/api/pet.service.ts index 46fef0be89fe..0c3bc22a4f25 100644 --- a/samples/client/petstore/typescript-angular-v10-provided-in-root/builds/with-npm/api/pet.service.ts +++ b/samples/client/petstore/typescript-angular-v10-provided-in-root/builds/with-npm/api/pet.service.ts @@ -148,9 +148,10 @@ export class PetService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/pet`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/pet`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -204,7 +205,8 @@ export class PetService { responseType = 'text'; } - return this.httpClient.delete(`${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, + return this.httpClient.request('delete', + `${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -264,7 +266,8 @@ export class PetService { responseType = 'text'; } - return this.httpClient.get>(`${this.configuration.basePath}/pet/findByStatus`, + return this.httpClient.request>('get', + `${this.configuration.basePath}/pet/findByStatus`, { params: queryParameters, responseType: responseType, @@ -326,7 +329,8 @@ export class PetService { responseType = 'text'; } - return this.httpClient.get>(`${this.configuration.basePath}/pet/findByTags`, + return this.httpClient.request>('get', + `${this.configuration.basePath}/pet/findByTags`, { params: queryParameters, responseType: responseType, @@ -381,7 +385,8 @@ export class PetService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, + return this.httpClient.request('get', + `${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -442,9 +447,10 @@ export class PetService { responseType = 'text'; } - return this.httpClient.put(`${this.configuration.basePath}/pet`, - body, + return this.httpClient.request('put', + `${this.configuration.basePath}/pet`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -518,9 +524,10 @@ export class PetService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, - convertFormParamsToString ? formParams.toString() : formParams, + return this.httpClient.request('post', + `${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, { + body: convertFormParamsToString ? formParams.toString() : formParams, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -598,9 +605,10 @@ export class PetService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}/uploadImage`, - convertFormParamsToString ? formParams.toString() : formParams, + return this.httpClient.request('post', + `${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}/uploadImage`, { + body: convertFormParamsToString ? formParams.toString() : formParams, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, diff --git a/samples/client/petstore/typescript-angular-v10-provided-in-root/builds/with-npm/api/store.service.ts b/samples/client/petstore/typescript-angular-v10-provided-in-root/builds/with-npm/api/store.service.ts index d5d08ab3adc3..ef2a1d848b03 100644 --- a/samples/client/petstore/typescript-angular-v10-provided-in-root/builds/with-npm/api/store.service.ts +++ b/samples/client/petstore/typescript-angular-v10-provided-in-root/builds/with-npm/api/store.service.ts @@ -118,7 +118,8 @@ export class StoreService { responseType = 'text'; } - return this.httpClient.delete(`${this.configuration.basePath}/store/order/${encodeURIComponent(String(orderId))}`, + return this.httpClient.request('delete', + `${this.configuration.basePath}/store/order/${encodeURIComponent(String(orderId))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -167,7 +168,8 @@ export class StoreService { responseType = 'text'; } - return this.httpClient.get<{ [key: string]: number; }>(`${this.configuration.basePath}/store/inventory`, + return this.httpClient.request<{ [key: string]: number; }>('get', + `${this.configuration.basePath}/store/inventory`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -214,7 +216,8 @@ export class StoreService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/store/order/${encodeURIComponent(String(orderId))}`, + return this.httpClient.request('get', + `${this.configuration.basePath}/store/order/${encodeURIComponent(String(orderId))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -268,9 +271,10 @@ export class StoreService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/store/order`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/store/order`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, diff --git a/samples/client/petstore/typescript-angular-v10-provided-in-root/builds/with-npm/api/user.service.ts b/samples/client/petstore/typescript-angular-v10-provided-in-root/builds/with-npm/api/user.service.ts index 399676219054..9cd1a2482604 100644 --- a/samples/client/petstore/typescript-angular-v10-provided-in-root/builds/with-npm/api/user.service.ts +++ b/samples/client/petstore/typescript-angular-v10-provided-in-root/builds/with-npm/api/user.service.ts @@ -126,9 +126,10 @@ export class UserService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/user`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/user`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -179,9 +180,10 @@ export class UserService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/user/createWithArray`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/user/createWithArray`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -232,9 +234,10 @@ export class UserService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/user/createWithList`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/user/createWithList`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -278,7 +281,8 @@ export class UserService { responseType = 'text'; } - return this.httpClient.delete(`${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, + return this.httpClient.request('delete', + `${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -324,7 +328,8 @@ export class UserService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, + return this.httpClient.request('get', + `${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -384,7 +389,8 @@ export class UserService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/user/login`, + return this.httpClient.request('get', + `${this.configuration.basePath}/user/login`, { params: queryParameters, responseType: responseType, @@ -425,7 +431,8 @@ export class UserService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/user/logout`, + return this.httpClient.request('get', + `${this.configuration.basePath}/user/logout`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -482,9 +489,10 @@ export class UserService { responseType = 'text'; } - return this.httpClient.put(`${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, - body, + return this.httpClient.request('put', + `${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, diff --git a/samples/client/petstore/typescript-angular-v6-not-provided-in-root/builds/default/api/pet.service.ts b/samples/client/petstore/typescript-angular-v6-not-provided-in-root/builds/default/api/pet.service.ts index c6125084a2d6..53b471535391 100644 --- a/samples/client/petstore/typescript-angular-v6-not-provided-in-root/builds/default/api/pet.service.ts +++ b/samples/client/petstore/typescript-angular-v6-not-provided-in-root/builds/default/api/pet.service.ts @@ -146,9 +146,10 @@ export class PetService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/pet`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/pet`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -202,7 +203,8 @@ export class PetService { responseType = 'text'; } - return this.httpClient.delete(`${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, + return this.httpClient.request('delete', + `${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -262,7 +264,8 @@ export class PetService { responseType = 'text'; } - return this.httpClient.get>(`${this.configuration.basePath}/pet/findByStatus`, + return this.httpClient.request>('get', + `${this.configuration.basePath}/pet/findByStatus`, { params: queryParameters, responseType: responseType, @@ -324,7 +327,8 @@ export class PetService { responseType = 'text'; } - return this.httpClient.get>(`${this.configuration.basePath}/pet/findByTags`, + return this.httpClient.request>('get', + `${this.configuration.basePath}/pet/findByTags`, { params: queryParameters, responseType: responseType, @@ -379,7 +383,8 @@ export class PetService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, + return this.httpClient.request('get', + `${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -440,9 +445,10 @@ export class PetService { responseType = 'text'; } - return this.httpClient.put(`${this.configuration.basePath}/pet`, - body, + return this.httpClient.request('put', + `${this.configuration.basePath}/pet`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -516,9 +522,10 @@ export class PetService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, - convertFormParamsToString ? formParams.toString() : formParams, + return this.httpClient.request('post', + `${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, { + body: convertFormParamsToString ? formParams.toString() : formParams, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -596,9 +603,10 @@ export class PetService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}/uploadImage`, - convertFormParamsToString ? formParams.toString() : formParams, + return this.httpClient.request('post', + `${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}/uploadImage`, { + body: convertFormParamsToString ? formParams.toString() : formParams, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, diff --git a/samples/client/petstore/typescript-angular-v6-not-provided-in-root/builds/default/api/store.service.ts b/samples/client/petstore/typescript-angular-v6-not-provided-in-root/builds/default/api/store.service.ts index a6065292a6db..e652b176b147 100644 --- a/samples/client/petstore/typescript-angular-v6-not-provided-in-root/builds/default/api/store.service.ts +++ b/samples/client/petstore/typescript-angular-v6-not-provided-in-root/builds/default/api/store.service.ts @@ -116,7 +116,8 @@ export class StoreService { responseType = 'text'; } - return this.httpClient.delete(`${this.configuration.basePath}/store/order/${encodeURIComponent(String(orderId))}`, + return this.httpClient.request('delete', + `${this.configuration.basePath}/store/order/${encodeURIComponent(String(orderId))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -165,7 +166,8 @@ export class StoreService { responseType = 'text'; } - return this.httpClient.get<{ [key: string]: number; }>(`${this.configuration.basePath}/store/inventory`, + return this.httpClient.request<{ [key: string]: number; }>('get', + `${this.configuration.basePath}/store/inventory`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -212,7 +214,8 @@ export class StoreService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/store/order/${encodeURIComponent(String(orderId))}`, + return this.httpClient.request('get', + `${this.configuration.basePath}/store/order/${encodeURIComponent(String(orderId))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -266,9 +269,10 @@ export class StoreService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/store/order`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/store/order`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, diff --git a/samples/client/petstore/typescript-angular-v6-not-provided-in-root/builds/default/api/user.service.ts b/samples/client/petstore/typescript-angular-v6-not-provided-in-root/builds/default/api/user.service.ts index da1199c86d45..93b8aa396d41 100644 --- a/samples/client/petstore/typescript-angular-v6-not-provided-in-root/builds/default/api/user.service.ts +++ b/samples/client/petstore/typescript-angular-v6-not-provided-in-root/builds/default/api/user.service.ts @@ -124,9 +124,10 @@ export class UserService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/user`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/user`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -177,9 +178,10 @@ export class UserService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/user/createWithArray`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/user/createWithArray`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -230,9 +232,10 @@ export class UserService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/user/createWithList`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/user/createWithList`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -276,7 +279,8 @@ export class UserService { responseType = 'text'; } - return this.httpClient.delete(`${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, + return this.httpClient.request('delete', + `${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -322,7 +326,8 @@ export class UserService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, + return this.httpClient.request('get', + `${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -382,7 +387,8 @@ export class UserService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/user/login`, + return this.httpClient.request('get', + `${this.configuration.basePath}/user/login`, { params: queryParameters, responseType: responseType, @@ -423,7 +429,8 @@ export class UserService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/user/logout`, + return this.httpClient.request('get', + `${this.configuration.basePath}/user/logout`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -480,9 +487,10 @@ export class UserService { responseType = 'text'; } - return this.httpClient.put(`${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, - body, + return this.httpClient.request('put', + `${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, diff --git a/samples/client/petstore/typescript-angular-v6-not-provided-in-root/builds/with-npm/api/pet.service.ts b/samples/client/petstore/typescript-angular-v6-not-provided-in-root/builds/with-npm/api/pet.service.ts index c6125084a2d6..53b471535391 100644 --- a/samples/client/petstore/typescript-angular-v6-not-provided-in-root/builds/with-npm/api/pet.service.ts +++ b/samples/client/petstore/typescript-angular-v6-not-provided-in-root/builds/with-npm/api/pet.service.ts @@ -146,9 +146,10 @@ export class PetService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/pet`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/pet`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -202,7 +203,8 @@ export class PetService { responseType = 'text'; } - return this.httpClient.delete(`${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, + return this.httpClient.request('delete', + `${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -262,7 +264,8 @@ export class PetService { responseType = 'text'; } - return this.httpClient.get>(`${this.configuration.basePath}/pet/findByStatus`, + return this.httpClient.request>('get', + `${this.configuration.basePath}/pet/findByStatus`, { params: queryParameters, responseType: responseType, @@ -324,7 +327,8 @@ export class PetService { responseType = 'text'; } - return this.httpClient.get>(`${this.configuration.basePath}/pet/findByTags`, + return this.httpClient.request>('get', + `${this.configuration.basePath}/pet/findByTags`, { params: queryParameters, responseType: responseType, @@ -379,7 +383,8 @@ export class PetService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, + return this.httpClient.request('get', + `${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -440,9 +445,10 @@ export class PetService { responseType = 'text'; } - return this.httpClient.put(`${this.configuration.basePath}/pet`, - body, + return this.httpClient.request('put', + `${this.configuration.basePath}/pet`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -516,9 +522,10 @@ export class PetService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, - convertFormParamsToString ? formParams.toString() : formParams, + return this.httpClient.request('post', + `${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, { + body: convertFormParamsToString ? formParams.toString() : formParams, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -596,9 +603,10 @@ export class PetService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}/uploadImage`, - convertFormParamsToString ? formParams.toString() : formParams, + return this.httpClient.request('post', + `${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}/uploadImage`, { + body: convertFormParamsToString ? formParams.toString() : formParams, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, diff --git a/samples/client/petstore/typescript-angular-v6-not-provided-in-root/builds/with-npm/api/store.service.ts b/samples/client/petstore/typescript-angular-v6-not-provided-in-root/builds/with-npm/api/store.service.ts index a6065292a6db..e652b176b147 100644 --- a/samples/client/petstore/typescript-angular-v6-not-provided-in-root/builds/with-npm/api/store.service.ts +++ b/samples/client/petstore/typescript-angular-v6-not-provided-in-root/builds/with-npm/api/store.service.ts @@ -116,7 +116,8 @@ export class StoreService { responseType = 'text'; } - return this.httpClient.delete(`${this.configuration.basePath}/store/order/${encodeURIComponent(String(orderId))}`, + return this.httpClient.request('delete', + `${this.configuration.basePath}/store/order/${encodeURIComponent(String(orderId))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -165,7 +166,8 @@ export class StoreService { responseType = 'text'; } - return this.httpClient.get<{ [key: string]: number; }>(`${this.configuration.basePath}/store/inventory`, + return this.httpClient.request<{ [key: string]: number; }>('get', + `${this.configuration.basePath}/store/inventory`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -212,7 +214,8 @@ export class StoreService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/store/order/${encodeURIComponent(String(orderId))}`, + return this.httpClient.request('get', + `${this.configuration.basePath}/store/order/${encodeURIComponent(String(orderId))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -266,9 +269,10 @@ export class StoreService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/store/order`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/store/order`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, diff --git a/samples/client/petstore/typescript-angular-v6-not-provided-in-root/builds/with-npm/api/user.service.ts b/samples/client/petstore/typescript-angular-v6-not-provided-in-root/builds/with-npm/api/user.service.ts index da1199c86d45..93b8aa396d41 100644 --- a/samples/client/petstore/typescript-angular-v6-not-provided-in-root/builds/with-npm/api/user.service.ts +++ b/samples/client/petstore/typescript-angular-v6-not-provided-in-root/builds/with-npm/api/user.service.ts @@ -124,9 +124,10 @@ export class UserService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/user`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/user`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -177,9 +178,10 @@ export class UserService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/user/createWithArray`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/user/createWithArray`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -230,9 +232,10 @@ export class UserService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/user/createWithList`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/user/createWithList`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -276,7 +279,8 @@ export class UserService { responseType = 'text'; } - return this.httpClient.delete(`${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, + return this.httpClient.request('delete', + `${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -322,7 +326,8 @@ export class UserService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, + return this.httpClient.request('get', + `${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -382,7 +387,8 @@ export class UserService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/user/login`, + return this.httpClient.request('get', + `${this.configuration.basePath}/user/login`, { params: queryParameters, responseType: responseType, @@ -423,7 +429,8 @@ export class UserService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/user/logout`, + return this.httpClient.request('get', + `${this.configuration.basePath}/user/logout`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -480,9 +487,10 @@ export class UserService { responseType = 'text'; } - return this.httpClient.put(`${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, - body, + return this.httpClient.request('put', + `${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, diff --git a/samples/client/petstore/typescript-angular-v6-provided-in-root/builds/default/api/pet.service.ts b/samples/client/petstore/typescript-angular-v6-provided-in-root/builds/default/api/pet.service.ts index 46fef0be89fe..0c3bc22a4f25 100644 --- a/samples/client/petstore/typescript-angular-v6-provided-in-root/builds/default/api/pet.service.ts +++ b/samples/client/petstore/typescript-angular-v6-provided-in-root/builds/default/api/pet.service.ts @@ -148,9 +148,10 @@ export class PetService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/pet`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/pet`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -204,7 +205,8 @@ export class PetService { responseType = 'text'; } - return this.httpClient.delete(`${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, + return this.httpClient.request('delete', + `${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -264,7 +266,8 @@ export class PetService { responseType = 'text'; } - return this.httpClient.get>(`${this.configuration.basePath}/pet/findByStatus`, + return this.httpClient.request>('get', + `${this.configuration.basePath}/pet/findByStatus`, { params: queryParameters, responseType: responseType, @@ -326,7 +329,8 @@ export class PetService { responseType = 'text'; } - return this.httpClient.get>(`${this.configuration.basePath}/pet/findByTags`, + return this.httpClient.request>('get', + `${this.configuration.basePath}/pet/findByTags`, { params: queryParameters, responseType: responseType, @@ -381,7 +385,8 @@ export class PetService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, + return this.httpClient.request('get', + `${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -442,9 +447,10 @@ export class PetService { responseType = 'text'; } - return this.httpClient.put(`${this.configuration.basePath}/pet`, - body, + return this.httpClient.request('put', + `${this.configuration.basePath}/pet`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -518,9 +524,10 @@ export class PetService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, - convertFormParamsToString ? formParams.toString() : formParams, + return this.httpClient.request('post', + `${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, { + body: convertFormParamsToString ? formParams.toString() : formParams, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -598,9 +605,10 @@ export class PetService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}/uploadImage`, - convertFormParamsToString ? formParams.toString() : formParams, + return this.httpClient.request('post', + `${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}/uploadImage`, { + body: convertFormParamsToString ? formParams.toString() : formParams, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, diff --git a/samples/client/petstore/typescript-angular-v6-provided-in-root/builds/default/api/store.service.ts b/samples/client/petstore/typescript-angular-v6-provided-in-root/builds/default/api/store.service.ts index d5d08ab3adc3..ef2a1d848b03 100644 --- a/samples/client/petstore/typescript-angular-v6-provided-in-root/builds/default/api/store.service.ts +++ b/samples/client/petstore/typescript-angular-v6-provided-in-root/builds/default/api/store.service.ts @@ -118,7 +118,8 @@ export class StoreService { responseType = 'text'; } - return this.httpClient.delete(`${this.configuration.basePath}/store/order/${encodeURIComponent(String(orderId))}`, + return this.httpClient.request('delete', + `${this.configuration.basePath}/store/order/${encodeURIComponent(String(orderId))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -167,7 +168,8 @@ export class StoreService { responseType = 'text'; } - return this.httpClient.get<{ [key: string]: number; }>(`${this.configuration.basePath}/store/inventory`, + return this.httpClient.request<{ [key: string]: number; }>('get', + `${this.configuration.basePath}/store/inventory`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -214,7 +216,8 @@ export class StoreService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/store/order/${encodeURIComponent(String(orderId))}`, + return this.httpClient.request('get', + `${this.configuration.basePath}/store/order/${encodeURIComponent(String(orderId))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -268,9 +271,10 @@ export class StoreService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/store/order`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/store/order`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, diff --git a/samples/client/petstore/typescript-angular-v6-provided-in-root/builds/default/api/user.service.ts b/samples/client/petstore/typescript-angular-v6-provided-in-root/builds/default/api/user.service.ts index 399676219054..9cd1a2482604 100644 --- a/samples/client/petstore/typescript-angular-v6-provided-in-root/builds/default/api/user.service.ts +++ b/samples/client/petstore/typescript-angular-v6-provided-in-root/builds/default/api/user.service.ts @@ -126,9 +126,10 @@ export class UserService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/user`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/user`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -179,9 +180,10 @@ export class UserService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/user/createWithArray`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/user/createWithArray`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -232,9 +234,10 @@ export class UserService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/user/createWithList`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/user/createWithList`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -278,7 +281,8 @@ export class UserService { responseType = 'text'; } - return this.httpClient.delete(`${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, + return this.httpClient.request('delete', + `${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -324,7 +328,8 @@ export class UserService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, + return this.httpClient.request('get', + `${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -384,7 +389,8 @@ export class UserService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/user/login`, + return this.httpClient.request('get', + `${this.configuration.basePath}/user/login`, { params: queryParameters, responseType: responseType, @@ -425,7 +431,8 @@ export class UserService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/user/logout`, + return this.httpClient.request('get', + `${this.configuration.basePath}/user/logout`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -482,9 +489,10 @@ export class UserService { responseType = 'text'; } - return this.httpClient.put(`${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, - body, + return this.httpClient.request('put', + `${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, diff --git a/samples/client/petstore/typescript-angular-v6-provided-in-root/builds/with-npm/api/pet.service.ts b/samples/client/petstore/typescript-angular-v6-provided-in-root/builds/with-npm/api/pet.service.ts index 46fef0be89fe..0c3bc22a4f25 100644 --- a/samples/client/petstore/typescript-angular-v6-provided-in-root/builds/with-npm/api/pet.service.ts +++ b/samples/client/petstore/typescript-angular-v6-provided-in-root/builds/with-npm/api/pet.service.ts @@ -148,9 +148,10 @@ export class PetService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/pet`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/pet`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -204,7 +205,8 @@ export class PetService { responseType = 'text'; } - return this.httpClient.delete(`${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, + return this.httpClient.request('delete', + `${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -264,7 +266,8 @@ export class PetService { responseType = 'text'; } - return this.httpClient.get>(`${this.configuration.basePath}/pet/findByStatus`, + return this.httpClient.request>('get', + `${this.configuration.basePath}/pet/findByStatus`, { params: queryParameters, responseType: responseType, @@ -326,7 +329,8 @@ export class PetService { responseType = 'text'; } - return this.httpClient.get>(`${this.configuration.basePath}/pet/findByTags`, + return this.httpClient.request>('get', + `${this.configuration.basePath}/pet/findByTags`, { params: queryParameters, responseType: responseType, @@ -381,7 +385,8 @@ export class PetService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, + return this.httpClient.request('get', + `${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -442,9 +447,10 @@ export class PetService { responseType = 'text'; } - return this.httpClient.put(`${this.configuration.basePath}/pet`, - body, + return this.httpClient.request('put', + `${this.configuration.basePath}/pet`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -518,9 +524,10 @@ export class PetService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, - convertFormParamsToString ? formParams.toString() : formParams, + return this.httpClient.request('post', + `${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, { + body: convertFormParamsToString ? formParams.toString() : formParams, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -598,9 +605,10 @@ export class PetService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}/uploadImage`, - convertFormParamsToString ? formParams.toString() : formParams, + return this.httpClient.request('post', + `${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}/uploadImage`, { + body: convertFormParamsToString ? formParams.toString() : formParams, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, diff --git a/samples/client/petstore/typescript-angular-v6-provided-in-root/builds/with-npm/api/store.service.ts b/samples/client/petstore/typescript-angular-v6-provided-in-root/builds/with-npm/api/store.service.ts index d5d08ab3adc3..ef2a1d848b03 100644 --- a/samples/client/petstore/typescript-angular-v6-provided-in-root/builds/with-npm/api/store.service.ts +++ b/samples/client/petstore/typescript-angular-v6-provided-in-root/builds/with-npm/api/store.service.ts @@ -118,7 +118,8 @@ export class StoreService { responseType = 'text'; } - return this.httpClient.delete(`${this.configuration.basePath}/store/order/${encodeURIComponent(String(orderId))}`, + return this.httpClient.request('delete', + `${this.configuration.basePath}/store/order/${encodeURIComponent(String(orderId))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -167,7 +168,8 @@ export class StoreService { responseType = 'text'; } - return this.httpClient.get<{ [key: string]: number; }>(`${this.configuration.basePath}/store/inventory`, + return this.httpClient.request<{ [key: string]: number; }>('get', + `${this.configuration.basePath}/store/inventory`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -214,7 +216,8 @@ export class StoreService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/store/order/${encodeURIComponent(String(orderId))}`, + return this.httpClient.request('get', + `${this.configuration.basePath}/store/order/${encodeURIComponent(String(orderId))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -268,9 +271,10 @@ export class StoreService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/store/order`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/store/order`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, diff --git a/samples/client/petstore/typescript-angular-v6-provided-in-root/builds/with-npm/api/user.service.ts b/samples/client/petstore/typescript-angular-v6-provided-in-root/builds/with-npm/api/user.service.ts index 399676219054..9cd1a2482604 100644 --- a/samples/client/petstore/typescript-angular-v6-provided-in-root/builds/with-npm/api/user.service.ts +++ b/samples/client/petstore/typescript-angular-v6-provided-in-root/builds/with-npm/api/user.service.ts @@ -126,9 +126,10 @@ export class UserService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/user`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/user`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -179,9 +180,10 @@ export class UserService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/user/createWithArray`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/user/createWithArray`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -232,9 +234,10 @@ export class UserService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/user/createWithList`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/user/createWithList`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -278,7 +281,8 @@ export class UserService { responseType = 'text'; } - return this.httpClient.delete(`${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, + return this.httpClient.request('delete', + `${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -324,7 +328,8 @@ export class UserService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, + return this.httpClient.request('get', + `${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -384,7 +389,8 @@ export class UserService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/user/login`, + return this.httpClient.request('get', + `${this.configuration.basePath}/user/login`, { params: queryParameters, responseType: responseType, @@ -425,7 +431,8 @@ export class UserService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/user/logout`, + return this.httpClient.request('get', + `${this.configuration.basePath}/user/logout`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -482,9 +489,10 @@ export class UserService { responseType = 'text'; } - return this.httpClient.put(`${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, - body, + return this.httpClient.request('put', + `${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, diff --git a/samples/client/petstore/typescript-angular-v7-not-provided-in-root/builds/default/api/pet.service.ts b/samples/client/petstore/typescript-angular-v7-not-provided-in-root/builds/default/api/pet.service.ts index c6125084a2d6..53b471535391 100644 --- a/samples/client/petstore/typescript-angular-v7-not-provided-in-root/builds/default/api/pet.service.ts +++ b/samples/client/petstore/typescript-angular-v7-not-provided-in-root/builds/default/api/pet.service.ts @@ -146,9 +146,10 @@ export class PetService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/pet`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/pet`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -202,7 +203,8 @@ export class PetService { responseType = 'text'; } - return this.httpClient.delete(`${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, + return this.httpClient.request('delete', + `${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -262,7 +264,8 @@ export class PetService { responseType = 'text'; } - return this.httpClient.get>(`${this.configuration.basePath}/pet/findByStatus`, + return this.httpClient.request>('get', + `${this.configuration.basePath}/pet/findByStatus`, { params: queryParameters, responseType: responseType, @@ -324,7 +327,8 @@ export class PetService { responseType = 'text'; } - return this.httpClient.get>(`${this.configuration.basePath}/pet/findByTags`, + return this.httpClient.request>('get', + `${this.configuration.basePath}/pet/findByTags`, { params: queryParameters, responseType: responseType, @@ -379,7 +383,8 @@ export class PetService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, + return this.httpClient.request('get', + `${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -440,9 +445,10 @@ export class PetService { responseType = 'text'; } - return this.httpClient.put(`${this.configuration.basePath}/pet`, - body, + return this.httpClient.request('put', + `${this.configuration.basePath}/pet`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -516,9 +522,10 @@ export class PetService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, - convertFormParamsToString ? formParams.toString() : formParams, + return this.httpClient.request('post', + `${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, { + body: convertFormParamsToString ? formParams.toString() : formParams, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -596,9 +603,10 @@ export class PetService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}/uploadImage`, - convertFormParamsToString ? formParams.toString() : formParams, + return this.httpClient.request('post', + `${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}/uploadImage`, { + body: convertFormParamsToString ? formParams.toString() : formParams, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, diff --git a/samples/client/petstore/typescript-angular-v7-not-provided-in-root/builds/default/api/store.service.ts b/samples/client/petstore/typescript-angular-v7-not-provided-in-root/builds/default/api/store.service.ts index a6065292a6db..e652b176b147 100644 --- a/samples/client/petstore/typescript-angular-v7-not-provided-in-root/builds/default/api/store.service.ts +++ b/samples/client/petstore/typescript-angular-v7-not-provided-in-root/builds/default/api/store.service.ts @@ -116,7 +116,8 @@ export class StoreService { responseType = 'text'; } - return this.httpClient.delete(`${this.configuration.basePath}/store/order/${encodeURIComponent(String(orderId))}`, + return this.httpClient.request('delete', + `${this.configuration.basePath}/store/order/${encodeURIComponent(String(orderId))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -165,7 +166,8 @@ export class StoreService { responseType = 'text'; } - return this.httpClient.get<{ [key: string]: number; }>(`${this.configuration.basePath}/store/inventory`, + return this.httpClient.request<{ [key: string]: number; }>('get', + `${this.configuration.basePath}/store/inventory`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -212,7 +214,8 @@ export class StoreService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/store/order/${encodeURIComponent(String(orderId))}`, + return this.httpClient.request('get', + `${this.configuration.basePath}/store/order/${encodeURIComponent(String(orderId))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -266,9 +269,10 @@ export class StoreService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/store/order`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/store/order`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, diff --git a/samples/client/petstore/typescript-angular-v7-not-provided-in-root/builds/default/api/user.service.ts b/samples/client/petstore/typescript-angular-v7-not-provided-in-root/builds/default/api/user.service.ts index da1199c86d45..93b8aa396d41 100644 --- a/samples/client/petstore/typescript-angular-v7-not-provided-in-root/builds/default/api/user.service.ts +++ b/samples/client/petstore/typescript-angular-v7-not-provided-in-root/builds/default/api/user.service.ts @@ -124,9 +124,10 @@ export class UserService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/user`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/user`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -177,9 +178,10 @@ export class UserService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/user/createWithArray`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/user/createWithArray`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -230,9 +232,10 @@ export class UserService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/user/createWithList`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/user/createWithList`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -276,7 +279,8 @@ export class UserService { responseType = 'text'; } - return this.httpClient.delete(`${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, + return this.httpClient.request('delete', + `${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -322,7 +326,8 @@ export class UserService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, + return this.httpClient.request('get', + `${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -382,7 +387,8 @@ export class UserService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/user/login`, + return this.httpClient.request('get', + `${this.configuration.basePath}/user/login`, { params: queryParameters, responseType: responseType, @@ -423,7 +429,8 @@ export class UserService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/user/logout`, + return this.httpClient.request('get', + `${this.configuration.basePath}/user/logout`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -480,9 +487,10 @@ export class UserService { responseType = 'text'; } - return this.httpClient.put(`${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, - body, + return this.httpClient.request('put', + `${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, diff --git a/samples/client/petstore/typescript-angular-v7-not-provided-in-root/builds/with-npm/api/pet.service.ts b/samples/client/petstore/typescript-angular-v7-not-provided-in-root/builds/with-npm/api/pet.service.ts index c6125084a2d6..53b471535391 100644 --- a/samples/client/petstore/typescript-angular-v7-not-provided-in-root/builds/with-npm/api/pet.service.ts +++ b/samples/client/petstore/typescript-angular-v7-not-provided-in-root/builds/with-npm/api/pet.service.ts @@ -146,9 +146,10 @@ export class PetService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/pet`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/pet`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -202,7 +203,8 @@ export class PetService { responseType = 'text'; } - return this.httpClient.delete(`${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, + return this.httpClient.request('delete', + `${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -262,7 +264,8 @@ export class PetService { responseType = 'text'; } - return this.httpClient.get>(`${this.configuration.basePath}/pet/findByStatus`, + return this.httpClient.request>('get', + `${this.configuration.basePath}/pet/findByStatus`, { params: queryParameters, responseType: responseType, @@ -324,7 +327,8 @@ export class PetService { responseType = 'text'; } - return this.httpClient.get>(`${this.configuration.basePath}/pet/findByTags`, + return this.httpClient.request>('get', + `${this.configuration.basePath}/pet/findByTags`, { params: queryParameters, responseType: responseType, @@ -379,7 +383,8 @@ export class PetService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, + return this.httpClient.request('get', + `${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -440,9 +445,10 @@ export class PetService { responseType = 'text'; } - return this.httpClient.put(`${this.configuration.basePath}/pet`, - body, + return this.httpClient.request('put', + `${this.configuration.basePath}/pet`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -516,9 +522,10 @@ export class PetService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, - convertFormParamsToString ? formParams.toString() : formParams, + return this.httpClient.request('post', + `${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, { + body: convertFormParamsToString ? formParams.toString() : formParams, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -596,9 +603,10 @@ export class PetService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}/uploadImage`, - convertFormParamsToString ? formParams.toString() : formParams, + return this.httpClient.request('post', + `${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}/uploadImage`, { + body: convertFormParamsToString ? formParams.toString() : formParams, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, diff --git a/samples/client/petstore/typescript-angular-v7-not-provided-in-root/builds/with-npm/api/store.service.ts b/samples/client/petstore/typescript-angular-v7-not-provided-in-root/builds/with-npm/api/store.service.ts index a6065292a6db..e652b176b147 100644 --- a/samples/client/petstore/typescript-angular-v7-not-provided-in-root/builds/with-npm/api/store.service.ts +++ b/samples/client/petstore/typescript-angular-v7-not-provided-in-root/builds/with-npm/api/store.service.ts @@ -116,7 +116,8 @@ export class StoreService { responseType = 'text'; } - return this.httpClient.delete(`${this.configuration.basePath}/store/order/${encodeURIComponent(String(orderId))}`, + return this.httpClient.request('delete', + `${this.configuration.basePath}/store/order/${encodeURIComponent(String(orderId))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -165,7 +166,8 @@ export class StoreService { responseType = 'text'; } - return this.httpClient.get<{ [key: string]: number; }>(`${this.configuration.basePath}/store/inventory`, + return this.httpClient.request<{ [key: string]: number; }>('get', + `${this.configuration.basePath}/store/inventory`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -212,7 +214,8 @@ export class StoreService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/store/order/${encodeURIComponent(String(orderId))}`, + return this.httpClient.request('get', + `${this.configuration.basePath}/store/order/${encodeURIComponent(String(orderId))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -266,9 +269,10 @@ export class StoreService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/store/order`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/store/order`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, diff --git a/samples/client/petstore/typescript-angular-v7-not-provided-in-root/builds/with-npm/api/user.service.ts b/samples/client/petstore/typescript-angular-v7-not-provided-in-root/builds/with-npm/api/user.service.ts index da1199c86d45..93b8aa396d41 100644 --- a/samples/client/petstore/typescript-angular-v7-not-provided-in-root/builds/with-npm/api/user.service.ts +++ b/samples/client/petstore/typescript-angular-v7-not-provided-in-root/builds/with-npm/api/user.service.ts @@ -124,9 +124,10 @@ export class UserService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/user`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/user`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -177,9 +178,10 @@ export class UserService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/user/createWithArray`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/user/createWithArray`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -230,9 +232,10 @@ export class UserService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/user/createWithList`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/user/createWithList`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -276,7 +279,8 @@ export class UserService { responseType = 'text'; } - return this.httpClient.delete(`${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, + return this.httpClient.request('delete', + `${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -322,7 +326,8 @@ export class UserService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, + return this.httpClient.request('get', + `${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -382,7 +387,8 @@ export class UserService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/user/login`, + return this.httpClient.request('get', + `${this.configuration.basePath}/user/login`, { params: queryParameters, responseType: responseType, @@ -423,7 +429,8 @@ export class UserService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/user/logout`, + return this.httpClient.request('get', + `${this.configuration.basePath}/user/logout`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -480,9 +487,10 @@ export class UserService { responseType = 'text'; } - return this.httpClient.put(`${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, - body, + return this.httpClient.request('put', + `${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, diff --git a/samples/client/petstore/typescript-angular-v7-provided-in-root/builds/default/api/pet.service.ts b/samples/client/petstore/typescript-angular-v7-provided-in-root/builds/default/api/pet.service.ts index 46fef0be89fe..0c3bc22a4f25 100644 --- a/samples/client/petstore/typescript-angular-v7-provided-in-root/builds/default/api/pet.service.ts +++ b/samples/client/petstore/typescript-angular-v7-provided-in-root/builds/default/api/pet.service.ts @@ -148,9 +148,10 @@ export class PetService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/pet`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/pet`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -204,7 +205,8 @@ export class PetService { responseType = 'text'; } - return this.httpClient.delete(`${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, + return this.httpClient.request('delete', + `${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -264,7 +266,8 @@ export class PetService { responseType = 'text'; } - return this.httpClient.get>(`${this.configuration.basePath}/pet/findByStatus`, + return this.httpClient.request>('get', + `${this.configuration.basePath}/pet/findByStatus`, { params: queryParameters, responseType: responseType, @@ -326,7 +329,8 @@ export class PetService { responseType = 'text'; } - return this.httpClient.get>(`${this.configuration.basePath}/pet/findByTags`, + return this.httpClient.request>('get', + `${this.configuration.basePath}/pet/findByTags`, { params: queryParameters, responseType: responseType, @@ -381,7 +385,8 @@ export class PetService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, + return this.httpClient.request('get', + `${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -442,9 +447,10 @@ export class PetService { responseType = 'text'; } - return this.httpClient.put(`${this.configuration.basePath}/pet`, - body, + return this.httpClient.request('put', + `${this.configuration.basePath}/pet`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -518,9 +524,10 @@ export class PetService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, - convertFormParamsToString ? formParams.toString() : formParams, + return this.httpClient.request('post', + `${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, { + body: convertFormParamsToString ? formParams.toString() : formParams, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -598,9 +605,10 @@ export class PetService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}/uploadImage`, - convertFormParamsToString ? formParams.toString() : formParams, + return this.httpClient.request('post', + `${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}/uploadImage`, { + body: convertFormParamsToString ? formParams.toString() : formParams, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, diff --git a/samples/client/petstore/typescript-angular-v7-provided-in-root/builds/default/api/store.service.ts b/samples/client/petstore/typescript-angular-v7-provided-in-root/builds/default/api/store.service.ts index d5d08ab3adc3..ef2a1d848b03 100644 --- a/samples/client/petstore/typescript-angular-v7-provided-in-root/builds/default/api/store.service.ts +++ b/samples/client/petstore/typescript-angular-v7-provided-in-root/builds/default/api/store.service.ts @@ -118,7 +118,8 @@ export class StoreService { responseType = 'text'; } - return this.httpClient.delete(`${this.configuration.basePath}/store/order/${encodeURIComponent(String(orderId))}`, + return this.httpClient.request('delete', + `${this.configuration.basePath}/store/order/${encodeURIComponent(String(orderId))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -167,7 +168,8 @@ export class StoreService { responseType = 'text'; } - return this.httpClient.get<{ [key: string]: number; }>(`${this.configuration.basePath}/store/inventory`, + return this.httpClient.request<{ [key: string]: number; }>('get', + `${this.configuration.basePath}/store/inventory`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -214,7 +216,8 @@ export class StoreService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/store/order/${encodeURIComponent(String(orderId))}`, + return this.httpClient.request('get', + `${this.configuration.basePath}/store/order/${encodeURIComponent(String(orderId))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -268,9 +271,10 @@ export class StoreService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/store/order`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/store/order`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, diff --git a/samples/client/petstore/typescript-angular-v7-provided-in-root/builds/default/api/user.service.ts b/samples/client/petstore/typescript-angular-v7-provided-in-root/builds/default/api/user.service.ts index 399676219054..9cd1a2482604 100644 --- a/samples/client/petstore/typescript-angular-v7-provided-in-root/builds/default/api/user.service.ts +++ b/samples/client/petstore/typescript-angular-v7-provided-in-root/builds/default/api/user.service.ts @@ -126,9 +126,10 @@ export class UserService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/user`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/user`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -179,9 +180,10 @@ export class UserService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/user/createWithArray`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/user/createWithArray`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -232,9 +234,10 @@ export class UserService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/user/createWithList`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/user/createWithList`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -278,7 +281,8 @@ export class UserService { responseType = 'text'; } - return this.httpClient.delete(`${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, + return this.httpClient.request('delete', + `${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -324,7 +328,8 @@ export class UserService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, + return this.httpClient.request('get', + `${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -384,7 +389,8 @@ export class UserService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/user/login`, + return this.httpClient.request('get', + `${this.configuration.basePath}/user/login`, { params: queryParameters, responseType: responseType, @@ -425,7 +431,8 @@ export class UserService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/user/logout`, + return this.httpClient.request('get', + `${this.configuration.basePath}/user/logout`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -482,9 +489,10 @@ export class UserService { responseType = 'text'; } - return this.httpClient.put(`${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, - body, + return this.httpClient.request('put', + `${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, diff --git a/samples/client/petstore/typescript-angular-v7-provided-in-root/builds/with-npm/api/pet.service.ts b/samples/client/petstore/typescript-angular-v7-provided-in-root/builds/with-npm/api/pet.service.ts index 46fef0be89fe..0c3bc22a4f25 100644 --- a/samples/client/petstore/typescript-angular-v7-provided-in-root/builds/with-npm/api/pet.service.ts +++ b/samples/client/petstore/typescript-angular-v7-provided-in-root/builds/with-npm/api/pet.service.ts @@ -148,9 +148,10 @@ export class PetService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/pet`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/pet`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -204,7 +205,8 @@ export class PetService { responseType = 'text'; } - return this.httpClient.delete(`${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, + return this.httpClient.request('delete', + `${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -264,7 +266,8 @@ export class PetService { responseType = 'text'; } - return this.httpClient.get>(`${this.configuration.basePath}/pet/findByStatus`, + return this.httpClient.request>('get', + `${this.configuration.basePath}/pet/findByStatus`, { params: queryParameters, responseType: responseType, @@ -326,7 +329,8 @@ export class PetService { responseType = 'text'; } - return this.httpClient.get>(`${this.configuration.basePath}/pet/findByTags`, + return this.httpClient.request>('get', + `${this.configuration.basePath}/pet/findByTags`, { params: queryParameters, responseType: responseType, @@ -381,7 +385,8 @@ export class PetService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, + return this.httpClient.request('get', + `${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -442,9 +447,10 @@ export class PetService { responseType = 'text'; } - return this.httpClient.put(`${this.configuration.basePath}/pet`, - body, + return this.httpClient.request('put', + `${this.configuration.basePath}/pet`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -518,9 +524,10 @@ export class PetService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, - convertFormParamsToString ? formParams.toString() : formParams, + return this.httpClient.request('post', + `${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, { + body: convertFormParamsToString ? formParams.toString() : formParams, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -598,9 +605,10 @@ export class PetService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}/uploadImage`, - convertFormParamsToString ? formParams.toString() : formParams, + return this.httpClient.request('post', + `${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}/uploadImage`, { + body: convertFormParamsToString ? formParams.toString() : formParams, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, diff --git a/samples/client/petstore/typescript-angular-v7-provided-in-root/builds/with-npm/api/store.service.ts b/samples/client/petstore/typescript-angular-v7-provided-in-root/builds/with-npm/api/store.service.ts index d5d08ab3adc3..ef2a1d848b03 100644 --- a/samples/client/petstore/typescript-angular-v7-provided-in-root/builds/with-npm/api/store.service.ts +++ b/samples/client/petstore/typescript-angular-v7-provided-in-root/builds/with-npm/api/store.service.ts @@ -118,7 +118,8 @@ export class StoreService { responseType = 'text'; } - return this.httpClient.delete(`${this.configuration.basePath}/store/order/${encodeURIComponent(String(orderId))}`, + return this.httpClient.request('delete', + `${this.configuration.basePath}/store/order/${encodeURIComponent(String(orderId))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -167,7 +168,8 @@ export class StoreService { responseType = 'text'; } - return this.httpClient.get<{ [key: string]: number; }>(`${this.configuration.basePath}/store/inventory`, + return this.httpClient.request<{ [key: string]: number; }>('get', + `${this.configuration.basePath}/store/inventory`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -214,7 +216,8 @@ export class StoreService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/store/order/${encodeURIComponent(String(orderId))}`, + return this.httpClient.request('get', + `${this.configuration.basePath}/store/order/${encodeURIComponent(String(orderId))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -268,9 +271,10 @@ export class StoreService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/store/order`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/store/order`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, diff --git a/samples/client/petstore/typescript-angular-v7-provided-in-root/builds/with-npm/api/user.service.ts b/samples/client/petstore/typescript-angular-v7-provided-in-root/builds/with-npm/api/user.service.ts index 399676219054..9cd1a2482604 100644 --- a/samples/client/petstore/typescript-angular-v7-provided-in-root/builds/with-npm/api/user.service.ts +++ b/samples/client/petstore/typescript-angular-v7-provided-in-root/builds/with-npm/api/user.service.ts @@ -126,9 +126,10 @@ export class UserService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/user`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/user`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -179,9 +180,10 @@ export class UserService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/user/createWithArray`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/user/createWithArray`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -232,9 +234,10 @@ export class UserService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/user/createWithList`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/user/createWithList`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -278,7 +281,8 @@ export class UserService { responseType = 'text'; } - return this.httpClient.delete(`${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, + return this.httpClient.request('delete', + `${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -324,7 +328,8 @@ export class UserService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, + return this.httpClient.request('get', + `${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -384,7 +389,8 @@ export class UserService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/user/login`, + return this.httpClient.request('get', + `${this.configuration.basePath}/user/login`, { params: queryParameters, responseType: responseType, @@ -425,7 +431,8 @@ export class UserService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/user/logout`, + return this.httpClient.request('get', + `${this.configuration.basePath}/user/logout`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -482,9 +489,10 @@ export class UserService { responseType = 'text'; } - return this.httpClient.put(`${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, - body, + return this.httpClient.request('put', + `${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, diff --git a/samples/client/petstore/typescript-angular-v8-provided-in-root/builds/single-request-parameter/api/pet.service.ts b/samples/client/petstore/typescript-angular-v8-provided-in-root/builds/single-request-parameter/api/pet.service.ts index 8552f9cb4e50..d0cc48f9166d 100644 --- a/samples/client/petstore/typescript-angular-v8-provided-in-root/builds/single-request-parameter/api/pet.service.ts +++ b/samples/client/petstore/typescript-angular-v8-provided-in-root/builds/single-request-parameter/api/pet.service.ts @@ -198,9 +198,10 @@ export class PetService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/pet`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/pet`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -255,7 +256,8 @@ export class PetService { responseType = 'text'; } - return this.httpClient.delete(`${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, + return this.httpClient.request('delete', + `${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -316,7 +318,8 @@ export class PetService { responseType = 'text'; } - return this.httpClient.get>(`${this.configuration.basePath}/pet/findByStatus`, + return this.httpClient.request>('get', + `${this.configuration.basePath}/pet/findByStatus`, { params: queryParameters, responseType: responseType, @@ -379,7 +382,8 @@ export class PetService { responseType = 'text'; } - return this.httpClient.get>(`${this.configuration.basePath}/pet/findByTags`, + return this.httpClient.request>('get', + `${this.configuration.basePath}/pet/findByTags`, { params: queryParameters, responseType: responseType, @@ -435,7 +439,8 @@ export class PetService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, + return this.httpClient.request('get', + `${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -497,9 +502,10 @@ export class PetService { responseType = 'text'; } - return this.httpClient.put(`${this.configuration.basePath}/pet`, - body, + return this.httpClient.request('put', + `${this.configuration.basePath}/pet`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -574,9 +580,10 @@ export class PetService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, - convertFormParamsToString ? formParams.toString() : formParams, + return this.httpClient.request('post', + `${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, { + body: convertFormParamsToString ? formParams.toString() : formParams, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -655,9 +662,10 @@ export class PetService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}/uploadImage`, - convertFormParamsToString ? formParams.toString() : formParams, + return this.httpClient.request('post', + `${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}/uploadImage`, { + body: convertFormParamsToString ? formParams.toString() : formParams, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, diff --git a/samples/client/petstore/typescript-angular-v8-provided-in-root/builds/single-request-parameter/api/store.service.ts b/samples/client/petstore/typescript-angular-v8-provided-in-root/builds/single-request-parameter/api/store.service.ts index b44e765a0fa4..248ae3aa7075 100644 --- a/samples/client/petstore/typescript-angular-v8-provided-in-root/builds/single-request-parameter/api/store.service.ts +++ b/samples/client/petstore/typescript-angular-v8-provided-in-root/builds/single-request-parameter/api/store.service.ts @@ -134,7 +134,8 @@ export class StoreService { responseType = 'text'; } - return this.httpClient.delete(`${this.configuration.basePath}/store/order/${encodeURIComponent(String(orderId))}`, + return this.httpClient.request('delete', + `${this.configuration.basePath}/store/order/${encodeURIComponent(String(orderId))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -183,7 +184,8 @@ export class StoreService { responseType = 'text'; } - return this.httpClient.get<{ [key: string]: number; }>(`${this.configuration.basePath}/store/inventory`, + return this.httpClient.request<{ [key: string]: number; }>('get', + `${this.configuration.basePath}/store/inventory`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -231,7 +233,8 @@ export class StoreService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/store/order/${encodeURIComponent(String(orderId))}`, + return this.httpClient.request('get', + `${this.configuration.basePath}/store/order/${encodeURIComponent(String(orderId))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -286,9 +289,10 @@ export class StoreService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/store/order`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/store/order`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, diff --git a/samples/client/petstore/typescript-angular-v8-provided-in-root/builds/single-request-parameter/api/user.service.ts b/samples/client/petstore/typescript-angular-v8-provided-in-root/builds/single-request-parameter/api/user.service.ts index 326c0f7b8730..577cc39f2bae 100644 --- a/samples/client/petstore/typescript-angular-v8-provided-in-root/builds/single-request-parameter/api/user.service.ts +++ b/samples/client/petstore/typescript-angular-v8-provided-in-root/builds/single-request-parameter/api/user.service.ts @@ -166,9 +166,10 @@ export class UserService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/user`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/user`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -220,9 +221,10 @@ export class UserService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/user/createWithArray`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/user/createWithArray`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -274,9 +276,10 @@ export class UserService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/user/createWithList`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/user/createWithList`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -321,7 +324,8 @@ export class UserService { responseType = 'text'; } - return this.httpClient.delete(`${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, + return this.httpClient.request('delete', + `${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -368,7 +372,8 @@ export class UserService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, + return this.httpClient.request('get', + `${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -429,7 +434,8 @@ export class UserService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/user/login`, + return this.httpClient.request('get', + `${this.configuration.basePath}/user/login`, { params: queryParameters, responseType: responseType, @@ -470,7 +476,8 @@ export class UserService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/user/logout`, + return this.httpClient.request('get', + `${this.configuration.basePath}/user/logout`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -528,9 +535,10 @@ export class UserService { responseType = 'text'; } - return this.httpClient.put(`${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, - body, + return this.httpClient.request('put', + `${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, diff --git a/samples/client/petstore/typescript-angular-v8-provided-in-root/builds/with-npm/api/pet.service.ts b/samples/client/petstore/typescript-angular-v8-provided-in-root/builds/with-npm/api/pet.service.ts index 46fef0be89fe..0c3bc22a4f25 100644 --- a/samples/client/petstore/typescript-angular-v8-provided-in-root/builds/with-npm/api/pet.service.ts +++ b/samples/client/petstore/typescript-angular-v8-provided-in-root/builds/with-npm/api/pet.service.ts @@ -148,9 +148,10 @@ export class PetService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/pet`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/pet`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -204,7 +205,8 @@ export class PetService { responseType = 'text'; } - return this.httpClient.delete(`${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, + return this.httpClient.request('delete', + `${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -264,7 +266,8 @@ export class PetService { responseType = 'text'; } - return this.httpClient.get>(`${this.configuration.basePath}/pet/findByStatus`, + return this.httpClient.request>('get', + `${this.configuration.basePath}/pet/findByStatus`, { params: queryParameters, responseType: responseType, @@ -326,7 +329,8 @@ export class PetService { responseType = 'text'; } - return this.httpClient.get>(`${this.configuration.basePath}/pet/findByTags`, + return this.httpClient.request>('get', + `${this.configuration.basePath}/pet/findByTags`, { params: queryParameters, responseType: responseType, @@ -381,7 +385,8 @@ export class PetService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, + return this.httpClient.request('get', + `${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -442,9 +447,10 @@ export class PetService { responseType = 'text'; } - return this.httpClient.put(`${this.configuration.basePath}/pet`, - body, + return this.httpClient.request('put', + `${this.configuration.basePath}/pet`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -518,9 +524,10 @@ export class PetService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, - convertFormParamsToString ? formParams.toString() : formParams, + return this.httpClient.request('post', + `${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, { + body: convertFormParamsToString ? formParams.toString() : formParams, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -598,9 +605,10 @@ export class PetService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}/uploadImage`, - convertFormParamsToString ? formParams.toString() : formParams, + return this.httpClient.request('post', + `${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}/uploadImage`, { + body: convertFormParamsToString ? formParams.toString() : formParams, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, diff --git a/samples/client/petstore/typescript-angular-v8-provided-in-root/builds/with-npm/api/store.service.ts b/samples/client/petstore/typescript-angular-v8-provided-in-root/builds/with-npm/api/store.service.ts index d5d08ab3adc3..ef2a1d848b03 100644 --- a/samples/client/petstore/typescript-angular-v8-provided-in-root/builds/with-npm/api/store.service.ts +++ b/samples/client/petstore/typescript-angular-v8-provided-in-root/builds/with-npm/api/store.service.ts @@ -118,7 +118,8 @@ export class StoreService { responseType = 'text'; } - return this.httpClient.delete(`${this.configuration.basePath}/store/order/${encodeURIComponent(String(orderId))}`, + return this.httpClient.request('delete', + `${this.configuration.basePath}/store/order/${encodeURIComponent(String(orderId))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -167,7 +168,8 @@ export class StoreService { responseType = 'text'; } - return this.httpClient.get<{ [key: string]: number; }>(`${this.configuration.basePath}/store/inventory`, + return this.httpClient.request<{ [key: string]: number; }>('get', + `${this.configuration.basePath}/store/inventory`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -214,7 +216,8 @@ export class StoreService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/store/order/${encodeURIComponent(String(orderId))}`, + return this.httpClient.request('get', + `${this.configuration.basePath}/store/order/${encodeURIComponent(String(orderId))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -268,9 +271,10 @@ export class StoreService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/store/order`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/store/order`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, diff --git a/samples/client/petstore/typescript-angular-v8-provided-in-root/builds/with-npm/api/user.service.ts b/samples/client/petstore/typescript-angular-v8-provided-in-root/builds/with-npm/api/user.service.ts index 399676219054..9cd1a2482604 100644 --- a/samples/client/petstore/typescript-angular-v8-provided-in-root/builds/with-npm/api/user.service.ts +++ b/samples/client/petstore/typescript-angular-v8-provided-in-root/builds/with-npm/api/user.service.ts @@ -126,9 +126,10 @@ export class UserService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/user`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/user`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -179,9 +180,10 @@ export class UserService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/user/createWithArray`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/user/createWithArray`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -232,9 +234,10 @@ export class UserService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/user/createWithList`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/user/createWithList`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -278,7 +281,8 @@ export class UserService { responseType = 'text'; } - return this.httpClient.delete(`${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, + return this.httpClient.request('delete', + `${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -324,7 +328,8 @@ export class UserService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, + return this.httpClient.request('get', + `${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -384,7 +389,8 @@ export class UserService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/user/login`, + return this.httpClient.request('get', + `${this.configuration.basePath}/user/login`, { params: queryParameters, responseType: responseType, @@ -425,7 +431,8 @@ export class UserService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/user/logout`, + return this.httpClient.request('get', + `${this.configuration.basePath}/user/logout`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -482,9 +489,10 @@ export class UserService { responseType = 'text'; } - return this.httpClient.put(`${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, - body, + return this.httpClient.request('put', + `${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, diff --git a/samples/client/petstore/typescript-angular-v8-provided-in-root/builds/with-prefixed-module-name/api/pet.service.ts b/samples/client/petstore/typescript-angular-v8-provided-in-root/builds/with-prefixed-module-name/api/pet.service.ts index 46fef0be89fe..0c3bc22a4f25 100644 --- a/samples/client/petstore/typescript-angular-v8-provided-in-root/builds/with-prefixed-module-name/api/pet.service.ts +++ b/samples/client/petstore/typescript-angular-v8-provided-in-root/builds/with-prefixed-module-name/api/pet.service.ts @@ -148,9 +148,10 @@ export class PetService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/pet`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/pet`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -204,7 +205,8 @@ export class PetService { responseType = 'text'; } - return this.httpClient.delete(`${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, + return this.httpClient.request('delete', + `${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -264,7 +266,8 @@ export class PetService { responseType = 'text'; } - return this.httpClient.get>(`${this.configuration.basePath}/pet/findByStatus`, + return this.httpClient.request>('get', + `${this.configuration.basePath}/pet/findByStatus`, { params: queryParameters, responseType: responseType, @@ -326,7 +329,8 @@ export class PetService { responseType = 'text'; } - return this.httpClient.get>(`${this.configuration.basePath}/pet/findByTags`, + return this.httpClient.request>('get', + `${this.configuration.basePath}/pet/findByTags`, { params: queryParameters, responseType: responseType, @@ -381,7 +385,8 @@ export class PetService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, + return this.httpClient.request('get', + `${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -442,9 +447,10 @@ export class PetService { responseType = 'text'; } - return this.httpClient.put(`${this.configuration.basePath}/pet`, - body, + return this.httpClient.request('put', + `${this.configuration.basePath}/pet`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -518,9 +524,10 @@ export class PetService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, - convertFormParamsToString ? formParams.toString() : formParams, + return this.httpClient.request('post', + `${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, { + body: convertFormParamsToString ? formParams.toString() : formParams, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -598,9 +605,10 @@ export class PetService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}/uploadImage`, - convertFormParamsToString ? formParams.toString() : formParams, + return this.httpClient.request('post', + `${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}/uploadImage`, { + body: convertFormParamsToString ? formParams.toString() : formParams, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, diff --git a/samples/client/petstore/typescript-angular-v8-provided-in-root/builds/with-prefixed-module-name/api/store.service.ts b/samples/client/petstore/typescript-angular-v8-provided-in-root/builds/with-prefixed-module-name/api/store.service.ts index d5d08ab3adc3..ef2a1d848b03 100644 --- a/samples/client/petstore/typescript-angular-v8-provided-in-root/builds/with-prefixed-module-name/api/store.service.ts +++ b/samples/client/petstore/typescript-angular-v8-provided-in-root/builds/with-prefixed-module-name/api/store.service.ts @@ -118,7 +118,8 @@ export class StoreService { responseType = 'text'; } - return this.httpClient.delete(`${this.configuration.basePath}/store/order/${encodeURIComponent(String(orderId))}`, + return this.httpClient.request('delete', + `${this.configuration.basePath}/store/order/${encodeURIComponent(String(orderId))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -167,7 +168,8 @@ export class StoreService { responseType = 'text'; } - return this.httpClient.get<{ [key: string]: number; }>(`${this.configuration.basePath}/store/inventory`, + return this.httpClient.request<{ [key: string]: number; }>('get', + `${this.configuration.basePath}/store/inventory`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -214,7 +216,8 @@ export class StoreService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/store/order/${encodeURIComponent(String(orderId))}`, + return this.httpClient.request('get', + `${this.configuration.basePath}/store/order/${encodeURIComponent(String(orderId))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -268,9 +271,10 @@ export class StoreService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/store/order`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/store/order`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, diff --git a/samples/client/petstore/typescript-angular-v8-provided-in-root/builds/with-prefixed-module-name/api/user.service.ts b/samples/client/petstore/typescript-angular-v8-provided-in-root/builds/with-prefixed-module-name/api/user.service.ts index 399676219054..9cd1a2482604 100644 --- a/samples/client/petstore/typescript-angular-v8-provided-in-root/builds/with-prefixed-module-name/api/user.service.ts +++ b/samples/client/petstore/typescript-angular-v8-provided-in-root/builds/with-prefixed-module-name/api/user.service.ts @@ -126,9 +126,10 @@ export class UserService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/user`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/user`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -179,9 +180,10 @@ export class UserService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/user/createWithArray`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/user/createWithArray`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -232,9 +234,10 @@ export class UserService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/user/createWithList`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/user/createWithList`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -278,7 +281,8 @@ export class UserService { responseType = 'text'; } - return this.httpClient.delete(`${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, + return this.httpClient.request('delete', + `${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -324,7 +328,8 @@ export class UserService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, + return this.httpClient.request('get', + `${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -384,7 +389,8 @@ export class UserService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/user/login`, + return this.httpClient.request('get', + `${this.configuration.basePath}/user/login`, { params: queryParameters, responseType: responseType, @@ -425,7 +431,8 @@ export class UserService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/user/logout`, + return this.httpClient.request('get', + `${this.configuration.basePath}/user/logout`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -482,9 +489,10 @@ export class UserService { responseType = 'text'; } - return this.httpClient.put(`${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, - body, + return this.httpClient.request('put', + `${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, diff --git a/samples/client/petstore/typescript-angular-v9-provided-in-root/builds/default/api/pet.service.ts b/samples/client/petstore/typescript-angular-v9-provided-in-root/builds/default/api/pet.service.ts index 46fef0be89fe..0c3bc22a4f25 100644 --- a/samples/client/petstore/typescript-angular-v9-provided-in-root/builds/default/api/pet.service.ts +++ b/samples/client/petstore/typescript-angular-v9-provided-in-root/builds/default/api/pet.service.ts @@ -148,9 +148,10 @@ export class PetService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/pet`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/pet`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -204,7 +205,8 @@ export class PetService { responseType = 'text'; } - return this.httpClient.delete(`${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, + return this.httpClient.request('delete', + `${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -264,7 +266,8 @@ export class PetService { responseType = 'text'; } - return this.httpClient.get>(`${this.configuration.basePath}/pet/findByStatus`, + return this.httpClient.request>('get', + `${this.configuration.basePath}/pet/findByStatus`, { params: queryParameters, responseType: responseType, @@ -326,7 +329,8 @@ export class PetService { responseType = 'text'; } - return this.httpClient.get>(`${this.configuration.basePath}/pet/findByTags`, + return this.httpClient.request>('get', + `${this.configuration.basePath}/pet/findByTags`, { params: queryParameters, responseType: responseType, @@ -381,7 +385,8 @@ export class PetService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, + return this.httpClient.request('get', + `${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -442,9 +447,10 @@ export class PetService { responseType = 'text'; } - return this.httpClient.put(`${this.configuration.basePath}/pet`, - body, + return this.httpClient.request('put', + `${this.configuration.basePath}/pet`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -518,9 +524,10 @@ export class PetService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, - convertFormParamsToString ? formParams.toString() : formParams, + return this.httpClient.request('post', + `${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, { + body: convertFormParamsToString ? formParams.toString() : formParams, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -598,9 +605,10 @@ export class PetService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}/uploadImage`, - convertFormParamsToString ? formParams.toString() : formParams, + return this.httpClient.request('post', + `${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}/uploadImage`, { + body: convertFormParamsToString ? formParams.toString() : formParams, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, diff --git a/samples/client/petstore/typescript-angular-v9-provided-in-root/builds/default/api/store.service.ts b/samples/client/petstore/typescript-angular-v9-provided-in-root/builds/default/api/store.service.ts index d5d08ab3adc3..ef2a1d848b03 100644 --- a/samples/client/petstore/typescript-angular-v9-provided-in-root/builds/default/api/store.service.ts +++ b/samples/client/petstore/typescript-angular-v9-provided-in-root/builds/default/api/store.service.ts @@ -118,7 +118,8 @@ export class StoreService { responseType = 'text'; } - return this.httpClient.delete(`${this.configuration.basePath}/store/order/${encodeURIComponent(String(orderId))}`, + return this.httpClient.request('delete', + `${this.configuration.basePath}/store/order/${encodeURIComponent(String(orderId))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -167,7 +168,8 @@ export class StoreService { responseType = 'text'; } - return this.httpClient.get<{ [key: string]: number; }>(`${this.configuration.basePath}/store/inventory`, + return this.httpClient.request<{ [key: string]: number; }>('get', + `${this.configuration.basePath}/store/inventory`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -214,7 +216,8 @@ export class StoreService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/store/order/${encodeURIComponent(String(orderId))}`, + return this.httpClient.request('get', + `${this.configuration.basePath}/store/order/${encodeURIComponent(String(orderId))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -268,9 +271,10 @@ export class StoreService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/store/order`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/store/order`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, diff --git a/samples/client/petstore/typescript-angular-v9-provided-in-root/builds/default/api/user.service.ts b/samples/client/petstore/typescript-angular-v9-provided-in-root/builds/default/api/user.service.ts index 399676219054..9cd1a2482604 100644 --- a/samples/client/petstore/typescript-angular-v9-provided-in-root/builds/default/api/user.service.ts +++ b/samples/client/petstore/typescript-angular-v9-provided-in-root/builds/default/api/user.service.ts @@ -126,9 +126,10 @@ export class UserService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/user`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/user`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -179,9 +180,10 @@ export class UserService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/user/createWithArray`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/user/createWithArray`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -232,9 +234,10 @@ export class UserService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/user/createWithList`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/user/createWithList`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -278,7 +281,8 @@ export class UserService { responseType = 'text'; } - return this.httpClient.delete(`${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, + return this.httpClient.request('delete', + `${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -324,7 +328,8 @@ export class UserService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, + return this.httpClient.request('get', + `${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -384,7 +389,8 @@ export class UserService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/user/login`, + return this.httpClient.request('get', + `${this.configuration.basePath}/user/login`, { params: queryParameters, responseType: responseType, @@ -425,7 +431,8 @@ export class UserService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/user/logout`, + return this.httpClient.request('get', + `${this.configuration.basePath}/user/logout`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -482,9 +489,10 @@ export class UserService { responseType = 'text'; } - return this.httpClient.put(`${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, - body, + return this.httpClient.request('put', + `${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, diff --git a/samples/client/petstore/typescript-angular-v9-provided-in-root/builds/with-npm/api/pet.service.ts b/samples/client/petstore/typescript-angular-v9-provided-in-root/builds/with-npm/api/pet.service.ts index 46fef0be89fe..0c3bc22a4f25 100644 --- a/samples/client/petstore/typescript-angular-v9-provided-in-root/builds/with-npm/api/pet.service.ts +++ b/samples/client/petstore/typescript-angular-v9-provided-in-root/builds/with-npm/api/pet.service.ts @@ -148,9 +148,10 @@ export class PetService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/pet`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/pet`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -204,7 +205,8 @@ export class PetService { responseType = 'text'; } - return this.httpClient.delete(`${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, + return this.httpClient.request('delete', + `${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -264,7 +266,8 @@ export class PetService { responseType = 'text'; } - return this.httpClient.get>(`${this.configuration.basePath}/pet/findByStatus`, + return this.httpClient.request>('get', + `${this.configuration.basePath}/pet/findByStatus`, { params: queryParameters, responseType: responseType, @@ -326,7 +329,8 @@ export class PetService { responseType = 'text'; } - return this.httpClient.get>(`${this.configuration.basePath}/pet/findByTags`, + return this.httpClient.request>('get', + `${this.configuration.basePath}/pet/findByTags`, { params: queryParameters, responseType: responseType, @@ -381,7 +385,8 @@ export class PetService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, + return this.httpClient.request('get', + `${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -442,9 +447,10 @@ export class PetService { responseType = 'text'; } - return this.httpClient.put(`${this.configuration.basePath}/pet`, - body, + return this.httpClient.request('put', + `${this.configuration.basePath}/pet`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -518,9 +524,10 @@ export class PetService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, - convertFormParamsToString ? formParams.toString() : formParams, + return this.httpClient.request('post', + `${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}`, { + body: convertFormParamsToString ? formParams.toString() : formParams, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -598,9 +605,10 @@ export class PetService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}/uploadImage`, - convertFormParamsToString ? formParams.toString() : formParams, + return this.httpClient.request('post', + `${this.configuration.basePath}/pet/${encodeURIComponent(String(petId))}/uploadImage`, { + body: convertFormParamsToString ? formParams.toString() : formParams, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, diff --git a/samples/client/petstore/typescript-angular-v9-provided-in-root/builds/with-npm/api/store.service.ts b/samples/client/petstore/typescript-angular-v9-provided-in-root/builds/with-npm/api/store.service.ts index d5d08ab3adc3..ef2a1d848b03 100644 --- a/samples/client/petstore/typescript-angular-v9-provided-in-root/builds/with-npm/api/store.service.ts +++ b/samples/client/petstore/typescript-angular-v9-provided-in-root/builds/with-npm/api/store.service.ts @@ -118,7 +118,8 @@ export class StoreService { responseType = 'text'; } - return this.httpClient.delete(`${this.configuration.basePath}/store/order/${encodeURIComponent(String(orderId))}`, + return this.httpClient.request('delete', + `${this.configuration.basePath}/store/order/${encodeURIComponent(String(orderId))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -167,7 +168,8 @@ export class StoreService { responseType = 'text'; } - return this.httpClient.get<{ [key: string]: number; }>(`${this.configuration.basePath}/store/inventory`, + return this.httpClient.request<{ [key: string]: number; }>('get', + `${this.configuration.basePath}/store/inventory`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -214,7 +216,8 @@ export class StoreService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/store/order/${encodeURIComponent(String(orderId))}`, + return this.httpClient.request('get', + `${this.configuration.basePath}/store/order/${encodeURIComponent(String(orderId))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -268,9 +271,10 @@ export class StoreService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/store/order`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/store/order`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, diff --git a/samples/client/petstore/typescript-angular-v9-provided-in-root/builds/with-npm/api/user.service.ts b/samples/client/petstore/typescript-angular-v9-provided-in-root/builds/with-npm/api/user.service.ts index 399676219054..9cd1a2482604 100644 --- a/samples/client/petstore/typescript-angular-v9-provided-in-root/builds/with-npm/api/user.service.ts +++ b/samples/client/petstore/typescript-angular-v9-provided-in-root/builds/with-npm/api/user.service.ts @@ -126,9 +126,10 @@ export class UserService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/user`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/user`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -179,9 +180,10 @@ export class UserService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/user/createWithArray`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/user/createWithArray`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -232,9 +234,10 @@ export class UserService { responseType = 'text'; } - return this.httpClient.post(`${this.configuration.basePath}/user/createWithList`, - body, + return this.httpClient.request('post', + `${this.configuration.basePath}/user/createWithList`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers, @@ -278,7 +281,8 @@ export class UserService { responseType = 'text'; } - return this.httpClient.delete(`${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, + return this.httpClient.request('delete', + `${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -324,7 +328,8 @@ export class UserService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, + return this.httpClient.request('get', + `${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -384,7 +389,8 @@ export class UserService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/user/login`, + return this.httpClient.request('get', + `${this.configuration.basePath}/user/login`, { params: queryParameters, responseType: responseType, @@ -425,7 +431,8 @@ export class UserService { responseType = 'text'; } - return this.httpClient.get(`${this.configuration.basePath}/user/logout`, + return this.httpClient.request('get', + `${this.configuration.basePath}/user/logout`, { responseType: responseType, withCredentials: this.configuration.withCredentials, @@ -482,9 +489,10 @@ export class UserService { responseType = 'text'; } - return this.httpClient.put(`${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, - body, + return this.httpClient.request('put', + `${this.configuration.basePath}/user/${encodeURIComponent(String(username))}`, { + body: body, responseType: responseType, withCredentials: this.configuration.withCredentials, headers: headers,