@remkoj/optimizely-cms-api 5.2.0 → 5.3.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (141) hide show
  1. package/dist/api-client.js +11 -7
  2. package/dist/client/CmsIntegrationApiClient.d.ts +2 -2
  3. package/dist/client/CmsIntegrationApiClient.js +4 -4
  4. package/dist/client/core/OpenAPI.js +2 -2
  5. package/dist/client/index.d.ts +14 -45
  6. package/dist/client/index.js +13 -19
  7. package/dist/client/models/ArrayItem.d.ts +70 -0
  8. package/dist/client/models/ArrayItem.js +25 -0
  9. package/dist/client/models/Blueprint.d.ts +24 -0
  10. package/dist/client/models/BlueprintData.d.ts +11 -0
  11. package/dist/client/models/BlueprintPage.d.ts +19 -0
  12. package/dist/client/models/Changeset.d.ts +3 -3
  13. package/dist/client/models/ChangesetItemPage.d.ts +1 -1
  14. package/dist/client/models/ChangesetPage.d.ts +1 -1
  15. package/dist/client/models/CompositionDisplaySettings.d.ts +13 -0
  16. package/dist/client/models/CompositionNode.d.ts +41 -0
  17. package/dist/client/models/ContentComponent.d.ts +8 -8
  18. package/dist/client/models/ContentItem.d.ts +28 -5
  19. package/dist/client/models/ContentItem.js +17 -0
  20. package/dist/client/models/ContentItemPage.d.ts +1 -1
  21. package/dist/client/models/ContentLocaleInfo.d.ts +13 -2
  22. package/dist/client/models/ContentLocaleInfo.js +12 -0
  23. package/dist/client/models/ContentMetadataPage.d.ts +1 -1
  24. package/dist/client/models/ContentType.d.ts +11 -36
  25. package/dist/client/models/ContentTypePage.d.ts +1 -1
  26. package/dist/client/models/ContentTypeProperty.d.ts +84 -8
  27. package/dist/client/models/ContentTypeProperty.js +34 -0
  28. package/dist/client/models/DisplayTemplate.d.ts +6 -5
  29. package/dist/client/models/DisplayTemplatePage.d.ts +1 -1
  30. package/dist/client/models/EnumerationValue.d.ts +13 -0
  31. package/dist/client/models/ImageDescriptor.d.ts +1 -1
  32. package/dist/client/models/Link.d.ts +21 -0
  33. package/dist/client/models/Preview.d.ts +13 -0
  34. package/dist/client/models/PropertyFormat.d.ts +60 -16
  35. package/dist/client/models/PropertyFormat.js +44 -0
  36. package/dist/client/models/PropertyFormatPage.d.ts +1 -1
  37. package/dist/client/models/PropertyGroup.d.ts +14 -1
  38. package/dist/client/models/PropertyGroupPage.d.ts +1 -1
  39. package/dist/client/services/BlueprintsService.d.ts +56 -0
  40. package/dist/client/services/BlueprintsService.js +135 -0
  41. package/dist/client/services/ChangesetsService.d.ts +32 -30
  42. package/dist/client/services/ChangesetsService.js +73 -60
  43. package/dist/client/services/ContentService.d.ts +46 -35
  44. package/dist/client/services/ContentService.js +100 -55
  45. package/dist/client/services/ContentTypesService.d.ts +17 -23
  46. package/dist/client/services/ContentTypesService.js +34 -41
  47. package/dist/client/services/DisplayTemplatesService.d.ts +14 -18
  48. package/dist/client/services/DisplayTemplatesService.js +31 -31
  49. package/dist/client/services/PropertyFormatsService.d.ts +3 -1
  50. package/dist/client/services/PropertyFormatsService.js +9 -1
  51. package/dist/client/services/PropertyGroupsService.d.ts +15 -20
  52. package/dist/client/services/PropertyGroupsService.js +32 -33
  53. package/dist/enums.d.ts +35 -0
  54. package/dist/enums.js +40 -0
  55. package/dist/getaccesstoken.js +4 -3
  56. package/dist/index.d.ts +1 -0
  57. package/dist/index.js +1 -0
  58. package/dist/version.json +3 -3
  59. package/package.json +2 -2
  60. package/dist/client/models/BinaryProperty.d.ts +0 -8
  61. package/dist/client/models/BooleanProperty.d.ts +0 -5
  62. package/dist/client/models/ComponentListItem.d.ts +0 -10
  63. package/dist/client/models/ComponentProperty.d.ts +0 -10
  64. package/dist/client/models/CompositionBehavior.d.ts +0 -7
  65. package/dist/client/models/CompositionBehavior.js +0 -15
  66. package/dist/client/models/ContentBaseType.d.ts +0 -14
  67. package/dist/client/models/ContentBaseType.js +0 -22
  68. package/dist/client/models/ContentItemListWithContentTypes.d.ts +0 -27
  69. package/dist/client/models/ContentItemWithContentTypes.d.ts +0 -12
  70. package/dist/client/models/ContentListItem.d.ts +0 -14
  71. package/dist/client/models/ContentProperty.d.ts +0 -14
  72. package/dist/client/models/ContentReferenceListItem.d.ts +0 -14
  73. package/dist/client/models/ContentReferenceListItem.js +0 -2
  74. package/dist/client/models/ContentReferenceProperty.d.ts +0 -14
  75. package/dist/client/models/ContentReferenceProperty.js +0 -2
  76. package/dist/client/models/ContentTypeFeature.d.ts +0 -10
  77. package/dist/client/models/ContentTypeFeature.js +0 -18
  78. package/dist/client/models/ContentTypeUsage.d.ts +0 -7
  79. package/dist/client/models/ContentTypeUsage.js +0 -15
  80. package/dist/client/models/DateTimeListItem.d.ts +0 -14
  81. package/dist/client/models/DateTimeListItem.js +0 -2
  82. package/dist/client/models/DateTimeProperty.d.ts +0 -14
  83. package/dist/client/models/DateTimeProperty.js +0 -2
  84. package/dist/client/models/DoubleEnumerationSettings.d.ts +0 -10
  85. package/dist/client/models/DoubleEnumerationSettings.js +0 -2
  86. package/dist/client/models/DoubleEnumerationValue.d.ts +0 -13
  87. package/dist/client/models/DoubleEnumerationValue.js +0 -2
  88. package/dist/client/models/FloatListItem.d.ts +0 -16
  89. package/dist/client/models/FloatListItem.js +0 -2
  90. package/dist/client/models/FloatProperty.d.ts +0 -16
  91. package/dist/client/models/FloatProperty.js +0 -2
  92. package/dist/client/models/IndexingType.d.ts +0 -8
  93. package/dist/client/models/IndexingType.js +0 -16
  94. package/dist/client/models/Int32EnumerationSettings.d.ts +0 -10
  95. package/dist/client/models/Int32EnumerationSettings.js +0 -2
  96. package/dist/client/models/Int32EnumerationValue.d.ts +0 -13
  97. package/dist/client/models/Int32EnumerationValue.js +0 -2
  98. package/dist/client/models/IntegerListItem.d.ts +0 -16
  99. package/dist/client/models/IntegerListItem.js +0 -2
  100. package/dist/client/models/IntegerProperty.d.ts +0 -16
  101. package/dist/client/models/IntegerProperty.js +0 -2
  102. package/dist/client/models/JsonStringProperty.d.ts +0 -5
  103. package/dist/client/models/JsonStringProperty.js +0 -2
  104. package/dist/client/models/ListProperty.d.ts +0 -26
  105. package/dist/client/models/ListProperty.js +0 -2
  106. package/dist/client/models/ListPropertyItem.d.ts +0 -11
  107. package/dist/client/models/ListPropertyItem.js +0 -2
  108. package/dist/client/models/LocaleStatus.d.ts +0 -7
  109. package/dist/client/models/LocaleStatus.js +0 -15
  110. package/dist/client/models/OauthToken.d.ts +0 -18
  111. package/dist/client/models/OauthToken.js +0 -2
  112. package/dist/client/models/OauthTokenError.d.ts +0 -13
  113. package/dist/client/models/OauthTokenError.js +0 -2
  114. package/dist/client/models/OauthTokenRequest.d.ts +0 -21
  115. package/dist/client/models/OauthTokenRequest.js +0 -2
  116. package/dist/client/models/PropertyDataType.d.ts +0 -18
  117. package/dist/client/models/PropertyDataType.js +0 -26
  118. package/dist/client/models/StringEnumerationSettings.d.ts +0 -10
  119. package/dist/client/models/StringEnumerationSettings.js +0 -2
  120. package/dist/client/models/StringEnumerationValue.d.ts +0 -13
  121. package/dist/client/models/StringEnumerationValue.js +0 -2
  122. package/dist/client/models/StringListItem.d.ts +0 -20
  123. package/dist/client/models/StringListItem.js +0 -2
  124. package/dist/client/models/StringProperty.d.ts +0 -20
  125. package/dist/client/models/StringProperty.js +0 -2
  126. package/dist/client/models/UrlListItem.d.ts +0 -5
  127. package/dist/client/models/UrlListItem.js +0 -2
  128. package/dist/client/models/UrlProperty.d.ts +0 -5
  129. package/dist/client/models/UrlProperty.js +0 -2
  130. package/dist/client/models/VersionStatus.d.ts +0 -12
  131. package/dist/client/models/VersionStatus.js +0 -20
  132. package/dist/client/services/OauthService.d.ts +0 -17
  133. package/dist/client/services/OauthService.js +0 -28
  134. /package/dist/client/models/{BinaryProperty.js → Blueprint.js} +0 -0
  135. /package/dist/client/models/{BooleanProperty.js → BlueprintData.js} +0 -0
  136. /package/dist/client/models/{ComponentListItem.js → BlueprintPage.js} +0 -0
  137. /package/dist/client/models/{ComponentProperty.js → CompositionDisplaySettings.js} +0 -0
  138. /package/dist/client/models/{ContentItemListWithContentTypes.js → CompositionNode.js} +0 -0
  139. /package/dist/client/models/{ContentItemWithContentTypes.js → EnumerationValue.js} +0 -0
  140. /package/dist/client/models/{ContentListItem.js → Link.js} +0 -0
  141. /package/dist/client/models/{ContentProperty.js → Preview.js} +0 -0
