contentful-management 11.54.4 → 11.55.0-canary.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.
@@ -2117,6 +2117,11 @@ function _toPrimitive(t, r) { if ("object" != typeof t || !t) return t; var e =
2117
2117
 
2118
2118
 
2119
2119
  const get = (http, params, rawData, headers) => {
2120
+ if (params.releaseId) {
2121
+ params.query = _objectSpread(_objectSpread({}, params.query), {}, {
2122
+ 'release[lte]': params.releaseId
2123
+ });
2124
+ }
2120
2125
  return _raw__WEBPACK_IMPORTED_MODULE_1__.get(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/entries/${params.entryId}`, {
2121
2126
  params: (0,_utils__WEBPACK_IMPORTED_MODULE_2__.normalizeSelect)(params.query),
2122
2127
  headers: _objectSpread({}, headers)
@@ -2129,6 +2134,11 @@ const getPublished = (http, params, rawData, headers) => {
2129
2134
  });
2130
2135
  };
2131
2136
  const getMany = (http, params, rawData, headers) => {
2137
+ if (params.releaseId) {
2138
+ params.query = _objectSpread(_objectSpread({}, params.query), {}, {
2139
+ 'release[lte]': params.releaseId
2140
+ });
2141
+ }
2132
2142
  return _raw__WEBPACK_IMPORTED_MODULE_1__.get(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/entries`, {
2133
2143
  params: (0,_utils__WEBPACK_IMPORTED_MODULE_2__.normalizeSelect)(params.query),
2134
2144
  headers: _objectSpread({}, headers)
@@ -2778,31 +2788,33 @@ __webpack_require__.r(__webpack_exports__);
2778
2788
  /* harmony import */ var _personal_access_token__WEBPACK_IMPORTED_MODULE_38__ = __webpack_require__(/*! ./personal-access-token */ "./adapters/REST/endpoints/personal-access-token.ts");
2779
2789
  /* harmony import */ var _preview_api_key__WEBPACK_IMPORTED_MODULE_39__ = __webpack_require__(/*! ./preview-api-key */ "./adapters/REST/endpoints/preview-api-key.ts");
2780
2790
  /* harmony import */ var _release__WEBPACK_IMPORTED_MODULE_40__ = __webpack_require__(/*! ./release */ "./adapters/REST/endpoints/release.ts");
2781
- /* harmony import */ var _release_action__WEBPACK_IMPORTED_MODULE_41__ = __webpack_require__(/*! ./release-action */ "./adapters/REST/endpoints/release-action.ts");
2782
- /* harmony import */ var _resource__WEBPACK_IMPORTED_MODULE_42__ = __webpack_require__(/*! ./resource */ "./adapters/REST/endpoints/resource.ts");
2783
- /* harmony import */ var _resource_provider__WEBPACK_IMPORTED_MODULE_43__ = __webpack_require__(/*! ./resource-provider */ "./adapters/REST/endpoints/resource-provider.ts");
2784
- /* harmony import */ var _resource_type__WEBPACK_IMPORTED_MODULE_44__ = __webpack_require__(/*! ./resource-type */ "./adapters/REST/endpoints/resource-type.ts");
2785
- /* harmony import */ var _role__WEBPACK_IMPORTED_MODULE_45__ = __webpack_require__(/*! ./role */ "./adapters/REST/endpoints/role.ts");
2786
- /* harmony import */ var _scheduled_action__WEBPACK_IMPORTED_MODULE_46__ = __webpack_require__(/*! ./scheduled-action */ "./adapters/REST/endpoints/scheduled-action.ts");
2787
- /* harmony import */ var _snapshot__WEBPACK_IMPORTED_MODULE_47__ = __webpack_require__(/*! ./snapshot */ "./adapters/REST/endpoints/snapshot.ts");
2788
- /* harmony import */ var _space__WEBPACK_IMPORTED_MODULE_48__ = __webpack_require__(/*! ./space */ "./adapters/REST/endpoints/space.ts");
2789
- /* harmony import */ var _space_member__WEBPACK_IMPORTED_MODULE_49__ = __webpack_require__(/*! ./space-member */ "./adapters/REST/endpoints/space-member.ts");
2790
- /* harmony import */ var _space_membership__WEBPACK_IMPORTED_MODULE_50__ = __webpack_require__(/*! ./space-membership */ "./adapters/REST/endpoints/space-membership.ts");
2791
- /* harmony import */ var _tag__WEBPACK_IMPORTED_MODULE_51__ = __webpack_require__(/*! ./tag */ "./adapters/REST/endpoints/tag.ts");
2792
- /* harmony import */ var _task__WEBPACK_IMPORTED_MODULE_52__ = __webpack_require__(/*! ./task */ "./adapters/REST/endpoints/task.ts");
2793
- /* harmony import */ var _team__WEBPACK_IMPORTED_MODULE_53__ = __webpack_require__(/*! ./team */ "./adapters/REST/endpoints/team.ts");
2794
- /* harmony import */ var _team_membership__WEBPACK_IMPORTED_MODULE_54__ = __webpack_require__(/*! ./team-membership */ "./adapters/REST/endpoints/team-membership.ts");
2795
- /* harmony import */ var _team_space_membership__WEBPACK_IMPORTED_MODULE_55__ = __webpack_require__(/*! ./team-space-membership */ "./adapters/REST/endpoints/team-space-membership.ts");
2796
- /* harmony import */ var _ui_config__WEBPACK_IMPORTED_MODULE_56__ = __webpack_require__(/*! ./ui-config */ "./adapters/REST/endpoints/ui-config.ts");
2797
- /* harmony import */ var _upload__WEBPACK_IMPORTED_MODULE_57__ = __webpack_require__(/*! ./upload */ "./adapters/REST/endpoints/upload.ts");
2798
- /* harmony import */ var _upload_credentials__WEBPACK_IMPORTED_MODULE_58__ = __webpack_require__(/*! ./upload-credentials */ "./adapters/REST/endpoints/upload-credentials.ts");
2799
- /* harmony import */ var _usage__WEBPACK_IMPORTED_MODULE_59__ = __webpack_require__(/*! ./usage */ "./adapters/REST/endpoints/usage.ts");
2800
- /* harmony import */ var _user__WEBPACK_IMPORTED_MODULE_60__ = __webpack_require__(/*! ./user */ "./adapters/REST/endpoints/user.ts");
2801
- /* harmony import */ var _user_ui_config__WEBPACK_IMPORTED_MODULE_61__ = __webpack_require__(/*! ./user-ui-config */ "./adapters/REST/endpoints/user-ui-config.ts");
2802
- /* harmony import */ var _webhook__WEBPACK_IMPORTED_MODULE_62__ = __webpack_require__(/*! ./webhook */ "./adapters/REST/endpoints/webhook.ts");
2803
- /* harmony import */ var _workflow__WEBPACK_IMPORTED_MODULE_63__ = __webpack_require__(/*! ./workflow */ "./adapters/REST/endpoints/workflow.ts");
2804
- /* harmony import */ var _workflow_definition__WEBPACK_IMPORTED_MODULE_64__ = __webpack_require__(/*! ./workflow-definition */ "./adapters/REST/endpoints/workflow-definition.ts");
2805
- /* harmony import */ var _workflows_changelog__WEBPACK_IMPORTED_MODULE_65__ = __webpack_require__(/*! ./workflows-changelog */ "./adapters/REST/endpoints/workflows-changelog.ts");
2791
+ /* harmony import */ var _release_entry__WEBPACK_IMPORTED_MODULE_41__ = __webpack_require__(/*! ./release-entry */ "./adapters/REST/endpoints/release-entry.ts");
2792
+ /* harmony import */ var _release_action__WEBPACK_IMPORTED_MODULE_42__ = __webpack_require__(/*! ./release-action */ "./adapters/REST/endpoints/release-action.ts");
2793
+ /* harmony import */ var _resource__WEBPACK_IMPORTED_MODULE_43__ = __webpack_require__(/*! ./resource */ "./adapters/REST/endpoints/resource.ts");
2794
+ /* harmony import */ var _resource_provider__WEBPACK_IMPORTED_MODULE_44__ = __webpack_require__(/*! ./resource-provider */ "./adapters/REST/endpoints/resource-provider.ts");
2795
+ /* harmony import */ var _resource_type__WEBPACK_IMPORTED_MODULE_45__ = __webpack_require__(/*! ./resource-type */ "./adapters/REST/endpoints/resource-type.ts");
2796
+ /* harmony import */ var _role__WEBPACK_IMPORTED_MODULE_46__ = __webpack_require__(/*! ./role */ "./adapters/REST/endpoints/role.ts");
2797
+ /* harmony import */ var _scheduled_action__WEBPACK_IMPORTED_MODULE_47__ = __webpack_require__(/*! ./scheduled-action */ "./adapters/REST/endpoints/scheduled-action.ts");
2798
+ /* harmony import */ var _snapshot__WEBPACK_IMPORTED_MODULE_48__ = __webpack_require__(/*! ./snapshot */ "./adapters/REST/endpoints/snapshot.ts");
2799
+ /* harmony import */ var _space__WEBPACK_IMPORTED_MODULE_49__ = __webpack_require__(/*! ./space */ "./adapters/REST/endpoints/space.ts");
2800
+ /* harmony import */ var _space_member__WEBPACK_IMPORTED_MODULE_50__ = __webpack_require__(/*! ./space-member */ "./adapters/REST/endpoints/space-member.ts");
2801
+ /* harmony import */ var _space_membership__WEBPACK_IMPORTED_MODULE_51__ = __webpack_require__(/*! ./space-membership */ "./adapters/REST/endpoints/space-membership.ts");
2802
+ /* harmony import */ var _tag__WEBPACK_IMPORTED_MODULE_52__ = __webpack_require__(/*! ./tag */ "./adapters/REST/endpoints/tag.ts");
2803
+ /* harmony import */ var _task__WEBPACK_IMPORTED_MODULE_53__ = __webpack_require__(/*! ./task */ "./adapters/REST/endpoints/task.ts");
2804
+ /* harmony import */ var _team__WEBPACK_IMPORTED_MODULE_54__ = __webpack_require__(/*! ./team */ "./adapters/REST/endpoints/team.ts");
2805
+ /* harmony import */ var _team_membership__WEBPACK_IMPORTED_MODULE_55__ = __webpack_require__(/*! ./team-membership */ "./adapters/REST/endpoints/team-membership.ts");
2806
+ /* harmony import */ var _team_space_membership__WEBPACK_IMPORTED_MODULE_56__ = __webpack_require__(/*! ./team-space-membership */ "./adapters/REST/endpoints/team-space-membership.ts");
2807
+ /* harmony import */ var _ui_config__WEBPACK_IMPORTED_MODULE_57__ = __webpack_require__(/*! ./ui-config */ "./adapters/REST/endpoints/ui-config.ts");
2808
+ /* harmony import */ var _upload__WEBPACK_IMPORTED_MODULE_58__ = __webpack_require__(/*! ./upload */ "./adapters/REST/endpoints/upload.ts");
2809
+ /* harmony import */ var _upload_credentials__WEBPACK_IMPORTED_MODULE_59__ = __webpack_require__(/*! ./upload-credentials */ "./adapters/REST/endpoints/upload-credentials.ts");
2810
+ /* harmony import */ var _usage__WEBPACK_IMPORTED_MODULE_60__ = __webpack_require__(/*! ./usage */ "./adapters/REST/endpoints/usage.ts");
2811
+ /* harmony import */ var _user__WEBPACK_IMPORTED_MODULE_61__ = __webpack_require__(/*! ./user */ "./adapters/REST/endpoints/user.ts");
2812
+ /* harmony import */ var _user_ui_config__WEBPACK_IMPORTED_MODULE_62__ = __webpack_require__(/*! ./user-ui-config */ "./adapters/REST/endpoints/user-ui-config.ts");
2813
+ /* harmony import */ var _webhook__WEBPACK_IMPORTED_MODULE_63__ = __webpack_require__(/*! ./webhook */ "./adapters/REST/endpoints/webhook.ts");
2814
+ /* harmony import */ var _workflow__WEBPACK_IMPORTED_MODULE_64__ = __webpack_require__(/*! ./workflow */ "./adapters/REST/endpoints/workflow.ts");
2815
+ /* harmony import */ var _workflow_definition__WEBPACK_IMPORTED_MODULE_65__ = __webpack_require__(/*! ./workflow-definition */ "./adapters/REST/endpoints/workflow-definition.ts");
2816
+ /* harmony import */ var _workflows_changelog__WEBPACK_IMPORTED_MODULE_66__ = __webpack_require__(/*! ./workflows-changelog */ "./adapters/REST/endpoints/workflows-changelog.ts");
2817
+
2806
2818
 
2807
2819
 
2808
2820
 
@@ -2911,31 +2923,32 @@ __webpack_require__.r(__webpack_exports__);
2911
2923
  AccessToken: _access_token__WEBPACK_IMPORTED_MODULE_2__,
2912
2924
  PreviewApiKey: _preview_api_key__WEBPACK_IMPORTED_MODULE_39__,
2913
2925
  Release: _release__WEBPACK_IMPORTED_MODULE_40__,
2914
- ReleaseAction: _release_action__WEBPACK_IMPORTED_MODULE_41__,
2915
- Resource: _resource__WEBPACK_IMPORTED_MODULE_42__,
2916
- ResourceProvider: _resource_provider__WEBPACK_IMPORTED_MODULE_43__,
2917
- ResourceType: _resource_type__WEBPACK_IMPORTED_MODULE_44__,
2918
- Role: _role__WEBPACK_IMPORTED_MODULE_45__,
2919
- ScheduledAction: _scheduled_action__WEBPACK_IMPORTED_MODULE_46__,
2920
- Snapshot: _snapshot__WEBPACK_IMPORTED_MODULE_47__,
2921
- Space: _space__WEBPACK_IMPORTED_MODULE_48__,
2922
- SpaceMember: _space_member__WEBPACK_IMPORTED_MODULE_49__,
2923
- SpaceMembership: _space_membership__WEBPACK_IMPORTED_MODULE_50__,
2924
- Tag: _tag__WEBPACK_IMPORTED_MODULE_51__,
2925
- Task: _task__WEBPACK_IMPORTED_MODULE_52__,
2926
- Team: _team__WEBPACK_IMPORTED_MODULE_53__,
2927
- TeamMembership: _team_membership__WEBPACK_IMPORTED_MODULE_54__,
2928
- TeamSpaceMembership: _team_space_membership__WEBPACK_IMPORTED_MODULE_55__,
2929
- UIConfig: _ui_config__WEBPACK_IMPORTED_MODULE_56__,
2930
- Upload: _upload__WEBPACK_IMPORTED_MODULE_57__,
2931
- UploadCredential: _upload_credentials__WEBPACK_IMPORTED_MODULE_58__,
2932
- Usage: _usage__WEBPACK_IMPORTED_MODULE_59__,
2933
- User: _user__WEBPACK_IMPORTED_MODULE_60__,
2934
- UserUIConfig: _user_ui_config__WEBPACK_IMPORTED_MODULE_61__,
2935
- Webhook: _webhook__WEBPACK_IMPORTED_MODULE_62__,
2936
- WorkflowDefinition: _workflow_definition__WEBPACK_IMPORTED_MODULE_64__,
2937
- Workflow: _workflow__WEBPACK_IMPORTED_MODULE_63__,
2938
- WorkflowsChangelog: _workflows_changelog__WEBPACK_IMPORTED_MODULE_65__
2926
+ ReleaseEntry: _release_entry__WEBPACK_IMPORTED_MODULE_41__,
2927
+ ReleaseAction: _release_action__WEBPACK_IMPORTED_MODULE_42__,
2928
+ Resource: _resource__WEBPACK_IMPORTED_MODULE_43__,
2929
+ ResourceProvider: _resource_provider__WEBPACK_IMPORTED_MODULE_44__,
2930
+ ResourceType: _resource_type__WEBPACK_IMPORTED_MODULE_45__,
2931
+ Role: _role__WEBPACK_IMPORTED_MODULE_46__,
2932
+ ScheduledAction: _scheduled_action__WEBPACK_IMPORTED_MODULE_47__,
2933
+ Snapshot: _snapshot__WEBPACK_IMPORTED_MODULE_48__,
2934
+ Space: _space__WEBPACK_IMPORTED_MODULE_49__,
2935
+ SpaceMember: _space_member__WEBPACK_IMPORTED_MODULE_50__,
2936
+ SpaceMembership: _space_membership__WEBPACK_IMPORTED_MODULE_51__,
2937
+ Tag: _tag__WEBPACK_IMPORTED_MODULE_52__,
2938
+ Task: _task__WEBPACK_IMPORTED_MODULE_53__,
2939
+ Team: _team__WEBPACK_IMPORTED_MODULE_54__,
2940
+ TeamMembership: _team_membership__WEBPACK_IMPORTED_MODULE_55__,
2941
+ TeamSpaceMembership: _team_space_membership__WEBPACK_IMPORTED_MODULE_56__,
2942
+ UIConfig: _ui_config__WEBPACK_IMPORTED_MODULE_57__,
2943
+ Upload: _upload__WEBPACK_IMPORTED_MODULE_58__,
2944
+ UploadCredential: _upload_credentials__WEBPACK_IMPORTED_MODULE_59__,
2945
+ Usage: _usage__WEBPACK_IMPORTED_MODULE_60__,
2946
+ User: _user__WEBPACK_IMPORTED_MODULE_61__,
2947
+ UserUIConfig: _user_ui_config__WEBPACK_IMPORTED_MODULE_62__,
2948
+ Webhook: _webhook__WEBPACK_IMPORTED_MODULE_63__,
2949
+ WorkflowDefinition: _workflow_definition__WEBPACK_IMPORTED_MODULE_65__,
2950
+ Workflow: _workflow__WEBPACK_IMPORTED_MODULE_64__,
2951
+ WorkflowsChangelog: _workflows_changelog__WEBPACK_IMPORTED_MODULE_66__
2939
2952
  });
2940
2953
 
2941
2954
  /***/ }),
