@teemill/platform 0.10.0 → 0.11.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/dist/api.js CHANGED
@@ -5,7 +5,7 @@
5
5
  * Platform API
6
6
  * Manage Your podOS platform
7
7
  *
8
- * The version of the OpenAPI document: 0.10.0
8
+ * The version of the OpenAPI document: 0.11.1
9
9
  *
10
10
  *
11
11
  * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
@@ -22,7 +22,7 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
22
22
  });
23
23
  };
24
24
  Object.defineProperty(exports, "__esModule", { value: true });
25
- exports.VariantsApi = exports.VariantsApiFactory = exports.VariantsApiFp = exports.VariantsApiAxiosParamCreator = exports.ProductsApi = exports.ProductsApiFactory = exports.ProductsApiFp = exports.ProductsApiAxiosParamCreator = exports.PlatformApi = exports.PlatformApiFactory = exports.PlatformApiFp = exports.PlatformApiAxiosParamCreator = exports.OrdersApi = exports.OrdersApiFactory = exports.OrdersApiFp = exports.OrdersApiAxiosParamCreator = exports.VariantAttributeThumbnailTypeEnum = exports.ProductAttributeValuesInnerThumbnailTypeEnum = exports.OutputFileFormatEnum = exports.OutputPositionEnum = exports.OrderStatus = void 0;
25
+ exports.VariantsApi = exports.VariantsApiFactory = exports.VariantsApiFp = exports.VariantsApiAxiosParamCreator = exports.ProductsApi = exports.ProductsApiFactory = exports.ProductsApiFp = exports.ProductsApiAxiosParamCreator = exports.PlatformApi = exports.PlatformApiFactory = exports.PlatformApiFp = exports.PlatformApiAxiosParamCreator = exports.OrdersApi = exports.OrdersApiFactory = exports.OrdersApiFp = exports.OrdersApiAxiosParamCreator = exports.CustomersApi = exports.CustomersApiFactory = exports.CustomersApiFp = exports.CustomersApiAxiosParamCreator = exports.VariantAttributeThumbnailTypeEnum = exports.ProductAttributeValuesInnerThumbnailTypeEnum = exports.OutputFileFormatEnum = exports.OutputPositionEnum = exports.OrderStatus = void 0;
26
26
  const axios_1 = require("axios");
27
27
  // Some imports not used depending on template conditions
28
28
  // @ts-ignore
@@ -69,6 +69,298 @@ exports.VariantAttributeThumbnailTypeEnum = {
69
69
  Color: 'color',
70
70
  Image: 'image'
71
71
  };
