@lcdp/api-react-rest-client 2.6.2-develop.8265310705 → 2.6.2-develop.8356314138
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/order/src/models/OrderJournal.d.ts +24 -0
- package/order/src/models/OrderJournal.js +8 -0
- package/package.json +1 -1
- package/sale-offer/src/models/SaleOffer.d.ts +17 -17
- package/sale-offer/src/models/SaleOffer.js +18 -19
- package/statistic/src/apis/SearchUserStatisticsApi.d.ts +42 -0
- package/statistic/src/apis/SearchUserStatisticsApi.js +248 -0
- package/statistic/src/apis/index.d.ts +1 -0
- package/statistic/src/apis/index.js +1 -0
- package/statistic/src/models/PaginatedUserStatistics.d.ts +29 -0
- package/statistic/src/models/PaginatedUserStatistics.js +50 -0
- package/statistic/src/models/PaginatedUserStatisticsAllOf.d.ts +28 -0
- package/statistic/src/models/PaginatedUserStatisticsAllOf.js +42 -0
- package/statistic/src/models/UserStatistic.d.ts +70 -0
- package/statistic/src/models/UserStatistic.js +57 -0
- package/statistic/src/models/index.d.ts +3 -0
- package/statistic/src/models/index.js +3 -0
- package/third-party/index.d.ts +1 -0
- package/third-party/index.js +17 -0
- package/third-party/src/apis/ManageThirdPartyLinkApi.d.ts +29 -0
- package/third-party/src/apis/ManageThirdPartyLinkApi.js +163 -0
- package/third-party/src/apis/index.d.ts +1 -0
- package/third-party/src/apis/index.js +17 -0
- package/third-party/src/index.d.ts +3 -0
- package/third-party/src/index.js +19 -0
- package/third-party/src/models/RestError.d.ts +87 -0
- package/third-party/src/models/RestError.js +99 -0
- package/third-party/src/models/ThirdPartyLink.d.ts +27 -0
- package/third-party/src/models/ThirdPartyLink.js +42 -0
- package/third-party/src/models/ThirdPartyLinkCreationParameters.d.ts +33 -0
- package/third-party/src/models/ThirdPartyLinkCreationParameters.js +43 -0
- package/third-party/src/models/index.d.ts +3 -0
- package/third-party/src/models/index.js +19 -0
- package/third-party/src/runtime.d.ts +149 -0
- package/third-party/src/runtime.js +480 -0
- package/user/src/models/User.d.ts +21 -8
- package/user/src/models/User.js +13 -8
- package/user/src/models/UserStatisticLink.d.ts +58 -0
- package/user/src/models/UserStatisticLink.js +50 -0
- package/user/src/models/UserStatisticLinkAllOf.d.ts +57 -0
- package/user/src/models/UserStatisticLinkAllOf.js +52 -0
- package/user/src/models/index.d.ts +2 -0
- package/user/src/models/index.js +2 -0
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/* tslint:disable */
|
|
3
|
+
/* eslint-disable */
|
|
4
|
+
/**
|
|
5
|
+
* lcdp-pharmaide-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.PaginatedUserStatisticsAllOfToJSON = exports.PaginatedUserStatisticsAllOfFromJSONTyped = exports.PaginatedUserStatisticsAllOfFromJSON = void 0;
|
|
17
|
+
var UserStatistic_1 = require("./UserStatistic");
|
|
18
|
+
function PaginatedUserStatisticsAllOfFromJSON(json) {
|
|
19
|
+
return PaginatedUserStatisticsAllOfFromJSONTyped(json, false);
|
|
20
|
+
}
|
|
21
|
+
exports.PaginatedUserStatisticsAllOfFromJSON = PaginatedUserStatisticsAllOfFromJSON;
|
|
22
|
+
function PaginatedUserStatisticsAllOfFromJSONTyped(json, ignoreDiscriminator) {
|
|
23
|
+
if ((json === undefined) || (json === null)) {
|
|
24
|
+
return json;
|
|
25
|
+
}
|
|
26
|
+
return {
|
|
27
|
+
'records': (json['records'].map(UserStatistic_1.UserStatisticFromJSON)),
|
|
28
|
+
};
|
|
29
|
+
}
|
|
30
|
+
exports.PaginatedUserStatisticsAllOfFromJSONTyped = PaginatedUserStatisticsAllOfFromJSONTyped;
|
|
31
|
+
function PaginatedUserStatisticsAllOfToJSON(value) {
|
|
32
|
+
if (value === undefined) {
|
|
33
|
+
return undefined;
|
|
34
|
+
}
|
|
35
|
+
if (value === null) {
|
|
36
|
+
return null;
|
|
37
|
+
}
|
|
38
|
+
return {
|
|
39
|
+
'records': (value.records.map(UserStatistic_1.UserStatisticToJSON)),
|
|
40
|
+
};
|
|
41
|
+
}
|
|
42
|
+
exports.PaginatedUserStatisticsAllOfToJSON = PaginatedUserStatisticsAllOfToJSON;
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* lcdp-pharmaide-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 { UserLink } from './UserLink';
|
|
13
|
+
/**
|
|
14
|
+
* All these statistics are computed based on a sampling taking the last [Variable] \'user.statistics.sampling_days\' days
|
|
15
|
+
* @export
|
|
16
|
+
* @interface UserStatistic
|
|
17
|
+
*/
|
|
18
|
+
export interface UserStatistic {
|
|
19
|
+
/**
|
|
20
|
+
* Unique id representing this statistic
|
|
21
|
+
* @type {string}
|
|
22
|
+
* @memberof UserStatistic
|
|
23
|
+
*/
|
|
24
|
+
id?: string;
|
|
25
|
+
/**
|
|
26
|
+
*
|
|
27
|
+
* @type {UserLink}
|
|
28
|
+
* @memberof UserStatistic
|
|
29
|
+
*/
|
|
30
|
+
user?: UserLink;
|
|
31
|
+
/**
|
|
32
|
+
* Number of sales
|
|
33
|
+
* @type {number}
|
|
34
|
+
* @memberof UserStatistic
|
|
35
|
+
*/
|
|
36
|
+
numberOfSales?: number;
|
|
37
|
+
/**
|
|
38
|
+
* Rate of sales that have at least one removed or refunded item
|
|
39
|
+
* @type {number}
|
|
40
|
+
* @memberof UserStatistic
|
|
41
|
+
*/
|
|
42
|
+
salesErrorRate?: number;
|
|
43
|
+
/**
|
|
44
|
+
* Rate of sales that have been canceled, ignoring cancellation issued by the buyer without any reason
|
|
45
|
+
* @type {number}
|
|
46
|
+
* @memberof UserStatistic
|
|
47
|
+
*/
|
|
48
|
+
salesCanceledRate?: number;
|
|
49
|
+
/**
|
|
50
|
+
* Rate of sales that are associated to a litigation
|
|
51
|
+
* @type {number}
|
|
52
|
+
* @memberof UserStatistic
|
|
53
|
+
*/
|
|
54
|
+
salesLitigationRate?: number;
|
|
55
|
+
/**
|
|
56
|
+
* Average delay of responsiveness for sales (delay between order created by buyer and accepted/modified/canceled by seller or administrator)
|
|
57
|
+
* @type {number}
|
|
58
|
+
* @memberof UserStatistic
|
|
59
|
+
*/
|
|
60
|
+
salesResponsivenessDelay?: number;
|
|
61
|
+
/**
|
|
62
|
+
* Average delay of delivery for sales
|
|
63
|
+
* @type {number}
|
|
64
|
+
* @memberof UserStatistic
|
|
65
|
+
*/
|
|
66
|
+
deliveryDelay?: number;
|
|
67
|
+
}
|
|
68
|
+
export declare function UserStatisticFromJSON(json: any): UserStatistic;
|
|
69
|
+
export declare function UserStatisticFromJSONTyped(json: any, ignoreDiscriminator: boolean): UserStatistic;
|
|
70
|
+
export declare function UserStatisticToJSON(value?: UserStatistic | null): any;
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/* tslint:disable */
|
|
3
|
+
/* eslint-disable */
|
|
4
|
+
/**
|
|
5
|
+
* lcdp-pharmaide-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.UserStatisticToJSON = exports.UserStatisticFromJSONTyped = exports.UserStatisticFromJSON = void 0;
|
|
17
|
+
var runtime_1 = require("../runtime");
|
|
18
|
+
var UserLink_1 = require("./UserLink");
|
|
19
|
+
function UserStatisticFromJSON(json) {
|
|
20
|
+
return UserStatisticFromJSONTyped(json, false);
|
|
21
|
+
}
|
|
22
|
+
exports.UserStatisticFromJSON = UserStatisticFromJSON;
|
|
23
|
+
function UserStatisticFromJSONTyped(json, ignoreDiscriminator) {
|
|
24
|
+
if ((json === undefined) || (json === null)) {
|
|
25
|
+
return json;
|
|
26
|
+
}
|
|
27
|
+
return {
|
|
28
|
+
'id': !(0, runtime_1.exists)(json, 'id') ? undefined : json['id'],
|
|
29
|
+
'user': !(0, runtime_1.exists)(json, 'user') ? undefined : (0, UserLink_1.UserLinkFromJSON)(json['user']),
|
|
30
|
+
'numberOfSales': !(0, runtime_1.exists)(json, 'numberOfSales') ? undefined : json['numberOfSales'],
|
|
31
|
+
'salesErrorRate': !(0, runtime_1.exists)(json, 'salesErrorRate') ? undefined : json['salesErrorRate'],
|
|
32
|
+
'salesCanceledRate': !(0, runtime_1.exists)(json, 'salesCanceledRate') ? undefined : json['salesCanceledRate'],
|
|
33
|
+
'salesLitigationRate': !(0, runtime_1.exists)(json, 'salesLitigationRate') ? undefined : json['salesLitigationRate'],
|
|
34
|
+
'salesResponsivenessDelay': !(0, runtime_1.exists)(json, 'salesResponsivenessDelay') ? undefined : json['salesResponsivenessDelay'],
|
|
35
|
+
'deliveryDelay': !(0, runtime_1.exists)(json, 'deliveryDelay') ? undefined : json['deliveryDelay'],
|
|
36
|
+
};
|
|
37
|
+
}
|
|
38
|
+
exports.UserStatisticFromJSONTyped = UserStatisticFromJSONTyped;
|
|
39
|
+
function UserStatisticToJSON(value) {
|
|
40
|
+
if (value === undefined) {
|
|
41
|
+
return undefined;
|
|
42
|
+
}
|
|
43
|
+
if (value === null) {
|
|
44
|
+
return null;
|
|
45
|
+
}
|
|
46
|
+
return {
|
|
47
|
+
'id': value.id,
|
|
48
|
+
'user': (0, UserLink_1.UserLinkToJSON)(value.user),
|
|
49
|
+
'numberOfSales': value.numberOfSales,
|
|
50
|
+
'salesErrorRate': value.salesErrorRate,
|
|
51
|
+
'salesCanceledRate': value.salesCanceledRate,
|
|
52
|
+
'salesLitigationRate': value.salesLitigationRate,
|
|
53
|
+
'salesResponsivenessDelay': value.salesResponsivenessDelay,
|
|
54
|
+
'deliveryDelay': value.deliveryDelay,
|
|
55
|
+
};
|
|
56
|
+
}
|
|
57
|
+
exports.UserStatisticToJSON = UserStatisticToJSON;
|
|
@@ -2,8 +2,11 @@ export * from './HttpLink';
|
|
|
2
2
|
export * from './PaginatedObject';
|
|
3
3
|
export * from './PaginatedSaleOfferStatistics';
|
|
4
4
|
export * from './PaginatedSaleOfferStatisticsAllOf';
|
|
5
|
+
export * from './PaginatedUserStatistics';
|
|
6
|
+
export * from './PaginatedUserStatisticsAllOf';
|
|
5
7
|
export * from './PagingMetadata';
|
|
6
8
|
export * from './RestError';
|
|
7
9
|
export * from './SaleOfferStatistic';
|
|
8
10
|
export * from './UserLink';
|
|
9
11
|
export * from './UserLinkAllOf';
|
|
12
|
+
export * from './UserStatistic';
|
|
@@ -18,8 +18,11 @@ __exportStar(require("./HttpLink"), exports);
|
|
|
18
18
|
__exportStar(require("./PaginatedObject"), exports);
|
|
19
19
|
__exportStar(require("./PaginatedSaleOfferStatistics"), exports);
|
|
20
20
|
__exportStar(require("./PaginatedSaleOfferStatisticsAllOf"), exports);
|
|
21
|
+
__exportStar(require("./PaginatedUserStatistics"), exports);
|
|
22
|
+
__exportStar(require("./PaginatedUserStatisticsAllOf"), exports);
|
|
21
23
|
__exportStar(require("./PagingMetadata"), exports);
|
|
22
24
|
__exportStar(require("./RestError"), exports);
|
|
23
25
|
__exportStar(require("./SaleOfferStatistic"), exports);
|
|
24
26
|
__exportStar(require("./UserLink"), exports);
|
|
25
27
|
__exportStar(require("./UserLinkAllOf"), exports);
|
|
28
|
+
__exportStar(require("./UserStatistic"), exports);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './src';
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./src"), exports);
|
|
@@ -0,0 +1,29 @@
|
|
|
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 { BaseAPI, ApiResponse, BlobWithMeta } from '../runtime';
|
|
13
|
+
import { ThirdPartyLink, ThirdPartyLinkCreationParameters } from '../models';
|
|
14
|
+
export interface CreateThirdPartyLinkRequest {
|
|
15
|
+
thirdPartyLinkCreationParameters: ThirdPartyLinkCreationParameters;
|
|
16
|
+
}
|
|
17
|
+
/**
|
|
18
|
+
* no description
|
|
19
|
+
*/
|
|
20
|
+
export declare class ManageThirdPartyLinkApi extends BaseAPI {
|
|
21
|
+
/**
|
|
22
|
+
* Generate link to access a third party for the user on the requested slug
|
|
23
|
+
*/
|
|
24
|
+
createThirdPartyLinkRaw(requestParameters: CreateThirdPartyLinkRequest): Promise<ApiResponse<ThirdPartyLink | BlobWithMeta>>;
|
|
25
|
+
/**
|
|
26
|
+
* Generate link to access a third party for the user on the requested slug
|
|
27
|
+
*/
|
|
28
|
+
createThirdPartyLink(requestParameters: CreateThirdPartyLinkRequest): Promise<ThirdPartyLink | BlobWithMeta>;
|
|
29
|
+
}
|
|
@@ -0,0 +1,163 @@
|
|
|
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
|
+
var __extends = (this && this.__extends) || (function () {
|
|
16
|
+
var extendStatics = function (d, b) {
|
|
17
|
+
extendStatics = Object.setPrototypeOf ||
|
|
18
|
+
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
19
|
+
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
|
|
20
|
+
return extendStatics(d, b);
|
|
21
|
+
};
|
|
22
|
+
return function (d, b) {
|
|
23
|
+
if (typeof b !== "function" && b !== null)
|
|
24
|
+
throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
|
|
25
|
+
extendStatics(d, b);
|
|
26
|
+
function __() { this.constructor = d; }
|
|
27
|
+
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
28
|
+
};
|
|
29
|
+
})();
|
|
30
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
31
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
32
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
33
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
34
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
35
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
36
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
37
|
+
});
|
|
38
|
+
};
|
|
39
|
+
var __generator = (this && this.__generator) || function (thisArg, body) {
|
|
40
|
+
var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
|
|
41
|
+
return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
|
|
42
|
+
function verb(n) { return function (v) { return step([n, v]); }; }
|
|
43
|
+
function step(op) {
|
|
44
|
+
if (f) throw new TypeError("Generator is already executing.");
|
|
45
|
+
while (_) try {
|
|
46
|
+
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
|
|
47
|
+
if (y = 0, t) op = [op[0] & 2, t.value];
|
|
48
|
+
switch (op[0]) {
|
|
49
|
+
case 0: case 1: t = op; break;
|
|
50
|
+
case 4: _.label++; return { value: op[1], done: false };
|
|
51
|
+
case 5: _.label++; y = op[1]; op = [0]; continue;
|
|
52
|
+
case 7: op = _.ops.pop(); _.trys.pop(); continue;
|
|
53
|
+
default:
|
|
54
|
+
if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
|
|
55
|
+
if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
|
|
56
|
+
if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
|
|
57
|
+
if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
|
|
58
|
+
if (t[2]) _.ops.pop();
|
|
59
|
+
_.trys.pop(); continue;
|
|
60
|
+
}
|
|
61
|
+
op = body.call(thisArg, _);
|
|
62
|
+
} catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
|
|
63
|
+
if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
|
|
64
|
+
}
|
|
65
|
+
};
|
|
66
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
67
|
+
exports.ManageThirdPartyLinkApi = void 0;
|
|
68
|
+
var runtime_1 = require("../runtime");
|
|
69
|
+
var models_1 = require("../models");
|
|
70
|
+
/**
|
|
71
|
+
* no description
|
|
72
|
+
*/
|
|
73
|
+
var ManageThirdPartyLinkApi = /** @class */ (function (_super) {
|
|
74
|
+
__extends(ManageThirdPartyLinkApi, _super);
|
|
75
|
+
function ManageThirdPartyLinkApi() {
|
|
76
|
+
return _super !== null && _super.apply(this, arguments) || this;
|
|
77
|
+
}
|
|
78
|
+
/**
|
|
79
|
+
* Generate link to access a third party for the user on the requested slug
|
|
80
|
+
*/
|
|
81
|
+
ManageThirdPartyLinkApi.prototype.createThirdPartyLinkRaw = function (requestParameters) {
|
|
82
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
83
|
+
var queryParameters, headerParameters, token, tokenString, _a, response, contentType, response_1;
|
|
84
|
+
return __generator(this, function (_b) {
|
|
85
|
+
switch (_b.label) {
|
|
86
|
+
case 0:
|
|
87
|
+
if (requestParameters.thirdPartyLinkCreationParameters === null || requestParameters.thirdPartyLinkCreationParameters === undefined) {
|
|
88
|
+
throw new runtime_1.RequiredError('thirdPartyLinkCreationParameters', 'Required parameter requestParameters.thirdPartyLinkCreationParameters was null or undefined when calling createThirdPartyLink.');
|
|
89
|
+
}
|
|
90
|
+
queryParameters = {};
|
|
91
|
+
headerParameters = {};
|
|
92
|
+
headerParameters['Content-Type'] = 'application/json';
|
|
93
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
94
|
+
headerParameters["x-api-key"] = this.configuration.apiKey("x-api-key"); // apiKeyAuth authentication
|
|
95
|
+
}
|
|
96
|
+
if (!(this.configuration && this.configuration.accessToken)) return [3 /*break*/, 4];
|
|
97
|
+
token = this.configuration.accessToken;
|
|
98
|
+
if (!(typeof token === 'function')) return [3 /*break*/, 2];
|
|
99
|
+
return [4 /*yield*/, token("bearerAuth", [])];
|
|
100
|
+
case 1:
|
|
101
|
+
_a = _b.sent();
|
|
102
|
+
return [3 /*break*/, 3];
|
|
103
|
+
case 2:
|
|
104
|
+
_a = token;
|
|
105
|
+
_b.label = 3;
|
|
106
|
+
case 3:
|
|
107
|
+
tokenString = _a;
|
|
108
|
+
if (tokenString) {
|
|
109
|
+
headerParameters["Authorization"] = "Bearer ".concat(tokenString);
|
|
110
|
+
}
|
|
111
|
+
_b.label = 4;
|
|
112
|
+
case 4:
|
|
113
|
+
_b.trys.push([4, 6, , 7]);
|
|
114
|
+
return [4 /*yield*/, this.request({
|
|
115
|
+
path: "/third-party-links",
|
|
116
|
+
method: 'POST',
|
|
117
|
+
headers: headerParameters,
|
|
118
|
+
query: queryParameters,
|
|
119
|
+
body: (0, models_1.ThirdPartyLinkCreationParametersToJSON)(requestParameters.thirdPartyLinkCreationParameters),
|
|
120
|
+
})];
|
|
121
|
+
case 5:
|
|
122
|
+
response = _b.sent();
|
|
123
|
+
contentType = response.headers.get("content-type");
|
|
124
|
+
if (contentType && contentType.indexOf("application/json") !== -1) {
|
|
125
|
+
return [2 /*return*/, new runtime_1.JSONApiResponse(response, function (jsonValue) { return (0, models_1.ThirdPartyLinkFromJSON)(jsonValue); })];
|
|
126
|
+
}
|
|
127
|
+
else if (contentType && contentType.indexOf("text/plain") !== -1) {
|
|
128
|
+
return [2 /*return*/, new runtime_1.TextApiResponse(response)];
|
|
129
|
+
}
|
|
130
|
+
else {
|
|
131
|
+
// TODO : Better handling of others application types
|
|
132
|
+
return [2 /*return*/, new runtime_1.BlobWithMetaApiResponse(response)];
|
|
133
|
+
}
|
|
134
|
+
return [3 /*break*/, 7];
|
|
135
|
+
case 6:
|
|
136
|
+
response_1 = _b.sent();
|
|
137
|
+
console.debug(response_1);
|
|
138
|
+
throw response_1;
|
|
139
|
+
case 7: return [2 /*return*/];
|
|
140
|
+
}
|
|
141
|
+
});
|
|
142
|
+
});
|
|
143
|
+
};
|
|
144
|
+
/**
|
|
145
|
+
* Generate link to access a third party for the user on the requested slug
|
|
146
|
+
*/
|
|
147
|
+
ManageThirdPartyLinkApi.prototype.createThirdPartyLink = function (requestParameters) {
|
|
148
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
149
|
+
var response;
|
|
150
|
+
return __generator(this, function (_a) {
|
|
151
|
+
switch (_a.label) {
|
|
152
|
+
case 0: return [4 /*yield*/, this.createThirdPartyLinkRaw(requestParameters)];
|
|
153
|
+
case 1:
|
|
154
|
+
response = _a.sent();
|
|
155
|
+
return [4 /*yield*/, response.value()];
|
|
156
|
+
case 2: return [2 /*return*/, _a.sent()];
|
|
157
|
+
}
|
|
158
|
+
});
|
|
159
|
+
});
|
|
160
|
+
};
|
|
161
|
+
return ManageThirdPartyLinkApi;
|
|
162
|
+
}(runtime_1.BaseAPI));
|
|
163
|
+
exports.ManageThirdPartyLinkApi = ManageThirdPartyLinkApi;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './ManageThirdPartyLinkApi';
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./ManageThirdPartyLinkApi"), exports);
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./runtime"), exports);
|
|
18
|
+
__exportStar(require("./apis"), exports);
|
|
19
|
+
__exportStar(require("./models"), exports);
|
|
@@ -0,0 +1,87 @@
|
|
|
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
|
+
/**
|
|
13
|
+
*
|
|
14
|
+
* @export
|
|
15
|
+
* @interface RestError
|
|
16
|
+
*/
|
|
17
|
+
export interface RestError {
|
|
18
|
+
/**
|
|
19
|
+
* Unique code to identify an error : * `CODE000` - Using outdated resource * `CODE001` - Invalid credentials * `CODE002` - Cannot renew token * `CODE003` - Invalid User CGV * `CODE004` - Resource already exists * `CODE005` - User account is disabled * `CODE006` - Invalid schedule * `CODE007` - Wrong Address according CHRONOPOST * `CODE008` - Invalid Mangopay Mandate * `CODE009` - Invalid Status * `CODE010` - Image dimension exceeded * `CODE011` - Empty User Address * `CODE012` - Empty User Legal Name * `CODE013` - Invalid quantities * `CODE014` - Invalid Meta-Order * `CODE015` - Can not release quantity greater than claimed * `CODE016` - Can not release a negative quantity of items * `CODE017` - Batch is forbidden for sale * `CODE018` - Trial already used * `CODE019` - Unable to generate session from disposableToken for admin users * `CODE020` - ETag do not match
|
|
20
|
+
* @type {string}
|
|
21
|
+
* @memberof RestError
|
|
22
|
+
*/
|
|
23
|
+
code: RestErrorCodeEnum;
|
|
24
|
+
/**
|
|
25
|
+
* Unique code to identify an error : * `MESSAGE000` - Using outdated resource * `MESSAGE001` - Invalid credentials * `MESSAGE002` - Cannot renew token * `MESSAGE003` - Invalid User CGV * `MESSAGE004` - Resource already exists * `MESSAGE005` - User account is disabled * `MESSAGE006` - Invalid schedule * `MESSAGE007` - Wrong Address according CHRONOPOST * `MESSAGE008` - Invalid Mangopay Mandate * `MESSAGE009` - Invalid Status * `MESSAGE010` - Image dimension exceeded * `MESSAGE011` - Empty User Address * `MESSAGE012` - Empty User Legal Name * `MESSAGE013` - Invalid quantities * `MESSAGE014` - Invalid Meta-Order * `MESSAGE015` - Can not release quantity greater than claimed * `MESSAGE016` - Can not release a negative quantity of items * `MESSAGE017` - Batch is forbidden for sale * `MESSAGE018` - Trial already used * `MESSAGE019` - Unable to generate session from disposableToken for admin users * `MESSAGE020` - ETag do not match
|
|
26
|
+
* @type {string}
|
|
27
|
+
* @memberof RestError
|
|
28
|
+
*/
|
|
29
|
+
message: RestErrorMessageEnum;
|
|
30
|
+
}
|
|
31
|
+
export declare function RestErrorFromJSON(json: any): RestError;
|
|
32
|
+
export declare function RestErrorFromJSONTyped(json: any, ignoreDiscriminator: boolean): RestError;
|
|
33
|
+
export declare function RestErrorToJSON(value?: RestError | null): any;
|
|
34
|
+
/**
|
|
35
|
+
* @export
|
|
36
|
+
* @enum {string}
|
|
37
|
+
*/
|
|
38
|
+
export declare enum RestErrorCodeEnum {
|
|
39
|
+
CODE000 = "CODE000",
|
|
40
|
+
CODE001 = "CODE001",
|
|
41
|
+
CODE002 = "CODE002",
|
|
42
|
+
CODE003 = "CODE003",
|
|
43
|
+
CODE004 = "CODE004",
|
|
44
|
+
CODE005 = "CODE005",
|
|
45
|
+
CODE006 = "CODE006",
|
|
46
|
+
CODE007 = "CODE007",
|
|
47
|
+
CODE008 = "CODE008",
|
|
48
|
+
CODE009 = "CODE009",
|
|
49
|
+
CODE010 = "CODE010",
|
|
50
|
+
CODE011 = "CODE011",
|
|
51
|
+
CODE012 = "CODE012",
|
|
52
|
+
CODE013 = "CODE013",
|
|
53
|
+
CODE014 = "CODE014",
|
|
54
|
+
CODE015 = "CODE015",
|
|
55
|
+
CODE016 = "CODE016",
|
|
56
|
+
CODE017 = "CODE017",
|
|
57
|
+
CODE018 = "CODE018",
|
|
58
|
+
CODE019 = "CODE019",
|
|
59
|
+
CODE020 = "CODE020"
|
|
60
|
+
}
|
|
61
|
+
/**
|
|
62
|
+
* @export
|
|
63
|
+
* @enum {string}
|
|
64
|
+
*/
|
|
65
|
+
export declare enum RestErrorMessageEnum {
|
|
66
|
+
MESSAGE000 = "Using outdated resource",
|
|
67
|
+
MESSAGE001 = "Login failed",
|
|
68
|
+
MESSAGE002 = "Cannot renew token",
|
|
69
|
+
MESSAGE003 = "Invalid User CGV",
|
|
70
|
+
MESSAGE004 = "Resource already exists",
|
|
71
|
+
MESSAGE005 = "User account is disabled",
|
|
72
|
+
MESSAGE006 = "Invalid schedule",
|
|
73
|
+
MESSAGE007 = "Wrong Address according CHRONOPOST",
|
|
74
|
+
MESSAGE008 = "Invalid Mangopay Mandate",
|
|
75
|
+
MESSAGE009 = "Invalid Status",
|
|
76
|
+
MESSAGE010 = "Image dimension exceeded",
|
|
77
|
+
MESSAGE011 = "Empty User Address",
|
|
78
|
+
MESSAGE012 = "Empty User Legal Name",
|
|
79
|
+
MESSAGE013 = "Invalid quantities",
|
|
80
|
+
MESSAGE014 = "Invalid Meta-Order",
|
|
81
|
+
MESSAGE015 = "Can not release quantity greater than claimed",
|
|
82
|
+
MESSAGE016 = "Can not release a negative quantity of items",
|
|
83
|
+
MESSAGE017 = "Batch is forbidden for sale",
|
|
84
|
+
MESSAGE018 = "Trial already used",
|
|
85
|
+
MESSAGE019 = "Unable to generate session from disposableToken for admin users",
|
|
86
|
+
MESSAGE020 = "ETag do not match"
|
|
87
|
+
}
|
|
@@ -0,0 +1,99 @@
|
|
|
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.RestErrorMessageEnum = exports.RestErrorCodeEnum = exports.RestErrorToJSON = exports.RestErrorFromJSONTyped = exports.RestErrorFromJSON = void 0;
|
|
17
|
+
function RestErrorFromJSON(json) {
|
|
18
|
+
return RestErrorFromJSONTyped(json, false);
|
|
19
|
+
}
|
|
20
|
+
exports.RestErrorFromJSON = RestErrorFromJSON;
|
|
21
|
+
function RestErrorFromJSONTyped(json, ignoreDiscriminator) {
|
|
22
|
+
if ((json === undefined) || (json === null)) {
|
|
23
|
+
return json;
|
|
24
|
+
}
|
|
25
|
+
return {
|
|
26
|
+
'code': json['code'],
|
|
27
|
+
'message': json['message'],
|
|
28
|
+
};
|
|
29
|
+
}
|
|
30
|
+
exports.RestErrorFromJSONTyped = RestErrorFromJSONTyped;
|
|
31
|
+
function RestErrorToJSON(value) {
|
|
32
|
+
if (value === undefined) {
|
|
33
|
+
return undefined;
|
|
34
|
+
}
|
|
35
|
+
if (value === null) {
|
|
36
|
+
return null;
|
|
37
|
+
}
|
|
38
|
+
return {
|
|
39
|
+
'code': value.code,
|
|
40
|
+
'message': value.message,
|
|
41
|
+
};
|
|
42
|
+
}
|
|
43
|
+
exports.RestErrorToJSON = RestErrorToJSON;
|
|
44
|
+
/**
|
|
45
|
+
* @export
|
|
46
|
+
* @enum {string}
|
|
47
|
+
*/
|
|
48
|
+
var RestErrorCodeEnum;
|
|
49
|
+
(function (RestErrorCodeEnum) {
|
|
50
|
+
RestErrorCodeEnum["CODE000"] = "CODE000";
|
|
51
|
+
RestErrorCodeEnum["CODE001"] = "CODE001";
|
|
52
|
+
RestErrorCodeEnum["CODE002"] = "CODE002";
|
|
53
|
+
RestErrorCodeEnum["CODE003"] = "CODE003";
|
|
54
|
+
RestErrorCodeEnum["CODE004"] = "CODE004";
|
|
55
|
+
RestErrorCodeEnum["CODE005"] = "CODE005";
|
|
56
|
+
RestErrorCodeEnum["CODE006"] = "CODE006";
|
|
57
|
+
RestErrorCodeEnum["CODE007"] = "CODE007";
|
|
58
|
+
RestErrorCodeEnum["CODE008"] = "CODE008";
|
|
59
|
+
RestErrorCodeEnum["CODE009"] = "CODE009";
|
|
60
|
+
RestErrorCodeEnum["CODE010"] = "CODE010";
|
|
61
|
+
RestErrorCodeEnum["CODE011"] = "CODE011";
|
|
62
|
+
RestErrorCodeEnum["CODE012"] = "CODE012";
|
|
63
|
+
RestErrorCodeEnum["CODE013"] = "CODE013";
|
|
64
|
+
RestErrorCodeEnum["CODE014"] = "CODE014";
|
|
65
|
+
RestErrorCodeEnum["CODE015"] = "CODE015";
|
|
66
|
+
RestErrorCodeEnum["CODE016"] = "CODE016";
|
|
67
|
+
RestErrorCodeEnum["CODE017"] = "CODE017";
|
|
68
|
+
RestErrorCodeEnum["CODE018"] = "CODE018";
|
|
69
|
+
RestErrorCodeEnum["CODE019"] = "CODE019";
|
|
70
|
+
RestErrorCodeEnum["CODE020"] = "CODE020";
|
|
71
|
+
})(RestErrorCodeEnum = exports.RestErrorCodeEnum || (exports.RestErrorCodeEnum = {}));
|
|
72
|
+
/**
|
|
73
|
+
* @export
|
|
74
|
+
* @enum {string}
|
|
75
|
+
*/
|
|
76
|
+
var RestErrorMessageEnum;
|
|
77
|
+
(function (RestErrorMessageEnum) {
|
|
78
|
+
RestErrorMessageEnum["MESSAGE000"] = "Using outdated resource";
|
|
79
|
+
RestErrorMessageEnum["MESSAGE001"] = "Login failed";
|
|
80
|
+
RestErrorMessageEnum["MESSAGE002"] = "Cannot renew token";
|
|
81
|
+
RestErrorMessageEnum["MESSAGE003"] = "Invalid User CGV";
|
|
82
|
+
RestErrorMessageEnum["MESSAGE004"] = "Resource already exists";
|
|
83
|
+
RestErrorMessageEnum["MESSAGE005"] = "User account is disabled";
|
|
84
|
+
RestErrorMessageEnum["MESSAGE006"] = "Invalid schedule";
|
|
85
|
+
RestErrorMessageEnum["MESSAGE007"] = "Wrong Address according CHRONOPOST";
|
|
86
|
+
RestErrorMessageEnum["MESSAGE008"] = "Invalid Mangopay Mandate";
|
|
87
|
+
RestErrorMessageEnum["MESSAGE009"] = "Invalid Status";
|
|
88
|
+
RestErrorMessageEnum["MESSAGE010"] = "Image dimension exceeded";
|
|
89
|
+
RestErrorMessageEnum["MESSAGE011"] = "Empty User Address";
|
|
90
|
+
RestErrorMessageEnum["MESSAGE012"] = "Empty User Legal Name";
|
|
91
|
+
RestErrorMessageEnum["MESSAGE013"] = "Invalid quantities";
|
|
92
|
+
RestErrorMessageEnum["MESSAGE014"] = "Invalid Meta-Order";
|
|
93
|
+
RestErrorMessageEnum["MESSAGE015"] = "Can not release quantity greater than claimed";
|
|
94
|
+
RestErrorMessageEnum["MESSAGE016"] = "Can not release a negative quantity of items";
|
|
95
|
+
RestErrorMessageEnum["MESSAGE017"] = "Batch is forbidden for sale";
|
|
96
|
+
RestErrorMessageEnum["MESSAGE018"] = "Trial already used";
|
|
97
|
+
RestErrorMessageEnum["MESSAGE019"] = "Unable to generate session from disposableToken for admin users";
|
|
98
|
+
RestErrorMessageEnum["MESSAGE020"] = "ETag do not match";
|
|
99
|
+
})(RestErrorMessageEnum = exports.RestErrorMessageEnum || (exports.RestErrorMessageEnum = {}));
|