@loopstack/hub-client 0.12.2 → 0.13.1
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/README.md +13 -9
- package/api.ts +7084 -3866
- package/base.ts +33 -29
- package/common.ts +88 -75
- package/configuration.ts +103 -96
- package/dist/api.d.ts +2945 -1440
- package/dist/api.js +1410 -260
- package/dist/base.d.ts +1 -1
- package/dist/base.js +6 -20
- package/dist/common.d.ts +2 -2
- package/dist/common.js +9 -24
- package/dist/configuration.js +1 -1
- package/dist/esm/api.d.ts +2945 -1440
- package/dist/esm/api.js +1397 -260
- package/dist/esm/base.d.ts +1 -1
- package/dist/esm/base.js +6 -20
- package/dist/esm/common.d.ts +2 -2
- package/dist/esm/common.js +10 -25
- package/dist/esm/configuration.js +1 -1
- package/dist/esm/index.d.ts +2 -2
- package/dist/esm/index.js +2 -3
- package/dist/index.d.ts +2 -2
- package/dist/index.js +0 -1
- package/index.ts +3 -6
- package/package.json +6 -9
- package/tsconfig.json +2 -7
- package/CHANGELOG.md +0 -43
- package/LICENSE +0 -19
package/dist/base.d.ts
CHANGED
|
@@ -9,8 +9,8 @@
|
|
|
9
9
|
* https://openapi-generator.tech
|
|
10
10
|
* Do not edit the class manually.
|
|
11
11
|
*/
|
|
12
|
-
import type { Configuration } from './configuration';
|
|
13
12
|
import type { AxiosInstance, RawAxiosRequestConfig } from 'axios';
|
|
13
|
+
import type { Configuration } from './configuration';
|
|
14
14
|
export declare const BASE_PATH: string;
|
|
15
15
|
/**
|
|
16
16
|
*
|
package/dist/base.js
CHANGED
|
@@ -1,30 +1,17 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
/* tslint:disable */
|
|
3
|
-
/* eslint-disable */
|
|
4
|
-
/**
|
|
5
|
-
* Loopstack Hub
|
|
6
|
-
* Loopstack Hub Documentation
|
|
7
|
-
*
|
|
8
|
-
* The version of the OpenAPI document: 1.0
|
|
9
|
-
*
|
|
10
|
-
*
|
|
11
|
-
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
12
|
-
* https://openapi-generator.tech
|
|
13
|
-
* Do not edit the class manually.
|
|
14
|
-
*/
|
|
15
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
16
3
|
exports.operationServerMap = exports.RequiredError = exports.BaseAPI = exports.COLLECTION_FORMATS = exports.BASE_PATH = void 0;
|
|
17
4
|
const axios_1 = require("axios");
|
|
18
|
-
exports.BASE_PATH =
|
|
5
|
+
exports.BASE_PATH = 'http://localhost'.replace(/\/+$/, '');
|
|
19
6
|
/**
|
|
20
7
|
*
|
|
21
8
|
* @export
|
|
22
9
|
*/
|
|
23
10
|
exports.COLLECTION_FORMATS = {
|
|
24
|
-
csv:
|
|
25
|
-
ssv:
|
|
26
|
-
tsv:
|
|
27
|
-
pipes:
|
|
11
|
+
csv: ',',
|
|
12
|
+
ssv: ' ',
|
|
13
|
+
tsv: '\t',
|
|
14
|
+
pipes: '|',
|
|
28
15
|
};
|
|
29
16
|
/**
|
|
30
17
|
*
|
|
@@ -43,7 +30,6 @@ class BaseAPI {
|
|
|
43
30
|
}
|
|
44
31
|
}
|
|
45
32
|
exports.BaseAPI = BaseAPI;
|
|
46
|
-
;
|
|
47
33
|
/**
|
|
48
34
|
*
|
|
49
35
|
* @export
|
|
@@ -54,7 +40,7 @@ class RequiredError extends Error {
|
|
|
54
40
|
constructor(field, msg) {
|
|
55
41
|
super(msg);
|
|
56
42
|
this.field = field;
|
|
57
|
-
this.name =
|
|
43
|
+
this.name = 'RequiredError';
|
|
58
44
|
}
|
|
59
45
|
}
|
|
60
46
|
exports.RequiredError = RequiredError;
|
package/dist/common.d.ts
CHANGED
|
@@ -9,9 +9,9 @@
|
|
|
9
9
|
* https://openapi-generator.tech
|
|
10
10
|
* Do not edit the class manually.
|
|
11
11
|
*/
|
|
12
|
-
import type { Configuration } from "./configuration";
|
|
13
|
-
import type { RequestArgs } from "./base";
|
|
14
12
|
import type { AxiosInstance, AxiosResponse } from 'axios';
|
|
13
|
+
import type { RequestArgs } from './base';
|
|
14
|
+
import type { Configuration } from './configuration';
|
|
15
15
|
/**
|
|
16
16
|
*
|
|
17
17
|
* @export
|
package/dist/common.js
CHANGED
|
@@ -1,17 +1,4 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
/* tslint:disable */
|
|
3
|
-
/* eslint-disable */
|
|
4
|
-
/**
|
|
5
|
-
* Loopstack Hub
|
|
6
|
-
* Loopstack Hub Documentation
|
|
7
|
-
*
|
|
8
|
-
* The version of the OpenAPI document: 1.0
|
|
9
|
-
*
|
|
10
|
-
*
|
|
11
|
-
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
12
|
-
* https://openapi-generator.tech
|
|
13
|
-
* Do not edit the class manually.
|
|
14
|
-
*/
|
|
15
2
|
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
16
3
|
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
17
4
|
return new (P || (P = Promise))(function (resolve, reject) {
|
|
@@ -61,7 +48,7 @@ exports.setApiKeyToObject = setApiKeyToObject;
|
|
|
61
48
|
*/
|
|
62
49
|
const setBasicAuthToObject = function (object, configuration) {
|
|
63
50
|
if (configuration && (configuration.username || configuration.password)) {
|
|
64
|
-
object[
|
|
51
|
+
object['auth'] = { username: configuration.username, password: configuration.password };
|
|
65
52
|
}
|
|
66
53
|
};
|
|
67
54
|
exports.setBasicAuthToObject = setBasicAuthToObject;
|
|
@@ -75,7 +62,7 @@ const setBearerAuthToObject = function (object, configuration) {
|
|
|
75
62
|
const accessToken = typeof configuration.accessToken === 'function'
|
|
76
63
|
? yield configuration.accessToken()
|
|
77
64
|
: yield configuration.accessToken;
|
|
78
|
-
object[
|
|
65
|
+
object['Authorization'] = 'Bearer ' + accessToken;
|
|
79
66
|
}
|
|
80
67
|
});
|
|
81
68
|
};
|
|
@@ -90,20 +77,20 @@ const setOAuthToObject = function (object, name, scopes, configuration) {
|
|
|
90
77
|
const localVarAccessTokenValue = typeof configuration.accessToken === 'function'
|
|
91
78
|
? yield configuration.accessToken(name, scopes)
|
|
92
79
|
: yield configuration.accessToken;
|
|
93
|
-
object[
|
|
80
|
+
object['Authorization'] = 'Bearer ' + localVarAccessTokenValue;
|
|
94
81
|
}
|
|
95
82
|
});
|
|
96
83
|
};
|
|
97
84
|
exports.setOAuthToObject = setOAuthToObject;
|
|
98
|
-
function setFlattenedQueryParams(urlSearchParams, parameter, key =
|
|
85
|
+
function setFlattenedQueryParams(urlSearchParams, parameter, key = '') {
|
|
99
86
|
if (parameter == null)
|
|
100
87
|
return;
|
|
101
|
-
if (typeof parameter ===
|
|
88
|
+
if (typeof parameter === 'object') {
|
|
102
89
|
if (Array.isArray(parameter)) {
|
|
103
|
-
parameter.forEach(item => setFlattenedQueryParams(urlSearchParams, item, key));
|
|
90
|
+
parameter.forEach((item) => setFlattenedQueryParams(urlSearchParams, item, key));
|
|
104
91
|
}
|
|
105
92
|
else {
|
|
106
|
-
Object.keys(parameter).forEach(currentKey => setFlattenedQueryParams(urlSearchParams, parameter[currentKey], `${key}${key !== '' ? '.' : ''}${currentKey}`));
|
|
93
|
+
Object.keys(parameter).forEach((currentKey) => setFlattenedQueryParams(urlSearchParams, parameter[currentKey], `${key}${key !== '' ? '.' : ''}${currentKey}`));
|
|
107
94
|
}
|
|
108
95
|
}
|
|
109
96
|
else {
|
|
@@ -134,9 +121,7 @@ const serializeDataIfNeeded = function (value, requestOptions, configuration) {
|
|
|
134
121
|
const needsSerialization = nonString && configuration && configuration.isJsonMime
|
|
135
122
|
? configuration.isJsonMime(requestOptions.headers['Content-Type'])
|
|
136
123
|
: nonString;
|
|
137
|
-
return needsSerialization
|
|
138
|
-
? JSON.stringify(value !== undefined ? value : {})
|
|
139
|
-
: (value || "");
|
|
124
|
+
return needsSerialization ? JSON.stringify(value !== undefined ? value : {}) : value || '';
|
|
140
125
|
};
|
|
141
126
|
exports.serializeDataIfNeeded = serializeDataIfNeeded;
|
|
142
127
|
/**
|
|
@@ -154,7 +139,7 @@ exports.toPathString = toPathString;
|
|
|
154
139
|
const createRequestFunction = function (axiosArgs, globalAxios, BASE_PATH, configuration) {
|
|
155
140
|
return (axios = globalAxios, basePath = BASE_PATH) => {
|
|
156
141
|
var _a;
|
|
157
|
-
const axiosRequestArgs = Object.assign(Object.assign({}, axiosArgs.options), { url: (axios.defaults.baseURL ? '' : (_a = configuration === null || configuration === void 0 ? void 0 : configuration.basePath) !== null && _a !== void 0 ? _a : basePath) + axiosArgs.url });
|
|
142
|
+
const axiosRequestArgs = Object.assign(Object.assign({}, axiosArgs.options), { url: (axios.defaults.baseURL ? '' : ((_a = configuration === null || configuration === void 0 ? void 0 : configuration.basePath) !== null && _a !== void 0 ? _a : basePath)) + axiosArgs.url });
|
|
158
143
|
return axios.request(axiosRequestArgs);
|
|
159
144
|
};
|
|
160
145
|
};
|
package/dist/configuration.js
CHANGED
|
@@ -23,7 +23,7 @@ class Configuration {
|
|
|
23
23
|
this.accessToken = param.accessToken;
|
|
24
24
|
this.basePath = param.basePath;
|
|
25
25
|
this.serverIndex = param.serverIndex;
|
|
26
|
-
this.baseOptions = Object.assign({ headers: Object.assign(Object.assign({}, (_a = param.baseOptions) === null || _a === void 0 ? void 0 : _a.headers), { 'User-Agent':
|
|
26
|
+
this.baseOptions = Object.assign({ headers: Object.assign(Object.assign({}, (_a = param.baseOptions) === null || _a === void 0 ? void 0 : _a.headers), { 'User-Agent': 'OpenAPI-Generator/1.0/typescript-axios' }) }, param.baseOptions);
|
|
27
27
|
this.formDataCtor = param.formDataCtor;
|
|
28
28
|
}
|
|
29
29
|
/**
|