@stackfactor/client-api 1.1.137 → 1.1.139
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 +4 -4
- package/src/lib/actionNotifications.ts +3 -9
- package/src/lib/address.ts +1 -3
- package/src/lib/aiAssistant.ts +5 -13
- package/src/lib/avatar.ts +1 -5
- package/src/lib/axiosClient.ts +6 -14
- package/src/lib/config.ts +3 -9
- package/src/lib/constants.ts +4 -11
- package/src/lib/dashboard.ts +3 -9
- package/src/lib/departmentTrainingPlans.ts +6 -17
- package/src/lib/groups.ts +12 -27
- package/src/lib/integration.ts +0 -14
- package/src/lib/integrationConfiguration.ts +3 -9
- package/src/lib/integrations/contentGenerator.ts +0 -3
- package/src/lib/learningContent.ts +15 -33
- package/src/lib/learningPath.ts +8 -19
- package/src/lib/logger.ts +2 -4
- package/src/lib/microSkillsQuizes.ts +2 -7
- package/src/lib/quotas.ts +2 -7
- package/src/lib/role.ts +14 -31
- package/src/lib/roleTemplate.ts +10 -22
- package/src/lib/security.ts +4 -11
- package/src/lib/skill.ts +19 -40
- package/src/lib/skillAssessmentTestingSession.ts +6 -15
- package/src/lib/skillAssessments.ts +6 -15
- package/src/lib/skillTemplate.ts +11 -25
- package/src/lib/talentTransfromation.ts +5 -12
- package/src/lib/teams.ts +11 -25
- package/src/lib/tenants.ts +2 -4
- package/src/lib/trainingPlans.ts +13 -28
- package/src/lib/trainingPlansProficiencyLevels.ts +4 -13
- package/src/lib/userInformation.ts +4 -10
- package/src/lib/users.ts +27 -57
- package/src/lib/utils.ts +2 -6
- package/dist/cjs/actionNotifications.d.ts +0 -7
- package/dist/cjs/actionNotifications.d.ts.map +0 -1
- package/dist/cjs/actionNotifications.js +0 -74
- package/dist/cjs/actionNotifications.js.map +0 -1
- package/dist/cjs/address.d.ts +0 -5
- package/dist/cjs/address.d.ts.map +0 -1
- package/dist/cjs/address.js +0 -23
- package/dist/cjs/address.js.map +0 -1
- package/dist/cjs/aiAssistant.d.ts +0 -9
- package/dist/cjs/aiAssistant.d.ts.map +0 -1
- package/dist/cjs/aiAssistant.js +0 -136
- package/dist/cjs/aiAssistant.js.map +0 -1
- package/dist/cjs/avatar.d.ts +0 -5
- package/dist/cjs/avatar.d.ts.map +0 -1
- package/dist/cjs/avatar.js +0 -33
- package/dist/cjs/avatar.js.map +0 -1
- package/dist/cjs/axiosClient.d.ts +0 -32
- package/dist/cjs/axiosClient.d.ts.map +0 -1
- package/dist/cjs/axiosClient.js +0 -91
- package/dist/cjs/axiosClient.js.map +0 -1
- package/dist/cjs/config.d.ts +0 -7
- package/dist/cjs/config.d.ts.map +0 -1
- package/dist/cjs/config.js +0 -64
- package/dist/cjs/config.js.map +0 -1
- package/dist/cjs/constants.d.ts +0 -70
- package/dist/cjs/constants.d.ts.map +0 -1
- package/dist/cjs/constants.js +0 -95
- package/dist/cjs/constants.js.map +0 -1
- package/dist/cjs/dashboard.d.ts +0 -7
- package/dist/cjs/dashboard.d.ts.map +0 -1
- package/dist/cjs/dashboard.js +0 -75
- package/dist/cjs/dashboard.js.map +0 -1
- package/dist/cjs/departmentTrainingPlans.d.ts +0 -13
- package/dist/cjs/departmentTrainingPlans.d.ts.map +0 -1
- package/dist/cjs/departmentTrainingPlans.js +0 -155
- package/dist/cjs/departmentTrainingPlans.js.map +0 -1
- package/dist/cjs/groups.d.ts +0 -16
- package/dist/cjs/groups.d.ts.map +0 -1
- package/dist/cjs/groups.js +0 -274
- package/dist/cjs/groups.js.map +0 -1
- package/dist/cjs/index.d.ts +0 -33
- package/dist/cjs/index.d.ts.map +0 -1
- package/dist/cjs/index.js +0 -78
- package/dist/cjs/index.js.map +0 -1
- package/dist/cjs/integration.d.ts +0 -95
- package/dist/cjs/integration.d.ts.map +0 -1
- package/dist/cjs/integration.js +0 -329
- package/dist/cjs/integration.js.map +0 -1
- package/dist/cjs/integrationConfiguration.d.ts +0 -7
- package/dist/cjs/integrationConfiguration.d.ts.map +0 -1
- package/dist/cjs/integrationConfiguration.js +0 -87
- package/dist/cjs/integrationConfiguration.js.map +0 -1
- package/dist/cjs/integrations/contentGenerator.d.ts +0 -27
- package/dist/cjs/integrations/contentGenerator.d.ts.map +0 -1
- package/dist/cjs/integrations/contentGenerator.js +0 -71
- package/dist/cjs/integrations/contentGenerator.js.map +0 -1
- package/dist/cjs/learningContent.d.ts +0 -19
- package/dist/cjs/learningContent.d.ts.map +0 -1
- package/dist/cjs/learningContent.js +0 -395
- package/dist/cjs/learningContent.js.map +0 -1
- package/dist/cjs/learningPath.d.ts +0 -12
- package/dist/cjs/learningPath.d.ts.map +0 -1
- package/dist/cjs/learningPath.js +0 -206
- package/dist/cjs/learningPath.js.map +0 -1
- package/dist/cjs/logger.d.ts +0 -6
- package/dist/cjs/logger.d.ts.map +0 -1
- package/dist/cjs/logger.js +0 -58
- package/dist/cjs/logger.js.map +0 -1
- package/dist/cjs/microSkillsQuizes.d.ts +0 -6
- package/dist/cjs/microSkillsQuizes.d.ts.map +0 -1
- package/dist/cjs/microSkillsQuizes.js +0 -54
- package/dist/cjs/microSkillsQuizes.js.map +0 -1
- package/dist/cjs/quotas.d.ts +0 -6
- package/dist/cjs/quotas.d.ts.map +0 -1
- package/dist/cjs/quotas.js +0 -51
- package/dist/cjs/quotas.js.map +0 -1
- package/dist/cjs/role.d.ts +0 -18
- package/dist/cjs/role.d.ts.map +0 -1
- package/dist/cjs/role.js +0 -364
- package/dist/cjs/role.js.map +0 -1
- package/dist/cjs/roleTemplate.d.ts +0 -13
- package/dist/cjs/roleTemplate.d.ts.map +0 -1
- package/dist/cjs/roleTemplate.js +0 -237
- package/dist/cjs/roleTemplate.js.map +0 -1
- package/dist/cjs/security.d.ts +0 -8
- package/dist/cjs/security.d.ts.map +0 -1
- package/dist/cjs/security.js +0 -80
- package/dist/cjs/security.js.map +0 -1
- package/dist/cjs/skill.d.ts +0 -22
- package/dist/cjs/skill.d.ts.map +0 -1
- package/dist/cjs/skill.js +0 -441
- package/dist/cjs/skill.js.map +0 -1
- package/dist/cjs/skillAssessmentTestingSession.d.ts +0 -10
- package/dist/cjs/skillAssessmentTestingSession.d.ts.map +0 -1
- package/dist/cjs/skillAssessmentTestingSession.js +0 -157
- package/dist/cjs/skillAssessmentTestingSession.js.map +0 -1
- package/dist/cjs/skillAssessments.d.ts +0 -10
- package/dist/cjs/skillAssessments.d.ts.map +0 -1
- package/dist/cjs/skillAssessments.js +0 -157
- package/dist/cjs/skillAssessments.js.map +0 -1
- package/dist/cjs/skillTemplate.d.ts +0 -15
- package/dist/cjs/skillTemplate.d.ts.map +0 -1
- package/dist/cjs/skillTemplate.js +0 -282
- package/dist/cjs/skillTemplate.js.map +0 -1
- package/dist/cjs/talentTransfromation.d.ts +0 -8
- package/dist/cjs/talentTransfromation.d.ts.map +0 -1
- package/dist/cjs/talentTransfromation.js +0 -101
- package/dist/cjs/talentTransfromation.js.map +0 -1
- package/dist/cjs/teams.d.ts +0 -15
- package/dist/cjs/teams.d.ts.map +0 -1
- package/dist/cjs/teams.js +0 -253
- package/dist/cjs/teams.js.map +0 -1
- package/dist/cjs/tenants.d.ts +0 -6
- package/dist/cjs/tenants.d.ts.map +0 -1
- package/dist/cjs/tenants.js +0 -53
- package/dist/cjs/tenants.js.map +0 -1
- package/dist/cjs/trainingPlans.d.ts +0 -16
- package/dist/cjs/trainingPlans.d.ts.map +0 -1
- package/dist/cjs/trainingPlans.js +0 -310
- package/dist/cjs/trainingPlans.js.map +0 -1
- package/dist/cjs/trainingPlansProficiencyLevels.d.ts +0 -8
- package/dist/cjs/trainingPlansProficiencyLevels.d.ts.map +0 -1
- package/dist/cjs/trainingPlansProficiencyLevels.js +0 -99
- package/dist/cjs/trainingPlansProficiencyLevels.js.map +0 -1
- package/dist/cjs/userInformation.d.ts +0 -7
- package/dist/cjs/userInformation.d.ts.map +0 -1
- package/dist/cjs/userInformation.js +0 -82
- package/dist/cjs/userInformation.js.map +0 -1
- package/dist/cjs/users.d.ts +0 -31
- package/dist/cjs/users.d.ts.map +0 -1
- package/dist/cjs/users.js +0 -695
- package/dist/cjs/users.js.map +0 -1
- package/dist/cjs/utils.d.ts +0 -8
- package/dist/cjs/utils.d.ts.map +0 -1
- package/dist/cjs/utils.js +0 -57
- package/dist/cjs/utils.js.map +0 -1
- package/dist/esm/actionNotifications.d.ts +0 -7
- package/dist/esm/actionNotifications.d.ts.map +0 -1
- package/dist/esm/actionNotifications.js +0 -72
- package/dist/esm/actionNotifications.js.map +0 -1
- package/dist/esm/address.d.ts +0 -5
- package/dist/esm/address.d.ts.map +0 -1
- package/dist/esm/address.js +0 -21
- package/dist/esm/address.js.map +0 -1
- package/dist/esm/aiAssistant.d.ts +0 -9
- package/dist/esm/aiAssistant.d.ts.map +0 -1
- package/dist/esm/aiAssistant.js +0 -133
- package/dist/esm/aiAssistant.js.map +0 -1
- package/dist/esm/avatar.d.ts +0 -5
- package/dist/esm/avatar.d.ts.map +0 -1
- package/dist/esm/avatar.js +0 -31
- package/dist/esm/avatar.js.map +0 -1
- package/dist/esm/axiosClient.d.ts +0 -32
- package/dist/esm/axiosClient.d.ts.map +0 -1
- package/dist/esm/axiosClient.js +0 -79
- package/dist/esm/axiosClient.js.map +0 -1
- package/dist/esm/config.d.ts +0 -7
- package/dist/esm/config.d.ts.map +0 -1
- package/dist/esm/config.js +0 -62
- package/dist/esm/config.js.map +0 -1
- package/dist/esm/constants.d.ts +0 -70
- package/dist/esm/constants.d.ts.map +0 -1
- package/dist/esm/constants.js +0 -89
- package/dist/esm/constants.js.map +0 -1
- package/dist/esm/dashboard.d.ts +0 -7
- package/dist/esm/dashboard.d.ts.map +0 -1
- package/dist/esm/dashboard.js +0 -73
- package/dist/esm/dashboard.js.map +0 -1
- package/dist/esm/departmentTrainingPlans.d.ts +0 -13
- package/dist/esm/departmentTrainingPlans.d.ts.map +0 -1
- package/dist/esm/departmentTrainingPlans.js +0 -153
- package/dist/esm/departmentTrainingPlans.js.map +0 -1
- package/dist/esm/groups.d.ts +0 -16
- package/dist/esm/groups.d.ts.map +0 -1
- package/dist/esm/groups.js +0 -272
- package/dist/esm/groups.js.map +0 -1
- package/dist/esm/index.d.ts +0 -33
- package/dist/esm/index.d.ts.map +0 -1
- package/dist/esm/index.js +0 -33
- package/dist/esm/index.js.map +0 -1
- package/dist/esm/integration.d.ts +0 -95
- package/dist/esm/integration.d.ts.map +0 -1
- package/dist/esm/integration.js +0 -312
- package/dist/esm/integration.js.map +0 -1
- package/dist/esm/integrationConfiguration.d.ts +0 -7
- package/dist/esm/integrationConfiguration.d.ts.map +0 -1
- package/dist/esm/integrationConfiguration.js +0 -85
- package/dist/esm/integrationConfiguration.js.map +0 -1
- package/dist/esm/integrations/contentGenerator.d.ts +0 -27
- package/dist/esm/integrations/contentGenerator.d.ts.map +0 -1
- package/dist/esm/integrations/contentGenerator.js +0 -66
- package/dist/esm/integrations/contentGenerator.js.map +0 -1
- package/dist/esm/learningContent.d.ts +0 -19
- package/dist/esm/learningContent.d.ts.map +0 -1
- package/dist/esm/learningContent.js +0 -393
- package/dist/esm/learningContent.js.map +0 -1
- package/dist/esm/learningPath.d.ts +0 -12
- package/dist/esm/learningPath.d.ts.map +0 -1
- package/dist/esm/learningPath.js +0 -204
- package/dist/esm/learningPath.js.map +0 -1
- package/dist/esm/logger.d.ts +0 -6
- package/dist/esm/logger.d.ts.map +0 -1
- package/dist/esm/logger.js +0 -56
- package/dist/esm/logger.js.map +0 -1
- package/dist/esm/microSkillsQuizes.d.ts +0 -6
- package/dist/esm/microSkillsQuizes.d.ts.map +0 -1
- package/dist/esm/microSkillsQuizes.js +0 -52
- package/dist/esm/microSkillsQuizes.js.map +0 -1
- package/dist/esm/quotas.d.ts +0 -6
- package/dist/esm/quotas.d.ts.map +0 -1
- package/dist/esm/quotas.js +0 -49
- package/dist/esm/quotas.js.map +0 -1
- package/dist/esm/role.d.ts +0 -18
- package/dist/esm/role.d.ts.map +0 -1
- package/dist/esm/role.js +0 -362
- package/dist/esm/role.js.map +0 -1
- package/dist/esm/roleTemplate.d.ts +0 -13
- package/dist/esm/roleTemplate.d.ts.map +0 -1
- package/dist/esm/roleTemplate.js +0 -235
- package/dist/esm/roleTemplate.js.map +0 -1
- package/dist/esm/security.d.ts +0 -8
- package/dist/esm/security.d.ts.map +0 -1
- package/dist/esm/security.js +0 -78
- package/dist/esm/security.js.map +0 -1
- package/dist/esm/skill.d.ts +0 -22
- package/dist/esm/skill.d.ts.map +0 -1
- package/dist/esm/skill.js +0 -438
- package/dist/esm/skill.js.map +0 -1
- package/dist/esm/skillAssessmentTestingSession.d.ts +0 -10
- package/dist/esm/skillAssessmentTestingSession.d.ts.map +0 -1
- package/dist/esm/skillAssessmentTestingSession.js +0 -155
- package/dist/esm/skillAssessmentTestingSession.js.map +0 -1
- package/dist/esm/skillAssessments.d.ts +0 -10
- package/dist/esm/skillAssessments.d.ts.map +0 -1
- package/dist/esm/skillAssessments.js +0 -155
- package/dist/esm/skillAssessments.js.map +0 -1
- package/dist/esm/skillTemplate.d.ts +0 -15
- package/dist/esm/skillTemplate.d.ts.map +0 -1
- package/dist/esm/skillTemplate.js +0 -280
- package/dist/esm/skillTemplate.js.map +0 -1
- package/dist/esm/talentTransfromation.d.ts +0 -8
- package/dist/esm/talentTransfromation.d.ts.map +0 -1
- package/dist/esm/talentTransfromation.js +0 -99
- package/dist/esm/talentTransfromation.js.map +0 -1
- package/dist/esm/teams.d.ts +0 -15
- package/dist/esm/teams.d.ts.map +0 -1
- package/dist/esm/teams.js +0 -251
- package/dist/esm/teams.js.map +0 -1
- package/dist/esm/tenants.d.ts +0 -6
- package/dist/esm/tenants.d.ts.map +0 -1
- package/dist/esm/tenants.js +0 -51
- package/dist/esm/tenants.js.map +0 -1
- package/dist/esm/trainingPlans.d.ts +0 -16
- package/dist/esm/trainingPlans.d.ts.map +0 -1
- package/dist/esm/trainingPlans.js +0 -307
- package/dist/esm/trainingPlans.js.map +0 -1
- package/dist/esm/trainingPlansProficiencyLevels.d.ts +0 -8
- package/dist/esm/trainingPlansProficiencyLevels.d.ts.map +0 -1
- package/dist/esm/trainingPlansProficiencyLevels.js +0 -97
- package/dist/esm/trainingPlansProficiencyLevels.js.map +0 -1
- package/dist/esm/userInformation.d.ts +0 -7
- package/dist/esm/userInformation.d.ts.map +0 -1
- package/dist/esm/userInformation.js +0 -80
- package/dist/esm/userInformation.js.map +0 -1
- package/dist/esm/users.d.ts +0 -31
- package/dist/esm/users.d.ts.map +0 -1
- package/dist/esm/users.js +0 -692
- package/dist/esm/users.js.map +0 -1
- package/dist/esm/utils.d.ts +0 -8
- package/dist/esm/utils.d.ts.map +0 -1
- package/dist/esm/utils.js +0 -52
- package/dist/esm/utils.js.map +0 -1
package/dist/cjs/index.js
DELETED
|
@@ -1,78 +0,0 @@
|
|
|
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 __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
-
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
-
}) : function(o, v) {
|
|
16
|
-
o["default"] = v;
|
|
17
|
-
});
|
|
18
|
-
var __importStar = (this && this.__importStar) || (function () {
|
|
19
|
-
var ownKeys = function(o) {
|
|
20
|
-
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
21
|
-
var ar = [];
|
|
22
|
-
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
23
|
-
return ar;
|
|
24
|
-
};
|
|
25
|
-
return ownKeys(o);
|
|
26
|
-
};
|
|
27
|
-
return function (mod) {
|
|
28
|
-
if (mod && mod.__esModule) return mod;
|
|
29
|
-
var result = {};
|
|
30
|
-
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
31
|
-
__setModuleDefault(result, mod);
|
|
32
|
-
return result;
|
|
33
|
-
};
|
|
34
|
-
})();
|
|
35
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
36
|
-
exports.users = exports.userInformation = exports.trainingPlanProficiencyLevel = exports.trainingPlan = exports.tenant = exports.team = exports.talentTransfromation = exports.skillTemplate = exports.skillAssessmentTestingSession = exports.skillAssessment = exports.skill = exports.security = exports.roleTemplate = exports.role = exports.quotas = exports.microSkillsQuizes = exports.logger = exports.learningPath = exports.learningContent = exports.groups = exports.integrationConfiguration = exports.integration = exports.departmentTraingPlans = exports.dashboard = exports.contentGenerator = exports.RESPONSE_TYPE = exports.PERMISSION_DESCRIPTIONS = exports.PERMISSIONS = exports.DOCUMENT_VERSION = exports.config = exports.address = exports.avatar = exports.aiAssistant = exports.shouldReturnError = exports.getErrorType = exports.getErrorInformation = exports.errorToString = exports.client = exports.actionNotifications = void 0;
|
|
37
|
-
exports.actionNotifications = __importStar(require("./actionNotifications"));
|
|
38
|
-
var axiosClient_1 = require("./axiosClient");
|
|
39
|
-
Object.defineProperty(exports, "client", { enumerable: true, get: function () { return axiosClient_1.client; } });
|
|
40
|
-
Object.defineProperty(exports, "errorToString", { enumerable: true, get: function () { return axiosClient_1.errorToString; } });
|
|
41
|
-
Object.defineProperty(exports, "getErrorInformation", { enumerable: true, get: function () { return axiosClient_1.getErrorInformation; } });
|
|
42
|
-
Object.defineProperty(exports, "getErrorType", { enumerable: true, get: function () { return axiosClient_1.getErrorType; } });
|
|
43
|
-
Object.defineProperty(exports, "shouldReturnError", { enumerable: true, get: function () { return axiosClient_1.shouldReturnError; } });
|
|
44
|
-
exports.aiAssistant = __importStar(require("./aiAssistant"));
|
|
45
|
-
exports.avatar = __importStar(require("./avatar"));
|
|
46
|
-
exports.address = __importStar(require("./address"));
|
|
47
|
-
exports.config = __importStar(require("./config"));
|
|
48
|
-
var constants_1 = require("./constants");
|
|
49
|
-
Object.defineProperty(exports, "DOCUMENT_VERSION", { enumerable: true, get: function () { return constants_1.DOCUMENT_VERSION; } });
|
|
50
|
-
Object.defineProperty(exports, "PERMISSIONS", { enumerable: true, get: function () { return constants_1.PERMISSIONS; } });
|
|
51
|
-
Object.defineProperty(exports, "PERMISSION_DESCRIPTIONS", { enumerable: true, get: function () { return constants_1.PERMISSION_DESCRIPTIONS; } });
|
|
52
|
-
Object.defineProperty(exports, "RESPONSE_TYPE", { enumerable: true, get: function () { return constants_1.RESPONSE_TYPE; } });
|
|
53
|
-
exports.contentGenerator = __importStar(require("./integrations/contentGenerator"));
|
|
54
|
-
exports.dashboard = __importStar(require("./dashboard"));
|
|
55
|
-
exports.departmentTraingPlans = __importStar(require("./departmentTrainingPlans"));
|
|
56
|
-
exports.integration = __importStar(require("./integration"));
|
|
57
|
-
exports.integrationConfiguration = __importStar(require("./integrationConfiguration"));
|
|
58
|
-
exports.groups = __importStar(require("./groups"));
|
|
59
|
-
exports.learningContent = __importStar(require("./learningContent"));
|
|
60
|
-
exports.learningPath = __importStar(require("./learningPath"));
|
|
61
|
-
exports.logger = __importStar(require("./logger"));
|
|
62
|
-
exports.microSkillsQuizes = __importStar(require("./microSkillsQuizes"));
|
|
63
|
-
exports.quotas = __importStar(require("./quotas"));
|
|
64
|
-
exports.role = __importStar(require("./role"));
|
|
65
|
-
exports.roleTemplate = __importStar(require("./roleTemplate"));
|
|
66
|
-
exports.security = __importStar(require("./security"));
|
|
67
|
-
exports.skill = __importStar(require("./skill"));
|
|
68
|
-
exports.skillAssessment = __importStar(require("./skillAssessments"));
|
|
69
|
-
exports.skillAssessmentTestingSession = __importStar(require("./skillAssessmentTestingSession"));
|
|
70
|
-
exports.skillTemplate = __importStar(require("./skillTemplate"));
|
|
71
|
-
exports.talentTransfromation = __importStar(require("./talentTransfromation"));
|
|
72
|
-
exports.team = __importStar(require("./teams"));
|
|
73
|
-
exports.tenant = __importStar(require("./tenants"));
|
|
74
|
-
exports.trainingPlan = __importStar(require("./trainingPlans"));
|
|
75
|
-
exports.trainingPlanProficiencyLevel = __importStar(require("./trainingPlansProficiencyLevels"));
|
|
76
|
-
exports.userInformation = __importStar(require("./userInformation"));
|
|
77
|
-
exports.users = __importStar(require("./users"));
|
|
78
|
-
//# sourceMappingURL=index.js.map
|
package/dist/cjs/index.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/lib/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,6EAA6D;AAC7D,6CAMuB;AALrB,qGAAA,MAAM,OAAA;AACN,4GAAA,aAAa,OAAA;AACb,kHAAA,mBAAmB,OAAA;AACnB,2GAAA,YAAY,OAAA;AACZ,gHAAA,iBAAiB,OAAA;AAEnB,6DAA6C;AAC7C,mDAAmC;AACnC,qDAAqC;AACrC,mDAAmC;AACnC,yCAKqB;AAJnB,6GAAA,gBAAgB,OAAA;AAChB,wGAAA,WAAW,OAAA;AACX,oHAAA,uBAAuB,OAAA;AACvB,0GAAA,aAAa,OAAA;AAEf,oFAAoE;AACpE,yDAAyC;AACzC,mFAAmE;AACnE,6DAA6C;AAC7C,uFAAuE;AACvE,mDAAmC;AACnC,qEAAqD;AACrD,+DAA+C;AAC/C,mDAAmC;AACnC,yEAAyD;AACzD,mDAAmC;AACnC,+CAA+B;AAC/B,+DAA+C;AAC/C,uDAAuC;AACvC,iDAAiC;AACjC,sEAAsD;AACtD,iGAAiF;AACjF,iEAAiD;AACjD,+EAA+D;AAC/D,gDAAgC;AAChC,oDAAoC;AACpC,gEAAgD;AAChD,iGAAiF;AACjF,qEAAqD;AACrD,iDAAiC"}
|
|
@@ -1,95 +0,0 @@
|
|
|
1
|
-
interface ContentInformationResponse {
|
|
2
|
-
description: string;
|
|
3
|
-
duration: number;
|
|
4
|
-
icon: string;
|
|
5
|
-
title: string;
|
|
6
|
-
type: number;
|
|
7
|
-
internal: boolean;
|
|
8
|
-
}
|
|
9
|
-
/**
|
|
10
|
-
* Create integration and set information
|
|
11
|
-
* @param {Object} data The new integration information
|
|
12
|
-
* @param {String} token Authorization token
|
|
13
|
-
*/
|
|
14
|
-
export declare const createIntegration: (data: object, token: string) => Promise<object>;
|
|
15
|
-
/**
|
|
16
|
-
* Delete integration
|
|
17
|
-
* @param {String} id The id of the integration to be deleted
|
|
18
|
-
* @param {String} token Authorization token
|
|
19
|
-
*/
|
|
20
|
-
export declare const deleteIntegration: (id: string, token: string) => Promise<object>;
|
|
21
|
-
/**
|
|
22
|
-
* Discard the integration draft changes
|
|
23
|
-
* @param {String} id The id of the role template to be deleted
|
|
24
|
-
* @param {String} token Authorization token
|
|
25
|
-
*/
|
|
26
|
-
export declare const discardIntegrationChanges: (id: string, token: string) => Promise<object>;
|
|
27
|
-
/**
|
|
28
|
-
* Get integration information
|
|
29
|
-
* @param {String} id The id of the integration
|
|
30
|
-
* @param {String} version The version of the integration to be received
|
|
31
|
-
* @param {String} token Authorization token
|
|
32
|
-
*/
|
|
33
|
-
export declare const getIntegrationInformationById: (id: string, version: string, token: string) => Promise<object>;
|
|
34
|
-
/**
|
|
35
|
-
* Get integrations list
|
|
36
|
-
* @param {Array<String>} filter The filter used to select the integration
|
|
37
|
-
* @param {String} type The type of the integration
|
|
38
|
-
* @param {String} version The version to be retrieved
|
|
39
|
-
* @param {Boolean} includeSupportedCapabilities If true, the supported capabilities will be included in the response
|
|
40
|
-
* @param {String} token Authorization token
|
|
41
|
-
*/
|
|
42
|
-
export declare const getIntegrationsList: (filter: string[], type: string, version: string, includeSupportedCapabilities: boolean, token: string) => Promise<object>;
|
|
43
|
-
/**
|
|
44
|
-
* Get content information by Url
|
|
45
|
-
* @param {String} url The training url
|
|
46
|
-
* @param {String} verb The verb
|
|
47
|
-
* @param {String} token Authorization token
|
|
48
|
-
*/
|
|
49
|
-
export declare const getContentInformationByUrl: (url: string, verb: string, token: string) => Promise<object>;
|
|
50
|
-
/**
|
|
51
|
-
* Get content information by url from the browser instead of the backend
|
|
52
|
-
* @param {String} url
|
|
53
|
-
* @returns {Promise<ContentInformationResponse>}
|
|
54
|
-
*/
|
|
55
|
-
export declare const getContentInformationByUrlFromBrowser: (url: string) => Promise<ContentInformationResponse>;
|
|
56
|
-
/**
|
|
57
|
-
* Get enabled content providers
|
|
58
|
-
* @param {String} userId
|
|
59
|
-
* @param {String} token Authorization token
|
|
60
|
-
*/
|
|
61
|
-
export declare const getEnabledContentProviders: (userId: string, token: string) => Promise<object>;
|
|
62
|
-
/**
|
|
63
|
-
* Publish integration
|
|
64
|
-
* @param {String} id The id of the integration to be published
|
|
65
|
-
* @param {String} token Authorization token
|
|
66
|
-
*/
|
|
67
|
-
export declare const publishIntegration: (id: string, token: string) => Promise<object>;
|
|
68
|
-
/**
|
|
69
|
-
* Set integration information
|
|
70
|
-
* @param {String} id The id of the integration to be updated
|
|
71
|
-
* @param {Object} data Data used to update the integration
|
|
72
|
-
* @param {String} token Authorization token
|
|
73
|
-
*/
|
|
74
|
-
export declare const setIntegrationInformation: (id: string, data: object, token: string) => Promise<object>;
|
|
75
|
-
/**
|
|
76
|
-
* Set default integration
|
|
77
|
-
* @param {String} id The id of the integration to be set as default
|
|
78
|
-
* @param {String} token Authorization token
|
|
79
|
-
*/
|
|
80
|
-
export declare const setDefaultIntegration: (id: string, token: string) => Promise<object>;
|
|
81
|
-
declare const _default: {
|
|
82
|
-
createIntegration: (data: object, token: string) => Promise<object>;
|
|
83
|
-
deleteIntegration: (id: string, token: string) => Promise<object>;
|
|
84
|
-
discardIntegrationChanges: (id: string, token: string) => Promise<object>;
|
|
85
|
-
getContentInformationByUrl: (url: string, verb: string, token: string) => Promise<object>;
|
|
86
|
-
getContentInformationByUrlFromBrowser: (url: string) => Promise<ContentInformationResponse>;
|
|
87
|
-
getEnabledContentProviders: (userId: string, token: string) => Promise<object>;
|
|
88
|
-
getIntegrationInformationById: (id: string, version: string, token: string) => Promise<object>;
|
|
89
|
-
getIntegrationsList: (filter: string[], type: string, version: string, includeSupportedCapabilities: boolean, token: string) => Promise<object>;
|
|
90
|
-
publishIntegration: (id: string, token: string) => Promise<object>;
|
|
91
|
-
setDefaultIntegration: (id: string, token: string) => Promise<object>;
|
|
92
|
-
setIntegrationInformation: (id: string, data: object, token: string) => Promise<object>;
|
|
93
|
-
};
|
|
94
|
-
export default _default;
|
|
95
|
-
//# sourceMappingURL=integration.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"integration.d.ts","sourceRoot":"","sources":["../../src/lib/integration.ts"],"names":[],"mappings":"AAsBA,UAAU,0BAA0B;IAClC,WAAW,EAAE,MAAM,CAAC;IACpB,QAAQ,EAAE,MAAM,CAAC;IACjB,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,MAAM,CAAC;IACd,IAAI,EAAE,MAAM,CAAC;IACb,QAAQ,EAAE,OAAO,CAAC;CACnB;AAED;;;;GAIG;AACH,eAAO,MAAM,iBAAiB,SACtB,MAAM,SACL,MAAM,KACZ,OAAO,CAAC,MAAM,CAgBhB,CAAC;AAEF;;;;GAIG;AACH,eAAO,MAAM,iBAAiB,OACxB,MAAM,SACH,MAAM,KACZ,OAAO,CAAC,MAAM,CAgBhB,CAAC;AAEF;;;;GAIG;AACH,eAAO,MAAM,yBAAyB,OAChC,MAAM,SACH,MAAM,KACZ,OAAO,CAAC,MAAM,CAehB,CAAC;AAEF;;;;;GAKG;AACH,eAAO,MAAM,6BAA6B,OACpC,MAAM,WACD,MAAM,SACR,MAAM,KACZ,OAAO,CAAC,MAAM,CAgBhB,CAAC;AAEF;;;;;;;GAOG;AACH,eAAO,MAAM,m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,MAAM,CAAC;6BAsKZ,MAAM,SACH,MAAM,KACZ,OAAO,CAAC,MAAM,CAAC;gCAyDZ,MAAM,SACH,MAAM,KACZ,OAAO,CAAC,MAAM,CAAC;oCAjCZ,MAAM,QACJ,MAAM,SACL,MAAM,KACZ,OAAO,CAAC,MAAM,CAAC;;AAiDlB,wBAYE"}
|
package/dist/cjs/integration.js
DELETED
|
@@ -1,329 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
-
};
|
|
5
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
exports.setDefaultIntegration = exports.setIntegrationInformation = exports.publishIntegration = exports.getEnabledContentProviders = exports.getContentInformationByUrlFromBrowser = exports.getContentInformationByUrl = exports.getIntegrationsList = exports.getIntegrationInformationById = exports.discardIntegrationChanges = exports.deleteIntegration = exports.createIntegration = void 0;
|
|
7
|
-
var axiosClient_1 = require("./axiosClient");
|
|
8
|
-
var axios_1 = __importDefault(require("axios"));
|
|
9
|
-
var node_html_parser_1 = __importDefault(require("node-html-parser"));
|
|
10
|
-
var html2plaintext_1 = __importDefault(require("html2plaintext"));
|
|
11
|
-
/**
|
|
12
|
-
* Create integration and set information
|
|
13
|
-
* @param {Object} data The new integration information
|
|
14
|
-
* @param {String} token Authorization token
|
|
15
|
-
*/
|
|
16
|
-
var createIntegration = function (data, token) {
|
|
17
|
-
return new Promise(function (resolve, reject) {
|
|
18
|
-
var requestData = {
|
|
19
|
-
data: data,
|
|
20
|
-
};
|
|
21
|
-
var confirmationRequest = axiosClient_1.client.put("api/v1/integrations/", requestData, {
|
|
22
|
-
headers: { authorization: token },
|
|
23
|
-
});
|
|
24
|
-
confirmationRequest
|
|
25
|
-
.then(function (response) {
|
|
26
|
-
resolve(response.data);
|
|
27
|
-
})
|
|
28
|
-
.catch(function (error) {
|
|
29
|
-
reject(error);
|
|
30
|
-
});
|
|
31
|
-
});
|
|
32
|
-
};
|
|
33
|
-
exports.createIntegration = createIntegration;
|
|
34
|
-
/**
|
|
35
|
-
* Delete integration
|
|
36
|
-
* @param {String} id The id of the integration to be deleted
|
|
37
|
-
* @param {String} token Authorization token
|
|
38
|
-
*/
|
|
39
|
-
var deleteIntegration = function (id, token) {
|
|
40
|
-
return new Promise(function (resolve, reject) {
|
|
41
|
-
var request = axiosClient_1.client.delete("api/v1/integrations/", {
|
|
42
|
-
headers: { authorization: token },
|
|
43
|
-
data: {
|
|
44
|
-
id: id,
|
|
45
|
-
},
|
|
46
|
-
});
|
|
47
|
-
request
|
|
48
|
-
.then(function (response) {
|
|
49
|
-
resolve(response.data);
|
|
50
|
-
})
|
|
51
|
-
.catch(function (error) {
|
|
52
|
-
reject(error);
|
|
53
|
-
});
|
|
54
|
-
});
|
|
55
|
-
};
|
|
56
|
-
exports.deleteIntegration = deleteIntegration;
|
|
57
|
-
/**
|
|
58
|
-
* Discard the integration draft changes
|
|
59
|
-
* @param {String} id The id of the role template to be deleted
|
|
60
|
-
* @param {String} token Authorization token
|
|
61
|
-
*/
|
|
62
|
-
var discardIntegrationChanges = function (id, token) {
|
|
63
|
-
return new Promise(function (resolve, reject) {
|
|
64
|
-
var data = {};
|
|
65
|
-
var request = axiosClient_1.client.get("api/v1/integrations/discard/".concat(id), {
|
|
66
|
-
headers: { authorization: token },
|
|
67
|
-
data: data,
|
|
68
|
-
});
|
|
69
|
-
request
|
|
70
|
-
.then(function (response) {
|
|
71
|
-
resolve(response.data);
|
|
72
|
-
})
|
|
73
|
-
.catch(function (error) {
|
|
74
|
-
reject(error);
|
|
75
|
-
});
|
|
76
|
-
});
|
|
77
|
-
};
|
|
78
|
-
exports.discardIntegrationChanges = discardIntegrationChanges;
|
|
79
|
-
/**
|
|
80
|
-
* Get integration information
|
|
81
|
-
* @param {String} id The id of the integration
|
|
82
|
-
* @param {String} version The version of the integration to be received
|
|
83
|
-
* @param {String} token Authorization token
|
|
84
|
-
*/
|
|
85
|
-
var getIntegrationInformationById = function (id, version, token) {
|
|
86
|
-
return new Promise(function (resolve, reject) {
|
|
87
|
-
var confirmationRequest = axiosClient_1.client.get("api/v1/integrations/".concat(id, "/").concat(version), {
|
|
88
|
-
headers: { authorization: token },
|
|
89
|
-
});
|
|
90
|
-
confirmationRequest
|
|
91
|
-
.then(function (response) {
|
|
92
|
-
resolve(response.data);
|
|
93
|
-
})
|
|
94
|
-
.catch(function (error) {
|
|
95
|
-
reject(error);
|
|
96
|
-
});
|
|
97
|
-
});
|
|
98
|
-
};
|
|
99
|
-
exports.getIntegrationInformationById = getIntegrationInformationById;
|
|
100
|
-
/**
|
|
101
|
-
* Get integrations list
|
|
102
|
-
* @param {Array<String>} filter The filter used to select the integration
|
|
103
|
-
* @param {String} type The type of the integration
|
|
104
|
-
* @param {String} version The version to be retrieved
|
|
105
|
-
* @param {Boolean} includeSupportedCapabilities If true, the supported capabilities will be included in the response
|
|
106
|
-
* @param {String} token Authorization token
|
|
107
|
-
*/
|
|
108
|
-
var getIntegrationsList = function (filter, type, version, includeSupportedCapabilities, token) {
|
|
109
|
-
return new Promise(function (resolve, reject) {
|
|
110
|
-
var requestData = {
|
|
111
|
-
includeSupportedCapabilities: includeSupportedCapabilities,
|
|
112
|
-
version: version,
|
|
113
|
-
};
|
|
114
|
-
if (filter)
|
|
115
|
-
requestData.filter = filter;
|
|
116
|
-
if (type)
|
|
117
|
-
requestData.type = type;
|
|
118
|
-
var confirmationRequest = axiosClient_1.client.post("api/v1/integrations", requestData, {
|
|
119
|
-
headers: { authorization: token },
|
|
120
|
-
});
|
|
121
|
-
confirmationRequest
|
|
122
|
-
.then(function (response) {
|
|
123
|
-
resolve(response.data);
|
|
124
|
-
})
|
|
125
|
-
.catch(function (error) {
|
|
126
|
-
reject(error);
|
|
127
|
-
});
|
|
128
|
-
});
|
|
129
|
-
};
|
|
130
|
-
exports.getIntegrationsList = getIntegrationsList;
|
|
131
|
-
/**
|
|
132
|
-
* Get content information by Url
|
|
133
|
-
* @param {String} url The training url
|
|
134
|
-
* @param {String} verb The verb
|
|
135
|
-
* @param {String} token Authorization token
|
|
136
|
-
*/
|
|
137
|
-
var getContentInformationByUrl = function (url, verb, token) {
|
|
138
|
-
return new Promise(function (resolve, reject) {
|
|
139
|
-
var requestData = {
|
|
140
|
-
url: url,
|
|
141
|
-
verb: verb,
|
|
142
|
-
};
|
|
143
|
-
var confirmationRequest = axiosClient_1.client.post("api/v1/contentproviders/getcontentinformationbyurl", requestData, {
|
|
144
|
-
headers: { authorization: token },
|
|
145
|
-
});
|
|
146
|
-
confirmationRequest
|
|
147
|
-
.then(function (response) {
|
|
148
|
-
resolve(response.data);
|
|
149
|
-
})
|
|
150
|
-
.catch(function (error) {
|
|
151
|
-
reject(error);
|
|
152
|
-
});
|
|
153
|
-
});
|
|
154
|
-
};
|
|
155
|
-
exports.getContentInformationByUrl = getContentInformationByUrl;
|
|
156
|
-
/**
|
|
157
|
-
* Get content information by url from the browser instead of the backend
|
|
158
|
-
* @param {String} url
|
|
159
|
-
* @returns {Promise<ContentInformationResponse>}
|
|
160
|
-
*/
|
|
161
|
-
var getContentInformationByUrlFromBrowser = function (url) {
|
|
162
|
-
return new Promise(function (resolve, reject) {
|
|
163
|
-
var domain = new URL(url);
|
|
164
|
-
var instance = axios_1.default.create({
|
|
165
|
-
baseURL: domain.origin,
|
|
166
|
-
});
|
|
167
|
-
var confirmationRequest = instance.get(domain.pathname, {
|
|
168
|
-
headers: {
|
|
169
|
-
"Access-Control-Allow-Origin": "*",
|
|
170
|
-
"Access-Control-Allow-Headers": "Authorization, Origin, X-Requested-With, Content-Type, Accept",
|
|
171
|
-
Accept: "text/html,application/xhtml+xml,application/xml;q=0.9,image/avif,image/webp,image/apng,*/*;q=0.8,application/signed-exchange;v=b3;q=0.7",
|
|
172
|
-
"Accept-Encoding": "gzip, deflate, br",
|
|
173
|
-
"Access-Control-Allow-Methods": "GET, POST, PUT, DELETE",
|
|
174
|
-
"User-Agent": "Mozilla/5.0",
|
|
175
|
-
},
|
|
176
|
-
});
|
|
177
|
-
confirmationRequest
|
|
178
|
-
.then(function (response) {
|
|
179
|
-
//get the reading time
|
|
180
|
-
var getReadingTime = function (text) {
|
|
181
|
-
var wpm = 225;
|
|
182
|
-
var words = text.trim().split(/\s+/).length;
|
|
183
|
-
return Math.ceil(words / wpm);
|
|
184
|
-
};
|
|
185
|
-
var document = node_html_parser_1.default.parse(response.data);
|
|
186
|
-
var duration = getReadingTime((0, html2plaintext_1.default)(response.data));
|
|
187
|
-
var titleTag = document.querySelector("title");
|
|
188
|
-
var title = titleTag ? titleTag.rawText : "";
|
|
189
|
-
var description = "";
|
|
190
|
-
var descriptionEl = document.querySelector("meta");
|
|
191
|
-
try {
|
|
192
|
-
if (descriptionEl) {
|
|
193
|
-
var descriptionParentNode = descriptionEl.parentNode;
|
|
194
|
-
if (descriptionEl) {
|
|
195
|
-
var descriptionChildNodes = descriptionParentNode.childNodes;
|
|
196
|
-
if (descriptionChildNodes) {
|
|
197
|
-
//TODO: Code needs fixing
|
|
198
|
-
// const descriptionRawAttr = descriptionChildNodes.find((element) => {
|
|
199
|
-
// return element.rawAttrs && element.rawAttrs.includes("description");
|
|
200
|
-
// });
|
|
201
|
-
// if (descriptionRawAttr) {
|
|
202
|
-
// const element = descriptionRawAttr as any; // Cast to any to access rawAttrs
|
|
203
|
-
// const descriptionContent = element.rawAttrs.substring(
|
|
204
|
-
// element.rawAttrs.indexOf("content=") + 8
|
|
205
|
-
// );
|
|
206
|
-
// description = descriptionContent.substring(
|
|
207
|
-
// 0,
|
|
208
|
-
// descriptionContent.length - 1
|
|
209
|
-
// );
|
|
210
|
-
// }
|
|
211
|
-
}
|
|
212
|
-
}
|
|
213
|
-
}
|
|
214
|
-
}
|
|
215
|
-
finally {
|
|
216
|
-
resolve({
|
|
217
|
-
description: description,
|
|
218
|
-
duration: duration,
|
|
219
|
-
icon: "http://www.google.com/s2/favicons?sz=128&domain_url=".concat(domain.hostname),
|
|
220
|
-
title: title ? title.trim() : url,
|
|
221
|
-
type: 0,
|
|
222
|
-
internal: true,
|
|
223
|
-
});
|
|
224
|
-
}
|
|
225
|
-
})
|
|
226
|
-
.catch(function (error) {
|
|
227
|
-
reject(new Error((0, axiosClient_1.errorToString)(error)));
|
|
228
|
-
});
|
|
229
|
-
});
|
|
230
|
-
};
|
|
231
|
-
exports.getContentInformationByUrlFromBrowser = getContentInformationByUrlFromBrowser;
|
|
232
|
-
/**
|
|
233
|
-
* Get enabled content providers
|
|
234
|
-
* @param {String} userId
|
|
235
|
-
* @param {String} token Authorization token
|
|
236
|
-
*/
|
|
237
|
-
var getEnabledContentProviders = function (userId, token) {
|
|
238
|
-
return new Promise(function (resolve, reject) {
|
|
239
|
-
var confirmationRequest = axiosClient_1.client.get("api/v1/contentproviders/getenabledcontentproviders/".concat(userId), {
|
|
240
|
-
headers: { authorization: token },
|
|
241
|
-
});
|
|
242
|
-
confirmationRequest
|
|
243
|
-
.then(function (response) {
|
|
244
|
-
resolve(response.data);
|
|
245
|
-
})
|
|
246
|
-
.catch(function (error) {
|
|
247
|
-
reject(error);
|
|
248
|
-
});
|
|
249
|
-
});
|
|
250
|
-
};
|
|
251
|
-
exports.getEnabledContentProviders = getEnabledContentProviders;
|
|
252
|
-
/**
|
|
253
|
-
* Publish integration
|
|
254
|
-
* @param {String} id The id of the integration to be published
|
|
255
|
-
* @param {String} token Authorization token
|
|
256
|
-
*/
|
|
257
|
-
var publishIntegration = function (id, token) {
|
|
258
|
-
return new Promise(function (resolve, reject) {
|
|
259
|
-
var confirmationRequest = axiosClient_1.client.post("api/v1/integrations/publish/".concat(id), {}, {
|
|
260
|
-
headers: { authorization: token },
|
|
261
|
-
});
|
|
262
|
-
confirmationRequest
|
|
263
|
-
.then(function (response) {
|
|
264
|
-
resolve(response.data);
|
|
265
|
-
})
|
|
266
|
-
.catch(function (error) {
|
|
267
|
-
reject(error);
|
|
268
|
-
});
|
|
269
|
-
});
|
|
270
|
-
};
|
|
271
|
-
exports.publishIntegration = publishIntegration;
|
|
272
|
-
/**
|
|
273
|
-
* Set integration information
|
|
274
|
-
* @param {String} id The id of the integration to be updated
|
|
275
|
-
* @param {Object} data Data used to update the integration
|
|
276
|
-
* @param {String} token Authorization token
|
|
277
|
-
*/
|
|
278
|
-
var setIntegrationInformation = function (id, data, token) {
|
|
279
|
-
return new Promise(function (resolve, reject) {
|
|
280
|
-
var requestData = {
|
|
281
|
-
data: data,
|
|
282
|
-
};
|
|
283
|
-
var confirmationRequest = axiosClient_1.client.post("api/v1/integrations/".concat(id), requestData, {
|
|
284
|
-
headers: { authorization: token },
|
|
285
|
-
});
|
|
286
|
-
confirmationRequest
|
|
287
|
-
.then(function (response) {
|
|
288
|
-
resolve(response.data);
|
|
289
|
-
})
|
|
290
|
-
.catch(function (error) {
|
|
291
|
-
reject(error);
|
|
292
|
-
});
|
|
293
|
-
});
|
|
294
|
-
};
|
|
295
|
-
exports.setIntegrationInformation = setIntegrationInformation;
|
|
296
|
-
/**
|
|
297
|
-
* Set default integration
|
|
298
|
-
* @param {String} id The id of the integration to be set as default
|
|
299
|
-
* @param {String} token Authorization token
|
|
300
|
-
*/
|
|
301
|
-
var setDefaultIntegration = function (id, token) {
|
|
302
|
-
return new Promise(function (resolve, reject) {
|
|
303
|
-
var confirmationRequest = axiosClient_1.client.post("api/v1/integrations/".concat(id, "/default"), "", {
|
|
304
|
-
headers: { authorization: token },
|
|
305
|
-
});
|
|
306
|
-
confirmationRequest
|
|
307
|
-
.then(function (response) {
|
|
308
|
-
resolve(response.data);
|
|
309
|
-
})
|
|
310
|
-
.catch(function (error) {
|
|
311
|
-
reject(error);
|
|
312
|
-
});
|
|
313
|
-
});
|
|
314
|
-
};
|
|
315
|
-
exports.setDefaultIntegration = setDefaultIntegration;
|
|
316
|
-
exports.default = {
|
|
317
|
-
createIntegration: exports.createIntegration,
|
|
318
|
-
deleteIntegration: exports.deleteIntegration,
|
|
319
|
-
discardIntegrationChanges: exports.discardIntegrationChanges,
|
|
320
|
-
getContentInformationByUrl: exports.getContentInformationByUrl,
|
|
321
|
-
getContentInformationByUrlFromBrowser: exports.getContentInformationByUrlFromBrowser,
|
|
322
|
-
getEnabledContentProviders: exports.getEnabledContentProviders,
|
|
323
|
-
getIntegrationInformationById: exports.getIntegrationInformationById,
|
|
324
|
-
getIntegrationsList: exports.getIntegrationsList,
|
|
325
|
-
publishIntegration: exports.publishIntegration,
|
|
326
|
-
setDefaultIntegration: exports.setDefaultIntegration,
|
|
327
|
-
setIntegrationInformation: exports.setIntegrationInformation,
|
|
328
|
-
};
|
|
329
|
-
//# sourceMappingURL=integration.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"integration.js","sourceRoot":"","sources":["../../src/lib/integration.ts"],"names":[],"mappings":";;;;;;AACA,6CAAsD;AACtD,gDAA6B;AAC7B,sEAA0C;AAC1C,kEAAwC;AA2BxC;;;;GAIG;AACI,IAAM,iBAAiB,GAAG,UAC/B,IAAY,EACZ,KAAa;IAEb,OAAO,IAAI,OAAO,CAAC,UAAC,OAAO,EAAE,MAAM;QACjC,IAAM,WAAW,GAAoB;YACnC,IAAI,EAAE,IAAI;SACX,CAAC;QACF,IAAM,mBAAmB,GAAG,oBAAM,CAAC,GAAG,CAAC,sBAAsB,EAAE,WAAW,EAAE;YAC1E,OAAO,EAAE,EAAE,aAAa,EAAE,KAAK,EAAE;SAClC,CAAC,CAAC;QACH,mBAAmB;aAChB,IAAI,CAAC,UAAC,QAAwB;YAC7B,OAAO,CAAC,QAAQ,CAAC,IAAI,CAAC,CAAC;QACzB,CAAC,CAAC;aACD,KAAK,CAAC,UAAC,KAAkB;YACxB,MAAM,CAAC,KAAK,CAAC,CAAC;QAChB,CAAC,CAAC,CAAC;IACP,CAAC,CAAC,CAAC;AACL,CAAC,CAAC;AAnBW,QAAA,iBAAiB,qBAmB5B;AAEF;;;;GAIG;AACI,IAAM,iBAAiB,GAAG,UAC/B,EAAU,EACV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F,mBAAmB;aAChB,IAAI,CAAC,UAAC,QAAwB;YAC7B,OAAO,CAAC,QAAQ,CAAC,IAAI,CAAC,CAAC;QACzB,CAAC,CAAC;aACD,KAAK,CAAC,UAAC,KAAkB;YACxB,MAAM,CAAC,KAAK,CAAC,CAAC;QAChB,CAAC,CAAC,CAAC;IACP,CAAC,CAAC,CAAC;AACL,CAAC,CAAC;AApBW,QAAA,qBAAqB,yBAoBhC;AAEF,kBAAe;IACb,iBAAiB,2BAAA;IACjB,iBAAiB,2BAAA;IACjB,yBAAyB,mCAAA;IACzB,0BAA0B,oCAAA;IAC1B,qCAAqC,+CAAA;IACrC,0BAA0B,oCAAA;IAC1B,6BAA6B,uCAAA;IAC7B,mBAAmB,6BAAA;IACnB,kBAAkB,4BAAA;IAClB,qBAAqB,+BAAA;IACrB,yBAAyB,mCAAA;CAC1B,CAAC"}
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
declare const _default: {
|
|
2
|
-
getIntegrationsConfiguration: (ids: string[], type: number, token: string) => Promise<object>;
|
|
3
|
-
saveIntegrationConfiguration: (id: string, type: number, configuration: object, token: string) => Promise<object>;
|
|
4
|
-
testIntegrationConfiguration: (id: string, type: string, configuration: object, token: string) => Promise<object>;
|
|
5
|
-
};
|
|
6
|
-
export default _default;
|
|
7
|
-
//# sourceMappingURL=integrationConfiguration.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"integrationConfiguration.d.ts","sourceRoot":"","sources":["../../src/lib/integrationConfiguration.ts"],"names":[],"mappings":";wCAWO,MAAM,EAAE,QACP,MAAM,SACL,MAAM,KACZ,OAAO,CAAC,MAAM,CAAC;uCA8BZ,MAAM,QACJ,MAAM,iBACG,MAAM,SACd,MAAM,KACZ,OAAO,CAAC,MAAM,CAAC;uCAiCZ,MAAM,QACJ,MAAM,iBACG,MAAM,SACd,MAAM,KACZ,OAAO,CAAC,MAAM,CAAC;;AAwBlB,wBAIE"}
|
|
@@ -1,87 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
var axiosClient_1 = require("./axiosClient");
|
|
4
|
-
/**
|
|
5
|
-
* Get the integration configuration
|
|
6
|
-
* @param {Array<String>} ids
|
|
7
|
-
* @param {Number} type
|
|
8
|
-
* @param {String} token Authorization token
|
|
9
|
-
* @returns {Promise<object>}
|
|
10
|
-
*/
|
|
11
|
-
var getIntegrationsConfiguration = function (ids, type, token) {
|
|
12
|
-
return new Promise(function (resolve, reject) {
|
|
13
|
-
var requestData = { type: type };
|
|
14
|
-
if (ids)
|
|
15
|
-
requestData.ids = ids;
|
|
16
|
-
var confirmationRequest = axiosClient_1.client.post("api/v1/integrationsconfiguration", requestData, {
|
|
17
|
-
headers: { authorization: token },
|
|
18
|
-
});
|
|
19
|
-
confirmationRequest
|
|
20
|
-
.then(function (response) {
|
|
21
|
-
resolve(response.data);
|
|
22
|
-
})
|
|
23
|
-
.catch(function (error) {
|
|
24
|
-
reject(error);
|
|
25
|
-
});
|
|
26
|
-
});
|
|
27
|
-
};
|
|
28
|
-
/**
|
|
29
|
-
* Save integration configuration
|
|
30
|
-
* @param {String} id The id of the integration configuration to be updated
|
|
31
|
-
* @param {Number} type The type of configuration
|
|
32
|
-
* @param {Object} configuration Data used to update the integration configuration
|
|
33
|
-
* @param {String} token Authorization token
|
|
34
|
-
* @returns {Promise<object>}
|
|
35
|
-
*/
|
|
36
|
-
var saveIntegrationConfiguration = function (id, type, configuration, token) {
|
|
37
|
-
return new Promise(function (resolve, reject) {
|
|
38
|
-
var requestData = {
|
|
39
|
-
id: id,
|
|
40
|
-
configuration: configuration,
|
|
41
|
-
type: type,
|
|
42
|
-
};
|
|
43
|
-
var confirmationRequest = axiosClient_1.client.put("api/v1/integrationsconfiguration", requestData, {
|
|
44
|
-
headers: { authorization: token },
|
|
45
|
-
});
|
|
46
|
-
confirmationRequest
|
|
47
|
-
.then(function (response) {
|
|
48
|
-
resolve(response.data);
|
|
49
|
-
})
|
|
50
|
-
.catch(function (error) {
|
|
51
|
-
reject(error);
|
|
52
|
-
});
|
|
53
|
-
});
|
|
54
|
-
};
|
|
55
|
-
/**
|
|
56
|
-
* Test integration configuration
|
|
57
|
-
* @param {String} id The id of the integration to be updated
|
|
58
|
-
* @param {String} type The type of configuration
|
|
59
|
-
* @param {Object} configuration Configuration to be tested
|
|
60
|
-
* @param {String} token Authorization token
|
|
61
|
-
* @returns {Promise<object>}
|
|
62
|
-
*/
|
|
63
|
-
var testIntegrationConfiguration = function (id, type, configuration, token) {
|
|
64
|
-
return new Promise(function (resolve, reject) {
|
|
65
|
-
var requestData = {
|
|
66
|
-
id: id,
|
|
67
|
-
configuration: configuration,
|
|
68
|
-
type: type,
|
|
69
|
-
};
|
|
70
|
-
var confirmationRequest = axiosClient_1.client.post("api/v1/integrationsconfiguration/testConfiguration", requestData, {
|
|
71
|
-
headers: { authorization: token },
|
|
72
|
-
});
|
|
73
|
-
confirmationRequest
|
|
74
|
-
.then(function (response) {
|
|
75
|
-
resolve(response.data);
|
|
76
|
-
})
|
|
77
|
-
.catch(function (error) {
|
|
78
|
-
reject(error);
|
|
79
|
-
});
|
|
80
|
-
});
|
|
81
|
-
};
|
|
82
|
-
exports.default = {
|
|
83
|
-
getIntegrationsConfiguration: getIntegrationsConfiguration,
|
|
84
|
-
saveIntegrationConfiguration: saveIntegrationConfiguration,
|
|
85
|
-
testIntegrationConfiguration: testIntegrationConfiguration,
|
|
86
|
-
};
|
|
87
|
-
//# sourceMappingURL=integrationConfiguration.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"integrationConfiguration.js","sourceRoot":"","sources":["../../src/lib/integrationConfiguration.ts"],"names":[],"mappings":";;AACA,6CAAuC;AAEvC;;;;;;GAMG;AACH,IAAM,4BAA4B,GAAG,UACnC,GAAa,EACb,IAAY,EACZ,KAAa;IAEb,OAAO,IAAI,OAAO,CAAC,UAAC,OAAO,EAAE,MAAM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AAa;IAEb,OAAO,IAAI,OAAO,CAAC,UAAC,OAAO,EAAE,MAAM;QACjC,IAAM,WAAW,GAAG;YAClB,EAAE,EAAE,EAAE;YACN,aAAa,EAAE,aAAa;YAC5B,IAAI,EAAE,IAAI;SACX,CAAC;QACF,IAAM,mBAAmB,GAAG,oBAAM,CAAC,IAAI,CACrC,oDAAoD,EACpD,WAAW,EACX;YACE,OAAO,EAAE,EAAE,aAAa,EAAE,KAAK,EAAE;SAClC,CACF,CAAC;QACF,mBAAmB;aAChB,IAAI,CAAC,UAAC,QAAwB;YAC7B,OAAO,CAAC,QAAQ,CAAC,IAAI,CAAC,CAAC;QACzB,CAAC,CAAC;aACD,KAAK,CAAC,UAAC,KAAkB;YACxB,MAAM,CAAC,KAAK,CAAC,CAAC;QAChB,CAAC,CAAC,CAAC;IACP,CAAC,CAAC,CAAC;AACL,CAAC,CAAC;AAEF,kBAAe;IACb,4BAA4B,8BAAA;IAC5B,4BAA4B,8BAAA;IAC5B,4BAA4B,8BAAA;CAC7B,CAAC"}
|
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Generate content
|
|
3
|
-
* @param {Array<String>} data
|
|
4
|
-
* @param {String} contentType
|
|
5
|
-
* @param {String} integrationId
|
|
6
|
-
* @param {String} token
|
|
7
|
-
* @returns {Promise<object>}
|
|
8
|
-
*/
|
|
9
|
-
export declare const generateContent: (data: string[], contentType: string, integrationId: string, token: string) => Promise<object>;
|
|
10
|
-
/**
|
|
11
|
-
* Generate content async
|
|
12
|
-
* @param {String} id
|
|
13
|
-
* @param {Object} data
|
|
14
|
-
* @param {String} contentType
|
|
15
|
-
* @param {String} elementType
|
|
16
|
-
* @param {String} integrationId
|
|
17
|
-
* @param {String} comments
|
|
18
|
-
* @param {String} token
|
|
19
|
-
* @returns {Promise<object>}
|
|
20
|
-
*/
|
|
21
|
-
export declare const generateContentAsync: (id: string, data: object, contentType: string, elementType: string, integrationId: string, comments: string, token: string) => Promise<object>;
|
|
22
|
-
declare const contentGenerator: {
|
|
23
|
-
generateContent: (data: string[], contentType: string, integrationId: string, token: string) => Promise<object>;
|
|
24
|
-
generateContentAsync: (id: string, data: object, contentType: string, elementType: string, integrationId: string, comments: string, token: string) => Promise<object>;
|
|
25
|
-
};
|
|
26
|
-
export default contentGenerator;
|
|
27
|
-
//# sourceMappingURL=contentGenerator.d.ts.map
|