@teemill/product-catalog 1.1.0 → 1.3.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/VERSION +1 -1
- package/README.md +2 -2
- package/dist/apis/ProductsApi.d.ts +3 -3
- package/dist/apis/ProductsApi.js +48 -15
- package/dist/apis/VariantsApi.d.ts +3 -3
- package/dist/apis/VariantsApi.js +48 -15
- package/dist/models/ApiError.d.ts +1 -1
- package/dist/models/ApiError.js +1 -1
- package/dist/models/Attribute.d.ts +1 -1
- package/dist/models/Attribute.js +1 -1
- package/dist/models/AttributeThumbnail.d.ts +1 -1
- package/dist/models/AttributeThumbnail.js +1 -1
- package/dist/models/Image.d.ts +1 -1
- package/dist/models/Image.js +1 -1
- package/dist/models/Price.d.ts +1 -1
- package/dist/models/Price.js +1 -1
- package/dist/models/Product.d.ts +1 -1
- package/dist/models/Product.js +1 -1
- package/dist/models/ProductsResponse.d.ts +1 -1
- package/dist/models/ProductsResponse.js +1 -1
- package/dist/models/Stock.d.ts +1 -1
- package/dist/models/Stock.js +1 -1
- package/dist/models/Variant.d.ts +1 -1
- package/dist/models/Variant.js +1 -1
- package/dist/models/VariantProduct.d.ts +1 -1
- package/dist/models/VariantProduct.js +1 -1
- package/dist/models/VariantsResponse.d.ts +1 -1
- package/dist/models/VariantsResponse.js +1 -1
- package/dist/runtime.d.ts +6 -1
- package/dist/runtime.js +6 -3
- package/package.json +1 -1
- package/src/apis/ProductsApi.ts +38 -5
- package/src/apis/VariantsApi.ts +38 -5
- package/src/models/ApiError.ts +1 -1
- package/src/models/Attribute.ts +1 -1
- package/src/models/AttributeThumbnail.ts +1 -1
- package/src/models/Image.ts +1 -1
- package/src/models/Price.ts +1 -1
- package/src/models/Product.ts +1 -1
- package/src/models/ProductsResponse.ts +1 -1
- package/src/models/Stock.ts +1 -1
- package/src/models/Variant.ts +1 -1
- package/src/models/VariantProduct.ts +1 -1
- package/src/models/VariantsResponse.ts +1 -1
- package/src/runtime.ts +13 -3
|
@@ -1 +1 @@
|
|
|
1
|
-
7.
|
|
1
|
+
7.2.0-SNAPSHOT
|
package/README.md
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
## @teemill/product-catalog@1.
|
|
1
|
+
## @teemill/product-catalog@1.3.0
|
|
2
2
|
|
|
3
3
|
This generator creates TypeScript/JavaScript client that utilizes [Fetch API](https://fetch.spec.whatwg.org/). The generated Node module can be used in the following environments:
|
|
4
4
|
|
|
@@ -36,7 +36,7 @@ navigate to the folder of your consuming project and run one of the following co
|
|
|
36
36
|
_published:_
|
|
37
37
|
|
|
38
38
|
```
|
|
39
|
-
npm install @teemill/product-catalog@1.
|
|
39
|
+
npm install @teemill/product-catalog@1.3.0 --save
|
|
40
40
|
```
|
|
41
41
|
|
|
42
42
|
_unPublished (not recommended):_
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
* Product Catalog API
|
|
3
3
|
* Manage Teemill Product Catalog For full documentation on functionality and account settings go to [teemill.com](https://teemill.com)
|
|
4
4
|
*
|
|
5
|
-
* The version of the OpenAPI document: 1.
|
|
5
|
+
* The version of the OpenAPI document: 1.3.0
|
|
6
6
|
* Contact: hello@teemill.com
|
|
7
7
|
*
|
|
8
8
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
@@ -35,7 +35,7 @@ export declare class ProductsApi extends runtime.BaseAPI {
|
|
|
35
35
|
* Gets a product by the given id
|
|
36
36
|
* Get product
|
|
37
37
|
*/
|
|
38
|
-
getProduct(
|
|
38
|
+
getProduct(project: string, productId: string, optionalParameters?: runtime.OptionalOnly<GetProductRequest>, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Product>;
|
|
39
39
|
/**
|
|
40
40
|
* Lists all products
|
|
41
41
|
* List products
|
|
@@ -45,5 +45,5 @@ export declare class ProductsApi extends runtime.BaseAPI {
|
|
|
45
45
|
* Lists all products
|
|
46
46
|
* List products
|
|
47
47
|
*/
|
|
48
|
-
getProducts(
|
|
48
|
+
getProducts(project: string, optionalParameters?: runtime.OptionalOnly<GetProductsRequest>, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<ProductsResponse>;
|
|
49
49
|
}
|
package/dist/apis/ProductsApi.js
CHANGED
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
* Product Catalog API
|
|
6
6
|
* Manage Teemill Product Catalog For full documentation on functionality and account settings go to [teemill.com](https://teemill.com)
|
|
7
7
|
*
|
|
8
|
-
* The version of the OpenAPI document: 1.
|
|
8
|
+
* The version of the OpenAPI document: 1.3.0
|
|
9
9
|
* Contact: hello@teemill.com
|
|
10
10
|
*
|
|
11
11
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
@@ -27,6 +27,17 @@ var __extends = (this && this.__extends) || (function () {
|
|
|
27
27
|
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
28
28
|
};
|
|
29
29
|
})();
|
|
30
|
+
var __assign = (this && this.__assign) || function () {
|
|
31
|
+
__assign = Object.assign || function(t) {
|
|
32
|
+
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
33
|
+
s = arguments[i];
|
|
34
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
|
35
|
+
t[p] = s[p];
|
|
36
|
+
}
|
|
37
|
+
return t;
|
|
38
|
+
};
|
|
39
|
+
return __assign.apply(this, arguments);
|
|
40
|
+
};
|
|
30
41
|
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
31
42
|
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
32
43
|
return new (P || (P = Promise))(function (resolve, reject) {
|
|
@@ -81,9 +92,9 @@ var ProductsApi = /** @class */ (function (_super) {
|
|
|
81
92
|
*/
|
|
82
93
|
ProductsApi.prototype.getProductRaw = function (requestParameters, initOverrides) {
|
|
83
94
|
return __awaiter(this, void 0, void 0, function () {
|
|
84
|
-
var queryParameters, headerParameters, response;
|
|
85
|
-
return __generator(this, function (
|
|
86
|
-
switch (
|
|
95
|
+
var queryParameters, headerParameters, _a, _b, response;
|
|
96
|
+
return __generator(this, function (_c) {
|
|
97
|
+
switch (_c.label) {
|
|
87
98
|
case 0:
|
|
88
99
|
if (requestParameters.project === null || requestParameters.project === undefined) {
|
|
89
100
|
throw new runtime.RequiredError('project', 'Required parameter requestParameters.project was null or undefined when calling getProduct.');
|
|
@@ -99,6 +110,16 @@ var ProductsApi = /** @class */ (function (_super) {
|
|
|
99
110
|
queryParameters['fields'] = requestParameters.fields;
|
|
100
111
|
}
|
|
101
112
|
headerParameters = {};
|
|
113
|
+
if (!(this.configuration && this.configuration.accessToken)) return [3 /*break*/, 2];
|
|
114
|
+
// oauth required
|
|
115
|
+
_a = headerParameters;
|
|
116
|
+
_b = "Authorization";
|
|
117
|
+
return [4 /*yield*/, this.configuration.accessToken("session-oauth", [])];
|
|
118
|
+
case 1:
|
|
119
|
+
// oauth required
|
|
120
|
+
_a[_b] = _c.sent();
|
|
121
|
+
_c.label = 2;
|
|
122
|
+
case 2:
|
|
102
123
|
if (this.configuration && this.configuration.apiKey) {
|
|
103
124
|
headerParameters["Authorization"] = this.configuration.apiKey("Authorization"); // api-key authentication
|
|
104
125
|
}
|
|
@@ -108,8 +129,8 @@ var ProductsApi = /** @class */ (function (_super) {
|
|
|
108
129
|
headers: headerParameters,
|
|
109
130
|
query: queryParameters,
|
|
110
131
|
}, initOverrides)];
|
|
111
|
-
case
|
|
112
|
-
response =
|
|
132
|
+
case 3:
|
|
133
|
+
response = _c.sent();
|
|
113
134
|
return [2 /*return*/, new runtime.JSONApiResponse(response, function (jsonValue) { return (0, index_1.ProductFromJSON)(jsonValue); })];
|
|
114
135
|
}
|
|
115
136
|
});
|
|
@@ -119,12 +140,13 @@ var ProductsApi = /** @class */ (function (_super) {
|
|
|
119
140
|
* Gets a product by the given id
|
|
120
141
|
* Get product
|
|
121
142
|
*/
|
|
122
|
-
ProductsApi.prototype.getProduct = function (
|
|
143
|
+
ProductsApi.prototype.getProduct = function (project, productId, optionalParameters, initOverrides) {
|
|
144
|
+
if (optionalParameters === void 0) { optionalParameters = {}; }
|
|
123
145
|
return __awaiter(this, void 0, void 0, function () {
|
|
124
146
|
var response;
|
|
125
147
|
return __generator(this, function (_a) {
|
|
126
148
|
switch (_a.label) {
|
|
127
|
-
case 0: return [4 /*yield*/, this.getProductRaw(
|
|
149
|
+
case 0: return [4 /*yield*/, this.getProductRaw(__assign({ project: project, productId: productId }, optionalParameters), initOverrides)];
|
|
128
150
|
case 1:
|
|
129
151
|
response = _a.sent();
|
|
130
152
|
return [4 /*yield*/, response.value()];
|
|
@@ -139,9 +161,9 @@ var ProductsApi = /** @class */ (function (_super) {
|
|
|
139
161
|
*/
|
|
140
162
|
ProductsApi.prototype.getProductsRaw = function (requestParameters, initOverrides) {
|
|
141
163
|
return __awaiter(this, void 0, void 0, function () {
|
|
142
|
-
var queryParameters, headerParameters, response;
|
|
143
|
-
return __generator(this, function (
|
|
144
|
-
switch (
|
|
164
|
+
var queryParameters, headerParameters, _a, _b, response;
|
|
165
|
+
return __generator(this, function (_c) {
|
|
166
|
+
switch (_c.label) {
|
|
145
167
|
case 0:
|
|
146
168
|
if (requestParameters.project === null || requestParameters.project === undefined) {
|
|
147
169
|
throw new runtime.RequiredError('project', 'Required parameter requestParameters.project was null or undefined when calling getProducts.');
|
|
@@ -160,6 +182,16 @@ var ProductsApi = /** @class */ (function (_super) {
|
|
|
160
182
|
queryParameters['fields'] = requestParameters.fields;
|
|
161
183
|
}
|
|
162
184
|
headerParameters = {};
|
|
185
|
+
if (!(this.configuration && this.configuration.accessToken)) return [3 /*break*/, 2];
|
|
186
|
+
// oauth required
|
|
187
|
+
_a = headerParameters;
|
|
188
|
+
_b = "Authorization";
|
|
189
|
+
return [4 /*yield*/, this.configuration.accessToken("session-oauth", [])];
|
|
190
|
+
case 1:
|
|
191
|
+
// oauth required
|
|
192
|
+
_a[_b] = _c.sent();
|
|
193
|
+
_c.label = 2;
|
|
194
|
+
case 2:
|
|
163
195
|
if (this.configuration && this.configuration.apiKey) {
|
|
164
196
|
headerParameters["Authorization"] = this.configuration.apiKey("Authorization"); // api-key authentication
|
|
165
197
|
}
|
|
@@ -169,8 +201,8 @@ var ProductsApi = /** @class */ (function (_super) {
|
|
|
169
201
|
headers: headerParameters,
|
|
170
202
|
query: queryParameters,
|
|
171
203
|
}, initOverrides)];
|
|
172
|
-
case
|
|
173
|
-
response =
|
|
204
|
+
case 3:
|
|
205
|
+
response = _c.sent();
|
|
174
206
|
return [2 /*return*/, new runtime.JSONApiResponse(response, function (jsonValue) { return (0, index_1.ProductsResponseFromJSON)(jsonValue); })];
|
|
175
207
|
}
|
|
176
208
|
});
|
|
@@ -180,12 +212,13 @@ var ProductsApi = /** @class */ (function (_super) {
|
|
|
180
212
|
* Lists all products
|
|
181
213
|
* List products
|
|
182
214
|
*/
|
|
183
|
-
ProductsApi.prototype.getProducts = function (
|
|
215
|
+
ProductsApi.prototype.getProducts = function (project, optionalParameters, initOverrides) {
|
|
216
|
+
if (optionalParameters === void 0) { optionalParameters = {}; }
|
|
184
217
|
return __awaiter(this, void 0, void 0, function () {
|
|
185
218
|
var response;
|
|
186
219
|
return __generator(this, function (_a) {
|
|
187
220
|
switch (_a.label) {
|
|
188
|
-
case 0: return [4 /*yield*/, this.getProductsRaw(
|
|
221
|
+
case 0: return [4 /*yield*/, this.getProductsRaw(__assign({ project: project }, optionalParameters), initOverrides)];
|
|
189
222
|
case 1:
|
|
190
223
|
response = _a.sent();
|
|
191
224
|
return [4 /*yield*/, response.value()];
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
* Product Catalog API
|
|
3
3
|
* Manage Teemill Product Catalog For full documentation on functionality and account settings go to [teemill.com](https://teemill.com)
|
|
4
4
|
*
|
|
5
|
-
* The version of the OpenAPI document: 1.
|
|
5
|
+
* The version of the OpenAPI document: 1.3.0
|
|
6
6
|
* Contact: hello@teemill.com
|
|
7
7
|
*
|
|
8
8
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
@@ -35,7 +35,7 @@ export declare class VariantsApi extends runtime.BaseAPI {
|
|
|
35
35
|
* Gets a variant by the given id
|
|
36
36
|
* Get variant
|
|
37
37
|
*/
|
|
38
|
-
getVariant(
|
|
38
|
+
getVariant(project: string, variantId: string, optionalParameters?: runtime.OptionalOnly<GetVariantRequest>, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Variant>;
|
|
39
39
|
/**
|
|
40
40
|
* Lists all variants
|
|
41
41
|
* List variants
|
|
@@ -45,5 +45,5 @@ export declare class VariantsApi extends runtime.BaseAPI {
|
|
|
45
45
|
* Lists all variants
|
|
46
46
|
* List variants
|
|
47
47
|
*/
|
|
48
|
-
listVariants(
|
|
48
|
+
listVariants(project: string, optionalParameters?: runtime.OptionalOnly<ListVariantsRequest>, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<VariantsResponse>;
|
|
49
49
|
}
|
package/dist/apis/VariantsApi.js
CHANGED
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
* Product Catalog API
|
|
6
6
|
* Manage Teemill Product Catalog For full documentation on functionality and account settings go to [teemill.com](https://teemill.com)
|
|
7
7
|
*
|
|
8
|
-
* The version of the OpenAPI document: 1.
|
|
8
|
+
* The version of the OpenAPI document: 1.3.0
|
|
9
9
|
* Contact: hello@teemill.com
|
|
10
10
|
*
|
|
11
11
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
@@ -27,6 +27,17 @@ var __extends = (this && this.__extends) || (function () {
|
|
|
27
27
|
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
28
28
|
};
|
|
29
29
|
})();
|
|
30
|
+
var __assign = (this && this.__assign) || function () {
|
|
31
|
+
__assign = Object.assign || function(t) {
|
|
32
|
+
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
33
|
+
s = arguments[i];
|
|
34
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
|
35
|
+
t[p] = s[p];
|
|
36
|
+
}
|
|
37
|
+
return t;
|
|
38
|
+
};
|
|
39
|
+
return __assign.apply(this, arguments);
|
|
40
|
+
};
|
|
30
41
|
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
31
42
|
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
32
43
|
return new (P || (P = Promise))(function (resolve, reject) {
|
|
@@ -81,9 +92,9 @@ var VariantsApi = /** @class */ (function (_super) {
|
|
|
81
92
|
*/
|
|
82
93
|
VariantsApi.prototype.getVariantRaw = function (requestParameters, initOverrides) {
|
|
83
94
|
return __awaiter(this, void 0, void 0, function () {
|
|
84
|
-
var queryParameters, headerParameters, response;
|
|
85
|
-
return __generator(this, function (
|
|
86
|
-
switch (
|
|
95
|
+
var queryParameters, headerParameters, _a, _b, response;
|
|
96
|
+
return __generator(this, function (_c) {
|
|
97
|
+
switch (_c.label) {
|
|
87
98
|
case 0:
|
|
88
99
|
if (requestParameters.project === null || requestParameters.project === undefined) {
|
|
89
100
|
throw new runtime.RequiredError('project', 'Required parameter requestParameters.project was null or undefined when calling getVariant.');
|
|
@@ -99,6 +110,16 @@ var VariantsApi = /** @class */ (function (_super) {
|
|
|
99
110
|
queryParameters['fields'] = requestParameters.fields;
|
|
100
111
|
}
|
|
101
112
|
headerParameters = {};
|
|
113
|
+
if (!(this.configuration && this.configuration.accessToken)) return [3 /*break*/, 2];
|
|
114
|
+
// oauth required
|
|
115
|
+
_a = headerParameters;
|
|
116
|
+
_b = "Authorization";
|
|
117
|
+
return [4 /*yield*/, this.configuration.accessToken("session-oauth", [])];
|
|
118
|
+
case 1:
|
|
119
|
+
// oauth required
|
|
120
|
+
_a[_b] = _c.sent();
|
|
121
|
+
_c.label = 2;
|
|
122
|
+
case 2:
|
|
102
123
|
if (this.configuration && this.configuration.apiKey) {
|
|
103
124
|
headerParameters["Authorization"] = this.configuration.apiKey("Authorization"); // api-key authentication
|
|
104
125
|
}
|
|
@@ -108,8 +129,8 @@ var VariantsApi = /** @class */ (function (_super) {
|
|
|
108
129
|
headers: headerParameters,
|
|
109
130
|
query: queryParameters,
|
|
110
131
|
}, initOverrides)];
|
|
111
|
-
case
|
|
112
|
-
response =
|
|
132
|
+
case 3:
|
|
133
|
+
response = _c.sent();
|
|
113
134
|
return [2 /*return*/, new runtime.JSONApiResponse(response, function (jsonValue) { return (0, index_1.VariantFromJSON)(jsonValue); })];
|
|
114
135
|
}
|
|
115
136
|
});
|
|
@@ -119,12 +140,13 @@ var VariantsApi = /** @class */ (function (_super) {
|
|
|
119
140
|
* Gets a variant by the given id
|
|
120
141
|
* Get variant
|
|
121
142
|
*/
|
|
122
|
-
VariantsApi.prototype.getVariant = function (
|
|
143
|
+
VariantsApi.prototype.getVariant = function (project, variantId, optionalParameters, initOverrides) {
|
|
144
|
+
if (optionalParameters === void 0) { optionalParameters = {}; }
|
|
123
145
|
return __awaiter(this, void 0, void 0, function () {
|
|
124
146
|
var response;
|
|
125
147
|
return __generator(this, function (_a) {
|
|
126
148
|
switch (_a.label) {
|
|
127
|
-
case 0: return [4 /*yield*/, this.getVariantRaw(
|
|
149
|
+
case 0: return [4 /*yield*/, this.getVariantRaw(__assign({ project: project, variantId: variantId }, optionalParameters), initOverrides)];
|
|
128
150
|
case 1:
|
|
129
151
|
response = _a.sent();
|
|
130
152
|
return [4 /*yield*/, response.value()];
|
|
@@ -139,9 +161,9 @@ var VariantsApi = /** @class */ (function (_super) {
|
|
|
139
161
|
*/
|
|
140
162
|
VariantsApi.prototype.listVariantsRaw = function (requestParameters, initOverrides) {
|
|
141
163
|
return __awaiter(this, void 0, void 0, function () {
|
|
142
|
-
var queryParameters, headerParameters, response;
|
|
143
|
-
return __generator(this, function (
|
|
144
|
-
switch (
|
|
164
|
+
var queryParameters, headerParameters, _a, _b, response;
|
|
165
|
+
return __generator(this, function (_c) {
|
|
166
|
+
switch (_c.label) {
|
|
145
167
|
case 0:
|
|
146
168
|
if (requestParameters.project === null || requestParameters.project === undefined) {
|
|
147
169
|
throw new runtime.RequiredError('project', 'Required parameter requestParameters.project was null or undefined when calling listVariants.');
|
|
@@ -160,6 +182,16 @@ var VariantsApi = /** @class */ (function (_super) {
|
|
|
160
182
|
queryParameters['fields'] = requestParameters.fields;
|
|
161
183
|
}
|
|
162
184
|
headerParameters = {};
|
|
185
|
+
if (!(this.configuration && this.configuration.accessToken)) return [3 /*break*/, 2];
|
|
186
|
+
// oauth required
|
|
187
|
+
_a = headerParameters;
|
|
188
|
+
_b = "Authorization";
|
|
189
|
+
return [4 /*yield*/, this.configuration.accessToken("session-oauth", [])];
|
|
190
|
+
case 1:
|
|
191
|
+
// oauth required
|
|
192
|
+
_a[_b] = _c.sent();
|
|
193
|
+
_c.label = 2;
|
|
194
|
+
case 2:
|
|
163
195
|
if (this.configuration && this.configuration.apiKey) {
|
|
164
196
|
headerParameters["Authorization"] = this.configuration.apiKey("Authorization"); // api-key authentication
|
|
165
197
|
}
|
|
@@ -169,8 +201,8 @@ var VariantsApi = /** @class */ (function (_super) {
|
|
|
169
201
|
headers: headerParameters,
|
|
170
202
|
query: queryParameters,
|
|
171
203
|
}, initOverrides)];
|
|
172
|
-
case
|
|
173
|
-
response =
|
|
204
|
+
case 3:
|
|
205
|
+
response = _c.sent();
|
|
174
206
|
return [2 /*return*/, new runtime.JSONApiResponse(response, function (jsonValue) { return (0, index_1.VariantsResponseFromJSON)(jsonValue); })];
|
|
175
207
|
}
|
|
176
208
|
});
|
|
@@ -180,12 +212,13 @@ var VariantsApi = /** @class */ (function (_super) {
|
|
|
180
212
|
* Lists all variants
|
|
181
213
|
* List variants
|
|
182
214
|
*/
|
|
183
|
-
VariantsApi.prototype.listVariants = function (
|
|
215
|
+
VariantsApi.prototype.listVariants = function (project, optionalParameters, initOverrides) {
|
|
216
|
+
if (optionalParameters === void 0) { optionalParameters = {}; }
|
|
184
217
|
return __awaiter(this, void 0, void 0, function () {
|
|
185
218
|
var response;
|
|
186
219
|
return __generator(this, function (_a) {
|
|
187
220
|
switch (_a.label) {
|
|
188
|
-
case 0: return [4 /*yield*/, this.listVariantsRaw(
|
|
221
|
+
case 0: return [4 /*yield*/, this.listVariantsRaw(__assign({ project: project }, optionalParameters), initOverrides)];
|
|
189
222
|
case 1:
|
|
190
223
|
response = _a.sent();
|
|
191
224
|
return [4 /*yield*/, response.value()];
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
* Product Catalog API
|
|
3
3
|
* Manage Teemill Product Catalog For full documentation on functionality and account settings go to [teemill.com](https://teemill.com)
|
|
4
4
|
*
|
|
5
|
-
* The version of the OpenAPI document: 1.
|
|
5
|
+
* The version of the OpenAPI document: 1.3.0
|
|
6
6
|
* Contact: hello@teemill.com
|
|
7
7
|
*
|
|
8
8
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
package/dist/models/ApiError.js
CHANGED
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
* Product Catalog API
|
|
6
6
|
* Manage Teemill Product Catalog For full documentation on functionality and account settings go to [teemill.com](https://teemill.com)
|
|
7
7
|
*
|
|
8
|
-
* The version of the OpenAPI document: 1.
|
|
8
|
+
* The version of the OpenAPI document: 1.3.0
|
|
9
9
|
* Contact: hello@teemill.com
|
|
10
10
|
*
|
|
11
11
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
* Product Catalog API
|
|
3
3
|
* Manage Teemill Product Catalog For full documentation on functionality and account settings go to [teemill.com](https://teemill.com)
|
|
4
4
|
*
|
|
5
|
-
* The version of the OpenAPI document: 1.
|
|
5
|
+
* The version of the OpenAPI document: 1.3.0
|
|
6
6
|
* Contact: hello@teemill.com
|
|
7
7
|
*
|
|
8
8
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
package/dist/models/Attribute.js
CHANGED
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
* Product Catalog API
|
|
6
6
|
* Manage Teemill Product Catalog For full documentation on functionality and account settings go to [teemill.com](https://teemill.com)
|
|
7
7
|
*
|
|
8
|
-
* The version of the OpenAPI document: 1.
|
|
8
|
+
* The version of the OpenAPI document: 1.3.0
|
|
9
9
|
* Contact: hello@teemill.com
|
|
10
10
|
*
|
|
11
11
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
* Product Catalog API
|
|
3
3
|
* Manage Teemill Product Catalog For full documentation on functionality and account settings go to [teemill.com](https://teemill.com)
|
|
4
4
|
*
|
|
5
|
-
* The version of the OpenAPI document: 1.
|
|
5
|
+
* The version of the OpenAPI document: 1.3.0
|
|
6
6
|
* Contact: hello@teemill.com
|
|
7
7
|
*
|
|
8
8
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
* Product Catalog API
|
|
6
6
|
* Manage Teemill Product Catalog For full documentation on functionality and account settings go to [teemill.com](https://teemill.com)
|
|
7
7
|
*
|
|
8
|
-
* The version of the OpenAPI document: 1.
|
|
8
|
+
* The version of the OpenAPI document: 1.3.0
|
|
9
9
|
* Contact: hello@teemill.com
|
|
10
10
|
*
|
|
11
11
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
package/dist/models/Image.d.ts
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
* Product Catalog API
|
|
3
3
|
* Manage Teemill Product Catalog For full documentation on functionality and account settings go to [teemill.com](https://teemill.com)
|
|
4
4
|
*
|
|
5
|
-
* The version of the OpenAPI document: 1.
|
|
5
|
+
* The version of the OpenAPI document: 1.3.0
|
|
6
6
|
* Contact: hello@teemill.com
|
|
7
7
|
*
|
|
8
8
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
package/dist/models/Image.js
CHANGED
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
* Product Catalog API
|
|
6
6
|
* Manage Teemill Product Catalog For full documentation on functionality and account settings go to [teemill.com](https://teemill.com)
|
|
7
7
|
*
|
|
8
|
-
* The version of the OpenAPI document: 1.
|
|
8
|
+
* The version of the OpenAPI document: 1.3.0
|
|
9
9
|
* Contact: hello@teemill.com
|
|
10
10
|
*
|
|
11
11
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
package/dist/models/Price.d.ts
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
* Product Catalog API
|
|
3
3
|
* Manage Teemill Product Catalog For full documentation on functionality and account settings go to [teemill.com](https://teemill.com)
|
|
4
4
|
*
|
|
5
|
-
* The version of the OpenAPI document: 1.
|
|
5
|
+
* The version of the OpenAPI document: 1.3.0
|
|
6
6
|
* Contact: hello@teemill.com
|
|
7
7
|
*
|
|
8
8
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
package/dist/models/Price.js
CHANGED
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
* Product Catalog API
|
|
6
6
|
* Manage Teemill Product Catalog For full documentation on functionality and account settings go to [teemill.com](https://teemill.com)
|
|
7
7
|
*
|
|
8
|
-
* The version of the OpenAPI document: 1.
|
|
8
|
+
* The version of the OpenAPI document: 1.3.0
|
|
9
9
|
* Contact: hello@teemill.com
|
|
10
10
|
*
|
|
11
11
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
package/dist/models/Product.d.ts
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
* Product Catalog API
|
|
3
3
|
* Manage Teemill Product Catalog For full documentation on functionality and account settings go to [teemill.com](https://teemill.com)
|
|
4
4
|
*
|
|
5
|
-
* The version of the OpenAPI document: 1.
|
|
5
|
+
* The version of the OpenAPI document: 1.3.0
|
|
6
6
|
* Contact: hello@teemill.com
|
|
7
7
|
*
|
|
8
8
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
package/dist/models/Product.js
CHANGED
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
* Product Catalog API
|
|
6
6
|
* Manage Teemill Product Catalog For full documentation on functionality and account settings go to [teemill.com](https://teemill.com)
|
|
7
7
|
*
|
|
8
|
-
* The version of the OpenAPI document: 1.
|
|
8
|
+
* The version of the OpenAPI document: 1.3.0
|
|
9
9
|
* Contact: hello@teemill.com
|
|
10
10
|
*
|
|
11
11
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
* Product Catalog API
|
|
3
3
|
* Manage Teemill Product Catalog For full documentation on functionality and account settings go to [teemill.com](https://teemill.com)
|
|
4
4
|
*
|
|
5
|
-
* The version of the OpenAPI document: 1.
|
|
5
|
+
* The version of the OpenAPI document: 1.3.0
|
|
6
6
|
* Contact: hello@teemill.com
|
|
7
7
|
*
|
|
8
8
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
* Product Catalog API
|
|
6
6
|
* Manage Teemill Product Catalog For full documentation on functionality and account settings go to [teemill.com](https://teemill.com)
|
|
7
7
|
*
|
|
8
|
-
* The version of the OpenAPI document: 1.
|
|
8
|
+
* The version of the OpenAPI document: 1.3.0
|
|
9
9
|
* Contact: hello@teemill.com
|
|
10
10
|
*
|
|
11
11
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
package/dist/models/Stock.d.ts
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
* Product Catalog API
|
|
3
3
|
* Manage Teemill Product Catalog For full documentation on functionality and account settings go to [teemill.com](https://teemill.com)
|
|
4
4
|
*
|
|
5
|
-
* The version of the OpenAPI document: 1.
|
|
5
|
+
* The version of the OpenAPI document: 1.3.0
|
|
6
6
|
* Contact: hello@teemill.com
|
|
7
7
|
*
|
|
8
8
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
package/dist/models/Stock.js
CHANGED
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
* Product Catalog API
|
|
6
6
|
* Manage Teemill Product Catalog For full documentation on functionality and account settings go to [teemill.com](https://teemill.com)
|
|
7
7
|
*
|
|
8
|
-
* The version of the OpenAPI document: 1.
|
|
8
|
+
* The version of the OpenAPI document: 1.3.0
|
|
9
9
|
* Contact: hello@teemill.com
|
|
10
10
|
*
|
|
11
11
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
package/dist/models/Variant.d.ts
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
* Product Catalog API
|
|
3
3
|
* Manage Teemill Product Catalog For full documentation on functionality and account settings go to [teemill.com](https://teemill.com)
|
|
4
4
|
*
|
|
5
|
-
* The version of the OpenAPI document: 1.
|
|
5
|
+
* The version of the OpenAPI document: 1.3.0
|
|
6
6
|
* Contact: hello@teemill.com
|
|
7
7
|
*
|
|
8
8
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
package/dist/models/Variant.js
CHANGED
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
* Product Catalog API
|
|
6
6
|
* Manage Teemill Product Catalog For full documentation on functionality and account settings go to [teemill.com](https://teemill.com)
|
|
7
7
|
*
|
|
8
|
-
* The version of the OpenAPI document: 1.
|
|
8
|
+
* The version of the OpenAPI document: 1.3.0
|
|
9
9
|
* Contact: hello@teemill.com
|
|
10
10
|
*
|
|
11
11
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
* Product Catalog API
|
|
3
3
|
* Manage Teemill Product Catalog For full documentation on functionality and account settings go to [teemill.com](https://teemill.com)
|
|
4
4
|
*
|
|
5
|
-
* The version of the OpenAPI document: 1.
|
|
5
|
+
* The version of the OpenAPI document: 1.3.0
|
|
6
6
|
* Contact: hello@teemill.com
|
|
7
7
|
*
|
|
8
8
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
* Product Catalog API
|
|
6
6
|
* Manage Teemill Product Catalog For full documentation on functionality and account settings go to [teemill.com](https://teemill.com)
|
|
7
7
|
*
|
|
8
|
-
* The version of the OpenAPI document: 1.
|
|
8
|
+
* The version of the OpenAPI document: 1.3.0
|
|
9
9
|
* Contact: hello@teemill.com
|
|
10
10
|
*
|
|
11
11
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
* Product Catalog API
|
|
3
3
|
* Manage Teemill Product Catalog For full documentation on functionality and account settings go to [teemill.com](https://teemill.com)
|
|
4
4
|
*
|
|
5
|
-
* The version of the OpenAPI document: 1.
|
|
5
|
+
* The version of the OpenAPI document: 1.3.0
|
|
6
6
|
* Contact: hello@teemill.com
|
|
7
7
|
*
|
|
8
8
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
* Product Catalog API
|
|
6
6
|
* Manage Teemill Product Catalog For full documentation on functionality and account settings go to [teemill.com](https://teemill.com)
|
|
7
7
|
*
|
|
8
|
-
* The version of the OpenAPI document: 1.
|
|
8
|
+
* The version of the OpenAPI document: 1.3.0
|
|
9
9
|
* Contact: hello@teemill.com
|
|
10
10
|
*
|
|
11
11
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
package/dist/runtime.d.ts
CHANGED
|
@@ -2,13 +2,17 @@
|
|
|
2
2
|
* Product Catalog API
|
|
3
3
|
* Manage Teemill Product Catalog For full documentation on functionality and account settings go to [teemill.com](https://teemill.com)
|
|
4
4
|
*
|
|
5
|
-
* The version of the OpenAPI document: 1.
|
|
5
|
+
* The version of the OpenAPI document: 1.3.0
|
|
6
6
|
* Contact: hello@teemill.com
|
|
7
7
|
*
|
|
8
8
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
9
9
|
* https://openapi-generator.tech
|
|
10
10
|
* Do not edit the class manually.
|
|
11
11
|
*/
|
|
12
|
+
export type OptionalProperties<T> = {
|
|
13
|
+
[K in keyof T]-?: undefined extends T[K] ? K : never;
|
|
14
|
+
}[keyof T];
|
|
15
|
+
export type OptionalOnly<T> = Partial<Pick<T, OptionalProperties<T>>>;
|
|
12
16
|
export declare const BASE_PATH: string;
|
|
13
17
|
export interface ConfigurationParameters {
|
|
14
18
|
basePath?: string;
|
|
@@ -46,6 +50,7 @@ export declare class BaseAPI {
|
|
|
46
50
|
private static readonly jsonRegex;
|
|
47
51
|
private middleware;
|
|
48
52
|
constructor(configuration?: Configuration);
|
|
53
|
+
isResponseError(error: any): error is ResponseError;
|
|
49
54
|
withMiddleware<T extends BaseAPI>(this: T, ...middlewares: Middleware[]): T;
|
|
50
55
|
withPreMiddleware<T extends BaseAPI>(this: T, ...preMiddlewares: Array<Middleware['pre']>): T;
|
|
51
56
|
withPostMiddleware<T extends BaseAPI>(this: T, ...postMiddlewares: Array<Middleware['post']>): T;
|
package/dist/runtime.js
CHANGED
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
* Product Catalog API
|
|
6
6
|
* Manage Teemill Product Catalog For full documentation on functionality and account settings go to [teemill.com](https://teemill.com)
|
|
7
7
|
*
|
|
8
|
-
* The version of the OpenAPI document: 1.
|
|
8
|
+
* The version of the OpenAPI document: 1.3.0
|
|
9
9
|
* Contact: hello@teemill.com
|
|
10
10
|
*
|
|
11
11
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
@@ -266,6 +266,9 @@ var BaseAPI = /** @class */ (function () {
|
|
|
266
266
|
}); };
|
|
267
267
|
this.middleware = configuration.middleware;
|
|
268
268
|
}
|
|
269
|
+
BaseAPI.prototype.isResponseError = function (error) {
|
|
270
|
+
return error instanceof Error && error.name === 'ResponseError';
|
|
271
|
+
};
|
|
269
272
|
BaseAPI.prototype.withMiddleware = function () {
|
|
270
273
|
var _a;
|
|
271
274
|
var middlewares = [];
|
|
@@ -456,8 +459,8 @@ function querystringSingleKey(key, value, keyPrefix) {
|
|
|
456
459
|
var fullKey = keyPrefix + (keyPrefix.length ? "[".concat(key, "]") : key);
|
|
457
460
|
if (value instanceof Array) {
|
|
458
461
|
var multiValue = value.map(function (singleValue) { return encodeURIComponent(String(singleValue)); })
|
|
459
|
-
.join("&".concat(encodeURIComponent(fullKey), "="));
|
|
460
|
-
return "".concat(encodeURIComponent(fullKey), "=").concat(multiValue);
|
|
462
|
+
.join("&".concat(encodeURIComponent(fullKey), "[]="));
|
|
463
|
+
return "".concat(encodeURIComponent(fullKey), "[]=").concat(multiValue);
|
|
461
464
|
}
|
|
462
465
|
if (value instanceof Set) {
|
|
463
466
|
var valueAsArray = Array.from(value);
|
package/package.json
CHANGED
package/src/apis/ProductsApi.ts
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* Product Catalog API
|
|
5
5
|
* Manage Teemill Product Catalog For full documentation on functionality and account settings go to [teemill.com](https://teemill.com)
|
|
6
6
|
*
|
|
7
|
-
* The version of the OpenAPI document: 1.
|
|
7
|
+
* The version of the OpenAPI document: 1.3.0
|
|
8
8
|
* Contact: hello@teemill.com
|
|
9
9
|
*
|
|
10
10
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
@@ -71,6 +71,11 @@ export class ProductsApi extends runtime.BaseAPI {
|
|
|
71
71
|
|
|
72
72
|
const headerParameters: runtime.HTTPHeaders = {};
|
|
73
73
|
|
|
74
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
75
|
+
// oauth required
|
|
76
|
+
headerParameters["Authorization"] = await this.configuration.accessToken("session-oauth", []);
|
|
77
|
+
}
|
|
78
|
+
|
|
74
79
|
if (this.configuration && this.configuration.apiKey) {
|
|
75
80
|
headerParameters["Authorization"] = this.configuration.apiKey("Authorization"); // api-key authentication
|
|
76
81
|
}
|
|
@@ -89,8 +94,20 @@ export class ProductsApi extends runtime.BaseAPI {
|
|
|
89
94
|
* Gets a product by the given id
|
|
90
95
|
* Get product
|
|
91
96
|
*/
|
|
92
|
-
async getProduct(
|
|
93
|
-
|
|
97
|
+
async getProduct(
|
|
98
|
+
project: string, productId: string,
|
|
99
|
+
optionalParameters: runtime.OptionalOnly<GetProductRequest> = {},
|
|
100
|
+
initOverrides?: RequestInit | runtime.InitOverrideFunction
|
|
101
|
+
): Promise<Product> {
|
|
102
|
+
const response = await this.getProductRaw(
|
|
103
|
+
{
|
|
104
|
+
project: project,
|
|
105
|
+
productId: productId,
|
|
106
|
+
...optionalParameters,
|
|
107
|
+
},
|
|
108
|
+
initOverrides
|
|
109
|
+
);
|
|
110
|
+
|
|
94
111
|
return await response.value();
|
|
95
112
|
}
|
|
96
113
|
|
|
@@ -123,6 +140,11 @@ export class ProductsApi extends runtime.BaseAPI {
|
|
|
123
140
|
|
|
124
141
|
const headerParameters: runtime.HTTPHeaders = {};
|
|
125
142
|
|
|
143
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
144
|
+
// oauth required
|
|
145
|
+
headerParameters["Authorization"] = await this.configuration.accessToken("session-oauth", []);
|
|
146
|
+
}
|
|
147
|
+
|
|
126
148
|
if (this.configuration && this.configuration.apiKey) {
|
|
127
149
|
headerParameters["Authorization"] = this.configuration.apiKey("Authorization"); // api-key authentication
|
|
128
150
|
}
|
|
@@ -141,8 +163,19 @@ export class ProductsApi extends runtime.BaseAPI {
|
|
|
141
163
|
* Lists all products
|
|
142
164
|
* List products
|
|
143
165
|
*/
|
|
144
|
-
async getProducts(
|
|
145
|
-
|
|
166
|
+
async getProducts(
|
|
167
|
+
project: string,
|
|
168
|
+
optionalParameters: runtime.OptionalOnly<GetProductsRequest> = {},
|
|
169
|
+
initOverrides?: RequestInit | runtime.InitOverrideFunction
|
|
170
|
+
): Promise<ProductsResponse> {
|
|
171
|
+
const response = await this.getProductsRaw(
|
|
172
|
+
{
|
|
173
|
+
project: project,
|
|
174
|
+
...optionalParameters,
|
|
175
|
+
},
|
|
176
|
+
initOverrides
|
|
177
|
+
);
|
|
178
|
+
|
|
146
179
|
return await response.value();
|
|
147
180
|
}
|
|
148
181
|
|
package/src/apis/VariantsApi.ts
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* Product Catalog API
|
|
5
5
|
* Manage Teemill Product Catalog For full documentation on functionality and account settings go to [teemill.com](https://teemill.com)
|
|
6
6
|
*
|
|
7
|
-
* The version of the OpenAPI document: 1.
|
|
7
|
+
* The version of the OpenAPI document: 1.3.0
|
|
8
8
|
* Contact: hello@teemill.com
|
|
9
9
|
*
|
|
10
10
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
@@ -71,6 +71,11 @@ export class VariantsApi extends runtime.BaseAPI {
|
|
|
71
71
|
|
|
72
72
|
const headerParameters: runtime.HTTPHeaders = {};
|
|
73
73
|
|
|
74
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
75
|
+
// oauth required
|
|
76
|
+
headerParameters["Authorization"] = await this.configuration.accessToken("session-oauth", []);
|
|
77
|
+
}
|
|
78
|
+
|
|
74
79
|
if (this.configuration && this.configuration.apiKey) {
|
|
75
80
|
headerParameters["Authorization"] = this.configuration.apiKey("Authorization"); // api-key authentication
|
|
76
81
|
}
|
|
@@ -89,8 +94,20 @@ export class VariantsApi extends runtime.BaseAPI {
|
|
|
89
94
|
* Gets a variant by the given id
|
|
90
95
|
* Get variant
|
|
91
96
|
*/
|
|
92
|
-
async getVariant(
|
|
93
|
-
|
|
97
|
+
async getVariant(
|
|
98
|
+
project: string, variantId: string,
|
|
99
|
+
optionalParameters: runtime.OptionalOnly<GetVariantRequest> = {},
|
|
100
|
+
initOverrides?: RequestInit | runtime.InitOverrideFunction
|
|
101
|
+
): Promise<Variant> {
|
|
102
|
+
const response = await this.getVariantRaw(
|
|
103
|
+
{
|
|
104
|
+
project: project,
|
|
105
|
+
variantId: variantId,
|
|
106
|
+
...optionalParameters,
|
|
107
|
+
},
|
|
108
|
+
initOverrides
|
|
109
|
+
);
|
|
110
|
+
|
|
94
111
|
return await response.value();
|
|
95
112
|
}
|
|
96
113
|
|
|
@@ -123,6 +140,11 @@ export class VariantsApi extends runtime.BaseAPI {
|
|
|
123
140
|
|
|
124
141
|
const headerParameters: runtime.HTTPHeaders = {};
|
|
125
142
|
|
|
143
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
144
|
+
// oauth required
|
|
145
|
+
headerParameters["Authorization"] = await this.configuration.accessToken("session-oauth", []);
|
|
146
|
+
}
|
|
147
|
+
|
|
126
148
|
if (this.configuration && this.configuration.apiKey) {
|
|
127
149
|
headerParameters["Authorization"] = this.configuration.apiKey("Authorization"); // api-key authentication
|
|
128
150
|
}
|
|
@@ -141,8 +163,19 @@ export class VariantsApi extends runtime.BaseAPI {
|
|
|
141
163
|
* Lists all variants
|
|
142
164
|
* List variants
|
|
143
165
|
*/
|
|
144
|
-
async listVariants(
|
|
145
|
-
|
|
166
|
+
async listVariants(
|
|
167
|
+
project: string,
|
|
168
|
+
optionalParameters: runtime.OptionalOnly<ListVariantsRequest> = {},
|
|
169
|
+
initOverrides?: RequestInit | runtime.InitOverrideFunction
|
|
170
|
+
): Promise<VariantsResponse> {
|
|
171
|
+
const response = await this.listVariantsRaw(
|
|
172
|
+
{
|
|
173
|
+
project: project,
|
|
174
|
+
...optionalParameters,
|
|
175
|
+
},
|
|
176
|
+
initOverrides
|
|
177
|
+
);
|
|
178
|
+
|
|
146
179
|
return await response.value();
|
|
147
180
|
}
|
|
148
181
|
|
package/src/models/ApiError.ts
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* Product Catalog API
|
|
5
5
|
* Manage Teemill Product Catalog For full documentation on functionality and account settings go to [teemill.com](https://teemill.com)
|
|
6
6
|
*
|
|
7
|
-
* The version of the OpenAPI document: 1.
|
|
7
|
+
* The version of the OpenAPI document: 1.3.0
|
|
8
8
|
* Contact: hello@teemill.com
|
|
9
9
|
*
|
|
10
10
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
package/src/models/Attribute.ts
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* Product Catalog API
|
|
5
5
|
* Manage Teemill Product Catalog For full documentation on functionality and account settings go to [teemill.com](https://teemill.com)
|
|
6
6
|
*
|
|
7
|
-
* The version of the OpenAPI document: 1.
|
|
7
|
+
* The version of the OpenAPI document: 1.3.0
|
|
8
8
|
* Contact: hello@teemill.com
|
|
9
9
|
*
|
|
10
10
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* Product Catalog API
|
|
5
5
|
* Manage Teemill Product Catalog For full documentation on functionality and account settings go to [teemill.com](https://teemill.com)
|
|
6
6
|
*
|
|
7
|
-
* The version of the OpenAPI document: 1.
|
|
7
|
+
* The version of the OpenAPI document: 1.3.0
|
|
8
8
|
* Contact: hello@teemill.com
|
|
9
9
|
*
|
|
10
10
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
package/src/models/Image.ts
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* Product Catalog API
|
|
5
5
|
* Manage Teemill Product Catalog For full documentation on functionality and account settings go to [teemill.com](https://teemill.com)
|
|
6
6
|
*
|
|
7
|
-
* The version of the OpenAPI document: 1.
|
|
7
|
+
* The version of the OpenAPI document: 1.3.0
|
|
8
8
|
* Contact: hello@teemill.com
|
|
9
9
|
*
|
|
10
10
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
package/src/models/Price.ts
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* Product Catalog API
|
|
5
5
|
* Manage Teemill Product Catalog For full documentation on functionality and account settings go to [teemill.com](https://teemill.com)
|
|
6
6
|
*
|
|
7
|
-
* The version of the OpenAPI document: 1.
|
|
7
|
+
* The version of the OpenAPI document: 1.3.0
|
|
8
8
|
* Contact: hello@teemill.com
|
|
9
9
|
*
|
|
10
10
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
package/src/models/Product.ts
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* Product Catalog API
|
|
5
5
|
* Manage Teemill Product Catalog For full documentation on functionality and account settings go to [teemill.com](https://teemill.com)
|
|
6
6
|
*
|
|
7
|
-
* The version of the OpenAPI document: 1.
|
|
7
|
+
* The version of the OpenAPI document: 1.3.0
|
|
8
8
|
* Contact: hello@teemill.com
|
|
9
9
|
*
|
|
10
10
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* Product Catalog API
|
|
5
5
|
* Manage Teemill Product Catalog For full documentation on functionality and account settings go to [teemill.com](https://teemill.com)
|
|
6
6
|
*
|
|
7
|
-
* The version of the OpenAPI document: 1.
|
|
7
|
+
* The version of the OpenAPI document: 1.3.0
|
|
8
8
|
* Contact: hello@teemill.com
|
|
9
9
|
*
|
|
10
10
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
package/src/models/Stock.ts
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* Product Catalog API
|
|
5
5
|
* Manage Teemill Product Catalog For full documentation on functionality and account settings go to [teemill.com](https://teemill.com)
|
|
6
6
|
*
|
|
7
|
-
* The version of the OpenAPI document: 1.
|
|
7
|
+
* The version of the OpenAPI document: 1.3.0
|
|
8
8
|
* Contact: hello@teemill.com
|
|
9
9
|
*
|
|
10
10
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
package/src/models/Variant.ts
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* Product Catalog API
|
|
5
5
|
* Manage Teemill Product Catalog For full documentation on functionality and account settings go to [teemill.com](https://teemill.com)
|
|
6
6
|
*
|
|
7
|
-
* The version of the OpenAPI document: 1.
|
|
7
|
+
* The version of the OpenAPI document: 1.3.0
|
|
8
8
|
* Contact: hello@teemill.com
|
|
9
9
|
*
|
|
10
10
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* Product Catalog API
|
|
5
5
|
* Manage Teemill Product Catalog For full documentation on functionality and account settings go to [teemill.com](https://teemill.com)
|
|
6
6
|
*
|
|
7
|
-
* The version of the OpenAPI document: 1.
|
|
7
|
+
* The version of the OpenAPI document: 1.3.0
|
|
8
8
|
* Contact: hello@teemill.com
|
|
9
9
|
*
|
|
10
10
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* Product Catalog API
|
|
5
5
|
* Manage Teemill Product Catalog For full documentation on functionality and account settings go to [teemill.com](https://teemill.com)
|
|
6
6
|
*
|
|
7
|
-
* The version of the OpenAPI document: 1.
|
|
7
|
+
* The version of the OpenAPI document: 1.3.0
|
|
8
8
|
* Contact: hello@teemill.com
|
|
9
9
|
*
|
|
10
10
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
package/src/runtime.ts
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* Product Catalog API
|
|
5
5
|
* Manage Teemill Product Catalog For full documentation on functionality and account settings go to [teemill.com](https://teemill.com)
|
|
6
6
|
*
|
|
7
|
-
* The version of the OpenAPI document: 1.
|
|
7
|
+
* The version of the OpenAPI document: 1.3.0
|
|
8
8
|
* Contact: hello@teemill.com
|
|
9
9
|
*
|
|
10
10
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
@@ -13,6 +13,12 @@
|
|
|
13
13
|
*/
|
|
14
14
|
|
|
15
15
|
|
|
16
|
+
export type OptionalProperties<T> = {
|
|
17
|
+
[K in keyof T]-?: undefined extends T[K] ? K : never
|
|
18
|
+
}[keyof T];
|
|
19
|
+
|
|
20
|
+
export type OptionalOnly<T> = Partial<Pick<T, OptionalProperties<T>>>;
|
|
21
|
+
|
|
16
22
|
export const BASE_PATH = "http://api.localhost".replace(/\/+$/, "");
|
|
17
23
|
|
|
18
24
|
export interface ConfigurationParameters {
|
|
@@ -98,6 +104,10 @@ export class BaseAPI {
|
|
|
98
104
|
this.middleware = configuration.middleware;
|
|
99
105
|
}
|
|
100
106
|
|
|
107
|
+
isResponseError(error: any): error is ResponseError {
|
|
108
|
+
return error instanceof Error && error.name === 'ResponseError';
|
|
109
|
+
}
|
|
110
|
+
|
|
101
111
|
withMiddleware<T extends BaseAPI>(this: T, ...middlewares: Middleware[]) {
|
|
102
112
|
const next = this.clone<T>();
|
|
103
113
|
next.middleware = next.middleware.concat(...middlewares);
|
|
@@ -326,8 +336,8 @@ function querystringSingleKey(key: string, value: string | number | null | undef
|
|
|
326
336
|
const fullKey = keyPrefix + (keyPrefix.length ? `[${key}]` : key);
|
|
327
337
|
if (value instanceof Array) {
|
|
328
338
|
const multiValue = value.map(singleValue => encodeURIComponent(String(singleValue)))
|
|
329
|
-
.join(`&${encodeURIComponent(fullKey)}=`);
|
|
330
|
-
return `${encodeURIComponent(fullKey)}=${multiValue}`;
|
|
339
|
+
.join(`&${encodeURIComponent(fullKey)}[]=`);
|
|
340
|
+
return `${encodeURIComponent(fullKey)}[]=${multiValue}`;
|
|
331
341
|
}
|
|
332
342
|
if (value instanceof Set) {
|
|
333
343
|
const valueAsArray = Array.from(value);
|