@drxsuperapp/sdk 1.0.0
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.
- package/.openapi-generator/FILES +12 -0
- package/.openapi-generator/VERSION +1 -0
- package/.openapi-generator-ignore +23 -0
- package/api.ts +469 -0
- package/base.ts +86 -0
- package/common.ts +150 -0
- package/configuration.ts +115 -0
- package/deploy.log +357 -0
- package/dist/api.d.ts +257 -0
- package/dist/api.js +360 -0
- package/dist/base.d.ts +66 -0
- package/dist/base.js +63 -0
- package/dist/common.d.ts +65 -0
- package/dist/common.js +133 -0
- package/dist/configuration.d.ts +91 -0
- package/dist/configuration.js +100 -0
- package/dist/index.d.ts +13 -0
- package/dist/index.js +15 -0
- package/docs/ApiExamplesGet200ResponseInner.md +24 -0
- package/docs/ApiExamplesIdPutRequest.md +22 -0
- package/docs/ApiExamplesPostRequest.md +22 -0
- package/docs/ExampleApi.md +270 -0
- package/ecosystem.config.js +13 -0
- package/git_push.sh +57 -0
- package/hooks.json +26 -0
- package/index.ts +18 -0
- package/openapitools.json +7 -0
- package/package.json +30 -0
- package/tsconfig.json +17 -0
- package/workflow.sh +68 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
7.13.0
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
# OpenAPI Generator Ignore
|
|
2
|
+
# Generated by openapi-generator https://github.com/openapitools/openapi-generator
|
|
3
|
+
|
|
4
|
+
# Use this file to prevent files from being overwritten by the generator.
|
|
5
|
+
# The patterns follow closely to .gitignore or .dockerignore.
|
|
6
|
+
|
|
7
|
+
# As an example, the C# client generator defines ApiClient.cs.
|
|
8
|
+
# You can make changes and tell OpenAPI Generator to ignore just this file by uncommenting the following line:
|
|
9
|
+
#ApiClient.cs
|
|
10
|
+
|
|
11
|
+
# You can match any string of characters against a directory, file or extension with a single asterisk (*):
|
|
12
|
+
#foo/*/qux
|
|
13
|
+
# The above matches foo/bar/qux and foo/baz/qux, but not foo/bar/baz/qux
|
|
14
|
+
|
|
15
|
+
# You can recursively match patterns against a directory, file or extension with a double asterisk (**):
|
|
16
|
+
#foo/**/qux
|
|
17
|
+
# This matches foo/bar/qux, foo/baz/qux, and foo/bar/baz/qux
|
|
18
|
+
|
|
19
|
+
# You can also negate patterns with an exclamation (!).
|
|
20
|
+
# For example, you can ignore all files in a docs folder with the file extension .md:
|
|
21
|
+
#docs/*.md
|
|
22
|
+
# Then explicitly reverse the ignore rule for a single file:
|
|
23
|
+
#!docs/README.md
|
package/api.ts
ADDED
|
@@ -0,0 +1,469 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* DRX API
|
|
5
|
+
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 1.0.0
|
|
8
|
+
*
|
|
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
|
+
|
|
16
|
+
import type { Configuration } from './configuration';
|
|
17
|
+
import type { AxiosPromise, AxiosInstance, RawAxiosRequestConfig } from 'axios';
|
|
18
|
+
import globalAxios from 'axios';
|
|
19
|
+
// Some imports not used depending on template conditions
|
|
20
|
+
// @ts-ignore
|
|
21
|
+
import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObject, setBearerAuthToObject, setOAuthToObject, setSearchParams, serializeDataIfNeeded, toPathString, createRequestFunction } from './common';
|
|
22
|
+
import type { RequestArgs } from './base';
|
|
23
|
+
// @ts-ignore
|
|
24
|
+
import { BASE_PATH, COLLECTION_FORMATS, BaseAPI, RequiredError, operationServerMap } from './base';
|
|
25
|
+
|
|
26
|
+
/**
|
|
27
|
+
*
|
|
28
|
+
* @export
|
|
29
|
+
* @interface ApiExamplesGet200ResponseInner
|
|
30
|
+
*/
|
|
31
|
+
export interface ApiExamplesGet200ResponseInner {
|
|
32
|
+
/**
|
|
33
|
+
*
|
|
34
|
+
* @type {string}
|
|
35
|
+
* @memberof ApiExamplesGet200ResponseInner
|
|
36
|
+
*/
|
|
37
|
+
'id': string;
|
|
38
|
+
/**
|
|
39
|
+
*
|
|
40
|
+
* @type {string}
|
|
41
|
+
* @memberof ApiExamplesGet200ResponseInner
|
|
42
|
+
*/
|
|
43
|
+
'name': string;
|
|
44
|
+
/**
|
|
45
|
+
*
|
|
46
|
+
* @type {string}
|
|
47
|
+
* @memberof ApiExamplesGet200ResponseInner
|
|
48
|
+
*/
|
|
49
|
+
'email': string;
|
|
50
|
+
}
|
|
51
|
+
/**
|
|
52
|
+
*
|
|
53
|
+
* @export
|
|
54
|
+
* @interface ApiExamplesIdPutRequest
|
|
55
|
+
*/
|
|
56
|
+
export interface ApiExamplesIdPutRequest {
|
|
57
|
+
/**
|
|
58
|
+
*
|
|
59
|
+
* @type {string}
|
|
60
|
+
* @memberof ApiExamplesIdPutRequest
|
|
61
|
+
*/
|
|
62
|
+
'name'?: string;
|
|
63
|
+
/**
|
|
64
|
+
*
|
|
65
|
+
* @type {string}
|
|
66
|
+
* @memberof ApiExamplesIdPutRequest
|
|
67
|
+
*/
|
|
68
|
+
'email'?: string;
|
|
69
|
+
}
|
|
70
|
+
/**
|
|
71
|
+
*
|
|
72
|
+
* @export
|
|
73
|
+
* @interface ApiExamplesPostRequest
|
|
74
|
+
*/
|
|
75
|
+
export interface ApiExamplesPostRequest {
|
|
76
|
+
/**
|
|
77
|
+
*
|
|
78
|
+
* @type {string}
|
|
79
|
+
* @memberof ApiExamplesPostRequest
|
|
80
|
+
*/
|
|
81
|
+
'name': string;
|
|
82
|
+
/**
|
|
83
|
+
*
|
|
84
|
+
* @type {string}
|
|
85
|
+
* @memberof ApiExamplesPostRequest
|
|
86
|
+
*/
|
|
87
|
+
'email': string;
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
/**
|
|
91
|
+
* ExampleApi - axios parameter creator
|
|
92
|
+
* @export
|
|
93
|
+
*/
|
|
94
|
+
export const ExampleApiAxiosParamCreator = function (configuration?: Configuration) {
|
|
95
|
+
return {
|
|
96
|
+
/**
|
|
97
|
+
*
|
|
98
|
+
* @param {number} [page]
|
|
99
|
+
* @param {number} [limit]
|
|
100
|
+
* @param {*} [options] Override http request option.
|
|
101
|
+
* @throws {RequiredError}
|
|
102
|
+
*/
|
|
103
|
+
apiExamplesGet: async (page?: number, limit?: number, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
|
|
104
|
+
const localVarPath = `/api/examples`;
|
|
105
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
106
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
107
|
+
let baseOptions;
|
|
108
|
+
if (configuration) {
|
|
109
|
+
baseOptions = configuration.baseOptions;
|
|
110
|
+
}
|
|
111
|
+
|
|
112
|
+
const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options};
|
|
113
|
+
const localVarHeaderParameter = {} as any;
|
|
114
|
+
const localVarQueryParameter = {} as any;
|
|
115
|
+
|
|
116
|
+
if (page !== undefined) {
|
|
117
|
+
localVarQueryParameter['page'] = page;
|
|
118
|
+
}
|
|
119
|
+
|
|
120
|
+
if (limit !== undefined) {
|
|
121
|
+
localVarQueryParameter['limit'] = limit;
|
|
122
|
+
}
|
|
123
|
+
|
|
124
|
+
|
|
125
|
+
|
|
126
|
+
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
127
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
128
|
+
localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
|
|
129
|
+
|
|
130
|
+
return {
|
|
131
|
+
url: toPathString(localVarUrlObj),
|
|
132
|
+
options: localVarRequestOptions,
|
|
133
|
+
};
|
|
134
|
+
},
|
|
135
|
+
/**
|
|
136
|
+
*
|
|
137
|
+
* @param {string} id
|
|
138
|
+
* @param {*} [options] Override http request option.
|
|
139
|
+
* @throws {RequiredError}
|
|
140
|
+
*/
|
|
141
|
+
apiExamplesIdDelete: async (id: string, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
|
|
142
|
+
// verify required parameter 'id' is not null or undefined
|
|
143
|
+
assertParamExists('apiExamplesIdDelete', 'id', id)
|
|
144
|
+
const localVarPath = `/api/examples/{id}`
|
|
145
|
+
.replace(`{${"id"}}`, encodeURIComponent(String(id)));
|
|
146
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
147
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
148
|
+
let baseOptions;
|
|
149
|
+
if (configuration) {
|
|
150
|
+
baseOptions = configuration.baseOptions;
|
|
151
|
+
}
|
|
152
|
+
|
|
153
|
+
const localVarRequestOptions = { method: 'DELETE', ...baseOptions, ...options};
|
|
154
|
+
const localVarHeaderParameter = {} as any;
|
|
155
|
+
const localVarQueryParameter = {} as any;
|
|
156
|
+
|
|
157
|
+
|
|
158
|
+
|
|
159
|
+
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
160
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
161
|
+
localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
|
|
162
|
+
|
|
163
|
+
return {
|
|
164
|
+
url: toPathString(localVarUrlObj),
|
|
165
|
+
options: localVarRequestOptions,
|
|
166
|
+
};
|
|
167
|
+
},
|
|
168
|
+
/**
|
|
169
|
+
*
|
|
170
|
+
* @param {string} id
|
|
171
|
+
* @param {*} [options] Override http request option.
|
|
172
|
+
* @throws {RequiredError}
|
|
173
|
+
*/
|
|
174
|
+
apiExamplesIdGet: async (id: string, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
|
|
175
|
+
// verify required parameter 'id' is not null or undefined
|
|
176
|
+
assertParamExists('apiExamplesIdGet', 'id', id)
|
|
177
|
+
const localVarPath = `/api/examples/{id}`
|
|
178
|
+
.replace(`{${"id"}}`, encodeURIComponent(String(id)));
|
|
179
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
180
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
181
|
+
let baseOptions;
|
|
182
|
+
if (configuration) {
|
|
183
|
+
baseOptions = configuration.baseOptions;
|
|
184
|
+
}
|
|
185
|
+
|
|
186
|
+
const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options};
|
|
187
|
+
const localVarHeaderParameter = {} as any;
|
|
188
|
+
const localVarQueryParameter = {} as any;
|
|
189
|
+
|
|
190
|
+
|
|
191
|
+
|
|
192
|
+
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
193
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
194
|
+
localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
|
|
195
|
+
|
|
196
|
+
return {
|
|
197
|
+
url: toPathString(localVarUrlObj),
|
|
198
|
+
options: localVarRequestOptions,
|
|
199
|
+
};
|
|
200
|
+
},
|
|
201
|
+
/**
|
|
202
|
+
*
|
|
203
|
+
* @param {string} id
|
|
204
|
+
* @param {ApiExamplesIdPutRequest} [apiExamplesIdPutRequest]
|
|
205
|
+
* @param {*} [options] Override http request option.
|
|
206
|
+
* @throws {RequiredError}
|
|
207
|
+
*/
|
|
208
|
+
apiExamplesIdPut: async (id: string, apiExamplesIdPutRequest?: ApiExamplesIdPutRequest, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
|
|
209
|
+
// verify required parameter 'id' is not null or undefined
|
|
210
|
+
assertParamExists('apiExamplesIdPut', 'id', id)
|
|
211
|
+
const localVarPath = `/api/examples/{id}`
|
|
212
|
+
.replace(`{${"id"}}`, encodeURIComponent(String(id)));
|
|
213
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
214
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
215
|
+
let baseOptions;
|
|
216
|
+
if (configuration) {
|
|
217
|
+
baseOptions = configuration.baseOptions;
|
|
218
|
+
}
|
|
219
|
+
|
|
220
|
+
const localVarRequestOptions = { method: 'PUT', ...baseOptions, ...options};
|
|
221
|
+
const localVarHeaderParameter = {} as any;
|
|
222
|
+
const localVarQueryParameter = {} as any;
|
|
223
|
+
|
|
224
|
+
|
|
225
|
+
|
|
226
|
+
localVarHeaderParameter['Content-Type'] = 'application/json';
|
|
227
|
+
|
|
228
|
+
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
229
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
230
|
+
localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
|
|
231
|
+
localVarRequestOptions.data = serializeDataIfNeeded(apiExamplesIdPutRequest, localVarRequestOptions, configuration)
|
|
232
|
+
|
|
233
|
+
return {
|
|
234
|
+
url: toPathString(localVarUrlObj),
|
|
235
|
+
options: localVarRequestOptions,
|
|
236
|
+
};
|
|
237
|
+
},
|
|
238
|
+
/**
|
|
239
|
+
*
|
|
240
|
+
* @param {ApiExamplesPostRequest} [apiExamplesPostRequest]
|
|
241
|
+
* @param {*} [options] Override http request option.
|
|
242
|
+
* @throws {RequiredError}
|
|
243
|
+
*/
|
|
244
|
+
apiExamplesPost: async (apiExamplesPostRequest?: ApiExamplesPostRequest, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
|
|
245
|
+
const localVarPath = `/api/examples`;
|
|
246
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
247
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
248
|
+
let baseOptions;
|
|
249
|
+
if (configuration) {
|
|
250
|
+
baseOptions = configuration.baseOptions;
|
|
251
|
+
}
|
|
252
|
+
|
|
253
|
+
const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options};
|
|
254
|
+
const localVarHeaderParameter = {} as any;
|
|
255
|
+
const localVarQueryParameter = {} as any;
|
|
256
|
+
|
|
257
|
+
|
|
258
|
+
|
|
259
|
+
localVarHeaderParameter['Content-Type'] = 'application/json';
|
|
260
|
+
|
|
261
|
+
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
262
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
263
|
+
localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
|
|
264
|
+
localVarRequestOptions.data = serializeDataIfNeeded(apiExamplesPostRequest, localVarRequestOptions, configuration)
|
|
265
|
+
|
|
266
|
+
return {
|
|
267
|
+
url: toPathString(localVarUrlObj),
|
|
268
|
+
options: localVarRequestOptions,
|
|
269
|
+
};
|
|
270
|
+
},
|
|
271
|
+
}
|
|
272
|
+
};
|
|
273
|
+
|
|
274
|
+
/**
|
|
275
|
+
* ExampleApi - functional programming interface
|
|
276
|
+
* @export
|
|
277
|
+
*/
|
|
278
|
+
export const ExampleApiFp = function(configuration?: Configuration) {
|
|
279
|
+
const localVarAxiosParamCreator = ExampleApiAxiosParamCreator(configuration)
|
|
280
|
+
return {
|
|
281
|
+
/**
|
|
282
|
+
*
|
|
283
|
+
* @param {number} [page]
|
|
284
|
+
* @param {number} [limit]
|
|
285
|
+
* @param {*} [options] Override http request option.
|
|
286
|
+
* @throws {RequiredError}
|
|
287
|
+
*/
|
|
288
|
+
async apiExamplesGet(page?: number, limit?: number, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<Array<ApiExamplesGet200ResponseInner>>> {
|
|
289
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.apiExamplesGet(page, limit, options);
|
|
290
|
+
const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
|
|
291
|
+
const localVarOperationServerBasePath = operationServerMap['ExampleApi.apiExamplesGet']?.[localVarOperationServerIndex]?.url;
|
|
292
|
+
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
293
|
+
},
|
|
294
|
+
/**
|
|
295
|
+
*
|
|
296
|
+
* @param {string} id
|
|
297
|
+
* @param {*} [options] Override http request option.
|
|
298
|
+
* @throws {RequiredError}
|
|
299
|
+
*/
|
|
300
|
+
async apiExamplesIdDelete(id: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>> {
|
|
301
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.apiExamplesIdDelete(id, options);
|
|
302
|
+
const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
|
|
303
|
+
const localVarOperationServerBasePath = operationServerMap['ExampleApi.apiExamplesIdDelete']?.[localVarOperationServerIndex]?.url;
|
|
304
|
+
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
305
|
+
},
|
|
306
|
+
/**
|
|
307
|
+
*
|
|
308
|
+
* @param {string} id
|
|
309
|
+
* @param {*} [options] Override http request option.
|
|
310
|
+
* @throws {RequiredError}
|
|
311
|
+
*/
|
|
312
|
+
async apiExamplesIdGet(id: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<ApiExamplesGet200ResponseInner>> {
|
|
313
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.apiExamplesIdGet(id, options);
|
|
314
|
+
const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
|
|
315
|
+
const localVarOperationServerBasePath = operationServerMap['ExampleApi.apiExamplesIdGet']?.[localVarOperationServerIndex]?.url;
|
|
316
|
+
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
317
|
+
},
|
|
318
|
+
/**
|
|
319
|
+
*
|
|
320
|
+
* @param {string} id
|
|
321
|
+
* @param {ApiExamplesIdPutRequest} [apiExamplesIdPutRequest]
|
|
322
|
+
* @param {*} [options] Override http request option.
|
|
323
|
+
* @throws {RequiredError}
|
|
324
|
+
*/
|
|
325
|
+
async apiExamplesIdPut(id: string, apiExamplesIdPutRequest?: ApiExamplesIdPutRequest, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<ApiExamplesGet200ResponseInner>> {
|
|
326
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.apiExamplesIdPut(id, apiExamplesIdPutRequest, options);
|
|
327
|
+
const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
|
|
328
|
+
const localVarOperationServerBasePath = operationServerMap['ExampleApi.apiExamplesIdPut']?.[localVarOperationServerIndex]?.url;
|
|
329
|
+
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
330
|
+
},
|
|
331
|
+
/**
|
|
332
|
+
*
|
|
333
|
+
* @param {ApiExamplesPostRequest} [apiExamplesPostRequest]
|
|
334
|
+
* @param {*} [options] Override http request option.
|
|
335
|
+
* @throws {RequiredError}
|
|
336
|
+
*/
|
|
337
|
+
async apiExamplesPost(apiExamplesPostRequest?: ApiExamplesPostRequest, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<ApiExamplesGet200ResponseInner>> {
|
|
338
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.apiExamplesPost(apiExamplesPostRequest, options);
|
|
339
|
+
const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
|
|
340
|
+
const localVarOperationServerBasePath = operationServerMap['ExampleApi.apiExamplesPost']?.[localVarOperationServerIndex]?.url;
|
|
341
|
+
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
342
|
+
},
|
|
343
|
+
}
|
|
344
|
+
};
|
|
345
|
+
|
|
346
|
+
/**
|
|
347
|
+
* ExampleApi - factory interface
|
|
348
|
+
* @export
|
|
349
|
+
*/
|
|
350
|
+
export const ExampleApiFactory = function (configuration?: Configuration, basePath?: string, axios?: AxiosInstance) {
|
|
351
|
+
const localVarFp = ExampleApiFp(configuration)
|
|
352
|
+
return {
|
|
353
|
+
/**
|
|
354
|
+
*
|
|
355
|
+
* @param {number} [page]
|
|
356
|
+
* @param {number} [limit]
|
|
357
|
+
* @param {*} [options] Override http request option.
|
|
358
|
+
* @throws {RequiredError}
|
|
359
|
+
*/
|
|
360
|
+
apiExamplesGet(page?: number, limit?: number, options?: RawAxiosRequestConfig): AxiosPromise<Array<ApiExamplesGet200ResponseInner>> {
|
|
361
|
+
return localVarFp.apiExamplesGet(page, limit, options).then((request) => request(axios, basePath));
|
|
362
|
+
},
|
|
363
|
+
/**
|
|
364
|
+
*
|
|
365
|
+
* @param {string} id
|
|
366
|
+
* @param {*} [options] Override http request option.
|
|
367
|
+
* @throws {RequiredError}
|
|
368
|
+
*/
|
|
369
|
+
apiExamplesIdDelete(id: string, options?: RawAxiosRequestConfig): AxiosPromise<void> {
|
|
370
|
+
return localVarFp.apiExamplesIdDelete(id, options).then((request) => request(axios, basePath));
|
|
371
|
+
},
|
|
372
|
+
/**
|
|
373
|
+
*
|
|
374
|
+
* @param {string} id
|
|
375
|
+
* @param {*} [options] Override http request option.
|
|
376
|
+
* @throws {RequiredError}
|
|
377
|
+
*/
|
|
378
|
+
apiExamplesIdGet(id: string, options?: RawAxiosRequestConfig): AxiosPromise<ApiExamplesGet200ResponseInner> {
|
|
379
|
+
return localVarFp.apiExamplesIdGet(id, options).then((request) => request(axios, basePath));
|
|
380
|
+
},
|
|
381
|
+
/**
|
|
382
|
+
*
|
|
383
|
+
* @param {string} id
|
|
384
|
+
* @param {ApiExamplesIdPutRequest} [apiExamplesIdPutRequest]
|
|
385
|
+
* @param {*} [options] Override http request option.
|
|
386
|
+
* @throws {RequiredError}
|
|
387
|
+
*/
|
|
388
|
+
apiExamplesIdPut(id: string, apiExamplesIdPutRequest?: ApiExamplesIdPutRequest, options?: RawAxiosRequestConfig): AxiosPromise<ApiExamplesGet200ResponseInner> {
|
|
389
|
+
return localVarFp.apiExamplesIdPut(id, apiExamplesIdPutRequest, options).then((request) => request(axios, basePath));
|
|
390
|
+
},
|
|
391
|
+
/**
|
|
392
|
+
*
|
|
393
|
+
* @param {ApiExamplesPostRequest} [apiExamplesPostRequest]
|
|
394
|
+
* @param {*} [options] Override http request option.
|
|
395
|
+
* @throws {RequiredError}
|
|
396
|
+
*/
|
|
397
|
+
apiExamplesPost(apiExamplesPostRequest?: ApiExamplesPostRequest, options?: RawAxiosRequestConfig): AxiosPromise<ApiExamplesGet200ResponseInner> {
|
|
398
|
+
return localVarFp.apiExamplesPost(apiExamplesPostRequest, options).then((request) => request(axios, basePath));
|
|
399
|
+
},
|
|
400
|
+
};
|
|
401
|
+
};
|
|
402
|
+
|
|
403
|
+
/**
|
|
404
|
+
* ExampleApi - object-oriented interface
|
|
405
|
+
* @export
|
|
406
|
+
* @class ExampleApi
|
|
407
|
+
* @extends {BaseAPI}
|
|
408
|
+
*/
|
|
409
|
+
export class ExampleApi extends BaseAPI {
|
|
410
|
+
/**
|
|
411
|
+
*
|
|
412
|
+
* @param {number} [page]
|
|
413
|
+
* @param {number} [limit]
|
|
414
|
+
* @param {*} [options] Override http request option.
|
|
415
|
+
* @throws {RequiredError}
|
|
416
|
+
* @memberof ExampleApi
|
|
417
|
+
*/
|
|
418
|
+
public apiExamplesGet(page?: number, limit?: number, options?: RawAxiosRequestConfig) {
|
|
419
|
+
return ExampleApiFp(this.configuration).apiExamplesGet(page, limit, options).then((request) => request(this.axios, this.basePath));
|
|
420
|
+
}
|
|
421
|
+
|
|
422
|
+
/**
|
|
423
|
+
*
|
|
424
|
+
* @param {string} id
|
|
425
|
+
* @param {*} [options] Override http request option.
|
|
426
|
+
* @throws {RequiredError}
|
|
427
|
+
* @memberof ExampleApi
|
|
428
|
+
*/
|
|
429
|
+
public apiExamplesIdDelete(id: string, options?: RawAxiosRequestConfig) {
|
|
430
|
+
return ExampleApiFp(this.configuration).apiExamplesIdDelete(id, options).then((request) => request(this.axios, this.basePath));
|
|
431
|
+
}
|
|
432
|
+
|
|
433
|
+
/**
|
|
434
|
+
*
|
|
435
|
+
* @param {string} id
|
|
436
|
+
* @param {*} [options] Override http request option.
|
|
437
|
+
* @throws {RequiredError}
|
|
438
|
+
* @memberof ExampleApi
|
|
439
|
+
*/
|
|
440
|
+
public apiExamplesIdGet(id: string, options?: RawAxiosRequestConfig) {
|
|
441
|
+
return ExampleApiFp(this.configuration).apiExamplesIdGet(id, options).then((request) => request(this.axios, this.basePath));
|
|
442
|
+
}
|
|
443
|
+
|
|
444
|
+
/**
|
|
445
|
+
*
|
|
446
|
+
* @param {string} id
|
|
447
|
+
* @param {ApiExamplesIdPutRequest} [apiExamplesIdPutRequest]
|
|
448
|
+
* @param {*} [options] Override http request option.
|
|
449
|
+
* @throws {RequiredError}
|
|
450
|
+
* @memberof ExampleApi
|
|
451
|
+
*/
|
|
452
|
+
public apiExamplesIdPut(id: string, apiExamplesIdPutRequest?: ApiExamplesIdPutRequest, options?: RawAxiosRequestConfig) {
|
|
453
|
+
return ExampleApiFp(this.configuration).apiExamplesIdPut(id, apiExamplesIdPutRequest, options).then((request) => request(this.axios, this.basePath));
|
|
454
|
+
}
|
|
455
|
+
|
|
456
|
+
/**
|
|
457
|
+
*
|
|
458
|
+
* @param {ApiExamplesPostRequest} [apiExamplesPostRequest]
|
|
459
|
+
* @param {*} [options] Override http request option.
|
|
460
|
+
* @throws {RequiredError}
|
|
461
|
+
* @memberof ExampleApi
|
|
462
|
+
*/
|
|
463
|
+
public apiExamplesPost(apiExamplesPostRequest?: ApiExamplesPostRequest, options?: RawAxiosRequestConfig) {
|
|
464
|
+
return ExampleApiFp(this.configuration).apiExamplesPost(apiExamplesPostRequest, options).then((request) => request(this.axios, this.basePath));
|
|
465
|
+
}
|
|
466
|
+
}
|
|
467
|
+
|
|
468
|
+
|
|
469
|
+
|
package/base.ts
ADDED
|
@@ -0,0 +1,86 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* DRX API
|
|
5
|
+
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 1.0.0
|
|
8
|
+
*
|
|
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
|
+
|
|
16
|
+
import type { Configuration } from './configuration';
|
|
17
|
+
// Some imports not used depending on template conditions
|
|
18
|
+
// @ts-ignore
|
|
19
|
+
import type { AxiosPromise, AxiosInstance, RawAxiosRequestConfig } from 'axios';
|
|
20
|
+
import globalAxios from 'axios';
|
|
21
|
+
|
|
22
|
+
export const BASE_PATH = "http://localhost".replace(/\/+$/, "");
|
|
23
|
+
|
|
24
|
+
/**
|
|
25
|
+
*
|
|
26
|
+
* @export
|
|
27
|
+
*/
|
|
28
|
+
export const COLLECTION_FORMATS = {
|
|
29
|
+
csv: ",",
|
|
30
|
+
ssv: " ",
|
|
31
|
+
tsv: "\t",
|
|
32
|
+
pipes: "|",
|
|
33
|
+
};
|
|
34
|
+
|
|
35
|
+
/**
|
|
36
|
+
*
|
|
37
|
+
* @export
|
|
38
|
+
* @interface RequestArgs
|
|
39
|
+
*/
|
|
40
|
+
export interface RequestArgs {
|
|
41
|
+
url: string;
|
|
42
|
+
options: RawAxiosRequestConfig;
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
/**
|
|
46
|
+
*
|
|
47
|
+
* @export
|
|
48
|
+
* @class BaseAPI
|
|
49
|
+
*/
|
|
50
|
+
export class BaseAPI {
|
|
51
|
+
protected configuration: Configuration | undefined;
|
|
52
|
+
|
|
53
|
+
constructor(configuration?: Configuration, protected basePath: string = BASE_PATH, protected axios: AxiosInstance = globalAxios) {
|
|
54
|
+
if (configuration) {
|
|
55
|
+
this.configuration = configuration;
|
|
56
|
+
this.basePath = configuration.basePath ?? basePath;
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
};
|
|
60
|
+
|
|
61
|
+
/**
|
|
62
|
+
*
|
|
63
|
+
* @export
|
|
64
|
+
* @class RequiredError
|
|
65
|
+
* @extends {Error}
|
|
66
|
+
*/
|
|
67
|
+
export class RequiredError extends Error {
|
|
68
|
+
constructor(public field: string, msg?: string) {
|
|
69
|
+
super(msg);
|
|
70
|
+
this.name = "RequiredError"
|
|
71
|
+
}
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
interface ServerMap {
|
|
75
|
+
[key: string]: {
|
|
76
|
+
url: string,
|
|
77
|
+
description: string,
|
|
78
|
+
}[];
|
|
79
|
+
}
|
|
80
|
+
|
|
81
|
+
/**
|
|
82
|
+
*
|
|
83
|
+
* @export
|
|
84
|
+
*/
|
|
85
|
+
export const operationServerMap: ServerMap = {
|
|
86
|
+
}
|