@@ -3467,6 +3480,66 @@ const queryForRelease = (http, params) => {
3467
3480
 
3468
3481
  /***/ }),
3469
3482
 
3483
+ /***/ "./adapters/REST/endpoints/release-entry.ts":
3484
+ /*!**************************************************!*\
3485
+ !*** ./adapters/REST/endpoints/release-entry.ts ***!
3486
+ \**************************************************/
3487
+ /***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
3488
+
3489
+ "use strict";
3490
+ __webpack_require__.r(__webpack_exports__);
3491
+ /* harmony export */ __webpack_require__.d(__webpack_exports__, {
3492
+ /* harmony export */ get: () => (/* binding */ get),
3493
+ /* harmony export */ getMany: () => (/* binding */ getMany),
3494
+ /* harmony export */ patch: () => (/* binding */ patch),
3495
+ /* harmony export */ update: () => (/* binding */ update)
3496
+ /* harmony export */ });
3497
+ /* harmony import */ var fast_copy__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! fast-copy */ "../node_modules/fast-copy/dist/esm/index.mjs");
3498
+ /* harmony import */ var _raw__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./raw */ "./adapters/REST/endpoints/raw.ts");
3499
+ function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
3500
+ function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
3501
+ function _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; }
3502
+ function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == typeof i ? i : i + ""; }
3503
+ function _toPrimitive(t, r) { if ("object" != typeof t || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != typeof i) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
3504
+
3505
+
3506
+ const get = (http, params) => {
3507
+ //TODO: not fully implemented yet, only the get method
3508
+ return _raw__WEBPACK_IMPORTED_MODULE_1__.get(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/releases/${params.releaseId}/entries/${params.entryId}`);
3509
+ };
3510
+ const getMany = (http, params) => {
3511
+ params.query = _objectSpread(_objectSpread({}, params.query), {}, {
3512
+ 'sys.schemaVersion': 'Release.V2'
3513
+ });
3514
+ return _raw__WEBPACK_IMPORTED_MODULE_1__.get(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/releases/${params.releaseId}/entries`);
3515
+ };
3516
+ const update = (http, params, rawData, headers) => {
3517
+ var _rawData$sys$version;
3518
+ params.query = _objectSpread(_objectSpread({}, params.query), {}, {
3519
+ 'sys.schemaVersion': 'Release.V2'
3520
+ });
3521
+ const data = (0,fast_copy__WEBPACK_IMPORTED_MODULE_0__["default"])(rawData);
3522
+ delete data.sys;
3523
+ return _raw__WEBPACK_IMPORTED_MODULE_1__.put(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/releases/${params.releaseId}/entries/${params.entryId}`, data, {
3524
+ headers: _objectSpread({
3525
+ 'X-Contentful-Version': (_rawData$sys$version = rawData.sys.version) !== null && _rawData$sys$version !== void 0 ? _rawData$sys$version : 0
3526
+ }, headers)
3527
+ });
3528
+ };
3529
+ const patch = (http, params, data, headers) => {
3530
+ params.query = _objectSpread(_objectSpread({}, params.query), {}, {
3531
+ 'sys.schemaVersion': 'Release.V2'
3532
+ });
3533
+ return _raw__WEBPACK_IMPORTED_MODULE_1__.patch(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/releases/${params.releaseId}/entries/${params.entryId}`, data, {
3534
+ headers: _objectSpread({
3535
+ 'X-Contentful-Version': params.version,
3536
+ 'Content-Type': 'application/json-patch+json'
3537
+ }, headers)
3538
+ });
3539
+ };
3540
+
3541
+ /***/ }),
3542
+
3470
3543
  /***/ "./adapters/REST/endpoints/release.ts":
