77
88import axios from "axios" ;
99import { type AxiosRequestConfig as AxiosRequestConfig } from "axios" ;
10- import { type AxiosPromise as AxiosPromise } from "axios" ;
10+ import { type AxiosResponse as AxiosResponse } from "axios" ;
1111
1212
1313
@@ -120,7 +120,7 @@ export type ApiResponse = {
120120 * @param data Pet object that needs to be added to the store
121121 * @param [config] request config
122122 */
123- export async function addPet ( data :Pet , config ?:AxiosRequestConfig ) : AxiosPromise < unknown > {
123+ export async function addPet ( data :Pet , config ?:AxiosRequestConfig ) : AxiosResponse < unknown > {
124124 return axios ( {
125125 method : "POST" ,
126126 url : `/pet` ,
@@ -136,7 +136,7 @@ data: data,
136136 * @param data Pet object that needs to be added to the store
137137 * @param [config] request config
138138 */
139- export async function updatePet ( data :Pet , config ?:AxiosRequestConfig ) : AxiosPromise < unknown > {
139+ export async function updatePet ( data :Pet , config ?:AxiosRequestConfig ) : AxiosResponse < unknown > {
140140 return axios ( {
141141 method : "PUT" ,
142142 url : `/pet` ,
@@ -158,7 +158,7 @@ export async function findPetsByStatus(status:Array<
158158 * @default available
159159 */
160160( "available" | "pending" | "sold" )
161- > , config ?:AxiosRequestConfig ) : AxiosPromise < Array < Pet > > {
161+ > , config ?:AxiosRequestConfig ) : AxiosResponse < Array < Pet > > {
162162 return axios ( {
163163 method : "GET" ,
164164 url : `/pet/findByStatus` ,
@@ -176,7 +176,7 @@ params: {"status": status},
176176 * @param [config] request config
177177 * @returns successful operation
178178 */
179- export async function findPetsByTags ( tags :Array < string > , config ?:AxiosRequestConfig ) : AxiosPromise < Array < Pet > > {
179+ export async function findPetsByTags ( tags :Array < string > , config ?:AxiosRequestConfig ) : AxiosResponse < Array < Pet > > {
180180 return axios ( {
181181 method : "GET" ,
182182 url : `/pet/findByTags` ,
@@ -198,7 +198,7 @@ export async function getPetById(petId:
198198 * @format int64
199199 */
200200number
201- , config ?:AxiosRequestConfig ) : AxiosPromise < Pet > {
201+ , config ?:AxiosRequestConfig ) : AxiosResponse < Pet > {
202202 return axios ( {
203203 method : "GET" ,
204204 url : `/pet/${ petId } ` ,
@@ -228,7 +228,7 @@ number
228228 * @description Updated status of the pet
229229 */
230230"status" ?:string ;
231- } , config ?:AxiosRequestConfig ) : AxiosPromise < unknown > {
231+ } , config ?:AxiosRequestConfig ) : AxiosResponse < unknown > {
232232 return axios ( {
233233 method : "POST" ,
234234 url : `/pet/${ petId } ` ,
@@ -250,7 +250,7 @@ export async function deletePet(petId:
250250 * @format int64
251251 */
252252number
253- , apiKey ?:string , config ?:AxiosRequestConfig ) : AxiosPromise < unknown > {
253+ , apiKey ?:string , config ?:AxiosRequestConfig ) : AxiosResponse < unknown > {
254254 return axios ( {
255255 method : "DELETE" ,
256256 url : `/pet/${ petId } ` ,
@@ -283,7 +283,7 @@ number
283283 * @format binary
284284 */
285285"file" ?:Blob ;
286- } , config ?:AxiosRequestConfig ) : AxiosPromise < ApiResponse > {
286+ } , config ?:AxiosRequestConfig ) : AxiosResponse < ApiResponse > {
287287 return axios ( {
288288 method : "POST" ,
289289 url : `/pet/${ petId } /uploadImage` ,
@@ -299,7 +299,7 @@ data: data,
299299 * @param [config] request config
300300 * @returns successful operation
301301 */
302- export async function getInventory ( config ?:AxiosRequestConfig ) : AxiosPromise < {
302+ export async function getInventory ( config ?:AxiosRequestConfig ) : AxiosResponse < {
303303/**
304304 * @format int32
305305 */
@@ -320,7 +320,7 @@ export async function getInventory(config?:AxiosRequestConfig): AxiosPromise<{
320320 * @param [config] request config
321321 * @returns successful operation
322322 */
323- export async function placeOrder ( data :Order , config ?:AxiosRequestConfig ) : AxiosPromise < Order > {
323+ export async function placeOrder ( data :Order , config ?:AxiosRequestConfig ) : AxiosResponse < Order > {
324324 return axios ( {
325325 method : "POST" ,
326326 url : `/store/order` ,
@@ -344,7 +344,7 @@ export async function getOrderById(orderId:
344344 * @maximum 10
345345 */
346346number
347- , config ?:AxiosRequestConfig ) : AxiosPromise < Order > {
347+ , config ?:AxiosRequestConfig ) : AxiosResponse < Order > {
348348 return axios ( {
349349 method : "GET" ,
350350 url : `/store/order/${ orderId } ` ,
@@ -365,7 +365,7 @@ export async function deleteOrder(orderId:
365365 * @minimum 1
366366 */
367367number
368- , config ?:AxiosRequestConfig ) : AxiosPromise < unknown > {
368+ , config ?:AxiosRequestConfig ) : AxiosResponse < unknown > {
369369 return axios ( {
370370 method : "DELETE" ,
371371 url : `/store/order/${ orderId } ` ,
@@ -380,7 +380,7 @@ number
380380 * @param data Created user object
381381 * @param [config] request config
382382 */
383- export async function createUser ( data :User , config ?:AxiosRequestConfig ) : AxiosPromise < unknown > {
383+ export async function createUser ( data :User , config ?:AxiosRequestConfig ) : AxiosResponse < unknown > {
384384 return axios ( {
385385 method : "POST" ,
386386 url : `/user` ,
@@ -396,7 +396,7 @@ data: data,
396396 * @param data List of user object
397397 * @param [config] request config
398398 */
399- export async function createUsersWithArrayInput ( data :Array < User > , config ?:AxiosRequestConfig ) : AxiosPromise < unknown > {
399+ export async function createUsersWithArrayInput ( data :Array < User > , config ?:AxiosRequestConfig ) : AxiosResponse < unknown > {
400400 return axios ( {
401401 method : "POST" ,
402402 url : `/user/createWithArray` ,
@@ -412,7 +412,7 @@ data: data,
412412 * @param data List of user object
413413 * @param [config] request config
414414 */
415- export async function createUsersWithListInput ( data :Array < User > , config ?:AxiosRequestConfig ) : AxiosPromise < unknown > {
415+ export async function createUsersWithListInput ( data :Array < User > , config ?:AxiosRequestConfig ) : AxiosResponse < unknown > {
416416 return axios ( {
417417 method : "POST" ,
418418 url : `/user/createWithList` ,
@@ -438,7 +438,7 @@ export async function loginUser(params:{
438438 * @description The password for login in clear text
439439 */
440440"password" :string ;
441- } , config ?:AxiosRequestConfig ) : AxiosPromise < string > {
441+ } , config ?:AxiosRequestConfig ) : AxiosResponse < string > {
442442 return axios ( {
443443 method : "GET" ,
444444 url : `/user/login` ,
@@ -453,7 +453,7 @@ params: params,
453453 * @see user Operations about user {@link http://swagger.io Find out more about our store}
454454 * @param [config] request config
455455 */
456- export async function logoutUser ( config ?:AxiosRequestConfig ) : AxiosPromise < unknown > {
456+ export async function logoutUser ( config ?:AxiosRequestConfig ) : AxiosResponse < unknown > {
457457 return axios ( {
458458 method : "GET" ,
459459 url : `/user/logout` ,
@@ -469,7 +469,7 @@ export async function logoutUser(config?:AxiosRequestConfig): AxiosPromise<unkno
469469 * @param [config] request config
470470 * @returns successful operation
471471 */
472- export async function getUserByName ( username :string , config ?:AxiosRequestConfig ) : AxiosPromise < User > {
472+ export async function getUserByName ( username :string , config ?:AxiosRequestConfig ) : AxiosResponse < User > {
473473 return axios ( {
474474 method : "GET" ,
475475 url : `/user/${ username } ` ,
@@ -484,7 +484,7 @@ export async function getUserByName(username:string,config?:AxiosRequestConfig):
484484 * @param username The name that needs to be deleted
485485 * @param [config] request config
486486 */
487- export async function deleteUser ( username :string , config ?:AxiosRequestConfig ) : AxiosPromise < unknown > {
487+ export async function deleteUser ( username :string , config ?:AxiosRequestConfig ) : AxiosResponse < unknown > {
488488 return axios ( {
489489 method : "DELETE" ,
490490 url : `/user/${ username } ` ,
@@ -500,7 +500,7 @@ export async function deleteUser(username:string,config?:AxiosRequestConfig): Ax
500500 * @param data Updated user object
501501 * @param [config] request config
502502 */
503- export async function updateUser ( username :string , data :User , config ?:AxiosRequestConfig ) : AxiosPromise < unknown > {
503+ export async function updateUser ( username :string , data :User , config ?:AxiosRequestConfig ) : AxiosResponse < unknown > {
504504 return axios ( {
505505 method : "PUT" ,
506506 url : `/user/${ username } ` ,
0 commit comments