@takaro/apiclient 0.0.0-dev.28828af

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (53) hide show
  1. package/README.md +32 -0
  2. package/dist/generated/api.d.ts +21285 -0
  3. package/dist/generated/api.d.ts.map +1 -0
  4. package/dist/generated/api.js +14416 -0
  5. package/dist/generated/api.js.map +1 -0
  6. package/dist/generated/base.d.ts +67 -0
  7. package/dist/generated/base.d.ts.map +1 -0
  8. package/dist/generated/base.js +59 -0
  9. package/dist/generated/base.js.map +1 -0
  10. package/dist/generated/common.d.ts +66 -0
  11. package/dist/generated/common.d.ts.map +1 -0
  12. package/dist/generated/common.js +135 -0
  13. package/dist/generated/common.js.map +1 -0
  14. package/dist/generated/configuration.d.ts +92 -0
  15. package/dist/generated/configuration.d.ts.map +1 -0
  16. package/dist/generated/configuration.js +46 -0
  17. package/dist/generated/configuration.js.map +1 -0
  18. package/dist/generated/index.d.ts +14 -0
  19. package/dist/generated/index.d.ts.map +1 -0
  20. package/dist/generated/index.js +16 -0
  21. package/dist/generated/index.js.map +1 -0
  22. package/dist/lib/adminClient.d.ts +13 -0
  23. package/dist/lib/adminClient.d.ts.map +1 -0
  24. package/dist/lib/adminClient.js +23 -0
  25. package/dist/lib/adminClient.js.map +1 -0
  26. package/dist/lib/baseClient.d.ts +31 -0
  27. package/dist/lib/baseClient.d.ts.map +1 -0
  28. package/dist/lib/baseClient.js +113 -0
  29. package/dist/lib/baseClient.js.map +1 -0
  30. package/dist/lib/client.d.ts +43 -0
  31. package/dist/lib/client.d.ts.map +1 -0
  32. package/dist/lib/client.js +154 -0
  33. package/dist/lib/client.js.map +1 -0
  34. package/dist/main.d.ts +8 -0
  35. package/dist/main.d.ts.map +1 -0
  36. package/dist/main.js +5 -0
  37. package/dist/main.js.map +1 -0
  38. package/package.json +23 -0
  39. package/src/__tests__/main.integration.test.ts +39 -0
  40. package/src/generated/.openapi-generator-ignore +23 -0
  41. package/src/generated/api.ts +32740 -0
  42. package/src/generated/base.ts +91 -0
  43. package/src/generated/common.ts +164 -0
  44. package/src/generated/configuration.ts +123 -0
  45. package/src/generated/git_push.sh +57 -0
  46. package/src/generated/index.ts +16 -0
  47. package/src/lib/adminClient.ts +37 -0
  48. package/src/lib/baseClient.ts +153 -0
  49. package/src/lib/client.ts +308 -0
  50. package/src/main.ts +9 -0
  51. package/tsconfig.build.json +10 -0
  52. package/tsconfig.json +8 -0
  53. package/typedoc.json +3 -0