72
+ /**
73
+ * CustomersApi - axios parameter creator
74
+ * @export
75
+ */
76
+ const CustomersApiAxiosParamCreator = function (configuration) {
77
+ return {
78
+ /**
79
+ * Export customers as a CSV file
80
+ * @summary Export customers
81
+ * @param {string} project Project unique identifier
82
+ * @param {string} platformId The platform identifier
83
+ * @param {*} [options] Override http request option.
84
+ * @throws {RequiredError}
85
+ */
86
+ exportCustomers: (project_1, platformId_1, ...args_1) => __awaiter(this, [project_1, platformId_1, ...args_1], void 0, function* (project, platformId, options = {}) {
87
+ // verify required parameter 'project' is not null or undefined
88
+ (0, common_1.assertParamExists)('exportCustomers', 'project', project);
89
+ // verify required parameter 'platformId' is not null or undefined
90
+ (0, common_1.assertParamExists)('exportCustomers', 'platformId', platformId);
91
+ const localVarPath = `/v1/platform/{platformId}/customers/export`
92
+ .replace(`{${"platformId"}}`, encodeURIComponent(String(platformId)));
93
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
94
+ const localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
95
+ let baseOptions;
96
+ if (configuration) {
97
+ baseOptions = configuration.baseOptions;
98
+ }
99
+ const localVarRequestOptions = Object.assign(Object.assign({ method: 'GET' }, baseOptions), options);
100
+ const localVarHeaderParameter = {};
101
+ const localVarQueryParameter = {};
102
+ // authentication session-oauth required
103
+ // oauth required
104
+ yield (0, common_1.setOAuthToObject)(localVarHeaderParameter, "session-oauth", [], configuration);
105
+ // authentication api-key required
106
+ yield (0, common_1.setApiKeyToObject)(localVarHeaderParameter, "Authorization", configuration);
107
+ if (project !== undefined) {
108
+ localVarQueryParameter['project'] = project;
109
+ }
110
+ (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
111
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
112
+ localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
113
+ return {
114
+ url: (0, common_1.toPathString)(localVarUrlObj),
115
+ options: localVarRequestOptions,
116
+ };
117
+ }),
118
+ /**
119
+ * Get a customer for a platform by a given customer ID.
120
+ * @summary Get customer
121
+ * @param {string} project Project unique identifier
122
+ * @param {string} platformId The platform identifier
123
+ * @param {string} customerId The customer identifier
124
+ * @param {*} [options] Override http request option.
125
+ * @throws {RequiredError}
126
+ */
127
+ getCustomer: (project_1, platformId_1, customerId_1, ...args_1) => __awaiter(this, [project_1, platformId_1, customerId_1, ...args_1], void 0, function* (project, platformId, customerId, options = {}) {
128
+ // verify required parameter 'project' is not null or undefined
129
+ (0, common_1.assertParamExists)('getCustomer', 'project', project);
130
+ // verify required parameter 'platformId' is not null or undefined
131
+ (0, common_1.assertParamExists)('getCustomer', 'platformId', platformId);
132
+ // verify required parameter 'customerId' is not null or undefined
133
+ (0, common_1.assertParamExists)('getCustomer', 'customerId', customerId);
134
+ const localVarPath = `/v1/platform/{platformId}/customers/{customerId}`
135
+ .replace(`{${"platformId"}}`, encodeURIComponent(String(platformId)))
136
+ .replace(`{${"customerId"}}`, encodeURIComponent(String(customerId)));
137
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
138
+ const localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
139
+ let baseOptions;
140
+ if (configuration) {
141
+ baseOptions = configuration.baseOptions;
142
+ }
143
+ const localVarRequestOptions = Object.assign(Object.assign({ method: 'GET' }, baseOptions), options);
144
+ const localVarHeaderParameter = {};
145
+ const localVarQueryParameter = {};
146
+ // authentication session-oauth required
147
+ // oauth required
148
+ yield (0, common_1.setOAuthToObject)(localVarHeaderParameter, "session-oauth", [], configuration);
149
+ // authentication api-key required
150
+ yield (0, common_1.setApiKeyToObject)(localVarHeaderParameter, "Authorization", configuration);
151
+ if (project !== undefined) {
152
+ localVarQueryParameter['project'] = project;
153
+ }
154
+ (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
155
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
156
+ localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
157
+ return {
158
+ url: (0, common_1.toPathString)(localVarUrlObj),
159
+ options: localVarRequestOptions,
160
+ };
161
+ }),
162
+ /**
163
+ * List customers for a platform
164
+ * @summary List customers
165
+ * @param {string} project Project unique identifier
166
+ * @param {string} platformId The platform identifier
167
+ * @param {number} [pageToken] Page reference token
168
+ * @param {number} [pageSize] Max page size. This is the maximum page size that will be returned, but it might be smaller.
169
+ * @param {string} [search] Search term to filter based on order reference, customer name and email
170
+ * @param {*} [options] Override http request option.
171
+ * @throws {RequiredError}
172
+ */
173
+ listCustomers: (project_1, platformId_1, pageToken_1, pageSize_1, search_1, ...args_1) => __awaiter(this, [project_1, platformId_1, pageToken_1, pageSize_1, search_1, ...args_1], void 0, function* (project, platformId, pageToken, pageSize, search, options = {}) {
174
+ // verify required parameter 'project' is not null or undefined
175
+ (0, common_1.assertParamExists)('listCustomers', 'project', project);
176
+ // verify required parameter 'platformId' is not null or undefined
177
+ (0, common_1.assertParamExists)('listCustomers', 'platformId', platformId);
178
+ const localVarPath = `/v1/platform/{platformId}/customers`
179
+ .replace(`{${"platformId"}}`, encodeURIComponent(String(platformId)));
180
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
181
+ const localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
182
+ let baseOptions;
183
+ if (configuration) {
184
+ baseOptions = configuration.baseOptions;
185
+ }
186
+ const localVarRequestOptions = Object.assign(Object.assign({ method: 'GET' }, baseOptions), options);
187
+ const localVarHeaderParameter = {};
188
+ const localVarQueryParameter = {};
189
+ // authentication session-oauth required
190
+ // oauth required
191
+ yield (0, common_1.setOAuthToObject)(localVarHeaderParameter, "session-oauth", [], configuration);
192
+ // authentication api-key required
193
+ yield (0, common_1.setApiKeyToObject)(localVarHeaderParameter, "Authorization", configuration);
194
+ if (project !== undefined) {
195
+ localVarQueryParameter['project'] = project;
196
+ }
197
+ if (pageToken !== undefined) {
198
+ localVarQueryParameter['pageToken'] = pageToken;
199
+ }
200
+ if (pageSize !== undefined) {
201
+ localVarQueryParameter['pageSize'] = pageSize;
202
+ }
203
+ if (search !== undefined) {
204
+ localVarQueryParameter['search'] = search;
205
+ }
206
+ (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
207
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
208
+ localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
209
+ return {
210
+ url: (0, common_1.toPathString)(localVarUrlObj),
211
+ options: localVarRequestOptions,
212
+ };
213
+ }),
214
+ };
215
+ };
216
+ exports.CustomersApiAxiosParamCreator = CustomersApiAxiosParamCreator;
217
+ /**
218
+ * CustomersApi - functional programming interface
219
+ * @export
220
+ */
221
+ const CustomersApiFp = function (configuration) {
222
+ const localVarAxiosParamCreator = (0, exports.CustomersApiAxiosParamCreator)(configuration);
223
+ return {
224
+ /**
225
+ * Export customers as a CSV file
226
+ * @summary Export customers
227
+ * @param {string} project Project unique identifier
228
+ * @param {string} platformId The platform identifier
229
+ * @param {*} [options] Override http request option.
230
+ * @throws {RequiredError}
231
+ */
232
+ exportCustomers(project, platformId, options) {
233
+ return __awaiter(this, void 0, void 0, function* () {
234
+ var _a, _b, _c;
235
+ const localVarAxiosArgs = yield localVarAxiosParamCreator.exportCustomers(project, platformId, options);
236
+ const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
237
+ const localVarOperationServerBasePath = (_c = (_b = base_1.operationServerMap['CustomersApi.exportCustomers']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
238
+ return (axios, basePath) => (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
239
+ });
240
+ },
241
+ /**
242
+ * Get a customer for a platform by a given customer ID.
243
+ * @summary Get customer
244
+ * @param {string} project Project unique identifier
245
+ * @param {string} platformId The platform identifier
246
+ * @param {string} customerId The customer identifier
247
+ * @param {*} [options] Override http request option.
248
+ * @throws {RequiredError}
249
+ */
250
+ getCustomer(project, platformId, customerId, options) {
251
+ return __awaiter(this, void 0, void 0, function* () {
252
+ var _a, _b, _c;
253
+ const localVarAxiosArgs = yield localVarAxiosParamCreator.getCustomer(project, platformId, customerId, options);
254
+ const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
255
+ const localVarOperationServerBasePath = (_c = (_b = base_1.operationServerMap['CustomersApi.getCustomer']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
256
+ return (axios, basePath) => (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
257
+ });
258
+ },
259
+ /**
260
+ * List customers for a platform
261
+ * @summary List customers
262
+ * @param {string} project Project unique identifier
263
+ * @param {string} platformId The platform identifier
264
+ * @param {number} [pageToken] Page reference token
265
+ * @param {number} [pageSize] Max page size. This is the maximum page size that will be returned, but it might be smaller.
266
+ * @param {string} [search] Search term to filter based on order reference, customer name and email
267
+ * @param {*} [options] Override http request option.
268
+ * @throws {RequiredError}
269
+ */
270
+ listCustomers(project, platformId, pageToken, pageSize, search, options) {
271
+ return __awaiter(this, void 0, void 0, function* () {
272
+ var _a, _b, _c;
273
+ const localVarAxiosArgs = yield localVarAxiosParamCreator.listCustomers(project, platformId, pageToken, pageSize, search, options);
274
+ const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
275
+ const localVarOperationServerBasePath = (_c = (_b = base_1.operationServerMap['CustomersApi.listCustomers']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
276
+ return (axios, basePath) => (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
277
+ });
278
+ },
279
+ };
280
+ };
281
+ exports.CustomersApiFp = CustomersApiFp;
282
+ /**
283
+ * CustomersApi - factory interface
284
+ * @export
285
+ */
286
+ const CustomersApiFactory = function (configuration, basePath, axios) {
287
+ const localVarFp = (0, exports.CustomersApiFp)(configuration);
288
+ return {
289
+ /**
290
+ * Export customers as a CSV file
291
+ * @summary Export customers
292
+ * @param {CustomersApiExportCustomersRequest} requestParameters Request parameters.
293
+ * @param {*} [options] Override http request option.
294
+ * @throws {RequiredError}
295
+ */
296
+ exportCustomers(requestParameters, options) {
297
+ return localVarFp.exportCustomers(requestParameters.project, requestParameters.platformId, options).then((request) => request(axios, basePath));
298
+ },
299
+ /**
300
+ * Get a customer for a platform by a given customer ID.
301
+ * @summary Get customer
302
+ * @param {CustomersApiGetCustomerRequest} requestParameters Request parameters.
303
+ * @param {*} [options] Override http request option.
304
+ * @throws {RequiredError}
305
+ */
306
+ getCustomer(requestParameters, options) {
307
+ return localVarFp.getCustomer(requestParameters.project, requestParameters.platformId, requestParameters.customerId, options).then((request) => request(axios, basePath));
308
+ },
309
+ /**
310
+ * List customers for a platform
311
+ * @summary List customers
312
+ * @param {CustomersApiListCustomersRequest} requestParameters Request parameters.
313
+ * @param {*} [options] Override http request option.
314
+ * @throws {RequiredError}
315
+ */
316
+ listCustomers(requestParameters, options) {
317
+ return localVarFp.listCustomers(requestParameters.project, requestParameters.platformId, requestParameters.pageToken, requestParameters.pageSize, requestParameters.search, options).then((request) => request(axios, basePath));
318
+ },
319
+ };
320
+ };
321
+ exports.CustomersApiFactory = CustomersApiFactory;
322
+ /**
323
+ * CustomersApi - object-oriented interface
324
+ * @export
325
+ * @class CustomersApi
326
+ * @extends {BaseAPI}
327
+ */
328
+ class CustomersApi extends base_1.BaseAPI {
329
+ /**
330
+ * Export customers as a CSV file
331
+ * @summary Export customers
332
+ * @param {CustomersApiExportCustomersRequest} requestParameters Request parameters.
333
+ * @param {*} [options] Override http request option.
334
+ * @throws {RequiredError}
335
+ * @memberof CustomersApi
336
+ */
337
+ exportCustomers(requestParameters, options) {
338
+ return (0, exports.CustomersApiFp)(this.configuration).exportCustomers(requestParameters.project, requestParameters.platformId, options).then((request) => request(this.axios, this.basePath));
339
+ }
340
+ /**
341
+ * Get a customer for a platform by a given customer ID.
342
+ * @summary Get customer
343
+ * @param {CustomersApiGetCustomerRequest} requestParameters Request parameters.
344
+ * @param {*} [options] Override http request option.
345
+ * @throws {RequiredError}
346
+ * @memberof CustomersApi
347
+ */
348
+ getCustomer(requestParameters, options) {
349
+ return (0, exports.CustomersApiFp)(this.configuration).getCustomer(requestParameters.project, requestParameters.platformId, requestParameters.customerId, options).then((request) => request(this.axios, this.basePath));
350
+ }
351
+ /**
352
+ * List customers for a platform
353
+ * @summary List customers
354
+ * @param {CustomersApiListCustomersRequest} requestParameters Request parameters.
355
+ * @param {*} [options] Override http request option.
356
+ * @throws {RequiredError}
357
+ * @memberof CustomersApi
358
+ */
359
+ listCustomers(requestParameters, options) {
360
+ return (0, exports.CustomersApiFp)(this.configuration).listCustomers(requestParameters.project, requestParameters.platformId, requestParameters.pageToken, requestParameters.pageSize, requestParameters.search, options).then((request) => request(this.axios, this.basePath));
361
+ }
362
+ }
363
+ exports.CustomersApi = CustomersApi;
72
364
  /**
73
365
  * OrdersApi - axios parameter creator
74
366
  * @export
@@ -657,6 +949,46 @@ exports.OrdersApi = OrdersApi;
657
949
  */
658
950
  const PlatformApiAxiosParamCreator = function (configuration) {
659
951
  return {
952
+ /**
953
+ * Export customers as a CSV file
954
+ * @summary Export customers
955
+ * @param {string} project Project unique identifier
956
+ * @param {string} platformId The platform identifier
957
+ * @param {*} [options] Override http request option.
958
+ * @throws {RequiredError}
959
+ */
960
+ exportCustomers: (project_1, platformId_1, ...args_1) => __awaiter(this, [project_1, platformId_1, ...args_1], void 0, function* (project, platformId, options = {}) {
961
+ // verify required parameter 'project' is not null or undefined
962
+ (0, common_1.assertParamExists)('exportCustomers', 'project', project);
963
+ // verify required parameter 'platformId' is not null or undefined
964
+ (0, common_1.assertParamExists)('exportCustomers', 'platformId', platformId);
965
+ const localVarPath = `/v1/platform/{platformId}/customers/export`
966
+ .replace(`{${"platformId"}}`, encodeURIComponent(String(platformId)));
967
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
968
+ const localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
969
+ let baseOptions;
970
+ if (configuration) {
971
+ baseOptions = configuration.baseOptions;
972
+ }
973
+ const localVarRequestOptions = Object.assign(Object.assign({ method: 'GET' }, baseOptions), options);
974
+ const localVarHeaderParameter = {};
975
+ const localVarQueryParameter = {};
976
+ // authentication session-oauth required
977
+ // oauth required
978
+ yield (0, common_1.setOAuthToObject)(localVarHeaderParameter, "session-oauth", [], configuration);
979
+ // authentication api-key required
980
+ yield (0, common_1.setApiKeyToObject)(localVarHeaderParameter, "Authorization", configuration);
981
+ if (project !== undefined) {
982
+ localVarQueryParameter['project'] = project;
983
+ }
984
+ (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
985
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
986
+ localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
987
+ return {
988
+ url: (0, common_1.toPathString)(localVarUrlObj),
989
+ options: localVarRequestOptions,
990
+ };
991
+ }),
660
992
  /**
661
993
  * Export orders as a CSV file
662
994
  * @summary Export orders
@@ -715,6 +1047,50 @@ const PlatformApiAxiosParamCreator = function (configuration) {
715
1047
  options: localVarRequestOptions,
716
1048
  };
717
1049
  }),
1050
+ /**
1051
+ * Get a customer for a platform by a given customer ID.
1052
+ * @summary Get customer
1053
+ * @param {string} project Project unique identifier
1054
+ * @param {string} platformId The platform identifier
1055
+ * @param {string} customerId The customer identifier
1056
+ * @param {*} [options] Override http request option.
1057
+ * @throws {RequiredError}
1058
+ */
1059
+ getCustomer: (project_1, platformId_1, customerId_1, ...args_1) => __awaiter(this, [project_1, platformId_1, customerId_1, ...args_1], void 0, function* (project, platformId, customerId, options = {}) {
1060
+ // verify required parameter 'project' is not null or undefined
1061
+ (0, common_1.assertParamExists)('getCustomer', 'project', project);
1062
+ // verify required parameter 'platformId' is not null or undefined
1063
+ (0, common_1.assertParamExists)('getCustomer', 'platformId', platformId);
1064
+ // verify required parameter 'customerId' is not null or undefined
1065
+ (0, common_1.assertParamExists)('getCustomer', 'customerId', customerId);
1066
+ const localVarPath = `/v1/platform/{platformId}/customers/{customerId}`
1067
+ .replace(`{${"platformId"}}`, encodeURIComponent(String(platformId)))
1068
+ .replace(`{${"customerId"}}`, encodeURIComponent(String(customerId)));
1069
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
1070
+ const localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
1071
+ let baseOptions;
1072
+ if (configuration) {
1073
+ baseOptions = configuration.baseOptions;
1074
+ }
1075
+ const localVarRequestOptions = Object.assign(Object.assign({ method: 'GET' }, baseOptions), options);
1076
+ const localVarHeaderParameter = {};
1077
+ const localVarQueryParameter = {};
1078
+ // authentication session-oauth required
1079
+ // oauth required
1080
+ yield (0, common_1.setOAuthToObject)(localVarHeaderParameter, "session-oauth", [], configuration);
1081
+ // authentication api-key required
1082
+ yield (0, common_1.setApiKeyToObject)(localVarHeaderParameter, "Authorization", configuration);
1083
+ if (project !== undefined) {
1084
+ localVarQueryParameter['project'] = project;
1085
+ }
1086
+ (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
1087
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
1088
+ localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
1089
+ return {
1090
+ url: (0, common_1.toPathString)(localVarUrlObj),
1091
+ options: localVarRequestOptions,
1092
+ };
1093
+ }),
718
1094
  /**
719
1095
  * Get a fulfillment for a platform by a given fulfillment ID.
720
1096
  * @summary Get fulfillment
@@ -883,6 +1259,58 @@ const PlatformApiAxiosParamCreator = function (configuration) {
883
1259
  options: localVarRequestOptions,
884
1260
  };
885
1261
  }),
1262
+ /**
1263
+ * List customers for a platform
1264
+ * @summary List customers
1265
+ * @param {string} project Project unique identifier
1266
+ * @param {string} platformId The platform identifier
1267
+ * @param {number} [pageToken] Page reference token
1268
+ * @param {number} [pageSize] Max page size. This is the maximum page size that will be returned, but it might be smaller.
1269
+ * @param {string} [search] Search term to filter based on order reference, customer name and email
1270
+ * @param {*} [options] Override http request option.
1271
+ * @throws {RequiredError}
1272
+ */
1273
+ listCustomers: (project_1, platformId_1, pageToken_1, pageSize_1, search_1, ...args_1) => __awaiter(this, [project_1, platformId_1, pageToken_1, pageSize_1, search_1, ...args_1], void 0, function* (project, platformId, pageToken, pageSize, search, options = {}) {
1274
+ // verify required parameter 'project' is not null or undefined
1275
+ (0, common_1.assertParamExists)('listCustomers', 'project', project);
1276
+ // verify required parameter 'platformId' is not null or undefined
1277
+ (0, common_1.assertParamExists)('listCustomers', 'platformId', platformId);
1278
+ const localVarPath = `/v1/platform/{platformId}/customers`
1279
+ .replace(`{${"platformId"}}`, encodeURIComponent(String(platformId)));
1280
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
1281
+ const localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
1282
+ let baseOptions;
1283
+ if (configuration) {
1284
+ baseOptions = configuration.baseOptions;
1285
+ }
1286
+ const localVarRequestOptions = Object.assign(Object.assign({ method: 'GET' }, baseOptions), options);
1287
+ const localVarHeaderParameter = {};
1288
+ const localVarQueryParameter = {};
1289
+ // authentication session-oauth required
1290
+ // oauth required
1291
+ yield (0, common_1.setOAuthToObject)(localVarHeaderParameter, "session-oauth", [], configuration);
1292
+ // authentication api-key required
1293
+ yield (0, common_1.setApiKeyToObject)(localVarHeaderParameter, "Authorization", configuration);
1294
+ if (project !== undefined) {
1295
+ localVarQueryParameter['project'] = project;
1296
+ }
1297
+ if (pageToken !== undefined) {
1298
+ localVarQueryParameter['pageToken'] = pageToken;
1299
+ }
1300
+ if (pageSize !== undefined) {
1301
+ localVarQueryParameter['pageSize'] = pageSize;
1302
+ }
1303
+ if (search !== undefined) {
1304
+ localVarQueryParameter['search'] = search;
1305
+ }
1306
+ (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
1307
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
1308
+ localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
1309
+ return {
1310
+ url: (0, common_1.toPathString)(localVarUrlObj),
1311
+ options: localVarRequestOptions,
1312
+ };
1313
+ }),
886
1314
  /**
887
1315
  * Lists all orders placed on projects belonging to this platform, paginated into configurable chunks.
888
1316
  * @summary List orders
@@ -1145,6 +1573,23 @@ exports.PlatformApiAxiosParamCreator = PlatformApiAxiosParamCreator;
1145
1573
  const PlatformApiFp = function (configuration) {
1146
1574
  const localVarAxiosParamCreator = (0, exports.PlatformApiAxiosParamCreator)(configuration);
1147
1575
  return {
1576
+ /**
1577
+ * Export customers as a CSV file
1578
+ * @summary Export customers
1579
+ * @param {string} project Project unique identifier
1580
+ * @param {string} platformId The platform identifier
1581
+ * @param {*} [options] Override http request option.
1582
+ * @throws {RequiredError}
1583
+ */
1584
+ exportCustomers(project, platformId, options) {
1585
+ return __awaiter(this, void 0, void 0, function* () {
1586
+ var _a, _b, _c;
1587
+ const localVarAxiosArgs = yield localVarAxiosParamCreator.exportCustomers(project, platformId, options);
1588
+ const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
1589
+ const localVarOperationServerBasePath = (_c = (_b = base_1.operationServerMap['PlatformApi.exportCustomers']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
1590
+ return (axios, basePath) => (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
1591
+ });
1592
+ },
1148
1593
  /**
1149
1594
  * Export orders as a CSV file
1150
1595
  * @summary Export orders
@@ -1165,6 +1610,24 @@ const PlatformApiFp = function (configuration) {
1165
1610
  return (axios, basePath) => (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
1166
1611
  });
1167
1612
  },
1613
+ /**
1614
+ * Get a customer for a platform by a given customer ID.
1615
+ * @summary Get customer
1616
+ * @param {string} project Project unique identifier
1617
+ * @param {string} platformId The platform identifier
1618
+ * @param {string} customerId The customer identifier
1619
+ * @param {*} [options] Override http request option.
1620
+ * @throws {RequiredError}
1621
+ */
1622
+ getCustomer(project, platformId, customerId, options) {
1623
+ return __awaiter(this, void 0, void 0, function* () {
1624
+ var _a, _b, _c;
1625
+ const localVarAxiosArgs = yield localVarAxiosParamCreator.getCustomer(project, platformId, customerId, options);
1626
+ const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
1627
+ const localVarOperationServerBasePath = (_c = (_b = base_1.operationServerMap['PlatformApi.getCustomer']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
1628
+ return (axios, basePath) => (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
1629
+ });
1630
+ },
1168
1631
  /**
1169
1632
  * Get a fulfillment for a platform by a given fulfillment ID.
1170
1633
  * @summary Get fulfillment
@@ -1235,6 +1698,26 @@ const PlatformApiFp = function (configuration) {
1235
1698
  return (axios, basePath) => (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
1236
1699
  });
1237
1700
  },
1701
+ /**
1702
+ * List customers for a platform
1703
+ * @summary List customers
1704
+ * @param {string} project Project unique identifier
1705
+ * @param {string} platformId The platform identifier
1706
+ * @param {number} [pageToken] Page reference token
1707
+ * @param {number} [pageSize] Max page size. This is the maximum page size that will be returned, but it might be smaller.
1708
+ * @param {string} [search] Search term to filter based on order reference, customer name and email
1709
+ * @param {*} [options] Override http request option.
1710
+ * @throws {RequiredError}
1711
+ */
1712
+ listCustomers(project, platformId, pageToken, pageSize, search, options) {
1713
+ return __awaiter(this, void 0, void 0, function* () {
1714
+ var _a, _b, _c;
1715
+ const localVarAxiosArgs = yield localVarAxiosParamCreator.listCustomers(project, platformId, pageToken, pageSize, search, options);
1716
+ const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
1717
+ const localVarOperationServerBasePath = (_c = (_b = base_1.operationServerMap['PlatformApi.listCustomers']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
1718
+ return (axios, basePath) => (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
1719
+ });
1720
+ },
1238
1721
  /**
1239
1722
  * Lists all orders placed on projects belonging to this platform, paginated into configurable chunks.
1240
1723
  * @summary List orders
@@ -1341,6 +1824,16 @@ exports.PlatformApiFp = PlatformApiFp;
1341
1824
  const PlatformApiFactory = function (configuration, basePath, axios) {
1342
1825
  const localVarFp = (0, exports.PlatformApiFp)(configuration);
1343
1826
  return {
1827
+ /**
1828
+ * Export customers as a CSV file
1829
+ * @summary Export customers
1830
+ * @param {PlatformApiExportCustomersRequest} requestParameters Request parameters.
1831
+ * @param {*} [options] Override http request option.
1832
+ * @throws {RequiredError}
1833
+ */
1834
+ exportCustomers(requestParameters, options) {
1835
+ return localVarFp.exportCustomers(requestParameters.project, requestParameters.platformId, options).then((request) => request(axios, basePath));
1836
+ },
1344
1837
  /**
1345
1838
  * Export orders as a CSV file
1346
1839
  * @summary Export orders
@@ -1351,6 +1844,16 @@ const PlatformApiFactory = function (configuration, basePath, axios) {
1351
1844
  exportOrders(requestParameters, options) {
1352
1845
  return localVarFp.exportOrders(requestParameters.project, requestParameters.platformId, requestParameters.start, requestParameters.end, requestParameters.search, options).then((request) => request(axios, basePath));
1353
1846
  },
1847
+ /**
1848
+ * Get a customer for a platform by a given customer ID.
1849
+ * @summary Get customer
1850
+ * @param {PlatformApiGetCustomerRequest} requestParameters Request parameters.
1851
+ * @param {*} [options] Override http request option.
1852
+ * @throws {RequiredError}
1853
+ */
1854
+ getCustomer(requestParameters, options) {
1855
+ return localVarFp.getCustomer(requestParameters.project, requestParameters.platformId, requestParameters.customerId, options).then((request) => request(axios, basePath));
1856
+ },
1354
1857
  /**
1355
1858
  * Get a fulfillment for a platform by a given fulfillment ID.
1356
1859
  * @summary Get fulfillment
@@ -1391,6 +1894,16 @@ const PlatformApiFactory = function (configuration, basePath, axios) {
1391
1894
  listAvailableFulfillers(requestParameters, options) {
1392
1895
  return localVarFp.listAvailableFulfillers(requestParameters.project, requestParameters.platformId, requestParameters.fulfillmentId, options).then((request) => request(axios, basePath));
1393
1896
  },
1897
+ /**
1898
+ * List customers for a platform
1899
+ * @summary List customers
1900
+ * @param {PlatformApiListCustomersRequest} requestParameters Request parameters.
1901
+ * @param {*} [options] Override http request option.
1902
+ * @throws {RequiredError}
1903
+ */
1904
+ listCustomers(requestParameters, options) {
1905
+ return localVarFp.listCustomers(requestParameters.project, requestParameters.platformId, requestParameters.pageToken, requestParameters.pageSize, requestParameters.search, options).then((request) => request(axios, basePath));
1906
+ },
1394
1907
  /**
1395
1908
  * Lists all orders placed on projects belonging to this platform, paginated into configurable chunks.
1396
1909
  * @summary List orders
@@ -1451,6 +1964,17 @@ exports.PlatformApiFactory = PlatformApiFactory;
1451
1964
  * @extends {BaseAPI}
1452
1965
  */
1453
1966
  class PlatformApi extends base_1.BaseAPI {
1967
+ /**
1968
+ * Export customers as a CSV file
1969
+ * @summary Export customers
1970
+ * @param {PlatformApiExportCustomersRequest} requestParameters Request parameters.
1971
+ * @param {*} [options] Override http request option.
1972
+ * @throws {RequiredError}
1973
+ * @memberof PlatformApi
1974
+ */
1975
+ exportCustomers(requestParameters, options) {
1976
+ return (0, exports.PlatformApiFp)(this.configuration).exportCustomers(requestParameters.project, requestParameters.platformId, options).then((request) => request(this.axios, this.basePath));
1977
+ }
1454
1978
  /**
1455
1979
  * Export orders as a CSV file
1456
1980
  * @summary Export orders
@@ -1462,6 +1986,17 @@ class PlatformApi extends base_1.BaseAPI {
1462
1986
  exportOrders(requestParameters, options) {
1463
1987
  return (0, exports.PlatformApiFp)(this.configuration).exportOrders(requestParameters.project, requestParameters.platformId, requestParameters.start, requestParameters.end, requestParameters.search, options).then((request) => request(this.axios, this.basePath));
1464
1988
  }
1989
+ /**
1990
+ * Get a customer for a platform by a given customer ID.
1991
+ * @summary Get customer
1992
+ * @param {PlatformApiGetCustomerRequest} requestParameters Request parameters.
1993
+ * @param {*} [options] Override http request option.
1994
+ * @throws {RequiredError}
1995
+ * @memberof PlatformApi
1996
+ */
1997
+ getCustomer(requestParameters, options) {
1998
+ return (0, exports.PlatformApiFp)(this.configuration).getCustomer(requestParameters.project, requestParameters.platformId, requestParameters.customerId, options).then((request) => request(this.axios, this.basePath));
1999
+ }
1465
2000
  /**
1466
2001
  * Get a fulfillment for a platform by a given fulfillment ID.
1467
2002
  * @summary Get fulfillment
@@ -1506,6 +2041,17 @@ class PlatformApi extends base_1.BaseAPI {
1506
2041
  listAvailableFulfillers(requestParameters, options) {
1507
2042
  return (0, exports.PlatformApiFp)(this.configuration).listAvailableFulfillers(requestParameters.project, requestParameters.platformId, requestParameters.fulfillmentId, options).then((request) => request(this.axios, this.basePath));
1508
2043
  }
2044
+ /**
2045
+ * List customers for a platform
2046
+ * @summary List customers
2047
+ * @param {PlatformApiListCustomersRequest} requestParameters Request parameters.
2048
+ * @param {*} [options] Override http request option.
2049
+ * @throws {RequiredError}
2050
+ * @memberof PlatformApi
2051
+ */
2052
+ listCustomers(requestParameters, options) {
2053
+ return (0, exports.PlatformApiFp)(this.configuration).listCustomers(requestParameters.project, requestParameters.platformId, requestParameters.pageToken, requestParameters.pageSize, requestParameters.search, options).then((request) => request(this.axios, this.basePath));
2054
+ }
1509
2055
  /**
1510
2056
  * Lists all orders placed on projects belonging to this platform, paginated into configurable chunks.
1511
2057
  * @summary List orders
package/dist/base.d.ts CHANGED
@@ -2,7 +2,7 @@
2
2
  * Platform API
3
3
  * Manage Your podOS platform
4
4
  *
5
- * The version of the OpenAPI document: 0.10.0
5
+ * The version of the OpenAPI document: 0.11.1
6
6
  *
7
7
  *
8
8
  * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).