@agility/management-sdk 0.1.26 → 0.1.31
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/.cursor/manifest.md +98 -0
- package/.env +92 -0
- package/README.md +238 -471
- package/dist/apiClient.js.map +1 -0
- package/dist/apiMethods/assetMethods.js +38 -38
- package/dist/apiMethods/assetMethods.js.map +1 -0
- package/dist/apiMethods/batchMethods.d.ts +32 -1
- package/dist/apiMethods/batchMethods.js +239 -9
- package/dist/apiMethods/batchMethods.js.map +1 -0
- package/dist/apiMethods/clientInstance.d.ts +1 -1
- package/dist/apiMethods/clientInstance.js +12 -11
- package/dist/apiMethods/clientInstance.js.map +1 -0
- package/dist/apiMethods/containerMethods.d.ts +8 -1
- package/dist/apiMethods/containerMethods.js +27 -20
- package/dist/apiMethods/containerMethods.js.map +1 -0
- package/dist/apiMethods/contentMethods.d.ts +8 -8
- package/dist/apiMethods/contentMethods.js +100 -68
- package/dist/apiMethods/contentMethods.js.map +1 -0
- package/dist/apiMethods/instanceMethods.js +3 -3
- package/dist/apiMethods/instanceMethods.js.map +1 -0
- package/dist/apiMethods/instanceUserMethods.js +10 -10
- package/dist/apiMethods/instanceUserMethods.js.map +1 -0
- package/dist/apiMethods/modelMethods.js +13 -13
- package/dist/apiMethods/modelMethods.js.map +1 -0
- package/dist/apiMethods/pageMethods.d.ts +7 -7
- package/dist/apiMethods/pageMethods.js +98 -67
- package/dist/apiMethods/pageMethods.js.map +1 -0
- package/dist/apiMethods/serverUserMethods.js +4 -4
- package/dist/apiMethods/serverUserMethods.js.map +1 -0
- package/dist/apiMethods/webhookMethods.js +11 -11
- package/dist/apiMethods/webhookMethods.js.map +1 -0
- package/dist/enums/assetGroupingType.js +1 -1
- package/dist/enums/assetGroupingType.js.map +1 -0
- package/dist/enums/batchItemType.d.ts +7 -0
- package/dist/enums/batchItemType.js +11 -0
- package/dist/enums/batchOperationType.js +1 -1
- package/dist/enums/batchOperationType.js.map +1 -0
- package/dist/enums/batchState..js +1 -1
- package/dist/enums/batchState.d.ts +7 -0
- package/dist/enums/batchState.js +12 -0
- package/dist/enums/batchState.js.map +1 -0
- package/dist/enums/pageItemTemplateType.js +1 -1
- package/dist/enums/pageItemTemplateType.js.map +1 -0
- package/dist/enums/workflowOperationType.d.ts +26 -0
- package/dist/enums/workflowOperationType.js +30 -0
- package/dist/errors/exception.d.ts +4 -0
- package/dist/errors/exception.js +11 -0
- package/dist/errors/exception.js.map +1 -0
- package/dist/index.d.ts +6 -0
- package/dist/index.js +11 -1
- package/dist/index.js.map +1 -0
- package/dist/models/batchItem.d.ts +1 -0
- package/dist/models/batchRequests.d.ts +67 -0
- package/dist/models/batchRequests.js +2 -0
- package/dist/models/batchTypes.d.ts +34 -0
- package/dist/models/batchTypes.js +2 -0
- package/dist/models/container.d.ts +2 -1
- package/dist/models/contentDefinitionTypeID.d.ts +17 -0
- package/dist/models/contentDefinitionTypeID.js +21 -0
- package/dist/models/exception.js +2 -0
- package/dist/models/locales.js +2 -0
- package/dist/tests/authHelper.d.ts +2 -0
- package/dist/tests/authHelper.js +14 -0
- package/dist/tests/authHelper.js.map +1 -0
- package/dist/tests/config/apiClient.config.d.ts +16 -0
- package/dist/tests/config/apiClient.config.js +84 -0
- package/dist/tests/config/apiClient.config.js.map +1 -0
- package/dist/tests/config/test.config.d.ts +24 -0
- package/dist/tests/config/test.config.js +47 -0
- package/dist/tests/config/test.config.js.map +1 -0
- package/dist/types/apiResponse.d.ts +13 -0
- package/dist/types/apiResponse.js +3 -0
- package/dist/types/apiResponse.js.map +1 -0
- package/dist/types/assetContainer.d.ts +7 -0
- package/dist/types/assetContainer.js +3 -0
- package/dist/types/assetContainer.js.map +1 -0
- package/dist/types/assetGalleries.d.ts +5 -0
- package/dist/types/assetGalleries.js +3 -0
- package/dist/types/assetGalleries.js.map +1 -0
- package/dist/types/assetMediaGrouping.d.ts +17 -0
- package/dist/types/assetMediaGrouping.js +3 -0
- package/dist/types/assetMediaGrouping.js.map +1 -0
- package/dist/types/assetMediaGroupingMetaData.d.ts +4 -0
- package/dist/types/assetMediaGroupingMetaData.js +3 -0
- package/dist/types/assetMediaGroupingMetaData.js.map +1 -0
- package/dist/types/batch.d.ts +29 -0
- package/dist/types/batch.js +3 -0
- package/dist/types/batch.js.map +1 -0
- package/dist/types/batchItem.d.ts +13 -0
- package/dist/types/batchItem.js +3 -0
- package/dist/types/batchItem.js.map +1 -0
- package/dist/types/container.d.ts +47 -0
- package/dist/types/container.js +3 -0
- package/dist/types/container.js.map +1 -0
- package/dist/types/contentItem.d.ts +37 -0
- package/dist/types/contentItem.js +3 -0
- package/dist/types/contentItem.js.map +1 -0
- package/dist/types/contentItemHistory.d.ts +20 -0
- package/dist/types/contentItemHistory.js +3 -0
- package/dist/types/contentItemHistory.js.map +1 -0
- package/dist/types/contentListFilterModel.d.ts +26 -0
- package/dist/types/contentListFilterModel.js +3 -0
- package/dist/types/contentListFilterModel.js.map +1 -0
- package/dist/types/contentSectionDefaultModule.d.ts +7 -0
- package/dist/types/contentSectionDefaultModule.js +3 -0
- package/dist/types/contentSectionDefaultModule.js.map +1 -0
- package/dist/types/contentSectionDefinition.d.ts +35 -0
- package/dist/types/contentSectionDefinition.js +3 -0
- package/dist/types/contentSectionDefinition.js.map +1 -0
- package/dist/types/contentViewColumn.d.ts +8 -0
- package/dist/types/contentViewColumn.js +3 -0
- package/dist/types/contentViewColumn.js.map +1 -0
- package/dist/types/instanceRole.d.ts +7 -0
- package/dist/types/instanceRole.js +3 -0
- package/dist/types/instanceRole.js.map +1 -0
- package/dist/types/instanceUser.d.ts +14 -0
- package/dist/types/instanceUser.js +3 -0
- package/dist/types/instanceUser.js.map +1 -0
- package/dist/types/itemComments.d.ts +14 -0
- package/dist/types/itemComments.js +3 -0
- package/dist/types/itemComments.js.map +1 -0
- package/dist/types/listParams.d.ts +9 -0
- package/dist/types/listParams.js +3 -0
- package/dist/types/listParams.js.map +1 -0
- package/dist/types/locales.d.ts +1 -0
- package/dist/types/locales.js +3 -0
- package/dist/types/locales.js.map +1 -0
- package/dist/types/media.d.ts +30 -0
- package/dist/types/media.js +3 -0
- package/dist/types/media.js.map +1 -0
- package/dist/types/model.d.ts +30 -0
- package/dist/types/model.js +3 -0
- package/dist/types/model.js.map +1 -0
- package/dist/types/notification.d.ts +13 -0
- package/dist/types/notification.js +3 -0
- package/dist/types/notification.js.map +1 -0
- package/dist/types/options.d.ts +7 -0
- package/dist/types/options.js +3 -0
- package/dist/types/options.js.map +1 -0
- package/dist/types/pageHistory.d.ts +21 -0
- package/dist/types/pageHistory.js +3 -0
- package/dist/types/pageHistory.js.map +1 -0
- package/dist/types/pageItem.d.ts +56 -0
- package/dist/types/pageItem.js +3 -0
- package/dist/types/pageItem.js.map +1 -0
- package/dist/types/pageModel.d.ts +14 -0
- package/dist/types/pageModel.js +3 -0
- package/dist/types/pageModel.js.map +1 -0
- package/dist/types/serverUser.d.ts +21 -0
- package/dist/types/serverUser.js +3 -0
- package/dist/types/serverUser.js.map +1 -0
- package/dist/types/sharedModule.d.ts +7 -0
- package/dist/types/sharedModule.js +3 -0
- package/dist/types/sharedModule.js.map +1 -0
- package/dist/types/sitemap.d.ts +20 -0
- package/dist/types/sitemap.js +3 -0
- package/dist/types/sitemap.js.map +1 -0
- package/dist/types/tokenResponseData.d.ts +10 -0
- package/dist/types/tokenResponseData.js +3 -0
- package/dist/types/tokenResponseData.js.map +1 -0
- package/dist/types/webhook.d.ts +9 -0
- package/dist/types/webhook.js +3 -0
- package/dist/types/webhook.js.map +1 -0
- package/dist/types/websiteListing.d.ts +16 -0
- package/dist/types/websiteListing.js +3 -0
- package/dist/types/websiteListing.js.map +1 -0
- package/dist/types/websiteUser.d.ts +22 -0
- package/dist/types/websiteUser.js +3 -0
- package/dist/types/websiteUser.js.map +1 -0
- package/package.json +1 -1
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.BatchItemType = void 0;
|
|
4
|
+
var BatchItemType;
|
|
5
|
+
(function (BatchItemType) {
|
|
6
|
+
BatchItemType[BatchItemType["Page"] = 1] = "Page";
|
|
7
|
+
BatchItemType[BatchItemType["ContentItem"] = 2] = "ContentItem";
|
|
8
|
+
BatchItemType[BatchItemType["ContentList"] = 3] = "ContentList";
|
|
9
|
+
BatchItemType[BatchItemType["Tag"] = 4] = "Tag";
|
|
10
|
+
BatchItemType[BatchItemType["ModuleDef"] = 5] = "ModuleDef";
|
|
11
|
+
})(BatchItemType || (exports.BatchItemType = BatchItemType = {}));
|
|
@@ -20,4 +20,4 @@ var BatchOperationType;
|
|
|
20
20
|
BatchOperationType[BatchOperationType["DeleteContent"] = 15] = "DeleteContent";
|
|
21
21
|
BatchOperationType[BatchOperationType["SavePage"] = 16] = "SavePage";
|
|
22
22
|
BatchOperationType[BatchOperationType["DeletePage"] = 17] = "DeletePage";
|
|
23
|
-
})(BatchOperationType
|
|
23
|
+
})(BatchOperationType || (exports.BatchOperationType = BatchOperationType = {}));
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"batchOperationType.js","sourceRoot":"","sources":["../../src/enums/batchOperationType.ts"],"names":[],"mappings":";;;AAAA,IAAY,kBAkBX;AAlBD,WAAY,kBAAkB;IAC1B,iEAAW,CAAA;IACX,qEAAa,CAAA;IACb,iEAAW,CAAA;IACX,iEAAW,CAAA;IACX,iFAAmB,CAAA;IACnB,2DAAQ,CAAA;IACR,qFAAqB,CAAA;IACrB,2DAAQ,CAAA;IACR,qEAAa,CAAA;IACb,sEAAc,CAAA;IACd,8EAAkB,CAAA;IAClB,8EAAkB,CAAA;IAClB,gGAA2B,CAAA;IAC3B,8EAAkB,CAAA;IAClB,8EAAkB,CAAA;IAClB,oEAAa,CAAA;IACb,wEAAe,CAAA;AACnB,CAAC,EAlBW,kBAAkB,kCAAlB,kBAAkB,QAkB7B"}
|
|
@@ -8,4 +8,4 @@ var BatchState;
|
|
|
8
8
|
BatchState[BatchState["InProcess"] = 2] = "InProcess";
|
|
9
9
|
BatchState[BatchState["Processed"] = 3] = "Processed";
|
|
10
10
|
BatchState[BatchState["Deleted"] = 4] = "Deleted";
|
|
11
|
-
})(BatchState
|
|
11
|
+
})(BatchState || (exports.BatchState = BatchState = {}));
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.BatchState = void 0;
|
|
4
|
+
var BatchState;
|
|
5
|
+
(function (BatchState) {
|
|
6
|
+
BatchState[BatchState["None"] = 0] = "None";
|
|
7
|
+
BatchState[BatchState["Pending"] = 1] = "Pending";
|
|
8
|
+
BatchState[BatchState["InProcess"] = 2] = "InProcess";
|
|
9
|
+
BatchState[BatchState["Processed"] = 3] = "Processed";
|
|
10
|
+
BatchState[BatchState["Deleted"] = 4] = "Deleted";
|
|
11
|
+
})(BatchState || (exports.BatchState = BatchState = {}));
|
|
12
|
+
//# sourceMappingURL=batchState.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"batchState.js","sourceRoot":"","sources":["../../src/enums/batchState.ts"],"names":[],"mappings":";;;AAAA,IAAY,UAMX;AAND,WAAY,UAAU;IAClB,2CAAQ,CAAA;IACR,iDAAW,CAAA;IACX,qDAAa,CAAA;IACb,qDAAa,CAAA;IACb,iDAAW,CAAA;AACf,CAAC,EANW,UAAU,0BAAV,UAAU,QAMrB"}
|
|
@@ -5,4 +5,4 @@ var PageItemTemplateType;
|
|
|
5
5
|
(function (PageItemTemplateType) {
|
|
6
6
|
PageItemTemplateType[PageItemTemplateType["Variable"] = 0] = "Variable";
|
|
7
7
|
PageItemTemplateType[PageItemTemplateType["FixedModule"] = 1] = "FixedModule";
|
|
8
|
-
})(PageItemTemplateType
|
|
8
|
+
})(PageItemTemplateType || (exports.PageItemTemplateType = PageItemTemplateType = {}));
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"pageItemTemplateType.js","sourceRoot":"","sources":["../../src/enums/pageItemTemplateType.ts"],"names":[],"mappings":";;;AAAA,IAAY,oBAGX;AAHD,WAAY,oBAAoB;IAC5B,uEAAY,CAAA;IACf,6EAAe,CAAA;AAChB,CAAC,EAHW,oBAAoB,oCAApB,oBAAoB,QAG/B"}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Workflow operation types specifically for batch processing.
|
|
3
|
+
* Subset of BatchOperationType containing only workflow-related operations.
|
|
4
|
+
*/
|
|
5
|
+
export declare enum WorkflowOperationType {
|
|
6
|
+
/**
|
|
7
|
+
* Publish the items in the batch.
|
|
8
|
+
*/
|
|
9
|
+
Publish = 1,
|
|
10
|
+
/**
|
|
11
|
+
* Unpublish the items in the batch.
|
|
12
|
+
*/
|
|
13
|
+
Unpublish = 2,
|
|
14
|
+
/**
|
|
15
|
+
* Approve the items in the batch.
|
|
16
|
+
*/
|
|
17
|
+
Approve = 3,
|
|
18
|
+
/**
|
|
19
|
+
* Decline the items in the batch.
|
|
20
|
+
*/
|
|
21
|
+
Decline = 4,
|
|
22
|
+
/**
|
|
23
|
+
* Request approval for the items in the batch.
|
|
24
|
+
*/
|
|
25
|
+
RequestApproval = 5
|
|
26
|
+
}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.WorkflowOperationType = void 0;
|
|
4
|
+
/**
|
|
5
|
+
* Workflow operation types specifically for batch processing.
|
|
6
|
+
* Subset of BatchOperationType containing only workflow-related operations.
|
|
7
|
+
*/
|
|
8
|
+
var WorkflowOperationType;
|
|
9
|
+
(function (WorkflowOperationType) {
|
|
10
|
+
/**
|
|
11
|
+
* Publish the items in the batch.
|
|
12
|
+
*/
|
|
13
|
+
WorkflowOperationType[WorkflowOperationType["Publish"] = 1] = "Publish";
|
|
14
|
+
/**
|
|
15
|
+
* Unpublish the items in the batch.
|
|
16
|
+
*/
|
|
17
|
+
WorkflowOperationType[WorkflowOperationType["Unpublish"] = 2] = "Unpublish";
|
|
18
|
+
/**
|
|
19
|
+
* Approve the items in the batch.
|
|
20
|
+
*/
|
|
21
|
+
WorkflowOperationType[WorkflowOperationType["Approve"] = 3] = "Approve";
|
|
22
|
+
/**
|
|
23
|
+
* Decline the items in the batch.
|
|
24
|
+
*/
|
|
25
|
+
WorkflowOperationType[WorkflowOperationType["Decline"] = 4] = "Decline";
|
|
26
|
+
/**
|
|
27
|
+
* Request approval for the items in the batch.
|
|
28
|
+
*/
|
|
29
|
+
WorkflowOperationType[WorkflowOperationType["RequestApproval"] = 5] = "RequestApproval";
|
|
30
|
+
})(WorkflowOperationType || (exports.WorkflowOperationType = WorkflowOperationType = {}));
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.Exception = void 0;
|
|
4
|
+
class Exception extends Error {
|
|
5
|
+
constructor(message, inner) {
|
|
6
|
+
super(message);
|
|
7
|
+
this.innerError = inner;
|
|
8
|
+
}
|
|
9
|
+
}
|
|
10
|
+
exports.Exception = Exception;
|
|
11
|
+
//# sourceMappingURL=exception.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"exception.js","sourceRoot":"","sources":["../../src/errors/exception.ts"],"names":[],"mappings":";;;AAAA,MAAa,SAAU,SAAQ,KAAK;IAEnC,YAAY,OAAe,EAAE,KAAa;QACzC,KAAK,CAAC,OAAO,CAAC,CAAA;QACd,IAAI,CAAC,UAAU,GAAG,KAAK,CAAA;IACxB,CAAC;CAGD;AARD,8BAQC"}
|
package/dist/index.d.ts
CHANGED
|
@@ -1,7 +1,9 @@
|
|
|
1
1
|
export * from "./models/options";
|
|
2
2
|
export * from "./models/batch";
|
|
3
3
|
export * from "./models/batchItem";
|
|
4
|
+
export * from "./models/batchTypes";
|
|
4
5
|
export * from "./models/container";
|
|
6
|
+
export * from "./models/contentDefinitionTypeID";
|
|
5
7
|
export * from "./models/contentItem";
|
|
6
8
|
export * from "./models/contentViewColumn";
|
|
7
9
|
export * from "./models/instanceRole";
|
|
@@ -21,4 +23,8 @@ export * from "./models/contentSectionDefaultModule";
|
|
|
21
23
|
export * from "./models/contentSectionDefinition";
|
|
22
24
|
export * from "./models/sharedModule";
|
|
23
25
|
export * from "./models/pageModel";
|
|
26
|
+
export * from "./enums/batchOperationType";
|
|
27
|
+
export * from "./enums/workflowOperationType";
|
|
28
|
+
export * from "./enums/batchState.";
|
|
29
|
+
export * from "./enums/batchItemType";
|
|
24
30
|
export * from "./apiClient";
|
package/dist/index.js
CHANGED
|
@@ -1,7 +1,11 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
3
|
if (k2 === undefined) k2 = k;
|
|
4
|
-
Object.
|
|
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);
|
|
5
9
|
}) : (function(o, m, k, k2) {
|
|
6
10
|
if (k2 === undefined) k2 = k;
|
|
7
11
|
o[k2] = m[k];
|
|
@@ -13,7 +17,9 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
13
17
|
__exportStar(require("./models/options"), exports);
|
|
14
18
|
__exportStar(require("./models/batch"), exports);
|
|
15
19
|
__exportStar(require("./models/batchItem"), exports);
|
|
20
|
+
__exportStar(require("./models/batchTypes"), exports);
|
|
16
21
|
__exportStar(require("./models/container"), exports);
|
|
22
|
+
__exportStar(require("./models/contentDefinitionTypeID"), exports);
|
|
17
23
|
__exportStar(require("./models/contentItem"), exports);
|
|
18
24
|
__exportStar(require("./models/contentViewColumn"), exports);
|
|
19
25
|
__exportStar(require("./models/instanceRole"), exports);
|
|
@@ -33,4 +39,8 @@ __exportStar(require("./models/contentSectionDefaultModule"), exports);
|
|
|
33
39
|
__exportStar(require("./models/contentSectionDefinition"), exports);
|
|
34
40
|
__exportStar(require("./models/sharedModule"), exports);
|
|
35
41
|
__exportStar(require("./models/pageModel"), exports);
|
|
42
|
+
__exportStar(require("./enums/batchOperationType"), exports);
|
|
43
|
+
__exportStar(require("./enums/workflowOperationType"), exports);
|
|
44
|
+
__exportStar(require("./enums/batchState."), exports);
|
|
45
|
+
__exportStar(require("./enums/batchItemType"), exports);
|
|
36
46
|
__exportStar(require("./apiClient"), exports);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,kDAAgC;AAChC,gDAA8B;AAC9B,oDAAkC;AAClC,oDAAkC;AAClC,sDAAoC;AACpC,4DAA0C;AAC1C,uDAAqC;AACrC,kDAAgC;AAChC,uDAAqC;AACrC,gDAA8B;AAC9B,gDAA8B;AAC9B,uDAAqC;AACrC,mDAAiC;AACjC,kDAAgC;AAChC,sDAAoC;AACpC,yDAAuC;AACvC,yDAAuC;AACvC,6DAA2C;AAC3C,qEAAmD;AACnD,sEAAoD;AACpD,mEAAiD;AACjD,uDAAqC;AACrC,oDAAkC;AAClC,qDAAmC;AACnC,8CAA4B"}
|
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
import { BatchOperationType } from "../enums/batchOperationType";
|
|
2
|
+
import { BatchItemType } from "../enums/batchItemType";
|
|
3
|
+
/**
|
|
4
|
+
* Request model for creating a new batch.
|
|
5
|
+
*/
|
|
6
|
+
export interface CreateBatchRequest {
|
|
7
|
+
/**
|
|
8
|
+
* Custom name for the batch. If not provided, defaults to "Custom Batch".
|
|
9
|
+
*/
|
|
10
|
+
batchName?: string;
|
|
11
|
+
/**
|
|
12
|
+
* Default operation type for the batch.
|
|
13
|
+
* If not provided, defaults to Publish (1).
|
|
14
|
+
*/
|
|
15
|
+
operationType?: BatchOperationType;
|
|
16
|
+
/**
|
|
17
|
+
* Whether the batch should be private (visible only to the creator).
|
|
18
|
+
* If not provided, defaults to true.
|
|
19
|
+
*/
|
|
20
|
+
isPrivate?: boolean;
|
|
21
|
+
/**
|
|
22
|
+
* Optional comments or notes about the batch.
|
|
23
|
+
*/
|
|
24
|
+
comments?: string;
|
|
25
|
+
}
|
|
26
|
+
/**
|
|
27
|
+
* Request model for adding a reference to an existing item to a batch.
|
|
28
|
+
*/
|
|
29
|
+
export interface AddBatchItemRequest {
|
|
30
|
+
/**
|
|
31
|
+
* The type of item to add to the batch.
|
|
32
|
+
*/
|
|
33
|
+
itemType: BatchItemType;
|
|
34
|
+
/**
|
|
35
|
+
* The ID of the existing item to add to the batch.
|
|
36
|
+
* For Content Items: use the ContentID of an existing content item
|
|
37
|
+
* For Page Items: use the PageID of an existing page
|
|
38
|
+
*/
|
|
39
|
+
itemID: number;
|
|
40
|
+
/**
|
|
41
|
+
* The language code for the item (e.g., "en-us", "fr-ca", "es-mx").
|
|
42
|
+
*/
|
|
43
|
+
languageCode: string;
|
|
44
|
+
/**
|
|
45
|
+
* Optional display title for the item in the batch for identification purposes.
|
|
46
|
+
*/
|
|
47
|
+
itemTitle?: string;
|
|
48
|
+
}
|
|
49
|
+
/**
|
|
50
|
+
* Request model for adding multiple items to a batch at once.
|
|
51
|
+
*/
|
|
52
|
+
export interface AddBatchItemsRequest {
|
|
53
|
+
/**
|
|
54
|
+
* Array of items to add to the batch.
|
|
55
|
+
* Each item must reference an existing content item or page in your CMS.
|
|
56
|
+
*/
|
|
57
|
+
items: AddBatchItemRequest[];
|
|
58
|
+
}
|
|
59
|
+
/**
|
|
60
|
+
* Request model for processing a batch with optional comments.
|
|
61
|
+
*/
|
|
62
|
+
export interface ProcessBatchRequest {
|
|
63
|
+
/**
|
|
64
|
+
* Optional comments for the batch operation (for audit trail).
|
|
65
|
+
*/
|
|
66
|
+
comments?: string;
|
|
67
|
+
}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Response model containing all batch-related enum types for developer discovery.
|
|
3
|
+
*/
|
|
4
|
+
export interface BatchTypesResponse {
|
|
5
|
+
/**
|
|
6
|
+
* Available item types that can be added to batches.
|
|
7
|
+
*/
|
|
8
|
+
itemTypes: EnumInfo[];
|
|
9
|
+
/**
|
|
10
|
+
* All available batch operation types (includes workflow and other operations).
|
|
11
|
+
*/
|
|
12
|
+
operationTypes: EnumInfo[];
|
|
13
|
+
/**
|
|
14
|
+
* Workflow-specific operation types (subset of operationTypes).
|
|
15
|
+
*/
|
|
16
|
+
workflowOperations: EnumInfo[];
|
|
17
|
+
/**
|
|
18
|
+
* Available batch states during lifecycle.
|
|
19
|
+
*/
|
|
20
|
+
states: EnumInfo[];
|
|
21
|
+
}
|
|
22
|
+
/**
|
|
23
|
+
* Information about an enum value including value and name.
|
|
24
|
+
*/
|
|
25
|
+
export interface EnumInfo {
|
|
26
|
+
/**
|
|
27
|
+
* The numeric value of the enum.
|
|
28
|
+
*/
|
|
29
|
+
value: number;
|
|
30
|
+
/**
|
|
31
|
+
* The string name of the enum value (e.g., "ContentItem", "Publish").
|
|
32
|
+
*/
|
|
33
|
+
name: string;
|
|
34
|
+
}
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { ContentViewColumn } from "./contentViewColumn";
|
|
2
|
+
import { ContentDefinitionTypeID } from "./contentDefinitionTypeID";
|
|
2
3
|
export declare class Container {
|
|
3
4
|
columns: ContentViewColumn[];
|
|
4
5
|
contentViewID: number | null;
|
|
@@ -30,7 +31,7 @@ export declare class Container {
|
|
|
30
31
|
enableAPIOutput: boolean | null;
|
|
31
32
|
commentsRecordTypeName: string | null;
|
|
32
33
|
numRowsInListing: number | null;
|
|
33
|
-
contentDefinitionTypeID:
|
|
34
|
+
contentDefinitionTypeID: ContentDefinitionTypeID | null;
|
|
34
35
|
fullSyncModDate: string | null;
|
|
35
36
|
confirmSharingOnPublish: boolean | null;
|
|
36
37
|
contentTemplateName: string | null;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Enum representing the content definition type ID values in Agility CMS
|
|
3
|
+
*/
|
|
4
|
+
export declare enum ContentDefinitionTypeID {
|
|
5
|
+
/**
|
|
6
|
+
* List type content definition (0)
|
|
7
|
+
*/
|
|
8
|
+
List = 0,
|
|
9
|
+
/**
|
|
10
|
+
* Single item type content definition (1)
|
|
11
|
+
*/
|
|
12
|
+
SingleItem = 1,
|
|
13
|
+
/**
|
|
14
|
+
* Component type content definition (2)
|
|
15
|
+
*/
|
|
16
|
+
Component = 2
|
|
17
|
+
}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.ContentDefinitionTypeID = void 0;
|
|
4
|
+
/**
|
|
5
|
+
* Enum representing the content definition type ID values in Agility CMS
|
|
6
|
+
*/
|
|
7
|
+
var ContentDefinitionTypeID;
|
|
8
|
+
(function (ContentDefinitionTypeID) {
|
|
9
|
+
/**
|
|
10
|
+
* List type content definition (0)
|
|
11
|
+
*/
|
|
12
|
+
ContentDefinitionTypeID[ContentDefinitionTypeID["List"] = 0] = "List";
|
|
13
|
+
/**
|
|
14
|
+
* Single item type content definition (1)
|
|
15
|
+
*/
|
|
16
|
+
ContentDefinitionTypeID[ContentDefinitionTypeID["SingleItem"] = 1] = "SingleItem";
|
|
17
|
+
/**
|
|
18
|
+
* Component type content definition (2)
|
|
19
|
+
*/
|
|
20
|
+
ContentDefinitionTypeID[ContentDefinitionTypeID["Component"] = 2] = "Component";
|
|
21
|
+
})(ContentDefinitionTypeID || (exports.ContentDefinitionTypeID = ContentDefinitionTypeID = {}));
|
package/dist/models/exception.js
CHANGED
|
@@ -7,6 +7,8 @@ var __extends = (this && this.__extends) || (function () {
|
|
|
7
7
|
return extendStatics(d, b);
|
|
8
8
|
};
|
|
9
9
|
return function (d, b) {
|
|
10
|
+
if (typeof b !== "function" && b !== null)
|
|
11
|
+
throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
|
|
10
12
|
extendStatics(d, b);
|
|
11
13
|
function __() { this.constructor = d; }
|
|
12
14
|
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
package/dist/models/locales.js
CHANGED
|
@@ -7,6 +7,8 @@ var __extends = (this && this.__extends) || (function () {
|
|
|
7
7
|
return extendStatics(d, b);
|
|
8
8
|
};
|
|
9
9
|
return function (d, b) {
|
|
10
|
+
if (typeof b !== "function" && b !== null)
|
|
11
|
+
throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
|
|
10
12
|
extendStatics(d, b);
|
|
11
13
|
function __() { this.constructor = d; }
|
|
12
14
|
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.getTestOptions = void 0;
|
|
4
|
+
const getTestOptions = () => {
|
|
5
|
+
return {
|
|
6
|
+
token: process.env.AGILITY_API_TOKEN || 'test-token',
|
|
7
|
+
baseUrl: process.env.AGILITY_API_URL || 'https://api.agilitycms.com',
|
|
8
|
+
refresh_token: process.env.AGILITY_REFRESH_TOKEN || 'test-refresh-token',
|
|
9
|
+
duration: 3000,
|
|
10
|
+
retryCount: 500
|
|
11
|
+
};
|
|
12
|
+
};
|
|
13
|
+
exports.getTestOptions = getTestOptions;
|
|
14
|
+
//# sourceMappingURL=authHelper.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"authHelper.js","sourceRoot":"","sources":["../../src/tests/authHelper.ts"],"names":[],"mappings":";;;AAEO,MAAM,cAAc,GAAG,GAAY,EAAE;IAC1C,OAAO;QACL,KAAK,EAAE,OAAO,CAAC,GAAG,CAAC,iBAAiB,IAAI,YAAY;QACpD,OAAO,EAAE,OAAO,CAAC,GAAG,CAAC,eAAe,IAAI,4BAA4B;QACpE,aAAa,EAAE,OAAO,CAAC,GAAG,CAAC,qBAAqB,IAAI,oBAAoB;QACxE,QAAQ,EAAE,IAAI;QACd,UAAU,EAAE,GAAG;KAChB,CAAC;AACJ,CAAC,CAAC;AARW,QAAA,cAAc,kBAQzB"}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { ClientInstance } from '../../apiMethods/clientInstance';
|
|
2
|
+
export declare class ApiClientConfig {
|
|
3
|
+
private static instance;
|
|
4
|
+
private testConfig;
|
|
5
|
+
private _mgmtApiClient;
|
|
6
|
+
private tableClient;
|
|
7
|
+
private constructor();
|
|
8
|
+
static getInstance(): ApiClientConfig;
|
|
9
|
+
private getTableClient;
|
|
10
|
+
private getCurrentToken;
|
|
11
|
+
private getAuthorizationToken;
|
|
12
|
+
createManagementSdkClient(): Promise<{
|
|
13
|
+
apiClient: ClientInstance;
|
|
14
|
+
guid: string;
|
|
15
|
+
}>;
|
|
16
|
+
}
|
|
@@ -0,0 +1,84 @@
|
|
|
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.ApiClientConfig = void 0;
|
|
7
|
+
const test_config_1 = require("./test.config");
|
|
8
|
+
const clientInstance_1 = require("../../apiMethods/clientInstance");
|
|
9
|
+
const data_tables_1 = require("@azure/data-tables");
|
|
10
|
+
const axios_1 = __importDefault(require("axios"));
|
|
11
|
+
const form_data_1 = __importDefault(require("form-data"));
|
|
12
|
+
class ApiClientConfig {
|
|
13
|
+
constructor() {
|
|
14
|
+
this._mgmtApiClient = null;
|
|
15
|
+
this.tableClient = null;
|
|
16
|
+
this.testConfig = test_config_1.TestConfiguration.getInstance();
|
|
17
|
+
}
|
|
18
|
+
static getInstance() {
|
|
19
|
+
if (!ApiClientConfig.instance) {
|
|
20
|
+
ApiClientConfig.instance = new ApiClientConfig();
|
|
21
|
+
}
|
|
22
|
+
return ApiClientConfig.instance;
|
|
23
|
+
}
|
|
24
|
+
async getTableClient() {
|
|
25
|
+
if (!this.tableClient) {
|
|
26
|
+
const azureConfig = this.testConfig.getAzureConfig();
|
|
27
|
+
const credentials = new data_tables_1.AzureNamedKeyCredential(azureConfig.storageAccount, azureConfig.storageAccountKey);
|
|
28
|
+
this.tableClient = new data_tables_1.TableClient(`https://${azureConfig.storageAccount}.table.core.windows.net`, azureConfig.storageAccountTable, credentials);
|
|
29
|
+
}
|
|
30
|
+
return this.tableClient;
|
|
31
|
+
}
|
|
32
|
+
async getCurrentToken(partitionKey, rowKey) {
|
|
33
|
+
try {
|
|
34
|
+
const tableClient = await this.getTableClient();
|
|
35
|
+
const tokenInfo = await tableClient.getEntity(partitionKey, rowKey);
|
|
36
|
+
return tokenInfo;
|
|
37
|
+
}
|
|
38
|
+
catch (err) {
|
|
39
|
+
return null;
|
|
40
|
+
}
|
|
41
|
+
}
|
|
42
|
+
async getAuthorizationToken() {
|
|
43
|
+
const rowKey = process.env.TEST_ENV === "dev" ? "dev" : "prod";
|
|
44
|
+
const partitionKey = 'Integration-Test';
|
|
45
|
+
const currentToken = await this.getCurrentToken(partitionKey, rowKey);
|
|
46
|
+
if (!currentToken) {
|
|
47
|
+
throw new Error('No current token found');
|
|
48
|
+
}
|
|
49
|
+
const form = new form_data_1.default();
|
|
50
|
+
form.append("refresh_token", currentToken.refresh_token);
|
|
51
|
+
const config = this.testConfig.getConfig();
|
|
52
|
+
const apiPath = `${config.managementApiBaseUrl}/oauth/refresh`;
|
|
53
|
+
const resp = await axios_1.default.post(apiPath, form, {
|
|
54
|
+
headers: {
|
|
55
|
+
'Cache-Control': 'no-cache'
|
|
56
|
+
}
|
|
57
|
+
});
|
|
58
|
+
const tokenInfo = resp.data;
|
|
59
|
+
tokenInfo.partitionKey = partitionKey;
|
|
60
|
+
tokenInfo.rowKey = rowKey;
|
|
61
|
+
const tableClient = await this.getTableClient();
|
|
62
|
+
await tableClient.updateEntity(tokenInfo);
|
|
63
|
+
return tokenInfo;
|
|
64
|
+
}
|
|
65
|
+
async createManagementSdkClient() {
|
|
66
|
+
if (!this._mgmtApiClient) {
|
|
67
|
+
const config = this.testConfig.getConfig();
|
|
68
|
+
const authToken = await this.getAuthorizationToken();
|
|
69
|
+
const mgmtOpt = {
|
|
70
|
+
token: authToken.access_token,
|
|
71
|
+
baseUrl: config.managementApiBaseUrl,
|
|
72
|
+
refresh_token: authToken.refresh_token
|
|
73
|
+
// duration and retryCount are optional and will be undefined
|
|
74
|
+
};
|
|
75
|
+
this._mgmtApiClient = new clientInstance_1.ClientInstance(mgmtOpt);
|
|
76
|
+
}
|
|
77
|
+
return {
|
|
78
|
+
apiClient: this._mgmtApiClient,
|
|
79
|
+
guid: this.testConfig.getConfig().guid
|
|
80
|
+
};
|
|
81
|
+
}
|
|
82
|
+
}
|
|
83
|
+
exports.ApiClientConfig = ApiClientConfig;
|
|
84
|
+
//# sourceMappingURL=apiClient.config.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"apiClient.config.js","sourceRoot":"","sources":["../../../src/tests/config/apiClient.config.ts"],"names":[],"mappings":";;;;;;AAAA,+CAAkD;AAElD,oEAAiE;AACjE,oDAA0E;AAC1E,kDAA0B;AAC1B,0DAAiC;AAEjC,MAAa,eAAe;IAMxB;QAHQ,mBAAc,GAA0B,IAAI,CAAC;QAC7C,gBAAW,GAAuB,IAAI,CAAC;QAG3C,IAAI,CAAC,UAAU,GAAG,+BAAiB,CAAC,WAAW,EAAE,CAAC;IACtD,CAAC;IAEM,MAAM,CAAC,WAAW;QACrB,IAAI,CAAC,eAAe,CAAC,QAAQ,EAAE,CAAC;YAC5B,eAAe,CAAC,QAAQ,GAAG,IAAI,eAAe,EAAE,CAAC;QACrD,CAAC;QACD,OAAO,eAAe,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|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
export interface TestConfig {
|
|
2
|
+
guid: string;
|
|
3
|
+
apiKeyFetch: string;
|
|
4
|
+
apiKeyPreview: string;
|
|
5
|
+
websiteName: string;
|
|
6
|
+
securityKey: string;
|
|
7
|
+
contentServerBaseUrl: string;
|
|
8
|
+
fetchApiBaseUrl: string;
|
|
9
|
+
directFetchApiBaseUrl: string;
|
|
10
|
+
managementApiBaseUrl: string;
|
|
11
|
+
}
|
|
12
|
+
export declare class TestConfiguration {
|
|
13
|
+
private static instance;
|
|
14
|
+
private config;
|
|
15
|
+
private constructor();
|
|
16
|
+
static getInstance(): TestConfiguration;
|
|
17
|
+
private loadConfig;
|
|
18
|
+
getConfig(): TestConfig;
|
|
19
|
+
getAzureConfig(): {
|
|
20
|
+
storageAccount: string;
|
|
21
|
+
storageAccountKey: string;
|
|
22
|
+
storageAccountTable: string;
|
|
23
|
+
};
|
|
24
|
+
}
|
|
@@ -0,0 +1,47 @@
|
|
|
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.TestConfiguration = void 0;
|
|
7
|
+
const dotenv_1 = __importDefault(require("dotenv"));
|
|
8
|
+
// Load environment variables from .env file
|
|
9
|
+
dotenv_1.default.config();
|
|
10
|
+
class TestConfiguration {
|
|
11
|
+
constructor() {
|
|
12
|
+
const env = process.env.TEST_ENV || 'dev';
|
|
13
|
+
this.config = this.loadConfig(env);
|
|
14
|
+
}
|
|
15
|
+
static getInstance() {
|
|
16
|
+
if (!TestConfiguration.instance) {
|
|
17
|
+
TestConfiguration.instance = new TestConfiguration();
|
|
18
|
+
}
|
|
19
|
+
return TestConfiguration.instance;
|
|
20
|
+
}
|
|
21
|
+
loadConfig(env) {
|
|
22
|
+
const prefix = env.toUpperCase().replace(/-/g, '_');
|
|
23
|
+
return {
|
|
24
|
+
guid: process.env[`${prefix}_GUID`] || '',
|
|
25
|
+
apiKeyFetch: process.env[`${prefix}_API_KEY_FETCH`] || '',
|
|
26
|
+
apiKeyPreview: process.env[`${prefix}_API_KEY_PREVIEW`] || '',
|
|
27
|
+
websiteName: process.env[`${prefix}_WEBSITE_NAME`] || '',
|
|
28
|
+
securityKey: process.env[`${prefix}_SECURITY_KEY`] || '',
|
|
29
|
+
contentServerBaseUrl: process.env[`${prefix}_CONTENT_SERVER_BASE_URL`] || '',
|
|
30
|
+
fetchApiBaseUrl: process.env[`${prefix}_FETCH_API_BASE_URL`] || '',
|
|
31
|
+
directFetchApiBaseUrl: process.env[`${prefix}_DIRECT_FETCH_API_BASE_URL`] || '',
|
|
32
|
+
managementApiBaseUrl: process.env[`${prefix}_MANAGEMENT_API_BASE_URL`] || ''
|
|
33
|
+
};
|
|
34
|
+
}
|
|
35
|
+
getConfig() {
|
|
36
|
+
return this.config;
|
|
37
|
+
}
|
|
38
|
+
getAzureConfig() {
|
|
39
|
+
return {
|
|
40
|
+
storageAccount: process.env.STORAGE_ACCOUNT || '',
|
|
41
|
+
storageAccountKey: process.env.STORAGE_ACCOUNT_KEY || '',
|
|
42
|
+
storageAccountTable: process.env.STORAGE_ACCOUNT_TABLE || ''
|
|
43
|
+
};
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
|
+
exports.TestConfiguration = TestConfiguration;
|
|
47
|
+
//# sourceMappingURL=test.config.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"test.config.js","sourceRoot":"","sources":["../../../src/tests/config/test.config.ts"],"names":[],"mappings":";;;;;;AAAA,oDAA4B;AAE5B,4CAA4C;AAC5C,gBAAM,CAAC,MAAM,EAAE,CAAC;AAchB,MAAa,iBAAiB;IAI1B;QACI,MAAM,GAAG,GAAG,OAAO,CAAC,GAAG,CAAC,QAAQ,IAAI,KAAK,CAAC;QAC1C,IAAI,CAAC,M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AO;YACH,cAAc,EAAE,OAAO,CAAC,GAAG,CAAC,eAAe,IAAI,EAAE;YACjD,iBAAiB,EAAE,OAAO,CAAC,GAAG,CAAC,mBAAmB,IAAI,EAAE;YACxD,mBAAmB,EAAE,OAAO,CAAC,GAAG,CAAC,qBAAqB,IAAI,EAAE;SAC/D,CAAC;IACN,CAAC;CACJ;AA3CD,8CA2CC"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Represents a generic success or informational message returned by the API.
|
|
3
|
+
*/
|
|
4
|
+
export interface ApiResponseMessage {
|
|
5
|
+
message: string;
|
|
6
|
+
}
|
|
7
|
+
/**
|
|
8
|
+
* Represents the typical response structure for DELETE operations, often empty or just a status.
|
|
9
|
+
* For simplicity, we can often expect an empty object or potentially a simple message.
|
|
10
|
+
*/
|
|
11
|
+
export interface DeleteResponse {
|
|
12
|
+
message?: string;
|
|
13
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"apiResponse.js","sourceRoot":"","sources":["../../src/types/apiResponse.ts"],"names":[],"mappings":""}
|