3471
3544
  /*!********************************************!*\
3472
3545
  !*** ./adapters/REST/endpoints/release.ts ***!
@@ -3498,14 +3571,38 @@ const get = (http, params) => {
3498
3571
  return _raw__WEBPACK_IMPORTED_MODULE_0__.get(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/releases/${params.releaseId}`);
3499
3572
  };
3500
3573
  const query = (http, params) => {
3574
+ var _ref, _params$query$sysSch, _params$query;
3575
+ // Set the schema version in the query if provided in params or query options
3576
+ const releaseSchemaVersion = (_ref = (_params$query$sysSch = (_params$query = params.query) === null || _params$query === void 0 ? void 0 : _params$query['sys.schemaVersion']) !== null && _params$query$sysSch !== void 0 ? _params$query$sysSch : params.releaseSchemaVersion) !== null && _ref !== void 0 ? _ref : undefined;
3577
+ if (releaseSchemaVersion !== undefined) {
3578
+ params.query = _objectSpread(_objectSpread({}, params.query), {}, {
3579
+ 'sys.schemaVersion': releaseSchemaVersion
3580
+ });
3581
+ }
3501
3582
  return _raw__WEBPACK_IMPORTED_MODULE_0__.get(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/releases`, {
3502
3583
  params: params.query
3503
3584
  });
3504
3585
  };
3505
3586
  const create = (http, params, payload) => {
3587
+ var _payload$sys$schemaVe, _payload$sys;
3588
+ const releaseSchemaVersion = (_payload$sys$schemaVe = (_payload$sys = payload.sys) === null || _payload$sys === void 0 ? void 0 : _payload$sys.schemaVersion) !== null && _payload$sys$schemaVe !== void 0 ? _payload$sys$schemaVe : params.releaseSchemaVersion;
3589
+ if (releaseSchemaVersion === 'Release.v2') {
3590
+ payload.sys = _objectSpread(_objectSpread({}, payload.sys), {}, {
3591
+ type: 'Release',
3592
+ schemaVersion: 'Release.v2'
3593
+ });
3594
+ }
3506
3595
  return _raw__WEBPACK_IMPORTED_MODULE_0__.post(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/releases`, payload);
3507
3596
  };
3508
3597
  const update = (http, params, payload, headers) => {
3598
+ var _payload$sys$schemaVe2, _payload$sys2;
3599
+ const releaseSchemaVersion = (_payload$sys$schemaVe2 = (_payload$sys2 = payload.sys) === null || _payload$sys2 === void 0 ? void 0 : _payload$sys2.schemaVersion) !== null && _payload$sys$schemaVe2 !== void 0 ? _payload$sys$schemaVe2 : params.releaseSchemaVersion;
3600
+ if (releaseSchemaVersion === 'Release.v2') {
3601
+ payload.sys = _objectSpread(_objectSpread({}, payload.sys), {}, {
3602
+ type: 'Release',
3603
+ schemaVersion: 'Release.v2'
3604
+ });
3605
+ }
3509
3606
  return _raw__WEBPACK_IMPORTED_MODULE_0__.put(http, `/spaces/${params.spaceId}/environments/${params.environmentId}/releases/${params.releaseId}`, payload, {
3510
3607
  headers: _objectSpread({
3511
3608
  'X-Contentful-Version': params.version
@@ -7468,7 +7565,7 @@ function createEnvironmentApi(makeRequest) {
7468
7565
  *
7469
7566
  * // Using Thenables
7470
7567
  * client.getSpace('<space_id>')
7471
- * .then((space) => space.getEnvironment('<environment_id>'))
7568
+ * .then((space) => space.getEnvironment('<environment-id>'))
7472
7569
  * .then((environment) => environment.createUnpublishBulkAction(payload))
7473
7570
  * .then((bulkAction) => console.log(bulkAction.waitProcessing()))
7474
7571
  * .catch(console.error)
@@ -7476,7 +7573,7 @@ function createEnvironmentApi(makeRequest) {
7476
7573
  * // Using async/await
7477
7574
  * try {
7478
7575
  * const space = await clientgetSpace('<space_id>')
7479
- * const environment = await space.getEnvironment('<environment_id>')
7576
+ * const environment = await space.getEnvironment('<environment-id>')
7480
7577
  * const bulkActionInProgress = await environment.createUnpublishBulkAction(payload)
7481
7578
  *
7482
7579
  * // You can wait for a recently created BulkAction to be processed by using `bulkAction.waitProcessing()`
@@ -7930,7 +8027,7 @@ function createEnvironmentApi(makeRequest) {
7930
8027
  *
7931
8028
  * // Get entry references
7932
8029
  * client.getSpace('<space_id>')
7933
- * .then((space) => space.getEnvironment('<environment_id>'))
8030
+ * .then((space) => space.getEnvironment('<environment-id>'))
7934
8031
  * .then((environment) => environment.getEntryReferences('<entry_id>', {include: number}))
7935
8032
  * .then((entry) => console.log(entry.includes))
7936
8033
  * // or
@@ -9480,7 +9577,7 @@ function createEnvironmentApi(makeRequest) {
9480
9577
  * })
9481
9578
  *
9482
9579
  * client.getSpace('<space_id>')
9483
- * .then((space) => space.getEnvironment('<environment_id>'))
9580
+ * .then((space) => space.getEnvironment('<environment-id>'))
9484
9581
  * .then((environment) => environment.getResourceTypes({limit: 10}))
9485
9582
  * .then((installations) => console.log(installations.items))
9486
9583
  * .catch(console.error)
@@ -18215,6 +18312,12 @@ const createPlainClient = (makeRequest, defaults) => {
18215
18312
  getManyForOrganization: (0,_wrappers_wrap__WEBPACK_IMPORTED_MODULE_1__.wrap)(wrapParams, 'Usage', 'getManyForOrganization')
18216
18313
  },
18217
18314
  release: {
18315
+ entry: {
18316
+ get: (0,_wrappers_wrap__WEBPACK_IMPORTED_MODULE_1__.wrap)(wrapParams, 'ReleaseEntry', 'get'),
18317
+ getMany: (0,_wrappers_wrap__WEBPACK_IMPORTED_MODULE_1__.wrap)(wrapParams, 'ReleaseEntry', 'getMany'),
18318
+ update: (0,_wrappers_wrap__WEBPACK_IMPORTED_MODULE_1__.wrap)(wrapParams, 'ReleaseEntry', 'update'),
18319
+ patch: (0,_wrappers_wrap__WEBPACK_IMPORTED_MODULE_1__.wrap)(wrapParams, 'ReleaseEntry', 'patch')
18320
+ },
18218
18321
  archive: (0,_wrappers_wrap__WEBPACK_IMPORTED_MODULE_1__.wrap)(wrapParams, 'Release', 'archive'),
18219
18322
  get: (0,_wrappers_wrap__WEBPACK_IMPORTED_MODULE_1__.wrap)(wrapParams, 'Release', 'get'),
18220
18323
  query: (0,_wrappers_wrap__WEBPACK_IMPORTED_MODULE_1__.wrap)(wrapParams, 'Release', 'query'),
@@ -20025,52 +20128,6 @@ module.exports = URIError;
20025
20128
  module.exports = Object;
20026
20129
 
20027
20130
 
20028
- /***/ }),
20029
-
20030
- /***/ "../node_modules/es-set-tostringtag/index.js":
20031
- /*!***************************************************!*\
20032
- !*** ../node_modules/es-set-tostringtag/index.js ***!
20033
- \***************************************************/
20034
- /***/ ((module, __unused_webpack_exports, __webpack_require__) => {
20035
-
20036
- "use strict";
20037
-
20038
-
20039
- var GetIntrinsic = __webpack_require__(/*! get-intrinsic */ "../node_modules/get-intrinsic/index.js");
20040
-
20041
- var $defineProperty = GetIntrinsic('%Object.defineProperty%', true);
20042
-
20043
- var hasToStringTag = __webpack_require__(/*! has-tostringtag/shams */ "../node_modules/has-tostringtag/shams.js")();
20044
- var hasOwn = __webpack_require__(/*! hasown */ "../node_modules/hasown/index.js");
20045
- var $TypeError = __webpack_require__(/*! es-errors/type */ "../node_modules/es-errors/type.js");
20046
-
20047
- var toStringTag = hasToStringTag ? Symbol.toStringTag : null;
20048
-
20049
- /** @type {import('.')} */
20050
- module.exports = function setToStringTag(object, value) {
20051
- var overrideIfSet = arguments.length > 2 && !!arguments[2] && arguments[2].force;
20052
- var nonConfigurable = arguments.length > 2 && !!arguments[2] && arguments[2].nonConfigurable;
20053
- if (
20054
- (typeof overrideIfSet !== 'undefined' && typeof overrideIfSet !== 'boolean')
20055
- || (typeof nonConfigurable !== 'undefined' && typeof nonConfigurable !== 'boolean')
20056
- ) {
20057
- throw new $TypeError('if provided, the `overrideIfSet` and `nonConfigurable` options must be booleans');
20058
- }
20059
- if (toStringTag && (overrideIfSet || !hasOwn(object, toStringTag))) {
20060
- if ($defineProperty) {
20061
- $defineProperty(object, toStringTag, {
20062
- configurable: !nonConfigurable,
20063
- enumerable: false,
20064
- value: value,
20065
- writable: false
20066
- });
20067
- } else {
20068
- object[toStringTag] = value; // eslint-disable-line no-param-reassign
20069
- }
20070
- }
20071
- };
20072
-
20073
-
20074
20131
  /***/ }),