@@ -0,0 +1,91 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * Takaro app-api
5
+ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
6
+ *
7
+ * The version of the OpenAPI document: 0.0.0
8
+ * Contact: support@takaro.io
9
+ *
10
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
+ * https://openapi-generator.tech
12
+ * Do not edit the class manually.
13
+ */
14
+
15
+ import type { Configuration } from './configuration.js';
16
+ // Some imports not used depending on template conditions
17
+ // @ts-ignore
18
+ import type { AxiosPromise, AxiosInstance, RawAxiosRequestConfig } from 'axios';
19
+ import globalAxios from 'axios';
20
+
21
+ export const BASE_PATH = 'http://localhost'.replace(/\/+$/, '');
22
+
23
+ /**
24
+ *
25
+ * @export
26
+ */
27
+ export const COLLECTION_FORMATS = {
28
+ csv: ',',
29
+ ssv: ' ',
30
+ tsv: '\t',
31
+ pipes: '|',
32
+ };
33
+
34
+ /**
35
+ *
36
+ * @export
37
+ * @interface RequestArgs
38
+ */
39
+ export interface RequestArgs {
40
+ url: string;
41
+ options: RawAxiosRequestConfig;
42
+ }
43
+
44
+ /**
45
+ *
46
+ * @export
47
+ * @class BaseAPI
48
+ */
49
+ export class BaseAPI {
50
+ protected configuration: Configuration | undefined;
51
+
52
+ constructor(
53
+ configuration?: Configuration,
54
+ protected basePath: string = BASE_PATH,
55
+ protected axios: AxiosInstance = globalAxios,
56
+ ) {
57
+ if (configuration) {
58
+ this.configuration = configuration;
59
+ this.basePath = configuration.basePath ?? basePath;
60
+ }
61
+ }
62
+ }
63
+
64
+ /**
65
+ *
66
+ * @export
67
+ * @class RequiredError
68
+ * @extends {Error}
69
+ */
70
+ export class RequiredError extends Error {
71
+ constructor(
72
+ public field: string,
73
+ msg?: string,
74
+ ) {
75
+ super(msg);
76
+ this.name = 'RequiredError';
77
+ }
78
+ }
79
+
80
+ interface ServerMap {
81
+ [key: string]: {
82
+ url: string;
83
+ description: string;
84
+ }[];
85
+ }
86
+
87
+ /**
88
+ *
89
+ * @export
90
+ */
91
+ export const operationServerMap: ServerMap = {};
@@ -0,0 +1,164 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * Takaro app-api
5
+ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
6
+ *
7
+ * The version of the OpenAPI document: 0.0.0
8
+ * Contact: support@takaro.io
9
+ *
10
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
+ * https://openapi-generator.tech
12
+ * Do not edit the class manually.
13
+ */
14
+
15
+ import type { Configuration } from './configuration.js';
16
+ import type { RequestArgs } from './base.js';
17
+ import type { AxiosInstance, AxiosResponse } from 'axios';
18
+ import { RequiredError } from './base.js';
19
+
20
+ /**
21
+ *
22
+ * @export
23
+ */
24
+ export const DUMMY_BASE_URL = 'https://example.com';
25
+
26
+ /**
27
+ *
28
+ * @throws {RequiredError}
29
+ * @export
30
+ */
31
+ export const assertParamExists = function (functionName: string, paramName: string, paramValue: unknown) {
32
+ if (paramValue === null || paramValue === undefined) {
33
+ throw new RequiredError(
34
+ paramName,
35
+ `Required parameter ${paramName} was null or undefined when calling ${functionName}.`,
36
+ );
37
+ }
38
+ };
39
+
40
+ /**
41
+ *
42
+ * @export
43
+ */
44
+ export const setApiKeyToObject = async function (object: any, keyParamName: string, configuration?: Configuration) {
45
+ if (configuration && configuration.apiKey) {
46
+ const localVarApiKeyValue =
47
+ typeof configuration.apiKey === 'function'
48
+ ? await configuration.apiKey(keyParamName)
49
+ : await configuration.apiKey;
50
+ object[keyParamName] = localVarApiKeyValue;
51
+ }
52
+ };
53
+
54
+ /**
55
+ *
56
+ * @export
57
+ */
58
+ export const setBasicAuthToObject = function (object: any, configuration?: Configuration) {
59
+ if (configuration && (configuration.username || configuration.password)) {
60
+ object['auth'] = { username: configuration.username, password: configuration.password };
61
+ }
62
+ };
63
+
64
+ /**
65
+ *
66
+ * @export
67
+ */
68
+ export const setBearerAuthToObject = async function (object: any, configuration?: Configuration) {
69
+ if (configuration && configuration.accessToken) {
70
+ const accessToken =
71
+ typeof configuration.accessToken === 'function'
72
+ ? await configuration.accessToken()
73
+ : await configuration.accessToken;
74
+ object['Authorization'] = 'Bearer ' + accessToken;
75
+ }
76
+ };
77
+
78
+ /**
79
+ *
80
+ * @export
81
+ */
82
+ export const setOAuthToObject = async function (
83
+ object: any,
84
+ name: string,
85
+ scopes: string[],
86
+ configuration?: Configuration,
87
+ ) {
88
+ if (configuration && configuration.accessToken) {
89
+ const localVarAccessTokenValue =
90
+ typeof configuration.accessToken === 'function'
91
+ ? await configuration.accessToken(name, scopes)
92
+ : await configuration.accessToken;
93
+ object['Authorization'] = 'Bearer ' + localVarAccessTokenValue;
94
+ }
95
+ };
96
+
97
+ function setFlattenedQueryParams(urlSearchParams: URLSearchParams, parameter: any, key: string = ''): void {
98
+ if (parameter == null) return;
99
+ if (typeof parameter === 'object') {
100
+ if (Array.isArray(parameter)) {
101
+ (parameter as any[]).forEach((item) => setFlattenedQueryParams(urlSearchParams, item, key));
102
+ } else {
103
+ Object.keys(parameter).forEach((currentKey) =>
104
+ setFlattenedQueryParams(urlSearchParams, parameter[currentKey], `${key}${key !== '' ? '.' : ''}${currentKey}`),
105
+ );
106
+ }
107
+ } else {
108
+ if (urlSearchParams.has(key)) {
109
+ urlSearchParams.append(key, parameter);
110
+ } else {
111
+ urlSearchParams.set(key, parameter);
112
+ }
113
+ }
114
+ }
115
+
116
+ /**
117
+ *
118
+ * @export
119
+ */
120
+ export const setSearchParams = function (url: URL, ...objects: any[]) {
121
+ const searchParams = new URLSearchParams(url.search);
122
+ setFlattenedQueryParams(searchParams, objects);
123
+ url.search = searchParams.toString();
124
+ };
125
+
126
+ /**
127
+ *
128
+ * @export
129
+ */
130
+ export const serializeDataIfNeeded = function (value: any, requestOptions: any, configuration?: Configuration) {
131
+ const nonString = typeof value !== 'string';
132
+ const needsSerialization =
133
+ nonString && configuration && configuration.isJsonMime
134
+ ? configuration.isJsonMime(requestOptions.headers['Content-Type'])
135
+ : nonString;
136
+ return needsSerialization ? JSON.stringify(value !== undefined ? value : {}) : value || '';
137
+ };
138
+
139
+ /**
140
+ *
141
+ * @export
142
+ */
143
+ export const toPathString = function (url: URL) {
144
+ return url.pathname + url.search + url.hash;
145
+ };
146
+
147
+ /**
148
+ *
149
+ * @export
150
+ */
151
+ export const createRequestFunction = function (
152
+ axiosArgs: RequestArgs,
153
+ globalAxios: AxiosInstance,
154
+ BASE_PATH: string,
155
+ configuration?: Configuration,
156
+ ) {
157
+ return <T = unknown, R = AxiosResponse<T>>(axios: AxiosInstance = globalAxios, basePath: string = BASE_PATH) => {
158
+ const axiosRequestArgs = {
159
+ ...axiosArgs.options,
160
+ url: (axios.defaults.baseURL ? '' : (configuration?.basePath ?? basePath)) + axiosArgs.url,
161
+ };
162
+ return axios.request<T, R>(axiosRequestArgs);
163
+ };
164
+ };
@@ -0,0 +1,123 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * Takaro app-api
5
+ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
6
+ *
7
+ * The version of the OpenAPI document: 0.0.0
8
+ * Contact: support@takaro.io
9
+ *
10
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
+ * https://openapi-generator.tech
12
+ * Do not edit the class manually.
13
+ */
14
+
15
+ export interface ConfigurationParameters {
16
+ apiKey?: string | Promise<string> | ((name: string) => string) | ((name: string) => Promise<string>);
17
+ username?: string;
18
+ password?: string;
19
+ accessToken?:
20
+ | string
21
+ | Promise<string>
22
+ | ((name?: string, scopes?: string[]) => string)
23
+ | ((name?: string, scopes?: string[]) => Promise<string>);
24
+ basePath?: string;
25
+ serverIndex?: number;
26
+ baseOptions?: any;
27
+ formDataCtor?: new () => any;
28
+ }
29
+
30
+ export class Configuration {
31
+ /**
32
+ * parameter for apiKey security
33
+ * @param name security name
34
+ * @memberof Configuration
35
+ */
36
+ apiKey?: string | Promise<string> | ((name: string) => string) | ((name: string) => Promise<string>);
37
+ /**
38
+ * parameter for basic security
39
+ *
40
+ * @type {string}
41
+ * @memberof Configuration
42
+ */
43
+ username?: string;
44
+ /**
45
+ * parameter for basic security
46
+ *
47
+ * @type {string}
48
+ * @memberof Configuration
49
+ */
50
+ password?: string;
51
+ /**
52
+ * parameter for oauth2 security
53
+ * @param name security name
54
+ * @param scopes oauth2 scope
55
+ * @memberof Configuration
56
+ */
57
+ accessToken?:
58
+ | string
59
+ | Promise<string>
60
+ | ((name?: string, scopes?: string[]) => string)
61
+ | ((name?: string, scopes?: string[]) => Promise<string>);
62
+ /**
63
+ * override base path
64
+ *
65
+ * @type {string}
66
+ * @memberof Configuration
67
+ */
68
+ basePath?: string;
69
+ /**
70
+ * override server index
71
+ *
72
+ * @type {number}
73
+ * @memberof Configuration
74
+ */
75
+ serverIndex?: number;
76
+ /**
77
+ * base options for axios calls
78
+ *
79
+ * @type {any}
80
+ * @memberof Configuration
81
+ */
82
+ baseOptions?: any;
83
+ /**
84
+ * The FormData constructor that will be used to create multipart form data
85
+ * requests. You can inject this here so that execution environments that
86
+ * do not support the FormData class can still run the generated client.
87
+ *
88
+ * @type {new () => FormData}
89
+ */
90
+ formDataCtor?: new () => any;
91
+
92
+ constructor(param: ConfigurationParameters = {}) {
93
+ this.apiKey = param.apiKey;
94
+ this.username = param.username;
95
+ this.password = param.password;
96
+ this.accessToken = param.accessToken;
97
+ this.basePath = param.basePath;
98
+ this.serverIndex = param.serverIndex;
99
+ this.baseOptions = {
100
+ headers: {
101
+ ...param.baseOptions?.headers,
102
+ 'User-Agent': 'OpenAPI-Generator/typescript-axios',
103
+ },
104
+ ...param.baseOptions,
105
+ };
106
+ this.formDataCtor = param.formDataCtor;
107
+ }
108
+
109
+ /**
110
+ * Check if the given MIME is a JSON MIME.
111
+ * JSON MIME examples:
112
+ * application/json
113
+ * application/json; charset=UTF8
114
+ * APPLICATION/JSON
115
+ * application/vnd.company+json
116
+ * @param mime - MIME (Multipurpose Internet Mail Extensions)
117
+ * @return True if the given MIME is JSON, false otherwise.
118
+ */
119
+ public isJsonMime(mime: string): boolean {
120
+ const jsonMime: RegExp = new RegExp('^(application/json|[^;/ \t]+/[^;/ \t]+[+]json)[ \t]*(;.*)?$', 'i');
121
+ return mime !== null && (jsonMime.test(mime) || mime.toLowerCase() === 'application/json-patch+json');
122
+ }
123
+ }
@@ -0,0 +1,57 @@
1
+ #!/bin/sh
2
+ # ref: https://help.github.com/articles/adding-an-existing-project-to-github-using-the-command-line/
3
+ #
4
+ # Usage example: /bin/sh ./git_push.sh wing328 openapi-petstore-perl "minor update" "gitlab.com"
5
+
6
+ git_user_id=$1
7
+ git_repo_id=$2
8
+ release_note=$3
9
+ git_host=$4
10
+
11
+ if [ "$git_host" = "" ]; then
12
+ git_host="github.com"
13
+ echo "[INFO] No command line input provided. Set \$git_host to $git_host"
14
+ fi
15
+
16
+ if [ "$git_user_id" = "" ]; then
17
+ git_user_id="GIT_USER_ID"
18
+ echo "[INFO] No command line input provided. Set \$git_user_id to $git_user_id"
19
+ fi
20
+
21
+ if [ "$git_repo_id" = "" ]; then
22
+ git_repo_id="GIT_REPO_ID"
23
+ echo "[INFO] No command line input provided. Set \$git_repo_id to $git_repo_id"
24
+ fi
25
+
26
+ if [ "$release_note" = "" ]; then
27
+ release_note="Minor update"
28
+ echo "[INFO] No command line input provided. Set \$release_note to $release_note"
29
+ fi
30
+
31
+ # Initialize the local directory as a Git repository
32
+ git init
33
+
34
+ # Adds the files in the local repository and stages them for commit.
35
+ git add .
36
+
37
+ # Commits the tracked changes and prepares them to be pushed to a remote repository.
38
+ git commit -m "$release_note"
39
+
40
+ # Sets the new remote
41
+ git_remote=$(git remote)
42
+ if [ "$git_remote" = "" ]; then # git remote not defined
43
+
44
+ if [ "$GIT_TOKEN" = "" ]; then
45
+ echo "[INFO] \$GIT_TOKEN (environment variable) is not set. Using the git credential in your environment."
46
+ git remote add origin https://${git_host}/${git_user_id}/${git_repo_id}.git
47
+ else
48
+ git remote add origin https://${git_user_id}:"${GIT_TOKEN}"@${git_host}/${git_user_id}/${git_repo_id}.git
49
+ fi
50
+
51
+ fi
52
+
53
+ git pull origin master
54
+
55
+ # Pushes (Forces) the changes in the local repository up to the remote repository
56
+ echo "Git pushing to https://${git_host}/${git_user_id}/${git_repo_id}.git"
57
+ git push origin master 2>&1 | grep -v 'To https'
@@ -0,0 +1,16 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * Takaro app-api
5
+ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
6
+ *
7
+ * The version of the OpenAPI document: 0.0.0
8
+ * Contact: support@takaro.io
9
+ *
10
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
+ * https://openapi-generator.tech
12
+ * Do not edit the class manually.
13
+ */
14
+
15
+ export * from './api.js';
16
+ export * from './configuration.js';
@@ -0,0 +1,37 @@
1
+ import { DomainApi } from '../generated/index.js';
2
+ import { BaseApiClient, IBaseApiClientConfig } from './baseClient.js';
3
+ import { AxiosInstance } from 'axios';
4
+
5
+ export interface IAdminApiClientConfig extends IBaseApiClientConfig {
6
+ auth: {
7
+ clientSecret: string;
8
+ };
9
+ }
10
+
11
+ export class AdminClient extends BaseApiClient<IAdminApiClientConfig> {
12
+ constructor(config: IAdminApiClientConfig) {
13
+ super(config);
14
+ this.addAuthInterceptor(config.auth.clientSecret, this.axios);
15
+ }
16
+
17
+ private addAuthInterceptor(token: string, axios: AxiosInstance): AxiosInstance {
18
+ axios.interceptors.request.use(async (request) => {
19
+ if (request.url?.includes('health')) return request;
20
+
21
+ request.headers['X-Takaro-Admin-Token'] = token;
22
+ return request;
23
+ });
24
+
25
+ return axios;
26
+ }
27
+
28
+ get domain() {
29
+ return new DomainApi(
30
+ {
31
+ isJsonMime: this.isJsonMime,
32
+ },
33
+ '',
34
+ this.axios,
35
+ );
36
+ }
37
+ }
@@ -0,0 +1,153 @@
1
+ import { MetaApi } from '../generated/api.js';
2
+ import axios, { AxiosError, AxiosInstance, AxiosRequestConfig } from 'axios';
3
+
4
+ export interface IBaseApiClientConfig {
5
+ url: string;
6
+ log?: Logger | false;
7
+ }
8
+
9
+ interface Logger {
10
+ info: (msg: string, meta?: unknown) => void;
11
+ warn: (msg: string, meta?: unknown) => void;
12
+ error: (msg: string, meta?: unknown) => void;
13
+ debug: (msg: string, meta?: unknown) => void;
14
+ }
15
+
16
+ export class BaseApiClient<T extends IBaseApiClientConfig> {
17
+ protected axios: AxiosInstance;
18
+ protected log: Logger = {
19
+ error: () => {},
20
+ info: () => {},
21
+ warn: () => {},
22
+ debug: () => {},
23
+ };
24
+
25
+ constructor(protected readonly config: T) {
26
+ const axiosConfig: AxiosRequestConfig = {
27
+ baseURL: this.config.url,
28
+ headers: {
29
+ 'Content-Type': 'application/json',
30
+ 'User-Agent': 'Takaro-API-Client',
31
+ },
32
+ withCredentials: true,
33
+ };
34
+ this.axios = this.addLoggers(axios.create(axiosConfig));
35
+
36
+ if (this.config.log) this.log = this.config.log;
37
+ }
38
+
39
+ setHeader(key: string, value: string) {
40
+ this.axios.defaults.headers.common[key] = value;
41
+ }
42
+
43
+ setDomain(domainId: string) {
44
+ this.axios.defaults.headers.common['X-Takaro-Domain'] = domainId;
45
+ }
46
+
47
+ get axiosInstance() {
48
+ return this.axios;
49
+ }
50
+
51
+ isJsonMime(mime: string) {
52
+ return mime === 'application/json';
53
+ }
54
+
55
+ private addLoggers(axios: AxiosInstance): AxiosInstance {
56
+ if (this.config.log === false) {
57
+ return axios;
58
+ }
59
+
60
+ axios.interceptors.request.use((request) => {
61
+ let prettyBody = null;
62
+
63
+ if (request.data) {
64
+ try {
65
+ prettyBody = JSON.parse(request.data);
66
+ } catch {
67
+ prettyBody = 'Could not parse body';
68
+ }
69
+ }
70
+
71
+ this.log.info(`➡️ ${request.method?.toUpperCase()} ${request.url}`, {
72
+ method: request.method,
73
+ url: request.url,
74
+ body: prettyBody ?? undefined,
75
+ });
76
+ return request;
77
+ });
78
+
79
+ axios.interceptors.response.use(
80
+ (response) => {
81
+ this.log.info(
82
+ `⬅️ ${response.request.method?.toUpperCase()} ${response.request.path} ${response.status} ${
83
+ response.statusText
84
+ }`,
85
+ {
86
+ status: response.status,
87
+ statusText: response.statusText,
88
+ method: response.request.method,
89
+ url: response.request.url,
90
+ },
91
+ );
92
+
93
+ return response;
94
+ },
95
+ (error: AxiosError) => {
96
+ let details = {};
97
+
98
+ if (error.response?.data) {
99
+ const data = error.response.data as Record<string, unknown>;
100
+ details = JSON.stringify(data.meta);
101
+ }
102
+
103
+ this.log.error('☠️ Request errored', {
104
+ traceId: error.response?.headers['x-trace-id'],
105
+ details,
106
+ status: error.response?.status,
107
+ statusText: error.response?.statusText,
108
+ method: error.config?.method,
109
+ url: error.config?.url,
110
+ response: error.response?.data,
111
+ });
112
+ return Promise.reject(error);
113
+ },
114
+ );
115
+
116
+ return axios;
117
+ }
118
+
119
+ /**
120
+ * Wait until the API reports that it is healthy
121
+ * @param timeout in milliseconds
122
+ */
123
+ async waitUntilHealthy(timeout = 600000) {
124
+ const start = Date.now();
125
+ let isHealthy = false;
126
+ while (!isHealthy) {
127
+ try {
128
+ const { data } = await this.meta.metaGetHealth();
129
+ if (data.healthy) {
130
+ isHealthy = true;
131
+ }
132
+ } catch {
133
+ // ignore
134
+ }
135
+
136
+ if (Date.now() - start > timeout) {
137
+ throw new Error('API did not become healthy in time');
138
+ }
139
+
140
+ await new Promise((resolve) => setTimeout(resolve, 1000));
141
+ }
142
+ }
143
+
144
+ get meta() {
145
+ return new MetaApi(
146
+ {
147
+ isJsonMime: this.isJsonMime,
148
+ },
149
+ '',
150
+ this.axios,
151
+ );
152
+ }
153
+ }