@lcdp/api-react-rest-client 2.13.9-LDS-4699-etape-1-no-more-archive-of-frid.17125564147 → 2.13.9-LDS-4699-etape-1-no-more-archive-of-frid.17202480489

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@lcdp/api-react-rest-client",
3
- "version": "2.13.9-LDS-4699-etape-1-no-more-archive-of-frid.17125564147",
3
+ "version": "2.13.9-LDS-4699-etape-1-no-more-archive-of-frid.17202480489",
4
4
  "scripts": {
5
5
  "build": "tsc"
6
6
  },
@@ -10,7 +10,7 @@
10
10
  * Do not edit the class manually.
11
11
  */
12
12
  import * as runtime from '../runtime';
13
- import type { ProductSecondaryType, ProductStorageType, ProductType } from '../models/index';
13
+ import type { ProductSecondaryType, ProductType } from '../models/index';
14
14
  export interface GetProductSecondaryTypeRequest {
15
15
  secondaryTypeId: string;
16
16
  }
@@ -37,14 +37,6 @@ export declare class SearchProductMetadataApi extends runtime.BaseAPI {
37
37
  * Get product secondary types
38
38
  */
39
39
  getProductSecondaryTypes(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Array<ProductSecondaryType> | runtime.BlobWithMeta>;
40
- /**
41
- * Get storage types relatives to a product
42
- */
43
- getProductStorageTypesRaw(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<Array<ProductStorageType> | runtime.BlobWithMeta>>;
44
- /**
45
- * Get storage types relatives to a product
46
- */
47
- getProductStorageTypes(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Array<ProductStorageType> | runtime.BlobWithMeta>;
48
40
  /**
49
41
  * Get product type
50
42
  */
@@ -230,88 +230,12 @@ var SearchProductMetadataApi = /** @class */ (function (_super) {
230
230
  });
231
231
  });
232
232
  };
233
- /**
234
- * Get storage types relatives to a product
235
- */
236
- SearchProductMetadataApi.prototype.getProductStorageTypesRaw = function (initOverrides) {
237
- return __awaiter(this, void 0, void 0, function () {
238
- var queryParameters, headerParameters, _a, _b, token, tokenString, response, contentType, response_3;
239
- return __generator(this, function (_c) {
240
- switch (_c.label) {
241
- case 0:
242
- queryParameters = {};
243
- headerParameters = {};
244
- if (!(this.configuration && this.configuration.apiKey)) return [3 /*break*/, 2];
245
- _a = headerParameters;
246
- _b = "x-api-key";
247
- return [4 /*yield*/, this.configuration.apiKey("x-api-key")];
248
- case 1:
249
- _a[_b] = _c.sent(); // apiKeyAuth authentication
250
- _c.label = 2;
251
- case 2:
252
- if (!(this.configuration && this.configuration.accessToken)) return [3 /*break*/, 4];
253
- token = this.configuration.accessToken;
254
- return [4 /*yield*/, token("bearerAuth", [])];
255
- case 3:
256
- tokenString = _c.sent();
257
- if (tokenString) {
258
- headerParameters["Authorization"] = "Bearer ".concat(tokenString);
259
- }
260
- _c.label = 4;
261
- case 4:
262
- _c.trys.push([4, 6, , 7]);
263
- return [4 /*yield*/, this.request({
264
- path: "/products/storage-types",
265
- method: 'GET',
266
- headers: headerParameters,
267
- query: queryParameters,
268
- }, initOverrides)];
269
- case 5:
270
- response = _c.sent();
271
- contentType = response.headers.get("content-type");
272
- if (contentType && contentType.indexOf("application/json") !== -1) {
273
- return [2 /*return*/, new runtime.JSONApiResponse(response, function (jsonValue) { return jsonValue.map(index_1.ProductStorageTypeFromJSON); })];
274
- }
275
- else if (contentType && contentType.indexOf("text/plain") !== -1) {
276
- return [2 /*return*/, new runtime.TextApiResponse(response)];
277
- }
278
- else {
279
- // TODO : Better handling of others application types
280
- return [2 /*return*/, new runtime.BlobWithMetaApiResponse(response)];
281
- }
282
- return [3 /*break*/, 7];
283
- case 6:
284
- response_3 = _c.sent();
285
- console.debug(response_3);
286
- throw response_3;
287
- case 7: return [2 /*return*/];
288
- }
289
- });
290
- });
291
- };
292
- /**
293
- * Get storage types relatives to a product
294
- */
295
- SearchProductMetadataApi.prototype.getProductStorageTypes = function (initOverrides) {
296
- return __awaiter(this, void 0, void 0, function () {
297
- var response;
298
- return __generator(this, function (_a) {
299
- switch (_a.label) {
300
- case 0: return [4 /*yield*/, this.getProductStorageTypesRaw(initOverrides)];
301
- case 1:
302
- response = _a.sent();
303
- return [4 /*yield*/, response.value()];
304
- case 2: return [2 /*return*/, _a.sent()];
305
- }
306
- });
307
- });
308
- };
309
233
  /**
310
234
  * Get product type
311
235
  */
312
236
  SearchProductMetadataApi.prototype.getProductTypeRaw = function (requestParameters, initOverrides) {
313
237
  return __awaiter(this, void 0, void 0, function () {
314
- var queryParameters, headerParameters, _a, _b, token, tokenString, response, contentType, response_4;
238
+ var queryParameters, headerParameters, _a, _b, token, tokenString, response, contentType, response_3;
315
239
  return __generator(this, function (_c) {
316
240
  switch (_c.label) {
317
241
  case 0:
@@ -360,9 +284,9 @@ var SearchProductMetadataApi = /** @class */ (function (_super) {
360
284
  }
361
285
  return [3 /*break*/, 7];
362
286
  case 6:
363
- response_4 = _c.sent();
364
- console.debug(response_4);
365
- throw response_4;
287
+ response_3 = _c.sent();
288
+ console.debug(response_3);
289
+ throw response_3;
366
290
  case 7: return [2 /*return*/];
367
291
  }
368
292
  });
@@ -390,7 +314,7 @@ var SearchProductMetadataApi = /** @class */ (function (_super) {
390
314
  */
391
315
  SearchProductMetadataApi.prototype.getProductTypesRaw = function (initOverrides) {
392
316
  return __awaiter(this, void 0, void 0, function () {
393
- var queryParameters, headerParameters, _a, _b, token, tokenString, response, contentType, response_5;
317
+ var queryParameters, headerParameters, _a, _b, token, tokenString, response, contentType, response_4;
394
318
  return __generator(this, function (_c) {
395
319
  switch (_c.label) {
396
320
  case 0:
@@ -436,9 +360,9 @@ var SearchProductMetadataApi = /** @class */ (function (_super) {
436
360
  }
437
361
  return [3 /*break*/, 7];
438
362
  case 6:
439
- response_5 = _c.sent();
440
- console.debug(response_5);
441
- throw response_5;
363
+ response_4 = _c.sent();
364
+ console.debug(response_4);
365
+ throw response_4;
442
366
  case 7: return [2 /*return*/];
443
367
  }
444
368
  });
@@ -0,0 +1,46 @@
1
+ /**
2
+ * lcdp-monolith-service
3
+ * This is the REST API of LCDP products
4
+ *
5
+ * The version of the OpenAPI document: 1.0.0
6
+ * Contact: contact@lecomptoirdespharmacies.fr
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ import type { ProductStorageType } from './ProductStorageType';
13
+ /**
14
+ *
15
+ * @export
16
+ * @interface RestrictedProductStorageType
17
+ */
18
+ export interface RestrictedProductStorageType {
19
+ /**
20
+ *
21
+ * @type {Array<string>}
22
+ * @memberof RestrictedProductStorageType
23
+ */
24
+ actions?: Array<RestrictedProductStorageTypeActionsEnum>;
25
+ /**
26
+ *
27
+ * @type {ProductStorageType}
28
+ * @memberof RestrictedProductStorageType
29
+ */
30
+ target?: ProductStorageType;
31
+ }
32
+ /**
33
+ * @export
34
+ */
35
+ export declare const RestrictedProductStorageTypeActionsEnum: {
36
+ readonly BUY: "BUY";
37
+ readonly SELL: "SELL";
38
+ };
39
+ export declare type RestrictedProductStorageTypeActionsEnum = typeof RestrictedProductStorageTypeActionsEnum[keyof typeof RestrictedProductStorageTypeActionsEnum];
40
+ /**
41
+ * Check if a given object implements the RestrictedProductStorageType interface.
42
+ */
43
+ export declare function instanceOfRestrictedProductStorageType(value: object): value is RestrictedProductStorageType;
44
+ export declare function RestrictedProductStorageTypeFromJSON(json: any): RestrictedProductStorageType;
45
+ export declare function RestrictedProductStorageTypeFromJSONTyped(json: any, ignoreDiscriminator: boolean): RestrictedProductStorageType;
46
+ export declare function RestrictedProductStorageTypeToJSON(value?: RestrictedProductStorageType | null): any;
@@ -0,0 +1,55 @@
1
+ "use strict";
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ /**
5
+ * lcdp-monolith-service
6
+ * This is the REST API of LCDP products
7
+ *
8
+ * The version of the OpenAPI document: 1.0.0
9
+ * Contact: contact@lecomptoirdespharmacies.fr
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
+ Object.defineProperty(exports, "__esModule", { value: true });
16
+ exports.RestrictedProductStorageTypeToJSON = exports.RestrictedProductStorageTypeFromJSONTyped = exports.RestrictedProductStorageTypeFromJSON = exports.instanceOfRestrictedProductStorageType = exports.RestrictedProductStorageTypeActionsEnum = void 0;
17
+ var ProductStorageType_1 = require("./ProductStorageType");
18
+ /**
19
+ * @export
20
+ */
21
+ exports.RestrictedProductStorageTypeActionsEnum = {
22
+ BUY: 'BUY',
23
+ SELL: 'SELL'
24
+ };
25
+ /**
26
+ * Check if a given object implements the RestrictedProductStorageType interface.
27
+ */
28
+ function instanceOfRestrictedProductStorageType(value) {
29
+ return true;
30
+ }
31
+ exports.instanceOfRestrictedProductStorageType = instanceOfRestrictedProductStorageType;
32
+ function RestrictedProductStorageTypeFromJSON(json) {
33
+ return RestrictedProductStorageTypeFromJSONTyped(json, false);
34
+ }
35
+ exports.RestrictedProductStorageTypeFromJSON = RestrictedProductStorageTypeFromJSON;
36
+ function RestrictedProductStorageTypeFromJSONTyped(json, ignoreDiscriminator) {
37
+ if (json == null) {
38
+ return json;
39
+ }
40
+ return {
41
+ 'actions': json['actions'],
42
+ 'target': (json['target'] === null || json['target'] === undefined) ? json['target'] : (0, ProductStorageType_1.ProductStorageTypeFromJSON)(json['target']),
43
+ };
44
+ }
45
+ exports.RestrictedProductStorageTypeFromJSONTyped = RestrictedProductStorageTypeFromJSONTyped;
46
+ function RestrictedProductStorageTypeToJSON(value) {
47
+ if (value == null) {
48
+ return value;
49
+ }
50
+ return {
51
+ 'actions': value['actions'],
52
+ 'target': (0, ProductStorageType_1.ProductStorageTypeToJSON)(value['target']),
53
+ };
54
+ }
55
+ exports.RestrictedProductStorageTypeToJSON = RestrictedProductStorageTypeToJSON;
@@ -15,7 +15,6 @@ import type { Address } from './Address';
15
15
  import type { UserStatisticLink } from './UserStatisticLink';
16
16
  import type { UserMangopayTarget } from './UserMangopayTarget';
17
17
  import type { UserDelegatedServices } from './UserDelegatedServices';
18
- import type { ProductStorageType } from './ProductStorageType';
19
18
  import type { HttpLink } from './HttpLink';
20
19
  import type { Gender } from './Gender';
21
20
  import type { ScaEnrollmentStatus } from './ScaEnrollmentStatus';
@@ -23,6 +22,7 @@ import type { UserThreads } from './UserThreads';
23
22
  import type { UserWallets } from './UserWallets';
24
23
  import type { UserRole } from './UserRole';
25
24
  import type { KycLevel } from './KycLevel';
25
+ import type { RestrictedProductStorageType } from './RestrictedProductStorageType';
26
26
  import type { UserJournal } from './UserJournal';
27
27
  /**
28
28
  * Fields :
@@ -256,10 +256,10 @@ export interface User {
256
256
  restrictedProductTypes?: HttpLink;
257
257
  /**
258
258
  *
259
- * @type {Array<ProductStorageType>}
259
+ * @type {Array<RestrictedProductStorageType>}
260
260
  * @memberof User
261
261
  */
262
- restrictedProductStorageTypes?: Array<ProductStorageType>;
262
+ restrictedProductStorageTypes?: Array<RestrictedProductStorageType>;
263
263
  /**
264
264
  *
265
265
  * @type {HttpLink}
@@ -21,7 +21,6 @@ var Address_1 = require("./Address");
21
21
  var UserStatisticLink_1 = require("./UserStatisticLink");
22
22
  var UserMangopayTarget_1 = require("./UserMangopayTarget");
23
23
  var UserDelegatedServices_1 = require("./UserDelegatedServices");
24
- var ProductStorageType_1 = require("./ProductStorageType");
25
24
  var HttpLink_1 = require("./HttpLink");
26
25
  var Gender_1 = require("./Gender");
27
26
  var ScaEnrollmentStatus_1 = require("./ScaEnrollmentStatus");
@@ -29,6 +28,7 @@ var UserThreads_1 = require("./UserThreads");
29
28
  var UserWallets_1 = require("./UserWallets");
30
29
  var UserRole_1 = require("./UserRole");
31
30
  var KycLevel_1 = require("./KycLevel");
31
+ var RestrictedProductStorageType_1 = require("./RestrictedProductStorageType");
32
32
  var UserJournal_1 = require("./UserJournal");
33
33
  /**
34
34
  * Check if a given object implements the User interface.
@@ -101,7 +101,7 @@ function UserFromJSONTyped(json, ignoreDiscriminator) {
101
101
  'rules': (json['rules'] === null || json['rules'] === undefined) ? json['rules'] : (0, HttpLink_1.HttpLinkFromJSON)(json['rules']),
102
102
  'restrictedFeatures': (json['restrictedFeatures'] === null || json['restrictedFeatures'] === undefined) ? json['restrictedFeatures'] : (0, HttpLink_1.HttpLinkFromJSON)(json['restrictedFeatures']),
103
103
  'restrictedProductTypes': (json['restrictedProductTypes'] === null || json['restrictedProductTypes'] === undefined) ? json['restrictedProductTypes'] : (0, HttpLink_1.HttpLinkFromJSON)(json['restrictedProductTypes']),
104
- 'restrictedProductStorageTypes': (json['restrictedProductStorageTypes'] === null || json['restrictedProductStorageTypes'] === undefined) ? json['restrictedProductStorageTypes'] : json['restrictedProductStorageTypes'].map(ProductStorageType_1.ProductStorageTypeFromJSON),
104
+ 'restrictedProductStorageTypes': (json['restrictedProductStorageTypes'] === null || json['restrictedProductStorageTypes'] === undefined) ? json['restrictedProductStorageTypes'] : json['restrictedProductStorageTypes'].map(RestrictedProductStorageType_1.RestrictedProductStorageTypeFromJSON),
105
105
  'restrictedNotificationTypes': (json['restrictedNotificationTypes'] === null || json['restrictedNotificationTypes'] === undefined) ? json['restrictedNotificationTypes'] : (0, HttpLink_1.HttpLinkFromJSON)(json['restrictedNotificationTypes']),
106
106
  'customCommissions': (json['customCommissions'] === null || json['customCommissions'] === undefined) ? json['customCommissions'] : (0, HttpLink_1.HttpLinkFromJSON)(json['customCommissions']),
107
107
  'tags': json['tags'],
@@ -158,7 +158,7 @@ function UserToJSON(value) {
158
158
  'rules': (0, HttpLink_1.HttpLinkToJSON)(value['rules']),
159
159
  'restrictedFeatures': (0, HttpLink_1.HttpLinkToJSON)(value['restrictedFeatures']),
160
160
  'restrictedProductTypes': (0, HttpLink_1.HttpLinkToJSON)(value['restrictedProductTypes']),
161
- 'restrictedProductStorageTypes': (value['restrictedProductStorageTypes'] === null || value['restrictedProductStorageTypes'] === undefined) ? value['restrictedProductStorageTypes'] : value['restrictedProductStorageTypes'].map(ProductStorageType_1.ProductStorageTypeToJSON),
161
+ 'restrictedProductStorageTypes': (value['restrictedProductStorageTypes'] === null || value['restrictedProductStorageTypes'] === undefined) ? value['restrictedProductStorageTypes'] : value['restrictedProductStorageTypes'].map(RestrictedProductStorageType_1.RestrictedProductStorageTypeToJSON),
162
162
  'restrictedNotificationTypes': (0, HttpLink_1.HttpLinkToJSON)(value['restrictedNotificationTypes']),
163
163
  'customCommissions': (0, HttpLink_1.HttpLinkToJSON)(value['customCommissions']),
164
164
  'tags': value['tags'],
@@ -14,6 +14,7 @@ export * from './PasswordResetCreationParameters';
14
14
  export * from './ProductStorageType';
15
15
  export * from './ProductTypeLink';
16
16
  export * from './RestError';
17
+ export * from './RestrictedProductStorageType';
17
18
  export * from './ScaEnrollmentStatus';
18
19
  export * from './SomeonePasswordUpdateParameters';
19
20
  export * from './ThreadLink';
@@ -32,6 +32,7 @@ __exportStar(require("./PasswordResetCreationParameters"), exports);
32
32
  __exportStar(require("./ProductStorageType"), exports);
33
33
  __exportStar(require("./ProductTypeLink"), exports);
34
34
  __exportStar(require("./RestError"), exports);
35
+ __exportStar(require("./RestrictedProductStorageType"), exports);
35
36
  __exportStar(require("./ScaEnrollmentStatus"), exports);
36
37
  __exportStar(require("./SomeonePasswordUpdateParameters"), exports);
37
38
  __exportStar(require("./ThreadLink"), exports);