mirror of
https://github.com/OpenAPITools/openapi-generator.git
synced 2025-06-30 20:50:53 +00:00
Using import type for types imports [typescript-axios] (#13964)
* type imports to use import type instead of import * generated samples Co-authored-by: onur-caplena <onur@caplena.com>
This commit is contained in:
parent
4667b7e471
commit
d8bed4228d
@ -3,8 +3,9 @@
|
|||||||
{{>licenseInfo}}
|
{{>licenseInfo}}
|
||||||
|
|
||||||
{{^withSeparateModelsAndApi}}
|
{{^withSeparateModelsAndApi}}
|
||||||
import { Configuration } from './configuration';
|
import type { Configuration } from './configuration';
|
||||||
import globalAxios, { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
|
import type { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
|
||||||
|
import globalAxios from 'axios';
|
||||||
{{#withNodeImports}}
|
{{#withNodeImports}}
|
||||||
// URLSearchParams not necessarily used
|
// URLSearchParams not necessarily used
|
||||||
// @ts-ignore
|
// @ts-ignore
|
||||||
@ -16,8 +17,9 @@ import FormData from 'form-data'
|
|||||||
// Some imports not used depending on template conditions
|
// Some imports not used depending on template conditions
|
||||||
// @ts-ignore
|
// @ts-ignore
|
||||||
import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObject, setBearerAuthToObject, setOAuthToObject, setSearchParams, serializeDataIfNeeded, toPathString, createRequestFunction } from './common';
|
import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObject, setBearerAuthToObject, setOAuthToObject, setSearchParams, serializeDataIfNeeded, toPathString, createRequestFunction } from './common';
|
||||||
|
import type { RequestArgs } from './base';
|
||||||
// @ts-ignore
|
// @ts-ignore
|
||||||
import { BASE_PATH, COLLECTION_FORMATS, RequestArgs, BaseAPI, RequiredError } from './base';
|
import { BASE_PATH, COLLECTION_FORMATS, BaseAPI, RequiredError } from './base';
|
||||||
|
|
||||||
{{#models}}
|
{{#models}}
|
||||||
{{#model}}{{#isEnum}}{{>modelEnum}}{{/isEnum}}{{#oneOf}}{{#-first}}{{>modelOneOf}}{{/-first}}{{/oneOf}}{{^isEnum}}{{^oneOf}}{{>modelGeneric}}{{/oneOf}}{{/isEnum}}{{/model}}
|
{{#model}}{{#isEnum}}{{>modelEnum}}{{/isEnum}}{{#oneOf}}{{#-first}}{{>modelOneOf}}{{/-first}}{{/oneOf}}{{^isEnum}}{{^oneOf}}{{>modelGeneric}}{{/oneOf}}{{/isEnum}}{{/model}}
|
||||||
|
5
modules/openapi-generator/src/main/resources/typescript-axios/apiInner.mustache
vendored
Normal file → Executable file
5
modules/openapi-generator/src/main/resources/typescript-axios/apiInner.mustache
vendored
Normal file → Executable file
@ -3,8 +3,9 @@
|
|||||||
/* eslint-disable */
|
/* eslint-disable */
|
||||||
{{>licenseInfo}}
|
{{>licenseInfo}}
|
||||||
|
|
||||||
import globalAxios, { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
|
import type { Configuration } from '{{apiRelativeToRoot}}configuration';
|
||||||
import { Configuration } from '{{apiRelativeToRoot}}configuration';
|
import type { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
|
||||||
|
import globalAxios from 'axios';
|
||||||
{{#withNodeImports}}
|
{{#withNodeImports}}
|
||||||
// URLSearchParams not necessarily used
|
// URLSearchParams not necessarily used
|
||||||
// @ts-ignore
|
// @ts-ignore
|
||||||
|
5
modules/openapi-generator/src/main/resources/typescript-axios/baseApi.mustache
vendored
Normal file → Executable file
5
modules/openapi-generator/src/main/resources/typescript-axios/baseApi.mustache
vendored
Normal file → Executable file
@ -2,10 +2,11 @@
|
|||||||
/* eslint-disable */
|
/* eslint-disable */
|
||||||
{{>licenseInfo}}
|
{{>licenseInfo}}
|
||||||
|
|
||||||
import { Configuration } from "./configuration";
|
import type { Configuration } from './configuration';
|
||||||
|
import type { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
|
||||||
// Some imports not used depending on template conditions
|
// Some imports not used depending on template conditions
|
||||||
// @ts-ignore
|
// @ts-ignore
|
||||||
import globalAxios, { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
|
import globalAxios from 'axios';
|
||||||
|
|
||||||
export const BASE_PATH = "{{{basePath}}}".replace(/\/+$/, "");
|
export const BASE_PATH = "{{{basePath}}}".replace(/\/+$/, "");
|
||||||
|
|
||||||
|
7
modules/openapi-generator/src/main/resources/typescript-axios/common.mustache
vendored
Normal file → Executable file
7
modules/openapi-generator/src/main/resources/typescript-axios/common.mustache
vendored
Normal file → Executable file
@ -2,9 +2,10 @@
|
|||||||
/* eslint-disable */
|
/* eslint-disable */
|
||||||
{{>licenseInfo}}
|
{{>licenseInfo}}
|
||||||
|
|
||||||
import { Configuration } from "./configuration";
|
import type { Configuration } from "./configuration";
|
||||||
import { RequiredError, RequestArgs } from "./base";
|
import type { RequestArgs } from "./base";
|
||||||
import { AxiosInstance, AxiosResponse } from 'axios';
|
import type { AxiosInstance, AxiosResponse } from 'axios';
|
||||||
|
import { RequiredError } from "./base";
|
||||||
{{#withNodeImports}}
|
{{#withNodeImports}}
|
||||||
import { URL, URLSearchParams } from 'url';
|
import { URL, URLSearchParams } from 'url';
|
||||||
{{/withNodeImports}}
|
{{/withNodeImports}}
|
||||||
|
@ -13,10 +13,11 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
import { Configuration } from "./configuration";
|
import type { Configuration } from './configuration';
|
||||||
|
import type { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
|
||||||
// Some imports not used depending on template conditions
|
// Some imports not used depending on template conditions
|
||||||
// @ts-ignore
|
// @ts-ignore
|
||||||
import globalAxios, { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
|
import globalAxios from 'axios';
|
||||||
|
|
||||||
export const BASE_PATH = "http://localhost".replace(/\/+$/, "");
|
export const BASE_PATH = "http://localhost".replace(/\/+$/, "");
|
||||||
|
|
||||||
|
@ -13,9 +13,10 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
import { Configuration } from "./configuration";
|
import type { Configuration } from "./configuration";
|
||||||
import { RequiredError, RequestArgs } from "./base";
|
import type { RequestArgs } from "./base";
|
||||||
import { AxiosInstance, AxiosResponse } from 'axios';
|
import type { AxiosInstance, AxiosResponse } from 'axios';
|
||||||
|
import { RequiredError } from "./base";
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
|
@ -13,13 +13,15 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
import { Configuration } from './configuration';
|
import type { Configuration } from './configuration';
|
||||||
import globalAxios, { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
|
import type { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
|
||||||
|
import globalAxios from 'axios';
|
||||||
// Some imports not used depending on template conditions
|
// Some imports not used depending on template conditions
|
||||||
// @ts-ignore
|
// @ts-ignore
|
||||||
import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObject, setBearerAuthToObject, setOAuthToObject, setSearchParams, serializeDataIfNeeded, toPathString, createRequestFunction } from './common';
|
import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObject, setBearerAuthToObject, setOAuthToObject, setSearchParams, serializeDataIfNeeded, toPathString, createRequestFunction } from './common';
|
||||||
|
import type { RequestArgs } from './base';
|
||||||
// @ts-ignore
|
// @ts-ignore
|
||||||
import { BASE_PATH, COLLECTION_FORMATS, RequestArgs, BaseAPI, RequiredError } from './base';
|
import { BASE_PATH, COLLECTION_FORMATS, BaseAPI, RequiredError } from './base';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
|
@ -13,10 +13,11 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
import { Configuration } from "./configuration";
|
import type { Configuration } from './configuration';
|
||||||
|
import type { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
|
||||||
// Some imports not used depending on template conditions
|
// Some imports not used depending on template conditions
|
||||||
// @ts-ignore
|
// @ts-ignore
|
||||||
import globalAxios, { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
|
import globalAxios from 'axios';
|
||||||
|
|
||||||
export const BASE_PATH = "http://api.example.xyz/v1".replace(/\/+$/, "");
|
export const BASE_PATH = "http://api.example.xyz/v1".replace(/\/+$/, "");
|
||||||
|
|
||||||
|
@ -13,9 +13,10 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
import { Configuration } from "./configuration";
|
import type { Configuration } from "./configuration";
|
||||||
import { RequiredError, RequestArgs } from "./base";
|
import type { RequestArgs } from "./base";
|
||||||
import { AxiosInstance, AxiosResponse } from 'axios';
|
import type { AxiosInstance, AxiosResponse } from 'axios';
|
||||||
|
import { RequiredError } from "./base";
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
|
@ -13,13 +13,15 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
import { Configuration } from './configuration';
|
import type { Configuration } from './configuration';
|
||||||
import globalAxios, { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
|
import type { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
|
||||||
|
import globalAxios from 'axios';
|
||||||
// Some imports not used depending on template conditions
|
// Some imports not used depending on template conditions
|
||||||
// @ts-ignore
|
// @ts-ignore
|
||||||
import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObject, setBearerAuthToObject, setOAuthToObject, setSearchParams, serializeDataIfNeeded, toPathString, createRequestFunction } from './common';
|
import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObject, setBearerAuthToObject, setOAuthToObject, setSearchParams, serializeDataIfNeeded, toPathString, createRequestFunction } from './common';
|
||||||
|
import type { RequestArgs } from './base';
|
||||||
// @ts-ignore
|
// @ts-ignore
|
||||||
import { BASE_PATH, COLLECTION_FORMATS, RequestArgs, BaseAPI, RequiredError } from './base';
|
import { BASE_PATH, COLLECTION_FORMATS, BaseAPI, RequiredError } from './base';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Describes the result of uploading an image resource
|
* Describes the result of uploading an image resource
|
||||||
|
@ -13,10 +13,11 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
import { Configuration } from "./configuration";
|
import type { Configuration } from './configuration';
|
||||||
|
import type { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
|
||||||
// Some imports not used depending on template conditions
|
// Some imports not used depending on template conditions
|
||||||
// @ts-ignore
|
// @ts-ignore
|
||||||
import globalAxios, { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
|
import globalAxios from 'axios';
|
||||||
|
|
||||||
export const BASE_PATH = "http://petstore.swagger.io/v2".replace(/\/+$/, "");
|
export const BASE_PATH = "http://petstore.swagger.io/v2".replace(/\/+$/, "");
|
||||||
|
|
||||||
|
@ -13,9 +13,10 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
import { Configuration } from "./configuration";
|
import type { Configuration } from "./configuration";
|
||||||
import { RequiredError, RequestArgs } from "./base";
|
import type { RequestArgs } from "./base";
|
||||||
import { AxiosInstance, AxiosResponse } from 'axios';
|
import type { AxiosInstance, AxiosResponse } from 'axios';
|
||||||
|
import { RequiredError } from "./base";
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
|
@ -13,13 +13,15 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
import { Configuration } from './configuration';
|
import type { Configuration } from './configuration';
|
||||||
import globalAxios, { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
|
import type { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
|
||||||
|
import globalAxios from 'axios';
|
||||||
// Some imports not used depending on template conditions
|
// Some imports not used depending on template conditions
|
||||||
// @ts-ignore
|
// @ts-ignore
|
||||||
import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObject, setBearerAuthToObject, setOAuthToObject, setSearchParams, serializeDataIfNeeded, toPathString, createRequestFunction } from './common';
|
import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObject, setBearerAuthToObject, setOAuthToObject, setSearchParams, serializeDataIfNeeded, toPathString, createRequestFunction } from './common';
|
||||||
|
import type { RequestArgs } from './base';
|
||||||
// @ts-ignore
|
// @ts-ignore
|
||||||
import { BASE_PATH, COLLECTION_FORMATS, RequestArgs, BaseAPI, RequiredError } from './base';
|
import { BASE_PATH, COLLECTION_FORMATS, BaseAPI, RequiredError } from './base';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Describes the result of uploading an image resource
|
* Describes the result of uploading an image resource
|
||||||
|
@ -13,10 +13,11 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
import { Configuration } from "./configuration";
|
import type { Configuration } from './configuration';
|
||||||
|
import type { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
|
||||||
// Some imports not used depending on template conditions
|
// Some imports not used depending on template conditions
|
||||||
// @ts-ignore
|
// @ts-ignore
|
||||||
import globalAxios, { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
|
import globalAxios from 'axios';
|
||||||
|
|
||||||
export const BASE_PATH = "http://petstore.swagger.io/v2".replace(/\/+$/, "");
|
export const BASE_PATH = "http://petstore.swagger.io/v2".replace(/\/+$/, "");
|
||||||
|
|
||||||
|
@ -13,9 +13,10 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
import { Configuration } from "./configuration";
|
import type { Configuration } from "./configuration";
|
||||||
import { RequiredError, RequestArgs } from "./base";
|
import type { RequestArgs } from "./base";
|
||||||
import { AxiosInstance, AxiosResponse } from 'axios';
|
import type { AxiosInstance, AxiosResponse } from 'axios';
|
||||||
|
import { RequiredError } from "./base";
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
|
@ -13,13 +13,15 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
import { Configuration } from './configuration';
|
import type { Configuration } from './configuration';
|
||||||
import globalAxios, { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
|
import type { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
|
||||||
|
import globalAxios from 'axios';
|
||||||
// Some imports not used depending on template conditions
|
// Some imports not used depending on template conditions
|
||||||
// @ts-ignore
|
// @ts-ignore
|
||||||
import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObject, setBearerAuthToObject, setOAuthToObject, setSearchParams, serializeDataIfNeeded, toPathString, createRequestFunction } from './common';
|
import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObject, setBearerAuthToObject, setOAuthToObject, setSearchParams, serializeDataIfNeeded, toPathString, createRequestFunction } from './common';
|
||||||
|
import type { RequestArgs } from './base';
|
||||||
// @ts-ignore
|
// @ts-ignore
|
||||||
import { BASE_PATH, COLLECTION_FORMATS, RequestArgs, BaseAPI, RequiredError } from './base';
|
import { BASE_PATH, COLLECTION_FORMATS, BaseAPI, RequiredError } from './base';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
|
@ -13,10 +13,11 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
import { Configuration } from "./configuration";
|
import type { Configuration } from './configuration';
|
||||||
|
import type { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
|
||||||
// Some imports not used depending on template conditions
|
// Some imports not used depending on template conditions
|
||||||
// @ts-ignore
|
// @ts-ignore
|
||||||
import globalAxios, { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
|
import globalAxios from 'axios';
|
||||||
|
|
||||||
export const BASE_PATH = "http://petstore.swagger.io:80/v2".replace(/\/+$/, "");
|
export const BASE_PATH = "http://petstore.swagger.io:80/v2".replace(/\/+$/, "");
|
||||||
|
|
||||||
|
@ -13,9 +13,10 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
import { Configuration } from "./configuration";
|
import type { Configuration } from "./configuration";
|
||||||
import { RequiredError, RequestArgs } from "./base";
|
import type { RequestArgs } from "./base";
|
||||||
import { AxiosInstance, AxiosResponse } from 'axios';
|
import type { AxiosInstance, AxiosResponse } from 'axios';
|
||||||
|
import { RequiredError } from "./base";
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
|
@ -13,13 +13,15 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
import { Configuration } from './configuration';
|
import type { Configuration } from './configuration';
|
||||||
import globalAxios, { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
|
import type { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
|
||||||
|
import globalAxios from 'axios';
|
||||||
// Some imports not used depending on template conditions
|
// Some imports not used depending on template conditions
|
||||||
// @ts-ignore
|
// @ts-ignore
|
||||||
import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObject, setBearerAuthToObject, setOAuthToObject, setSearchParams, serializeDataIfNeeded, toPathString, createRequestFunction } from './common';
|
import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObject, setBearerAuthToObject, setOAuthToObject, setSearchParams, serializeDataIfNeeded, toPathString, createRequestFunction } from './common';
|
||||||
|
import type { RequestArgs } from './base';
|
||||||
// @ts-ignore
|
// @ts-ignore
|
||||||
import { BASE_PATH, COLLECTION_FORMATS, RequestArgs, BaseAPI, RequiredError } from './base';
|
import { BASE_PATH, COLLECTION_FORMATS, BaseAPI, RequiredError } from './base';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Describes the result of uploading an image resource
|
* Describes the result of uploading an image resource
|
||||||
|
@ -13,10 +13,11 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
import { Configuration } from "./configuration";
|
import type { Configuration } from './configuration';
|
||||||
|
import type { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
|
||||||
// Some imports not used depending on template conditions
|
// Some imports not used depending on template conditions
|
||||||
// @ts-ignore
|
// @ts-ignore
|
||||||
import globalAxios, { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
|
import globalAxios from 'axios';
|
||||||
|
|
||||||
export const BASE_PATH = "http://petstore.swagger.io/v2".replace(/\/+$/, "");
|
export const BASE_PATH = "http://petstore.swagger.io/v2".replace(/\/+$/, "");
|
||||||
|
|
||||||
|
@ -13,9 +13,10 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
import { Configuration } from "./configuration";
|
import type { Configuration } from "./configuration";
|
||||||
import { RequiredError, RequestArgs } from "./base";
|
import type { RequestArgs } from "./base";
|
||||||
import { AxiosInstance, AxiosResponse } from 'axios';
|
import type { AxiosInstance, AxiosResponse } from 'axios';
|
||||||
|
import { RequiredError } from "./base";
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
|
@ -13,13 +13,15 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
import { Configuration } from './configuration';
|
import type { Configuration } from './configuration';
|
||||||
import globalAxios, { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
|
import type { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
|
||||||
|
import globalAxios from 'axios';
|
||||||
// Some imports not used depending on template conditions
|
// Some imports not used depending on template conditions
|
||||||
// @ts-ignore
|
// @ts-ignore
|
||||||
import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObject, setBearerAuthToObject, setOAuthToObject, setSearchParams, serializeDataIfNeeded, toPathString, createRequestFunction } from './common';
|
import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObject, setBearerAuthToObject, setOAuthToObject, setSearchParams, serializeDataIfNeeded, toPathString, createRequestFunction } from './common';
|
||||||
|
import type { RequestArgs } from './base';
|
||||||
// @ts-ignore
|
// @ts-ignore
|
||||||
import { BASE_PATH, COLLECTION_FORMATS, RequestArgs, BaseAPI, RequiredError } from './base';
|
import { BASE_PATH, COLLECTION_FORMATS, BaseAPI, RequiredError } from './base';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
|
@ -13,10 +13,11 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
import { Configuration } from "./configuration";
|
import type { Configuration } from './configuration';
|
||||||
|
import type { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
|
||||||
// Some imports not used depending on template conditions
|
// Some imports not used depending on template conditions
|
||||||
// @ts-ignore
|
// @ts-ignore
|
||||||
import globalAxios, { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
|
import globalAxios from 'axios';
|
||||||
|
|
||||||
export const BASE_PATH = "http://petstore.swagger.io:80/v2".replace(/\/+$/, "");
|
export const BASE_PATH = "http://petstore.swagger.io:80/v2".replace(/\/+$/, "");
|
||||||
|
|
||||||
|
@ -13,9 +13,10 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
import { Configuration } from "./configuration";
|
import type { Configuration } from "./configuration";
|
||||||
import { RequiredError, RequestArgs } from "./base";
|
import type { RequestArgs } from "./base";
|
||||||
import { AxiosInstance, AxiosResponse } from 'axios';
|
import type { AxiosInstance, AxiosResponse } from 'axios';
|
||||||
|
import { RequiredError } from "./base";
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
|
@ -13,13 +13,15 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
import { Configuration } from './configuration';
|
import type { Configuration } from './configuration';
|
||||||
import globalAxios, { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
|
import type { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
|
||||||
|
import globalAxios from 'axios';
|
||||||
// Some imports not used depending on template conditions
|
// Some imports not used depending on template conditions
|
||||||
// @ts-ignore
|
// @ts-ignore
|
||||||
import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObject, setBearerAuthToObject, setOAuthToObject, setSearchParams, serializeDataIfNeeded, toPathString, createRequestFunction } from './common';
|
import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObject, setBearerAuthToObject, setOAuthToObject, setSearchParams, serializeDataIfNeeded, toPathString, createRequestFunction } from './common';
|
||||||
|
import type { RequestArgs } from './base';
|
||||||
// @ts-ignore
|
// @ts-ignore
|
||||||
import { BASE_PATH, COLLECTION_FORMATS, RequestArgs, BaseAPI, RequiredError } from './base';
|
import { BASE_PATH, COLLECTION_FORMATS, BaseAPI, RequiredError } from './base';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Describes the result of uploading an image resource
|
* Describes the result of uploading an image resource
|
||||||
|
@ -13,10 +13,11 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
import { Configuration } from "./configuration";
|
import type { Configuration } from './configuration';
|
||||||
|
import type { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
|
||||||
// Some imports not used depending on template conditions
|
// Some imports not used depending on template conditions
|
||||||
// @ts-ignore
|
// @ts-ignore
|
||||||
import globalAxios, { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
|
import globalAxios from 'axios';
|
||||||
|
|
||||||
export const BASE_PATH = "http://petstore.swagger.io/v2".replace(/\/+$/, "");
|
export const BASE_PATH = "http://petstore.swagger.io/v2".replace(/\/+$/, "");
|
||||||
|
|
||||||
|
@ -13,9 +13,10 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
import { Configuration } from "./configuration";
|
import type { Configuration } from "./configuration";
|
||||||
import { RequiredError, RequestArgs } from "./base";
|
import type { RequestArgs } from "./base";
|
||||||
import { AxiosInstance, AxiosResponse } from 'axios';
|
import type { AxiosInstance, AxiosResponse } from 'axios';
|
||||||
|
import { RequiredError } from "./base";
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
|
@ -13,8 +13,9 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
import { Configuration } from './configuration';
|
import type { Configuration } from './configuration';
|
||||||
import globalAxios, { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
|
import type { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
|
||||||
|
import globalAxios from 'axios';
|
||||||
// URLSearchParams not necessarily used
|
// URLSearchParams not necessarily used
|
||||||
// @ts-ignore
|
// @ts-ignore
|
||||||
import { URL, URLSearchParams } from 'url';
|
import { URL, URLSearchParams } from 'url';
|
||||||
@ -22,8 +23,9 @@ import FormData from 'form-data'
|
|||||||
// Some imports not used depending on template conditions
|
// Some imports not used depending on template conditions
|
||||||
// @ts-ignore
|
// @ts-ignore
|
||||||
import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObject, setBearerAuthToObject, setOAuthToObject, setSearchParams, serializeDataIfNeeded, toPathString, createRequestFunction } from './common';
|
import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObject, setBearerAuthToObject, setOAuthToObject, setSearchParams, serializeDataIfNeeded, toPathString, createRequestFunction } from './common';
|
||||||
|
import type { RequestArgs } from './base';
|
||||||
// @ts-ignore
|
// @ts-ignore
|
||||||
import { BASE_PATH, COLLECTION_FORMATS, RequestArgs, BaseAPI, RequiredError } from './base';
|
import { BASE_PATH, COLLECTION_FORMATS, BaseAPI, RequiredError } from './base';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Describes the result of uploading an image resource
|
* Describes the result of uploading an image resource
|
||||||
|
@ -13,10 +13,11 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
import { Configuration } from "./configuration";
|
import type { Configuration } from './configuration';
|
||||||
|
import type { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
|
||||||
// Some imports not used depending on template conditions
|
// Some imports not used depending on template conditions
|
||||||
// @ts-ignore
|
// @ts-ignore
|
||||||
import globalAxios, { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
|
import globalAxios from 'axios';
|
||||||
|
|
||||||
export const BASE_PATH = "http://petstore.swagger.io/v2".replace(/\/+$/, "");
|
export const BASE_PATH = "http://petstore.swagger.io/v2".replace(/\/+$/, "");
|
||||||
|
|
||||||
|
@ -13,9 +13,10 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
import { Configuration } from "./configuration";
|
import type { Configuration } from "./configuration";
|
||||||
import { RequiredError, RequestArgs } from "./base";
|
import type { RequestArgs } from "./base";
|
||||||
import { AxiosInstance, AxiosResponse } from 'axios';
|
import type { AxiosInstance, AxiosResponse } from 'axios';
|
||||||
|
import { RequiredError } from "./base";
|
||||||
import { URL, URLSearchParams } from 'url';
|
import { URL, URLSearchParams } from 'url';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -13,8 +13,9 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
import globalAxios, { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
|
import type { Configuration } from '../../../configuration';
|
||||||
import { Configuration } from '../../../configuration';
|
import type { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
|
||||||
|
import globalAxios from 'axios';
|
||||||
// Some imports not used depending on template conditions
|
// Some imports not used depending on template conditions
|
||||||
// @ts-ignore
|
// @ts-ignore
|
||||||
import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObject, setBearerAuthToObject, setOAuthToObject, setSearchParams, serializeDataIfNeeded, toPathString, createRequestFunction } from '../../../common';
|
import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObject, setBearerAuthToObject, setOAuthToObject, setSearchParams, serializeDataIfNeeded, toPathString, createRequestFunction } from '../../../common';
|
||||||
|
@ -13,8 +13,9 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
import globalAxios, { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
|
import type { Configuration } from '../../../configuration';
|
||||||
import { Configuration } from '../../../configuration';
|
import type { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
|
||||||
|
import globalAxios from 'axios';
|
||||||
// Some imports not used depending on template conditions
|
// Some imports not used depending on template conditions
|
||||||
// @ts-ignore
|
// @ts-ignore
|
||||||
import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObject, setBearerAuthToObject, setOAuthToObject, setSearchParams, serializeDataIfNeeded, toPathString, createRequestFunction } from '../../../common';
|
import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObject, setBearerAuthToObject, setOAuthToObject, setSearchParams, serializeDataIfNeeded, toPathString, createRequestFunction } from '../../../common';
|
||||||
|
@ -13,8 +13,9 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
import globalAxios, { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
|
import type { Configuration } from '../../../configuration';
|
||||||
import { Configuration } from '../../../configuration';
|
import type { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
|
||||||
|
import globalAxios from 'axios';
|
||||||
// Some imports not used depending on template conditions
|
// Some imports not used depending on template conditions
|
||||||
// @ts-ignore
|
// @ts-ignore
|
||||||
import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObject, setBearerAuthToObject, setOAuthToObject, setSearchParams, serializeDataIfNeeded, toPathString, createRequestFunction } from '../../../common';
|
import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObject, setBearerAuthToObject, setOAuthToObject, setSearchParams, serializeDataIfNeeded, toPathString, createRequestFunction } from '../../../common';
|
||||||
|
@ -13,10 +13,11 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
import { Configuration } from "./configuration";
|
import type { Configuration } from './configuration';
|
||||||
|
import type { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
|
||||||
// Some imports not used depending on template conditions
|
// Some imports not used depending on template conditions
|
||||||
// @ts-ignore
|
// @ts-ignore
|
||||||
import globalAxios, { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
|
import globalAxios from 'axios';
|
||||||
|
|
||||||
export const BASE_PATH = "http://petstore.swagger.io/v2".replace(/\/+$/, "");
|
export const BASE_PATH = "http://petstore.swagger.io/v2".replace(/\/+$/, "");
|
||||||
|
|
||||||
|
@ -13,9 +13,10 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
import { Configuration } from "./configuration";
|
import type { Configuration } from "./configuration";
|
||||||
import { RequiredError, RequestArgs } from "./base";
|
import type { RequestArgs } from "./base";
|
||||||
import { AxiosInstance, AxiosResponse } from 'axios';
|
import type { AxiosInstance, AxiosResponse } from 'axios';
|
||||||
|
import { RequiredError } from "./base";
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
|
@ -13,13 +13,15 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
import { Configuration } from './configuration';
|
import type { Configuration } from './configuration';
|
||||||
import globalAxios, { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
|
import type { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
|
||||||
|
import globalAxios from 'axios';
|
||||||
// Some imports not used depending on template conditions
|
// Some imports not used depending on template conditions
|
||||||
// @ts-ignore
|
// @ts-ignore
|
||||||
import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObject, setBearerAuthToObject, setOAuthToObject, setSearchParams, serializeDataIfNeeded, toPathString, createRequestFunction } from './common';
|
import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObject, setBearerAuthToObject, setOAuthToObject, setSearchParams, serializeDataIfNeeded, toPathString, createRequestFunction } from './common';
|
||||||
|
import type { RequestArgs } from './base';
|
||||||
// @ts-ignore
|
// @ts-ignore
|
||||||
import { BASE_PATH, COLLECTION_FORMATS, RequestArgs, BaseAPI, RequiredError } from './base';
|
import { BASE_PATH, COLLECTION_FORMATS, BaseAPI, RequiredError } from './base';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Describes the result of uploading an image resource
|
* Describes the result of uploading an image resource
|
||||||
|
@ -13,10 +13,11 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
import { Configuration } from "./configuration";
|
import type { Configuration } from './configuration';
|
||||||
|
import type { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
|
||||||
// Some imports not used depending on template conditions
|
// Some imports not used depending on template conditions
|
||||||
// @ts-ignore
|
// @ts-ignore
|
||||||
import globalAxios, { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
|
import globalAxios from 'axios';
|
||||||
|
|
||||||
export const BASE_PATH = "http://petstore.swagger.io/v2".replace(/\/+$/, "");
|
export const BASE_PATH = "http://petstore.swagger.io/v2".replace(/\/+$/, "");
|
||||||
|
|
||||||
|
@ -13,9 +13,10 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
import { Configuration } from "./configuration";
|
import type { Configuration } from "./configuration";
|
||||||
import { RequiredError, RequestArgs } from "./base";
|
import type { RequestArgs } from "./base";
|
||||||
import { AxiosInstance, AxiosResponse } from 'axios';
|
import type { AxiosInstance, AxiosResponse } from 'axios';
|
||||||
|
import { RequiredError } from "./base";
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
|
@ -13,13 +13,15 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
import { Configuration } from './configuration';
|
import type { Configuration } from './configuration';
|
||||||
import globalAxios, { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
|
import type { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
|
||||||
|
import globalAxios from 'axios';
|
||||||
// Some imports not used depending on template conditions
|
// Some imports not used depending on template conditions
|
||||||
// @ts-ignore
|
// @ts-ignore
|
||||||
import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObject, setBearerAuthToObject, setOAuthToObject, setSearchParams, serializeDataIfNeeded, toPathString, createRequestFunction } from './common';
|
import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObject, setBearerAuthToObject, setOAuthToObject, setSearchParams, serializeDataIfNeeded, toPathString, createRequestFunction } from './common';
|
||||||
|
import type { RequestArgs } from './base';
|
||||||
// @ts-ignore
|
// @ts-ignore
|
||||||
import { BASE_PATH, COLLECTION_FORMATS, RequestArgs, BaseAPI, RequiredError } from './base';
|
import { BASE_PATH, COLLECTION_FORMATS, BaseAPI, RequiredError } from './base';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Describes the result of uploading an image resource
|
* Describes the result of uploading an image resource
|
||||||
|
@ -13,10 +13,11 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
import { Configuration } from "./configuration";
|
import type { Configuration } from './configuration';
|
||||||
|
import type { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
|
||||||
// Some imports not used depending on template conditions
|
// Some imports not used depending on template conditions
|
||||||
// @ts-ignore
|
// @ts-ignore
|
||||||
import globalAxios, { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
|
import globalAxios from 'axios';
|
||||||
|
|
||||||
export const BASE_PATH = "http://petstore.swagger.io/v2".replace(/\/+$/, "");
|
export const BASE_PATH = "http://petstore.swagger.io/v2".replace(/\/+$/, "");
|
||||||
|
|
||||||
|
@ -13,9 +13,10 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
import { Configuration } from "./configuration";
|
import type { Configuration } from "./configuration";
|
||||||
import { RequiredError, RequestArgs } from "./base";
|
import type { RequestArgs } from "./base";
|
||||||
import { AxiosInstance, AxiosResponse } from 'axios';
|
import type { AxiosInstance, AxiosResponse } from 'axios';
|
||||||
|
import { RequiredError } from "./base";
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
|
@ -13,13 +13,15 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
import { Configuration } from './configuration';
|
import type { Configuration } from './configuration';
|
||||||
import globalAxios, { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
|
import type { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
|
||||||
|
import globalAxios from 'axios';
|
||||||
// Some imports not used depending on template conditions
|
// Some imports not used depending on template conditions
|
||||||
// @ts-ignore
|
// @ts-ignore
|
||||||
import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObject, setBearerAuthToObject, setOAuthToObject, setSearchParams, serializeDataIfNeeded, toPathString, createRequestFunction } from './common';
|
import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObject, setBearerAuthToObject, setOAuthToObject, setSearchParams, serializeDataIfNeeded, toPathString, createRequestFunction } from './common';
|
||||||
|
import type { RequestArgs } from './base';
|
||||||
// @ts-ignore
|
// @ts-ignore
|
||||||
import { BASE_PATH, COLLECTION_FORMATS, RequestArgs, BaseAPI, RequiredError } from './base';
|
import { BASE_PATH, COLLECTION_FORMATS, BaseAPI, RequiredError } from './base';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Describes the result of uploading an image resource
|
* Describes the result of uploading an image resource
|
||||||
|
@ -13,10 +13,11 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
import { Configuration } from "./configuration";
|
import type { Configuration } from './configuration';
|
||||||
|
import type { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
|
||||||
// Some imports not used depending on template conditions
|
// Some imports not used depending on template conditions
|
||||||
// @ts-ignore
|
// @ts-ignore
|
||||||
import globalAxios, { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios';
|
import globalAxios from 'axios';
|
||||||
|
|
||||||
export const BASE_PATH = "http://petstore.swagger.io/v2".replace(/\/+$/, "");
|
export const BASE_PATH = "http://petstore.swagger.io/v2".replace(/\/+$/, "");
|
||||||
|
|
||||||
|
@ -13,9 +13,10 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
import { Configuration } from "./configuration";
|
import type { Configuration } from "./configuration";
|
||||||
import { RequiredError, RequestArgs } from "./base";
|
import type { RequestArgs } from "./base";
|
||||||
import { AxiosInstance, AxiosResponse } from 'axios';
|
import type { AxiosInstance, AxiosResponse } from 'axios';
|
||||||
|
import { RequiredError } from "./base";
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
|
Loading…
x
Reference in New Issue
Block a user