contentful-management 11.50.1 → 11.52.0
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/dist/contentful-management.browser.js +11 -10
- package/dist/contentful-management.browser.js.map +1 -1
- package/dist/contentful-management.browser.min.js +1 -1
- package/dist/contentful-management.node.js +12 -10
- package/dist/contentful-management.node.js.map +1 -1
- package/dist/contentful-management.node.min.js +1 -1
- package/dist/es-modules/adapters/REST/endpoints/ai-action.js +1 -1
- package/dist/es-modules/contentful-management.js +1 -1
- package/dist/es-modules/create-space-api.js +5 -6
- package/dist/es-modules/entities/ai-action.js +5 -2
- package/dist/typings/common-types.d.ts +1 -1
- package/dist/typings/create-space-api.d.ts +3 -1
- package/dist/typings/entities/app-bundle.d.ts +4 -0
- package/dist/typings/plain/entities/ai-action.d.ts +2 -2
- package/package.json +1 -1
|
@@ -711,7 +711,7 @@ const del = (http, params, headers) => {
|
|
|
711
711
|
const publish = (http, params, rawData, headers) => {
|
|
712
712
|
return _raw__WEBPACK_IMPORTED_MODULE_1__.put(http, `/spaces/${params.spaceId}/ai/actions/${params.aiActionId}/published`, null, {
|
|
713
713
|
headers: _objectSpread({
|
|
714
|
-
'X-Contentful-Version':
|
|
714
|
+
'X-Contentful-Version': params.version
|
|
715
715
|
}, headers)
|
|
716
716
|
});
|
|
717
717
|
};
|
|
@@ -12961,18 +12961,17 @@ function createSpaceApi(makeRequest) {
|
|
|
12961
12961
|
* .catch(console.error)
|
|
12962
12962
|
* ```
|
|
12963
12963
|
*/
|
|
12964
|
-
publishAiAction(aiActionId,
|
|
12964
|
+
publishAiAction(aiActionId, {
|
|
12965
|
+
version
|
|
12966
|
+
}) {
|
|
12965
12967
|
const raw = this.toPlainObject();
|
|
12966
12968
|
return makeRequest({
|
|
12967
12969
|
entityType: 'AiAction',
|
|
12968
12970
|
action: 'publish',
|
|
12969
12971
|
params: {
|
|
12970
12972
|
spaceId: raw.sys.id,
|
|
12971
|
-
aiActionId
|
|
12972
|
-
|
|
12973
|
-
payload: data,
|
|
12974
|
-
headers: {
|
|
12975
|
-
'X-Contentful-Version': data.sys.version
|
|
12973
|
+
aiActionId,
|
|
12974
|
+
version
|
|
12976
12975
|
}
|
|
12977
12976
|
}).then(response => wrapAiAction(makeRequest, response));
|
|
12978
12977
|
},
|
|
@@ -13409,8 +13408,11 @@ function createAiActionApi(makeRequest) {
|
|
|
13409
13408
|
return makeRequest({
|
|
13410
13409
|
entityType: 'AiAction',
|
|
13411
13410
|
action: 'publish',
|
|
13412
|
-
params:
|
|
13413
|
-
|
|
13411
|
+
params: {
|
|
13412
|
+
aiActionId: self.sys.id,
|
|
13413
|
+
spaceId: self.sys.space.sys.id,
|
|
13414
|
+
version: self.sys.version
|
|
13415
|
+
}
|
|
13414
13416
|
}).then(data => wrapAiAction(makeRequest, data));
|
|
13415
13417
|
},
|
|
13416
13418
|
unpublish: function unpublish() {
|
|
@@ -32597,7 +32599,7 @@ function createClient(params, opts = {}) {
|
|
|
32597
32599
|
const sdkMain = opts.type === 'plain' ? 'contentful-management-plain.js' : 'contentful-management.js';
|
|
32598
32600
|
const userAgent = (0,contentful_sdk_core__WEBPACK_IMPORTED_MODULE_0__.getUserAgentHeader)(
|
|
32599
32601
|
// @ts-expect-error
|
|
32600
|
-
`${sdkMain}/${"11.
|
|
32602
|
+
`${sdkMain}/${"11.52.0"}`, params.application, params.integration, params.feature);
|
|
32601
32603
|
const adapter = (0,_create_adapter__WEBPACK_IMPORTED_MODULE_1__.createAdapter)(_objectSpread(_objectSpread({}, params), {}, {
|
|
32602
32604
|
userAgent
|
|
32603
32605
|
}));
|