20075
20132
 
20076
20133
  /***/ "../node_modules/follow-redirects/debug.js":
@@ -20800,9 +20857,6 @@ module.exports.wrap = wrap;
20800
20857
  \**************************************************/
20801
20858
  /***/ ((module, __unused_webpack_exports, __webpack_require__) => {
20802
20859
 
20803
- "use strict";
20804
-
20805
-
20806
20860
  var CombinedStream = __webpack_require__(/*! combined-stream */ "../node_modules/combined-stream/lib/combined_stream.js");
20807
20861
  var util = __webpack_require__(/*! util */ "util");
20808
20862
  var path = __webpack_require__(/*! path */ "path");
@@ -20811,20 +20865,23 @@ var https = __webpack_require__(/*! https */ "https");
20811
20865
  var parseUrl = (__webpack_require__(/*! url */ "url").parse);
20812
20866
  var fs = __webpack_require__(/*! fs */ "fs");
20813
20867
  var Stream = (__webpack_require__(/*! stream */ "stream").Stream);
20814
- var crypto = __webpack_require__(/*! crypto */ "crypto");
20815
20868
  var mime = __webpack_require__(/*! mime-types */ "../node_modules/mime-types/index.js");
20816
20869
  var asynckit = __webpack_require__(/*! asynckit */ "../node_modules/asynckit/index.js");
20817
- var setToStringTag = __webpack_require__(/*! es-set-tostringtag */ "../node_modules/es-set-tostringtag/index.js");
20818
- var hasOwn = __webpack_require__(/*! hasown */ "../node_modules/hasown/index.js");
20819
20870
  var populate = __webpack_require__(/*! ./populate.js */ "../node_modules/form-data/lib/populate.js");
20820
20871
 
20872
+ // Public API
20873
+ module.exports = FormData;
20874
+
20875
+ // make it a Stream
20876
+ util.inherits(FormData, CombinedStream);
20877
+
20821
20878
  /**
20822
20879
  * Create readable "multipart/form-data" streams.
20823
20880
  * Can be used to submit forms
20824
20881
  * and file uploads to other web applications.
20825
20882
  *
20826
20883
  * @constructor
20827
- * @param {object} options - Properties to be added/overriden for FormData and CombinedStream
20884
+ * @param {Object} options - Properties to be added/overriden for FormData and CombinedStream
20828
20885
  */
20829
20886
  function FormData(options) {
20830
20887
  if (!(this instanceof FormData)) {
@@ -20837,39 +20894,35 @@ function FormData(options) {
20837
20894
 
20838
20895
  CombinedStream.call(this);
20839
20896
 
20840
- options = options || {}; // eslint-disable-line no-param-reassign
20841
- for (var option in options) { // eslint-disable-line no-restricted-syntax
20897
+ options = options || {};
20898
+ for (var option in options) {
20842
20899
  this[option] = options[option];
20843
20900
  }
20844
20901
  }
20845
20902
 
20846
- // make it a Stream
20847
- util.inherits(FormData, CombinedStream);
20848
-
20849
20903
  FormData.LINE_BREAK = '\r\n';
20850
20904
  FormData.DEFAULT_CONTENT_TYPE = 'application/octet-stream';
20851
20905
 
20852
- FormData.prototype.append = function (field, value, options) {
20853
- options = options || {}; // eslint-disable-line no-param-reassign
20906
+ FormData.prototype.append = function(field, value, options) {
20907
+
20908
+ options = options || {};
20854
20909
 
20855
20910
  // allow filename as single option
20856
- if (typeof options === 'string') {
20857
- options = { filename: options }; // eslint-disable-line no-param-reassign
20911
+ if (typeof options == 'string') {
20912
+ options = {filename: options};
20858
20913
  }
20859
20914
 
20860
20915
  var append = CombinedStream.prototype.append.bind(this);
20861
20916
 
20862
20917
  // all that streamy business can't handle numbers
20863
- if (typeof value === 'number' || value == null) {
20864
- value = String(value); // eslint-disable-line no-param-reassign
20918
+ if (typeof value == 'number') {
20919
+ value = '' + value;
20865
20920
  }
20866
20921
 
20867
20922
  // https://github.com/felixge/node-form-data/issues/38
20868
20923
  if (Array.isArray(value)) {
20869
- /*
20870
- * Please convert your array into string
20871
- * the way web server expects it
20872
- */
20924
+ // Please convert your array into string
20925
+ // the way web server expects it
20873
20926
  this._error(new Error('Arrays are not supported.'));
20874
20927
  return;
20875
20928
  }
@@ -20885,17 +20938,15 @@ FormData.prototype.append = function (field, value, options) {
20885
20938
  this._trackLength(header, value, options);
20886
20939
  };
20887
20940
 
20888
- FormData.prototype._trackLength = function (header, value, options) {
20941
+ FormData.prototype._trackLength = function(header, value, options) {
20889
20942
  var valueLength = 0;
20890
20943
 
20891
- /*
20892
- * used w/ getLengthSync(), when length is known.
20893
- * e.g. for streaming directly from a remote server,
20894
- * w/ a known file a size, and not wanting to wait for
20895
- * incoming file to finish to get its size.
20896
- */
20944
+ // used w/ getLengthSync(), when length is known.
20945
+ // e.g. for streaming directly from a remote server,
20946
+ // w/ a known file a size, and not wanting to wait for
20947
+ // incoming file to finish to get its size.
20897
20948
  if (options.knownLength != null) {
20898
- valueLength += Number(options.knownLength);
20949
+ valueLength += +options.knownLength;
20899
20950
  } else if (Buffer.isBuffer(value)) {
20900
20951
  valueLength = value.length;
20901
20952
  } else if (typeof value === 'string') {
@@ -20905,10 +20956,12 @@ FormData.prototype._trackLength = function (header, value, options) {
20905
20956
  this._valueLength += valueLength;
20906
20957
 
20907
20958
  // @check why add CRLF? does this account for custom/multiple CRLFs?
20908
- this._overheadLength += Buffer.byteLength(header) + FormData.LINE_BREAK.length;
20959
+ this._overheadLength +=
20960
+ Buffer.byteLength(header) +
20961
+ FormData.LINE_BREAK.length;
20909
20962
 
20910
20963
  // empty or either doesn't have path or not an http response or not a stream
20911
- if (!value || (!value.path && !(value.readable && hasOwn(value, 'httpVersion')) && !(value instanceof Stream))) {
20964
+ if (!value || ( !value.path && !(value.readable && value.hasOwnProperty('httpVersion')) && !(value instanceof Stream))) {
20912
20965
  return;
20913
20966
  }
20914
20967
 
@@ -20918,8 +20971,10 @@ FormData.prototype._trackLength = function (header, value, options) {
20918
20971
  }
20919
20972
  };
20920
20973
 
20921
- FormData.prototype._lengthRetriever = function (value, callback) {
20922
- if (hasOwn(value, 'fd')) {
20974
+ FormData.prototype._lengthRetriever = function(value, callback) {
20975
+
20976
+ if (value.hasOwnProperty('fd')) {
20977
+
20923
20978
  // take read range into a account
20924
20979
  // `end` = Infinity –> read file till the end
20925
20980
  //
@@ -20928,52 +20983,54 @@ FormData.prototype._lengthRetriever = function (value, callback) {
20928
20983
  // Fix it when node fixes it.
20929
20984
  // https://github.com/joyent/node/issues/7819
20930
20985
  if (value.end != undefined && value.end != Infinity && value.start != undefined) {
20986
+
20931
20987
  // when end specified
20932
20988
  // no need to calculate range
20933
20989
  // inclusive, starts with 0
20934
- callback(null, value.end + 1 - (value.start ? value.start : 0)); // eslint-disable-line callback-return
20990
+ callback(null, value.end + 1 - (value.start ? value.start : 0));
20935
20991
 
20936
- // not that fast snoopy
20992
+ // not that fast snoopy
20937
20993
  } else {
20938
20994
  // still need to fetch file size from fs
20939
- fs.stat(value.path, function (err, stat) {
20995
+ fs.stat(value.path, function(err, stat) {
20996
+
20997
+ var fileSize;
20998
+
20940
20999
  if (err) {
20941
21000
  callback(err);
20942
21001
  return;
20943
21002
  }
20944
21003
 
20945
21004
  // update final size based on the range options
20946
- var fileSize = stat.size - (value.start ? value.start : 0);
21005
+ fileSize = stat.size - (value.start ? value.start : 0);
20947
21006
  callback(null, fileSize);
20948
21007
  });
20949
21008
  }
20950
21009
 
20951
- // or http response
20952
- } else if (hasOwn(value, 'httpVersion')) {
20953
- callback(null, Number(value.headers['content-length'])); // eslint-disable-line callback-return
21010
+ // or http response
21011
+ } else if (value.hasOwnProperty('httpVersion')) {
21012
+ callback(null, +value.headers['content-length']);
20954
21013
 
20955
- // or request stream http://github.com/mikeal/request
20956
- } else if (hasOwn(value, 'httpModule')) {
21014
+ // or request stream http://github.com/mikeal/request
21015
+ } else if (value.hasOwnProperty('httpModule')) {
20957
21016
  // wait till response come back
20958
- value.on('response', function (response) {
21017
+ value.on('response', function(response) {
20959
21018
  value.pause();
20960
- callback(null, Number(response.headers['content-length']));
21019
+ callback(null, +response.headers['content-length']);
20961
21020
  });
20962
21021
  value.resume();
20963
21022
 
20964
- // something else
21023
+ // something else
20965
21024
  } else {
20966
- callback('Unknown stream'); // eslint-disable-line callback-return
21025
+ callback('Unknown stream');
20967
21026
  }
20968
21027
  };
20969
21028
 
20970
- FormData.prototype._multiPartHeader = function (field, value, options) {
20971
- /*
20972
- * custom header specified (as string)?
20973
- * it becomes responsible for boundary
20974
- * (e.g. to handle extra CRLFs on .NET servers)
20975
- */
20976
- if (typeof options.header === 'string') {
21029
+ FormData.prototype._multiPartHeader = function(field, value, options) {
21030
+ // custom header specified (as string)?
21031
+ // it becomes responsible for boundary
21032
+ // (e.g. to handle extra CRLFs on .NET servers)
21033
+ if (typeof options.header == 'string') {
20977
21034
  return options.header;
20978
21035
  }
20979
21036
 
@@ -20981,7 +21038,7 @@ FormData.prototype._multiPartHeader = function (field, value, options) {
20981
21038
  var contentType = this._getContentType(value, options);
20982
21039
 
20983
21040
  var contents = '';
20984
- var headers = {
21041
+ var headers = {
20985
21042
  // add custom disposition as third element or keep it two elements if not
20986
21043
  'Content-Disposition': ['form-data', 'name="' + field + '"'].concat(contentDisposition || []),
20987
21044
  // if no content type. allow it to be empty array
@@ -20989,74 +21046,77 @@ FormData.prototype._multiPartHeader = function (field, value, options) {
20989
21046
  };
20990
21047
 
20991
21048
  // allow custom headers.
20992
- if (typeof options.header === 'object') {
21049
+ if (typeof options.header == 'object') {
20993
21050
  populate(headers, options.header);
20994
21051
  }
20995
21052
 
20996
21053
  var header;
20997
- for (var prop in headers) { // eslint-disable-line no-restricted-syntax
20998
- if (hasOwn(headers, prop)) {
20999
- header = headers[prop];
21054
+ for (var prop in headers) {
21055
+ if (!headers.hasOwnProperty(prop)) continue;
21056
+ header = headers[prop];
21000
21057
 
21001
- // skip nullish headers.
21002
- if (header == null) {
21003
- continue; // eslint-disable-line no-restricted-syntax, no-continue
21004
- }
21058
+ // skip nullish headers.
21059
+ if (header == null) {
21060
+ continue;
21061
+ }
21005
21062
 
21006
- // convert all headers to arrays.
21007
- if (!Array.isArray(header)) {
21008
- header = [header];
21009
- }
21063
+ // convert all headers to arrays.
21064
+ if (!Array.isArray(header)) {
21065
+ header = [header];
21066
+ }
21010
21067
 
21011
- // add non-empty headers.
21012
- if (header.length) {
21013
- contents += prop + ': ' + header.join('; ') + FormData.LINE_BREAK;
21014
- }
21068
+ // add non-empty headers.
21069
+ if (header.length) {
21070
+ contents += prop + ': ' + header.join('; ') + FormData.LINE_BREAK;
21015
21071
  }
21016
21072
  }
21017
21073
 
21018
21074
  return '--' + this.getBoundary() + FormData.LINE_BREAK + contents + FormData.LINE_BREAK;
21019
21075
  };
21020
21076
 
21021
- FormData.prototype._getContentDisposition = function (value, options) { // eslint-disable-line consistent-return
21022
- var filename;
21077
+ FormData.prototype._getContentDisposition = function(value, options) {
21078
+
21079
+ var filename
21080
+ , contentDisposition
21081
+ ;
21023
21082
 
21024
21083
  if (typeof options.filepath === 'string') {
21025
21084
  // custom filepath for relative paths
21026
21085
  filename = path.normalize(options.filepath).replace(/\\/g, '/');
21027
- } else if (options.filename || (value && (value.name || value.path))) {
21028
- /*
21029
- * custom filename take precedence
21030
- * formidable and the browser add a name property
21031
- * fs- and request- streams have path property
21032
- */
21033
- filename = path.basename(options.filename || (value && (value.name || value.path)));
21034
- } else if (value && value.readable && hasOwn(value, 'httpVersion')) {
21086
+ } else if (options.filename || value.name || value.path) {
21087
+ // custom filename take precedence
21088
+ // formidable and the browser add a name property
21089
+ // fs- and request- streams have path property
21090
+ filename = path.basename(options.filename || value.name || value.path);
21091
+ } else if (value.readable && value.hasOwnProperty('httpVersion')) {
21035
21092
  // or try http response
21036
21093
  filename = path.basename(value.client._httpMessage.path || '');
21037
21094
  }
21038
21095
 
21039
21096
  if (filename) {
21040
- return 'filename="' + filename + '"';
21097
+ contentDisposition = 'filename="' + filename + '"';
21041
21098
  }
21099
+
21100
+ return contentDisposition;
21042
21101
  };
21043
21102
 
21044
- FormData.prototype._getContentType = function (value, options) {
21103
+ FormData.prototype._getContentType = function(value, options) {
21104
+
21045
21105
  // use custom content-type above all
21046
21106
  var contentType = options.contentType;
21047
21107
 
21048
21108
  // or try `name` from formidable, browser
21049
- if (!contentType && value && value.name) {
21109
+ if (!contentType && value.name) {
21050
21110
  contentType = mime.lookup(value.name);
21051
21111
  }
21052
21112
 
21053
21113
  // or try `path` from fs-, request- streams
21054
- if (!contentType && value && value.path) {
21114
+ if (!contentType && value.path) {
21055
21115
  contentType = mime.lookup(value.path);
21056
21116
  }
21057
21117
 
21058
21118
  // or if it's http-reponse
21059
- if (!contentType && value && value.readable && hasOwn(value, 'httpVersion')) {
21119
+ if (!contentType && value.readable && value.hasOwnProperty('httpVersion')) {
21060
21120
  contentType = value.headers['content-type'];
21061
21121
  }
21062
21122
 
@@ -21066,18 +21126,18 @@ FormData.prototype._getContentType = function (value, options) {
21066
21126
  }
21067
21127
 
21068
21128
  // fallback to the default content type if `value` is not simple value
21069
- if (!contentType && value && typeof value === 'object') {
21129
+ if (!contentType && typeof value == 'object') {
21070
21130
  contentType = FormData.DEFAULT_CONTENT_TYPE;
21071
21131
  }
21072
21132
 
21073
21133
  return contentType;
21074
21134
  };
21075
21135
 
21076
- FormData.prototype._multiPartFooter = function () {
21077
- return function (next) {
21136
+ FormData.prototype._multiPartFooter = function() {
21137
+ return function(next) {
21078
21138
  var footer = FormData.LINE_BREAK;
21079
21139
 
21080
- var lastPart = this._streams.length === 0;
21140
+ var lastPart = (this._streams.length === 0);
21081
21141
  if (lastPart) {
21082
21142
  footer += this._lastBoundary();
21083
21143
  }
@@ -21086,18 +21146,18 @@ FormData.prototype._multiPartFooter = function () {
21086
21146
  }.bind(this);
21087
21147
  };
21088
21148
 
21089
- FormData.prototype._lastBoundary = function () {
21149
+ FormData.prototype._lastBoundary = function() {
21090
21150
  return '--' + this.getBoundary() + '--' + FormData.LINE_BREAK;
21091
21151
  };
21092
21152
 
21093
- FormData.prototype.getHeaders = function (userHeaders) {
21153
+ FormData.prototype.getHeaders = function(userHeaders) {
21094
21154
  var header;
21095
21155
  var formHeaders = {
21096
21156
  'content-type': 'multipart/form-data; boundary=' + this.getBoundary()
21097
21157
  };
21098
21158
 
21099
- for (header in userHeaders) { // eslint-disable-line no-restricted-syntax
21100
- if (hasOwn(userHeaders, header)) {
21159
+ for (header in userHeaders) {
21160
+ if (userHeaders.hasOwnProperty(header)) {
21101
21161
  formHeaders[header.toLowerCase()] = userHeaders[header];
21102
21162
  }
21103
21163
  }
@@ -21105,14 +21165,11 @@ FormData.prototype.getHeaders = function (userHeaders) {
21105
21165
  return formHeaders;
21106
21166
  };
21107
21167
 
21108
- FormData.prototype.setBoundary = function (boundary) {
21109
- if (typeof boundary !== 'string') {
21110
- throw new TypeError('FormData boundary must be a string');
21111
- }
21168
+ FormData.prototype.setBoundary = function(boundary) {
21112
21169
  this._boundary = boundary;
21113
21170
  };
21114
21171
 
21115
- FormData.prototype.getBoundary = function () {
21172
+ FormData.prototype.getBoundary = function() {
21116
21173
  if (!this._boundary) {
21117
21174
  this._generateBoundary();
21118
21175
  }
@@ -21120,55 +21177,60 @@ FormData.prototype.getBoundary = function () {
21120
21177
  return this._boundary;
21121
21178
  };
21122
21179
 
21123
- FormData.prototype.getBuffer = function () {
21124
- var dataBuffer = new Buffer.alloc(0); // eslint-disable-line new-cap
21180
+ FormData.prototype.getBuffer = function() {
21181
+ var dataBuffer = new Buffer.alloc( 0 );
21125
21182
  var boundary = this.getBoundary();
21126
21183
 
21127
21184
  // Create the form content. Add Line breaks to the end of data.
21128
21185
  for (var i = 0, len = this._streams.length; i < len; i++) {
21129
21186
  if (typeof this._streams[i] !== 'function') {
21187
+
21130
21188
  // Add content to the buffer.
21131
- if (Buffer.isBuffer(this._streams[i])) {
21132
- dataBuffer = Buffer.concat([dataBuffer, this._streams[i]]);
21133
- } else {
21134
- dataBuffer = Buffer.concat([dataBuffer, Buffer.from(this._streams[i])]);
21189
+ if(Buffer.isBuffer(this._streams[i])) {
21190
+ dataBuffer = Buffer.concat( [dataBuffer, this._streams[i]]);
21191
+ }else {
21192
+ dataBuffer = Buffer.concat( [dataBuffer, Buffer.from(this._streams[i])]);
21135
21193
  }
21136
21194
 
21137
21195
  // Add break after content.
21138
- if (typeof this._streams[i] !== 'string' || this._streams[i].substring(2, boundary.length + 2) !== boundary) {
21139
- dataBuffer = Buffer.concat([dataBuffer, Buffer.from(FormData.LINE_BREAK)]);
21196
+ if (typeof this._streams[i] !== 'string' || this._streams[i].substring( 2, boundary.length + 2 ) !== boundary) {
21197
+ dataBuffer = Buffer.concat( [dataBuffer, Buffer.from(FormData.LINE_BREAK)] );
21140
21198
  }
21141
21199
  }
21142
21200
  }
21143
21201
 
21144
21202
  // Add the footer and return the Buffer object.
21145
- return Buffer.concat([dataBuffer, Buffer.from(this._lastBoundary())]);
21203
+ return Buffer.concat( [dataBuffer, Buffer.from(this._lastBoundary())] );
21146
21204
  };
21147
21205
 
21148
- FormData.prototype._generateBoundary = function () {
21206
+ FormData.prototype._generateBoundary = function() {
21149
21207
  // This generates a 50 character boundary similar to those used by Firefox.
21150
-
21151
21208
  // They are optimized for boyer-moore parsing.
21152
- this._boundary = '--------------------------' + crypto.randomBytes(12).toString('hex');
21209
+ var boundary = '--------------------------';
21210
+ for (var i = 0; i < 24; i++) {
21211
+ boundary += Math.floor(Math.random() * 10).toString(16);
21212
+ }
21213
+
21214
+ this._boundary = boundary;
21153
21215
  };
21154
21216
 
21155
21217
  // Note: getLengthSync DOESN'T calculate streams length
21156
- // As workaround one can calculate file size manually and add it as knownLength option
21157
- FormData.prototype.getLengthSync = function () {
21218
+ // As workaround one can calculate file size manually
21219
+ // and add it as knownLength option
21220
+ FormData.prototype.getLengthSync = function() {
21158
21221
  var knownLength = this._overheadLength + this._valueLength;
21159
21222
 
21160
- // Don't get confused, there are 3 "internal" streams for each keyval pair so it basically checks if there is any value added to the form
21223
+ // Don't get confused, there are 3 "internal" streams for each keyval pair
21224
+ // so it basically checks if there is any value added to the form
21161
21225
  if (this._streams.length) {
21162
21226
  knownLength += this._lastBoundary().length;
21163
21227
  }
21164
21228
 
21165
21229
  // https://github.com/form-data/form-data/issues/40
21166
21230
  if (!this.hasKnownLength()) {
21167
- /*
21168
- * Some async length retrievers are present
21169
- * therefore synchronous length calculation is false.
21170
- * Please use getLength(callback) to get proper length
21171
- */
21231
+ // Some async length retrievers are present
21232
+ // therefore synchronous length calculation is false.
21233
+ // Please use getLength(callback) to get proper length
21172
21234
  this._error(new Error('Cannot calculate proper length in synchronous way.'));
21173
21235
  }
21174
21236
 
@@ -21178,7 +21240,7 @@ FormData.prototype.getLengthSync = function () {
21178
21240
  // Public API to check if length of added values is known
21179
21241
  // https://github.com/form-data/form-data/issues/196
21180
21242
  // https://github.com/form-data/form-data/issues/262
21181
- FormData.prototype.hasKnownLength = function () {
21243
+ FormData.prototype.hasKnownLength = function() {
21182
21244
  var hasKnownLength = true;
21183
21245
 
21184
21246
  if (this._valuesToMeasure.length) {
@@ -21188,7 +21250,7 @@ FormData.prototype.hasKnownLength = function () {
21188
21250
  return hasKnownLength;
21189
21251
  };
21190
21252
 
21191
- FormData.prototype.getLength = function (cb) {
21253
+ FormData.prototype.getLength = function(cb) {
21192
21254
  var knownLength = this._overheadLength + this._valueLength;
21193
21255
 
21194
21256
  if (this._streams.length) {
@@ -21200,13 +21262,13 @@ FormData.prototype.getLength = function (cb) {
21200
21262
  return;
21201
21263
  }
21202
21264
 
21203
- asynckit.parallel(this._valuesToMeasure, this._lengthRetriever, function (err, values) {
21265
+ asynckit.parallel(this._valuesToMeasure, this._lengthRetriever, function(err, values) {
21204
21266
  if (err) {
21205
21267
  cb(err);
21206
21268
  return;
21207
21269
  }
21208
21270
 
21209
- values.forEach(function (length) {
21271
+ values.forEach(function(length) {
21210
21272
  knownLength += length;
21211
21273
  });
21212
21274
 
@@ -21214,26 +21276,31 @@ FormData.prototype.getLength = function (cb) {
21214
21276
  });
21215
21277
  };
21216
21278
 
21217
- FormData.prototype.submit = function (params, cb) {
21218
- var request;
21219
- var options;
21220
- var defaults = { method: 'post' };
21279
+ FormData.prototype.submit = function(params, cb) {
21280
+ var request
21281
+ , options
21282
+ , defaults = {method: 'post'}
21283
+ ;
21221
21284
 
21222
- // parse provided url if it's string or treat it as options object
21223
- if (typeof params === 'string') {
21224
- params = parseUrl(params); // eslint-disable-line no-param-reassign
21225
- /* eslint sort-keys: 0 */
21285
+ // parse provided url if it's string
21286
+ // or treat it as options object
21287
+ if (typeof params == 'string') {
21288
+
21289
+ params = parseUrl(params);
21226
21290
  options = populate({
21227
21291
  port: params.port,
21228
21292
  path: params.pathname,
21229
21293
  host: params.hostname,
21230
21294
  protocol: params.protocol
21231
21295
  }, defaults);
21232
- } else { // use custom params
21296
+
21297
+ // use custom params
21298
+ } else {
21299
+
21233
21300
  options = populate(params, defaults);
21234
21301
  // if no port provided use default one
21235
21302
  if (!options.port) {
21236
- options.port = options.protocol === 'https:' ? 443 : 80;
21303
+ options.port = options.protocol == 'https:' ? 443 : 80;
21237
21304
  }
21238
21305
  }
21239
21306
 
@@ -21241,14 +21308,14 @@ FormData.prototype.submit = function (params, cb) {
21241
21308
  options.headers = this.getHeaders(params.headers);
21242
21309
 
21243
21310
  // https if specified, fallback to http in any other case
21244
- if (options.protocol === 'https:') {
21311
+ if (options.protocol == 'https:') {
21245
21312
  request = https.request(options);
21246
21313
  } else {
21247
21314
  request = http.request(options);
21248
21315
  }
21249
21316
 
21250
21317
  // get content length and fire away
21251
- this.getLength(function (err, length) {
21318
+ this.getLength(function(err, length) {
21252
21319
  if (err && err !== 'Unknown stream') {
21253
21320
  this._error(err);
21254
21321
  return;
@@ -21267,7 +21334,7 @@ FormData.prototype.submit = function (params, cb) {
21267
21334
  request.removeListener('error', callback);
21268
21335
  request.removeListener('response', onResponse);
21269
21336
 
21270
- return cb.call(this, error, responce); // eslint-disable-line no-invalid-this
21337
+ return cb.call(this, error, responce);
21271
21338
  };
21272
21339
 
21273
21340
  onResponse = callback.bind(this, null);
@@ -21280,7 +21347,7 @@ FormData.prototype.submit = function (params, cb) {
21280
21347
  return request;
21281
21348
  };
21282
21349
 
21283
- FormData.prototype._error = function (err) {
21350
+ FormData.prototype._error = function(err) {
21284
21351
  if (!this.error) {
21285
21352
  this.error = err;
21286
21353
  this.pause();
@@ -21291,10 +21358,6 @@ FormData.prototype._error = function (err) {
21291
21358
  FormData.prototype.toString = function () {
21292
21359
  return '[object FormData]';
21293
21360
  };
21294
- setToStringTag(FormData, 'FormData');
21295
-
21296
- // Public API
21297
- module.exports = FormData;
21298
21361
 
21299
21362
 
21300
21363
  /***/ }),
@@ -21305,13 +21368,12 @@ module.exports = FormData;
21305
21368
  \*************************************************/
21306
21369
  /***/ ((module) => {
21307
21370
 
21308
- "use strict";
21309
-
21310
-
21311
21371
  // populates missing values
21312
- module.exports = function (dst, src) {
21313
- Object.keys(src).forEach(function (prop) {
21314
- dst[prop] = dst[prop] || src[prop]; // eslint-disable-line no-param-reassign
21372
+ module.exports = function(dst, src) {
21373
+
21374
+ Object.keys(src).forEach(function(prop)
21375
+ {
21376
+ dst[prop] = dst[prop] || src[prop];
21315
21377
  });
21316
21378
 
21317
21379
  return dst;
@@ -22028,25 +22090,6 @@ module.exports = function hasSymbols() {
22028
22090
  };
22029
22091
 
22030
22092
 
22031
- /***/ }),
22032
-
22033
- /***/ "../node_modules/has-tostringtag/shams.js":
22034
- /*!************************************************!*\
22035
- !*** ../node_modules/has-tostringtag/shams.js ***!
22036
- \************************************************/
22037
- /***/ ((module, __unused_webpack_exports, __webpack_require__) => {
22038
-
22039
- "use strict";
22040
-
22041
-
22042
- var hasSymbols = __webpack_require__(/*! has-symbols/shams */ "../node_modules/has-symbols/shams.js");
22043
-
22044
- /** @type {import('.')} */
22045
- module.exports = function hasToStringTagShams() {
22046
- return hasSymbols() && !!Symbol.toStringTag;
22047
- };
22048
-
22049
-
22050
22093
  /***/ }),
22051
22094
 
22052
22095
  /***/ "../node_modules/hasown/index.js":
@@ -27042,8 +27085,8 @@ class Axios {
27042
27085
 
27043
27086
  if (!synchronousRequestInterceptors) {
27044
27087
  const chain = [_dispatchRequest_js__WEBPACK_IMPORTED_MODULE_5__["default"].bind(this), undefined];
27045
- chain.unshift(...requestInterceptorChain);
27046
- chain.push(...responseInterceptorChain);
27088
+ chain.unshift.apply(chain, requestInterceptorChain);
27089
+ chain.push.apply(chain, responseInterceptorChain);
27047
27090
  len = chain.length;
27048
27091
 
27049
27092
  promise = Promise.resolve(config);
@@ -27922,7 +27965,7 @@ function mergeConfig(config1, config2) {
27922
27965
  headers: (a, b , prop) => mergeDeepProperties(headersToObject(a), headersToObject(b),prop, true)
27923
27966
  };
27924
27967
 
27925
- _utils_js__WEBPACK_IMPORTED_MODULE_1__["default"].forEach(Object.keys({...config1, ...config2}), function computeConfigValue(prop) {
27968
+ _utils_js__WEBPACK_IMPORTED_MODULE_1__["default"].forEach(Object.keys(Object.assign({}, config1, config2)), function computeConfigValue(prop) {
27926
27969
  const merge = mergeMap[prop] || mergeDeepProperties;
27927
27970
  const configValue = merge(config1[prop], config2[prop], prop);
27928
27971
  (_utils_js__WEBPACK_IMPORTED_MODULE_1__["default"].isUndefined(configValue) && merge !== mergeDirectKeys) || (config[prop] = configValue);
@@ -28239,7 +28282,7 @@ __webpack_require__.r(__webpack_exports__);
28239
28282
  /* harmony export */ __webpack_require__.d(__webpack_exports__, {
28240
28283
  /* harmony export */ VERSION: () => (/* binding */ VERSION)
28241
28284
  /* harmony export */ });
28242
- const VERSION = "1.11.0";
28285
+ const VERSION = "1.10.0";
28243
28286
 
28244
28287
  /***/ }),
28245
28288
 
@@ -29715,7 +29758,7 @@ function throttle(fn, freq) {
29715
29758
  clearTimeout(timer);
29716
29759
  timer = null;
29717
29760
  }
29718
- fn(...args);
29761
+ fn.apply(null, args);
29719
29762
  }
29720
29763
 
29721
29764
  const throttled = (...args) => {
@@ -30006,7 +30049,7 @@ __webpack_require__.r(__webpack_exports__);
30006
30049
 
30007
30050
 
30008
30051
  function toURLEncodedForm(data, options) {
30009
- return (0,_toFormData_js__WEBPACK_IMPORTED_MODULE_0__["default"])(data, new _platform_index_js__WEBPACK_IMPORTED_MODULE_1__["default"].classes.URLSearchParams(), {
30052
+ return (0,_toFormData_js__WEBPACK_IMPORTED_MODULE_0__["default"])(data, new _platform_index_js__WEBPACK_IMPORTED_MODULE_1__["default"].classes.URLSearchParams(), Object.assign({
30010
30053
  visitor: function(value, key, path, helpers) {
30011
30054
  if (_platform_index_js__WEBPACK_IMPORTED_MODULE_1__["default"].isNode && _utils_js__WEBPACK_IMPORTED_MODULE_2__["default"].isBuffer(value)) {
30012
30055
  this.append(key, value.toString('base64'));
@@ -30014,9 +30057,8 @@ function toURLEncodedForm(data, options) {
30014
30057
  }
30015
30058
 
30016
30059
  return helpers.defaultVisitor.apply(this, arguments);
30017
- },
30018
- ...options
30019
- });
30060
+ }
30061
+ }, options));
30020
30062
  }
30021
30063
 
30022
30064
 
@@ -30575,27 +30617,6 @@ const isPlainObject = (val) => {
30575
30617
  return (prototype === null || prototype === Object.prototype || Object.getPrototypeOf(prototype) === null) && !(toStringTag in val) && !(iterator in val);
30576
30618
  }
30577
30619
 
30578
- /**
30579
- * Determine if a value is an empty object (safely handles Buffers)
30580
- *
30581
- * @param {*} val The value to test
30582
- *
30583
- * @returns {boolean} True if value is an empty object, otherwise false
30584
- */
30585
- const isEmptyObject = (val) => {
30586
- // Early return for non-objects or Buffers to prevent RangeError
30587
- if (!isObject(val) || isBuffer(val)) {
30588
- return false;
30589
- }
30590
-
30591
- try {
30592
- return Object.keys(val).length === 0 && Object.getPrototypeOf(val) === Object.prototype;
30593
- } catch (e) {
30594
- // Fallback for any other objects that might cause RangeError with Object.keys()
30595
- return false;
30596
- }
30597
- }
30598
-
30599
30620
  /**
30600
30621
  * Determine if a value is a Date
30601
30622
  *
@@ -30718,11 +30739,6 @@ function forEach(obj, fn, {allOwnKeys = false} = {}) {
30718
30739
  fn.call(null, obj[i], i, obj);
30719
30740
  }
30720
30741
  } else {
30721
- // Buffer check
30722
- if (isBuffer(obj)) {
30723
- return;
30724
- }
30725
-
30726
30742
  // Iterate over object keys
30727
30743
  const keys = allOwnKeys ? Object.getOwnPropertyNames(obj) : Object.keys(obj);
30728
30744
  const len = keys.length;
@@ -30736,10 +30752,6 @@ function forEach(obj, fn, {allOwnKeys = false} = {}) {
30736
30752
  }
30737
30753
 
30738
30754
  function findKey(obj, key) {
30739
- if (isBuffer(obj)){
30740
- return null;
30741
- }
30742
-
30743
30755
  key = key.toLowerCase();
30744
30756
  const keys = Object.keys(obj);
30745
30757
  let i = keys.length;
@@ -31093,11 +31105,6 @@ const toJSONObject = (obj) => {
31093
31105
  return;
31094
31106
  }
31095
31107
 
31096
- //Buffer check
31097
- if (isBuffer(source)) {
31098
- return source;
31099
- }
31100
-
31101
31108
  if(!('toJSON' in source)) {
31102
31109
  stack[i] = source;
31103
31110
  const target = isArray(source) ? [] : {};
@@ -31169,7 +31176,6 @@ const isIterable = (thing) => thing != null && isFunction(thing[iterator]);
31169
31176
  isBoolean,
31170
31177
  isObject,
31171
31178
  isPlainObject,
31172
- isEmptyObject,
31173
31179
  isReadableStream,
31174
31180
  isRequest,
31175
31181
  isResponse,
@@ -32681,7 +32687,7 @@ function createClient(params, opts = {}) {
32681
32687
  const sdkMain = opts.type === 'plain' ? 'contentful-management-plain.js' : 'contentful-management.js';
32682
32688
  const userAgent = (0,contentful_sdk_core__WEBPACK_IMPORTED_MODULE_0__.getUserAgentHeader)(
32683
32689
  // @ts-expect-error
32684
- `${sdkMain}/${"11.54.4"}`, params.application, params.integration, params.feature);
32690
+ `${sdkMain}/${"11.55.0-canary.1"}`, params.application, params.integration, params.feature);
32685
32691
  const adapter = (0,_create_adapter__WEBPACK_IMPORTED_MODULE_1__.createAdapter)(_objectSpread(_objectSpread({}, params), {}, {
32686
32692
  userAgent
32687
32693
  }));