@@ -8,9 +8,8 @@ class PropertyGroupsService {
8
8
  /**
9
9
  * List property groups
10
10
  * List property groups using the provided options.
11
- * @param sources Indicates which property groups sources that should be listed.
12
- * Use All to include groups from all sources or
13
- * Default to include groups without a specific sources.
11
+ * @param sources Indicates which property groups sources should be listed.
12
+ * Use 'DEFAULT' to include groups without a specific sources.
14
13
  * @returns PropertyGroupPage OK
15
14
  * @throws ApiError
16
15
  */
@@ -30,7 +29,7 @@ class PropertyGroupsService {
30
29
  * Create property group
31
30
  * Create a new property group.
32
31
  * @param requestBody The property group that should be created.
33
- * @returns PropertyGroup OK
32
+ * @returns PropertyGroup Created
34
33
  * @throws ApiError
35
34
  */
36
35
  propertyGroupsCreate(requestBody) {
@@ -49,65 +48,57 @@ class PropertyGroupsService {
49
48
  * Get property group
50
49
  * Get the property group with the provided key.
51
50
  * @param key The key of the property group to retrieve.
51
+ * @param ifNoneMatch If provided and the value matches the RFC7232 ETag of the current resource a 304 NotModified response will be returned. Weak ETags will always be ignored.
52
+ * @param ifModifiedSince If provided and the resource has not been modified since the date a 304 NotModified response will be returned. This parameter will be ignored if an 'If-None-Match' parameter is also provided.
52
53
  * @returns PropertyGroup OK
53
54
  * @throws ApiError
54
55
  */
55
- propertyGroupsGet(key) {
56
+ propertyGroupsGet(key, ifNoneMatch, ifModifiedSince) {
56
57
  return this.httpRequest.request({
57
58
  method: 'GET',
58
59
  url: '/propertygroups/{key}',
59
60
  path: {
60
61
  'key': key,
61
62
  },
62
- errors: {
63
- 403: `Forbidden`,
63
+ headers: {
64
+ 'If-None-Match': ifNoneMatch,
65
+ 'If-Modified-Since': ifModifiedSince,
64
66
  },
65
- });
66
- }
67
- /**
68
- * Create or replace property group
69
- * Create or replace a property group. If a property group with the provided key exist it is replaced.
70
- * Otherwise a new property group is created.
71
- * @param key The key of the property group to update or create.
72
- * @param requestBody The values of the created or replaced property group.
73
- * @returns PropertyGroup OK
74
- * @throws ApiError
75
- */
76
- propertyGroupsPut(key, requestBody) {
77
- return this.httpRequest.request({
78
- method: 'PUT',
79
- url: '/propertygroups/{key}',
80
- path: {
81
- 'key': key,
82
- },
83
- body: requestBody,
84
- mediaType: 'application/json',
85
67
  errors: {
86
- 400: `Bad Request`,
68
+ 304: `Not Modified`,
87
69
  403: `Forbidden`,
70
+ 404: `Not Found`,
88
71
  },
89
72
  });
90
73
  }
91
74
  /**
92
- * Update property group
93
- * Update an existing property group.
75
+ * Patch property group
76
+ * Patch an existing property group.
94
77
  * @param key The key of the property group to patch.
95
- * @param requestBody The values of the property group that should be updated.
78
+ * @param requestBody The values of the property group that should be patched formatted according to RFC7396.
79
+ * @param ifMatch If provided, the PATCH request will only be considered if the value matches the RFC7232 ETag of the current resource. Weak ETags will always be ignored.
80
+ * @param ifUnmodifiedSince If provided, the PATCH request will only be considered if the resource has not been modified since the provided date. This parameter will be ignored if an 'If-Match' parameter is also provided.
96
81
  * @returns PropertyGroup OK
97
82
  * @throws ApiError
98
83
  */
99
- propertyGroupsPatch(key, requestBody) {
84
+ propertyGroupsPatch(key, requestBody, ifMatch, ifUnmodifiedSince) {
100
85
  return this.httpRequest.request({
101
86
  method: 'PATCH',
102
87
  url: '/propertygroups/{key}',
103
88
  path: {
104
89
  'key': key,
105
90
  },
91
+ headers: {
92
+ 'If-Match': ifMatch,
93
+ 'If-Unmodified-Since': ifUnmodifiedSince,
94
+ },
106
95
  body: requestBody,
107
96
  mediaType: 'application/merge-patch+json',
108
97
  errors: {
109
98
  400: `Bad Request`,
110
99
  403: `Forbidden`,
100
+ 404: `Not Found`,
101
+ 412: `Precondition Failed`,
111
102
  },
112
103
  });
113
104
  }
@@ -115,19 +106,27 @@ class PropertyGroupsService {
115
106
  * Delete property group
116
107
  * Deletes the property group with the provided key.
117
108
  * @param key The key of the property group to delete.
109
+ * @param ifMatch If provided, the DELETE request will only be considered if the value matches the RFC7232 ETag of the current resource. Weak ETags will always be ignored.
110
+ * @param ifUnmodifiedSince If provided, the DELETE request will only be considered if the resource has not been modified since the provided date. This parameter will be ignored if an 'If-Match' parameter is also provided.
118
111
  * @returns PropertyGroup OK
119
112
  * @throws ApiError
120
113
  */
121
- propertyGroupsDelete(key) {
114
+ propertyGroupsDelete(key, ifMatch, ifUnmodifiedSince) {
122
115
  return this.httpRequest.request({
123
116
  method: 'DELETE',
124
117
  url: '/propertygroups/{key}',
125
118
  path: {
126
119
  'key': key,
127
120
  },
121
+ headers: {
122
+ 'If-Match': ifMatch,
123
+ 'If-Unmodified-Since': ifUnmodifiedSince,
124
+ },
128
125
  errors: {
129
126
  400: `Bad Request`,
130
127
  403: `Forbidden`,
128
+ 404: `Not Found`,
129
+ 412: `Precondition Failed`,
131
130
  },
132
131
  });
133
132
  }
@@ -0,0 +1,35 @@
1
+ /**
2
+ * List of content base types used by the CMS
3
+ *
4
+ * @deprecated Only retained here for compatibility
5
+ */
6
+ export declare enum ContentBaseType {
7
+ PAGE = "_page",
8
+ COMPONENT = "_component",
9
+ MEDIA = "_media",
10
+ IMAGE = "_image",
11
+ VIDEO = "_video",
12
+ FOLDER = "_folder",
13
+ EXPERIENCE = "_experience",
14
+ SECTION = "_section",
15
+ ELEMENT = "_element"
16
+ }
17
+ /**
18
+ * List of property types used by the CMS
19
+ *
20
+ * @deprecated Only retained here for compatibility
21
+ */
22
+ export declare enum PropertyDataType {
23
+ STRING = "string",
24
+ URL = "url",
25
+ BOOLEAN = "boolean",
26
+ INTEGER = "integer",
27
+ FLOAT = "float",
28
+ DATE_TIME = "dateTime",
29
+ CONTENT_REFERENCE = "contentReference",
30
+ CONTENT = "content",
31
+ BINARY = "binary",
32
+ JSON = "json",
33
+ ARRAY = "array",
34
+ COMPONENT = "component"
35
+ }
package/dist/enums.js ADDED
@@ -0,0 +1,40 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.PropertyDataType = exports.ContentBaseType = void 0;
4
+ /**
5
+ * List of content base types used by the CMS
6
+ *
7
+ * @deprecated Only retained here for compatibility
8
+ */
9
+ var ContentBaseType;
10
+ (function (ContentBaseType) {
11
+ ContentBaseType["PAGE"] = "_page";
12
+ ContentBaseType["COMPONENT"] = "_component";
13
+ ContentBaseType["MEDIA"] = "_media";
14
+ ContentBaseType["IMAGE"] = "_image";
15
+ ContentBaseType["VIDEO"] = "_video";
16
+ ContentBaseType["FOLDER"] = "_folder";
17
+ ContentBaseType["EXPERIENCE"] = "_experience";
18
+ ContentBaseType["SECTION"] = "_section";
19
+ ContentBaseType["ELEMENT"] = "_element";
20
+ })(ContentBaseType || (exports.ContentBaseType = ContentBaseType = {}));
21
+ /**
22
+ * List of property types used by the CMS
23
+ *
24
+ * @deprecated Only retained here for compatibility
25
+ */
26
+ var PropertyDataType;
27
+ (function (PropertyDataType) {
28
+ PropertyDataType["STRING"] = "string";
29
+ PropertyDataType["URL"] = "url";
30
+ PropertyDataType["BOOLEAN"] = "boolean";
31
+ PropertyDataType["INTEGER"] = "integer";
32
+ PropertyDataType["FLOAT"] = "float";
33
+ PropertyDataType["DATE_TIME"] = "dateTime";
34
+ PropertyDataType["CONTENT_REFERENCE"] = "contentReference";
35
+ PropertyDataType["CONTENT"] = "content";
36
+ PropertyDataType["BINARY"] = "binary";
37
+ PropertyDataType["JSON"] = "json";
38
+ PropertyDataType["ARRAY"] = "array";
39
+ PropertyDataType["COMPONENT"] = "component";
40
+ })(PropertyDataType || (exports.PropertyDataType = PropertyDataType = {}));
@@ -9,10 +9,11 @@ function isErrorResponse(response) {
9
9
  }
10
10
  async function getAccessToken(config) {
11
11
  const options = config ?? (0, config_1.getCmsIntegrationApiConfigFromEnvironment)();
12
- let authUrl = new URL(`${OpenAPI_1.OpenAPI.BASE}/oauth/token`, options.base).href;
12
+ let authUrl = options.cmsVersion === types_1.OptiCmsVersion.CMS12 ? (() => {
13
+ let u = new URL(`${OpenAPI_1.OpenAPI.BASE}/oauth/token`, options.base).href;
14
+ return u.replace('preview2', 'preview1');
15
+ })() : new URL('/oauth/token', OpenAPI_1.OpenAPI.BASE).href;
13
16
  const headers = new Headers();
14
- if (options.cmsVersion == types_1.OptiCmsVersion.CMS12)
15
- authUrl = authUrl.replace('preview2', 'preview1');
16
17
  headers.append('Authorization', `Basic ${base64Encode(`${options.clientId}:${options.clientSecret}`)}`);
17
18
  headers.append('Content-Type', 'application/x-www-form-urlencoded');
18
19
  headers.append('Connection', 'close');
package/dist/index.d.ts CHANGED
@@ -4,6 +4,7 @@ export { CmsIntegrationApiClient as CoreClient } from './client';
4
4
  export { ApiClient } from './api-client';
5
5
  export { ApiClient as CmsIntegrationApiClient } from './api-client';
6
6
  export { OptiCmsVersion } from "./types";
7
+ export * from './enums';
7
8
  import { type CmsIntegrationApiOptions } from './config';
8
9
  import { ApiClient as CmsIntegrationApiClient } from './api-client';
9
10
  export type ApiClientInstance = InstanceType<typeof CmsIntegrationApiClient>;
package/dist/index.js CHANGED
@@ -48,6 +48,7 @@ var api_client_2 = require("./api-client");
48
48
  Object.defineProperty(exports, "CmsIntegrationApiClient", { enumerable: true, get: function () { return api_client_2.ApiClient; } });
49
49
  var types_1 = require("./types");
50
50
  Object.defineProperty(exports, "OptiCmsVersion", { enumerable: true, get: function () { return types_1.OptiCmsVersion; } });
51
+ __exportStar(require("./enums"), exports);
51
52
  const api_client_3 = require("./api-client");
52
53
  function createClient(config) {
53
54
  return new api_client_3.ApiClient(config);
package/dist/version.json CHANGED
@@ -1,5 +1,5 @@
1
1
  {
2
- "api": "preview2-1.0.0",
3
- "service": "2025.03.18.1237",
4
- "cms": "2025.03.18.1237"
2
+ "api": "preview3-1.0.0",
3
+ "service": "2026.01.06.0826-preview2",
4
+ "cms": "2026.01.06.0826-preview2"
5
5
  }
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "@remkoj/optimizely-cms-api",
3
3
  "displayName": "Optimizely CMS - Integration API Client",
4
4
  "description": "A Javascript client for the Integration API provided by the Optimizely CMS.",
5
- "version": "5.2.0",
5
+ "version": "5.3.1",
6
6
  "type": "commonjs",
7
7
  "license": "Apache-2.0",
8
8
  "main": "./dist/index.js",
@@ -22,7 +22,7 @@
22
22
  "clean": "tsc --build --clean",
23
23
  "prepare": "tsc --build",
24
24
  "watch": "tsc --watch",
25
- "rebuild": "yarn clean && yarn update-client && tsc --build --force",
25
+ "rebuild": "yarn clean && yarn generate && tsc --build --force",
26
26
  "generate": "yarn generate-spec && yarn generate-client",
27
27
  "generate-client": "yarn openapi --input ./integrationapi.spec.json --output ./src/client --name CmsIntegrationApiClient",
28
28
  "generate-spec": "yarn node scripts/update-spec.js"
@@ -1,8 +0,0 @@
1
- import type { ContentTypeProperty } from './ContentTypeProperty';
2
- import type { ImageDescriptor } from './ImageDescriptor';
3
- /**
4
- * Describes a property that can contain a reference to binary data.
5
- */
6
- export type BinaryProperty = (ContentTypeProperty & {
7
- imageDescriptor?: ImageDescriptor;
8
- });
@@ -1,5 +0,0 @@
1
- import type { ContentTypeProperty } from './ContentTypeProperty';
2
- /**
3
- * Describes a property that can contain a boolean value.
4
- */
5
- export type BooleanProperty = (ContentTypeProperty & Record<string, any>);
@@ -1,10 +0,0 @@
1
- import type { ListPropertyItem } from './ListPropertyItem';
2
- /**
3
- * Describes a property list item that can contain a component instance of a specific type.
4
- */
5
- export type ComponentListItem = (ListPropertyItem & {
6
- /**
7
- * The key of the ContentType that this ComponentListItem can contain.
8
- */
9
- contentType: string;
10
- });
@@ -1,10 +0,0 @@
1
- import type { ContentTypeProperty } from './ContentTypeProperty';
2
- /**
3
- * Describes a property that can contain a component instance of a specific type.
4
- */
5
- export type ComponentProperty = (ContentTypeProperty & {
6
- /**
7
- * The key of the ContentType that this ComponentProperty can contain.
8
- */
9
- contentType: string;
10
- });
@@ -1,7 +0,0 @@
1
- /**
2
- * Represent a Composition behavior for a ContentType.
3
- */
4
- export declare enum CompositionBehavior {
5
- SECTION_ENABLED = "sectionEnabled",
6
- ELEMENT_ENABLED = "elementEnabled"
7
- }
@@ -1,15 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.CompositionBehavior = void 0;
4
- /* generated using openapi-typescript-codegen -- do not edit */
5
- /* istanbul ignore file */
6
- /* tslint:disable */
7
- /* eslint-disable */
8
- /**
9
- * Represent a Composition behavior for a ContentType.
10
- */
11
- var CompositionBehavior;
12
- (function (CompositionBehavior) {
13
- CompositionBehavior["SECTION_ENABLED"] = "sectionEnabled";
14
- CompositionBehavior["ELEMENT_ENABLED"] = "elementEnabled";
15
- })(CompositionBehavior || (exports.CompositionBehavior = CompositionBehavior = {}));
@@ -1,14 +0,0 @@
1
- /**
2
- * Represent the base type of a ContentType.
3
- */
4
- export declare enum ContentBaseType {
5
- PAGE = "page",
6
- COMPONENT = "component",
7
- MEDIA = "media",
8
- IMAGE = "image",
9
- VIDEO = "video",
10
- FOLDER = "folder",
11
- EXPERIENCE = "experience",
12
- SECTION = "section",
13
- ELEMENT = "element"
14
- }
@@ -1,22 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.ContentBaseType = void 0;
4
- /* generated using openapi-typescript-codegen -- do not edit */
5
- /* istanbul ignore file */
6
- /* tslint:disable */
7
- /* eslint-disable */
8
- /**
9
- * Represent the base type of a ContentType.
10
- */
11
- var ContentBaseType;
12
- (function (ContentBaseType) {
13
- ContentBaseType["PAGE"] = "page";
14
- ContentBaseType["COMPONENT"] = "component";
15
- ContentBaseType["MEDIA"] = "media";
16
- ContentBaseType["IMAGE"] = "image";
17
- ContentBaseType["VIDEO"] = "video";
18
- ContentBaseType["FOLDER"] = "folder";
19
- ContentBaseType["EXPERIENCE"] = "experience";
20
- ContentBaseType["SECTION"] = "section";
21
- ContentBaseType["ELEMENT"] = "element";
22
- })(ContentBaseType || (exports.ContentBaseType = ContentBaseType = {}));
@@ -1,27 +0,0 @@
1
- import type { ContentItem } from './ContentItem';
2
- import type { ContentType } from './ContentType';
3
- /**
4
- * The response object for Page`1 when used ContentType are included.
5
- */
6
- export type ContentItemListWithContentTypes = {
7
- /**
8
- * The content types that are used by the content items in the response.
9
- */
10
- readonly contentTypes?: Array<ContentType>;
11
- /**
12
- * The content items in this paged collection.
13
- */
14
- readonly items?: Array<ContentItem>;
15
- /**
16
- * The zero-based index of the current page.
17
- */
18
- readonly pageIndex?: number;
19
- /**
20
- * The number of item in each page. Not necessarily the same as the number of items in this page.
21
- */
22
- readonly pageSize?: number;
23
- /**
24
- * The estimated total number of items in the collection. May be omitted if the total item count is unknown.
25
- */
26
- readonly totalItemCount?: number;
27
- };
@@ -1,12 +0,0 @@
1
- import type { ContentItem } from './ContentItem';
2
- import type { ContentType } from './ContentType';
3
- /**
4
- * The response object for ContentItem when used ContentType are included.
5
- */
6
- export type ContentItemWithContentTypes = {
7
- /**
8
- * The content types that are used by the content item in the response.
9
- */
10
- readonly contentTypes?: Array<ContentType>;
11
- item?: ContentItem;
12
- };
@@ -1,14 +0,0 @@
1
- import type { ListPropertyItem } from './ListPropertyItem';
2
- /**
3
- * Describes a property list item that can hold a content item.
4
- */
5
- export type ContentListItem = (ListPropertyItem & {
6
- /**
7
- * Specifies which content types and base types these property items are allowed to contain.
8
- */
9
- allowedTypes?: Array<string>;
10
- /**
11
- * Specifies which content types and base types these property items cannot contain.
12
- */
13
- restrictedTypes?: Array<string>;
14
- });
@@ -1,14 +0,0 @@
1
- import type { ContentTypeProperty } from './ContentTypeProperty';
2
- /**
3
- * Describes a property that can contain a content item.
4
- */
5
- export type ContentProperty = (ContentTypeProperty & {
6
- /**
7
- * Specifies which content types and base types this property is allowed to contain.
8
- */
9
- allowedTypes?: Array<string>;
10
- /**
11
- * Specifies which content types and base types this property cannot contain.
12
- */
13
- restrictedTypes?: Array<string>;
14
- });
@@ -1,14 +0,0 @@
1
- import type { ListPropertyItem } from './ListPropertyItem';
2
- /**
3
- * Describes a property list item that can hold a reference to a content item.
4
- */
5
- export type ContentReferenceListItem = (ListPropertyItem & {
6
- /**
7
- * Specifies which content types and base types these list items are allowed to reference.
8
- */
9
- allowedTypes?: Array<string>;
10
- /**
11
- * Specifies which content types and base types these list items cannot contain.
12
- */
13
- restrictedTypes?: Array<string>;
14
- });
@@ -1,2 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
@@ -1,14 +0,0 @@
1
- import type { ContentTypeProperty } from './ContentTypeProperty';
2
- /**
3
- * Describes a property that can contain a reference to a content item.
4
- */
5
- export type ContentReferenceProperty = (ContentTypeProperty & {
6
- /**
7
- * Specifies which content types and base types this property is allowed to reference.
8
- */
9
- allowedTypes?: Array<string>;
10
- /**
11
- * Specifies which content types and base types this property is restricted from referencing.
12
- */
13
- restrictedTypes?: Array<string>;
14
- });
@@ -1,2 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
@@ -1,10 +0,0 @@
1
- /**
2
- * Represent different features that a content type can have.
3
- */
4
- export declare enum ContentTypeFeature {
5
- LOCALIZATION = "localization",
6
- VERSIONING = "versioning",
7
- PUBLISH_PERIOD = "publishPeriod",
8
- ROUTING = "routing",
9
- BINARY = "binary"
10
- }
@@ -1,18 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.ContentTypeFeature = void 0;
4
- /* generated using openapi-typescript-codegen -- do not edit */
5
- /* istanbul ignore file */
6
- /* tslint:disable */
7
- /* eslint-disable */
8
- /**
9
- * Represent different features that a content type can have.
10
- */
11
- var ContentTypeFeature;
12
- (function (ContentTypeFeature) {
13
- ContentTypeFeature["LOCALIZATION"] = "localization";
14
- ContentTypeFeature["VERSIONING"] = "versioning";
15
- ContentTypeFeature["PUBLISH_PERIOD"] = "publishPeriod";
16
- ContentTypeFeature["ROUTING"] = "routing";
17
- ContentTypeFeature["BINARY"] = "binary";
18
- })(ContentTypeFeature || (exports.ContentTypeFeature = ContentTypeFeature = {}));
@@ -1,7 +0,0 @@
1
- /**
2
- * Represent the usage types for a ContentType.
3
- */
4
- export declare enum ContentTypeUsage {
5
- PROPERTY = "property",
6
- INSTANCE = "instance"
7
- }
@@ -1,15 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.ContentTypeUsage = void 0;
4
- /* generated using openapi-typescript-codegen -- do not edit */
5
- /* istanbul ignore file */
6
- /* tslint:disable */
7
- /* eslint-disable */
8
- /**
9
- * Represent the usage types for a ContentType.
10
- */
11
- var ContentTypeUsage;
12
- (function (ContentTypeUsage) {
13
- ContentTypeUsage["PROPERTY"] = "property";
14
- ContentTypeUsage["INSTANCE"] = "instance";
15
- })(ContentTypeUsage || (exports.ContentTypeUsage = ContentTypeUsage = {}));
@@ -1,14 +0,0 @@
1
- import type { ListPropertyItem } from './ListPropertyItem';
2
- /**
3
- * Describes a property list item that can contain a timestamp.
4
- */
5
- export type DateTimeListItem = (ListPropertyItem & {
6
- /**
7
- * The earliest timestamp that list items of this type should be able to contain.
8
- */
9
- minimum?: string | null;
10
- /**
11
- * The latest timestamp that list items of this type should be able to contain.
12
- */
13
- maximum?: string | null;
14
- });
@@ -1,2 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
@@ -1,14 +0,0 @@
1
- import type { ContentTypeProperty } from './ContentTypeProperty';
2
- /**
3
- * Describes a property that can contain a timestamp.
4
- */
5
- export type DateTimeProperty = (ContentTypeProperty & {
6
- /**
7
- * The earliest timestamp that properties of this type should be able to contain.
8
- */
9
- minimum?: string | null;
10
- /**
11
- * The latest timestamp that properties of this type should be able to contain.
12
- */
13
- maximum?: string | null;
14
- });
@@ -1,2 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
@@ -1,10 +0,0 @@
1
- import type { DoubleEnumerationValue } from './DoubleEnumerationValue';
2
- /**
3
- * Enumeration settings for a property or format.
4
- */
5
- export type DoubleEnumerationSettings = {
6
- /**
7
- * Enumeration values for this property or format.
8
- */
9
- values?: Array<DoubleEnumerationValue>;
10
- };
@@ -1,2 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
@@ -1,13 +0,0 @@
1
- /**
2
- * Describes an enumeration value.
3
- */
4
- export type DoubleEnumerationValue = {
5
- /**
6
- * The display name of the value.
7
- */
8
- displayName?: string;
9
- /**
10
- * The underlying enumeration value.
11
- */
12
- value?: number;
13
- };
@@ -1,2 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
@@ -1,16 +0,0 @@
1
- import type { DoubleEnumerationSettings } from './DoubleEnumerationSettings';
2
- import type { ListPropertyItem } from './ListPropertyItem';
3
- /**
4
- * Describes a property list item that can contain a float number.
5
- */
6
- export type FloatListItem = (ListPropertyItem & {
7
- /**
8
- * The minimum value that list items of this type should be able to contain.
9
- */
10
- minimum?: number | null;
11
- /**
12
- * The maximum value that list items of this type should be able to contain.
13
- */
14
- maximum?: number | null;
15
- enum?: DoubleEnumerationSettings;
16
- });
@@ -1,2 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });