@wix/auto_sdk_online-programs_sections 1.0.20 → 1.0.22

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.
@@ -37,8 +37,6 @@ interface Section {
37
37
  programId?: string;
38
38
  /** Section title and deprecated backward-compatibility content fields. */
39
39
  description?: Description;
40
- /** Publication state of the section. If omitted when creating a section, the state defaults to `PUBLISHED`. */
41
- state?: StateWithLiterals;
42
40
  /**
43
41
  * Legacy total number of steps in the section.
44
42
  * @readonly
@@ -855,12 +853,13 @@ interface AccountInfo {
855
853
  * @public
856
854
  * @documentationMaturity preview
857
855
  * @requiredField section
856
+ * @requiredField section.programId
858
857
  * @permissionId ONLINE_PROGRAMS.SECTION_CREATE
859
858
  * @applicableIdentity APP
860
859
  * @returns Created section.
861
860
  * @fqn wix.onlineprograms.sections.v3.SectionsService.CreateSection
862
861
  */
863
- declare function createSection(section: Section, options?: CreateSectionOptions): Promise<NonNullablePaths<Section, `programId` | `description.title` | `state` | `oldTotalSteps` | `trialSection` | `ordering` | `delayInDays`, 3>>;
862
+ declare function createSection(section: NonNullablePaths<Section, `programId`, 2>, options?: CreateSectionOptions): Promise<NonNullablePaths<Section, `programId` | `description.title` | `oldTotalSteps` | `trialSection` | `ordering` | `delayInDays`, 3>>;
864
863
  interface CreateSectionOptions {
865
864
  /**
866
865
  * Predefined sets of fields to return.
@@ -878,11 +877,12 @@ interface CreateSectionOptions {
878
877
  * @public
879
878
  * @documentationMaturity preview
880
879
  * @requiredField sections
880
+ * @requiredField sections.programId
881
881
  * @permissionId ONLINE_PROGRAMS.SECTION_CREATE
882
882
  * @applicableIdentity APP
883
883
  * @fqn wix.onlineprograms.sections.v3.SectionsService.BulkCreateSections
884
884
  */
885
- declare function bulkCreateSections(sections: Section[], options?: BulkCreateSectionsOptions): Promise<NonNullablePaths<BulkCreateSectionsResponse, `results` | `results.${number}.itemMetadata.originalIndex` | `results.${number}.itemMetadata.success` | `results.${number}.itemMetadata.error.code` | `results.${number}.itemMetadata.error.description` | `results.${number}.action` | `bulkActionMetadata.totalSuccesses` | `bulkActionMetadata.totalFailures` | `bulkActionMetadata.undetailedFailures`, 6>>;
885
+ declare function bulkCreateSections(sections: NonNullablePaths<Section, `programId`, 2>[], options?: BulkCreateSectionsOptions): Promise<NonNullablePaths<BulkCreateSectionsResponse, `results` | `results.${number}.itemMetadata.originalIndex` | `results.${number}.itemMetadata.success` | `results.${number}.itemMetadata.error.code` | `results.${number}.itemMetadata.error.description` | `results.${number}.action` | `bulkActionMetadata.totalSuccesses` | `bulkActionMetadata.totalFailures` | `bulkActionMetadata.undetailedFailures`, 6>>;
886
886
  interface BulkCreateSectionsOptions {
887
887
  /**
888
888
  * Predefined sets of fields to return.
@@ -903,7 +903,7 @@ interface BulkCreateSectionsOptions {
903
903
  * @returns Retrieved section.
904
904
  * @fqn wix.onlineprograms.sections.v3.SectionsService.GetSection
905
905
  */
906
- declare function getSection(sectionId: string, options?: GetSectionOptions): Promise<NonNullablePaths<Section, `programId` | `description.title` | `state` | `oldTotalSteps` | `trialSection` | `ordering` | `delayInDays`, 3>>;
906
+ declare function getSection(sectionId: string, options?: GetSectionOptions): Promise<NonNullablePaths<Section, `programId` | `description.title` | `oldTotalSteps` | `trialSection` | `ordering` | `delayInDays`, 3>>;
907
907
  interface GetSectionOptions {
908
908
  /** Compatibility option for existing integrations. Current section responses return the section title. */
909
909
  descriptionFieldSet?: DescriptionFieldSetWithLiterals;
@@ -918,7 +918,7 @@ interface GetSectionOptions {
918
918
  *
919
919
  * Each time the section is updated, `revision` increments by 1. The current `revision` must be passed when updating the section. This ensures you're working with the latest section and prevents unintended overwrites.
920
920
  *
921
- * Use this method to update section content and settings. To reorder a section, call [Move Section](https://dev.wix.com/docs/api-reference/business-management/online-programs/sections/move-section). To publish a section, call [Publish Section](https://dev.wix.com/docs/api-reference/business-management/online-programs/sections/publish-section).
921
+ * Use this method to update section content and settings. To reorder a section, call [Move Section](https://dev.wix.com/docs/api-reference/business-management/online-programs/sections/move-section).
922
922
  * @param _id - Section ID.
923
923
  * @public
924
924
  * @documentationMaturity preview
@@ -929,7 +929,7 @@ interface GetSectionOptions {
929
929
  * @returns Updated section.
930
930
  * @fqn wix.onlineprograms.sections.v3.SectionsService.UpdateSection
931
931
  */
932
- declare function updateSection(_id: string, options?: NonNullablePaths<UpdateSectionOptions, `section.revision`, 3>): Promise<NonNullablePaths<Section, `programId` | `description.title` | `state` | `oldTotalSteps` | `trialSection` | `ordering` | `delayInDays`, 3>>;
932
+ declare function updateSection(_id: string, options?: NonNullablePaths<UpdateSectionOptions, `section.revision`, 3>): Promise<NonNullablePaths<Section, `programId` | `description.title` | `oldTotalSteps` | `trialSection` | `ordering` | `delayInDays`, 3>>;
933
933
  interface UpdateSectionOptions {
934
934
  section?: {
935
935
  /**
@@ -962,8 +962,6 @@ interface UpdateSectionOptions {
962
962
  programId?: string;
963
963
  /** Section title and deprecated backward-compatibility content fields. */
964
964
  description?: Description;
965
- /** Publication state of the section. If omitted when creating a section, the state defaults to `PUBLISHED`. */
966
- state?: StateWithLiterals;
967
965
  /**
968
966
  * Legacy total number of steps in the section.
969
967
  * @readonly
@@ -1014,8 +1012,8 @@ declare function deleteSection(sectionId: string): Promise<void>;
1014
1012
  * - `paging.limit` is `1000`.
1015
1013
  * - `paging.offset` is `0`.
1016
1014
  *
1017
- * Supported filter fields are `programId`, `id`, `delayInDays`, `trialSection`, and `state`.
1018
- * Supported sorting fields are `id`, `delayInDays`, `trialSection`, `state`, `createdDate`, and `ordering`. When sorting by a field other than `programId`, also filter by `programId`.
1015
+ * Supported filter fields are `programId`, `id`, `delayInDays`, and `trialSection`.
1016
+ * Supported sorting fields are `id`, `delayInDays`, `trialSection`, `createdDate`, and `ordering`. When sorting by a field other than `programId`, also filter by `programId`.
1019
1017
  * `descriptionFieldSet` is retained for backward compatibility. Current section responses return the section title.
1020
1018
  *
1021
1019
  * To learn about working with Query methods, see [API Query Language](https://dev.wix.com/docs/api-reference/articles/work-with-wix-apis/data-retrieval/about-the-wix-api-query-language), [Sorting and Paging](https://dev.wix.com/docs/api-reference/articles/work-with-wix-apis/data-retrieval/about-sorting-and-paging), and [Field Projection](https://dev.wix.com/docs/api-reference/articles/work-with-wix-apis/data-retrieval/about-field-projection).
@@ -1060,12 +1058,12 @@ interface SectionsQueryBuilder {
1060
1058
  * @param value - Value to compare against.
1061
1059
  * @documentationMaturity preview
1062
1060
  */
1063
- eq: (propertyName: '_id' | 'programId' | 'state' | 'trialSection' | 'delayInDays', value: any) => SectionsQueryBuilder;
1061
+ eq: (propertyName: '_id' | 'programId' | 'trialSection' | 'delayInDays', value: any) => SectionsQueryBuilder;
1064
1062
  /** @param propertyName - Property whose value is compared with `value`.
1065
1063
  * @param value - Value to compare against.
1066
1064
  * @documentationMaturity preview
1067
1065
  */
1068
- ne: (propertyName: '_id' | 'state' | 'trialSection' | 'delayInDays', value: any) => SectionsQueryBuilder;
1066
+ ne: (propertyName: '_id' | 'trialSection' | 'delayInDays', value: any) => SectionsQueryBuilder;
1069
1067
  /** @param propertyName - Property whose value is compared with `value`.
1070
1068
  * @param value - Value to compare against.
1071
1069
  * @documentationMaturity preview
@@ -1092,9 +1090,9 @@ interface SectionsQueryBuilder {
1092
1090
  */
1093
1091
  startsWith: (propertyName: '_id', value: string) => SectionsQueryBuilder;
1094
1092
  /** @documentationMaturity preview */
1095
- in: (propertyName: '_id' | 'state' | 'trialSection' | 'delayInDays', value: any) => SectionsQueryBuilder;
1093
+ in: (propertyName: '_id' | 'trialSection' | 'delayInDays', value: any) => SectionsQueryBuilder;
1096
1094
  /** @documentationMaturity preview */
1097
- exists: (propertyName: '_id' | 'state' | 'trialSection' | 'delayInDays', value: boolean) => SectionsQueryBuilder;
1095
+ exists: (propertyName: '_id' | 'trialSection' | 'delayInDays', value: boolean) => SectionsQueryBuilder;
1098
1096
  /** @param propertyNames - Properties used in the sort. To sort by multiple properties, pass properties as additional arguments.
1099
1097
  * @documentationMaturity preview
1100
1098
  */
@@ -1119,7 +1117,7 @@ interface SectionsQueryBuilder {
1119
1117
  * @fqn wix.onlineprograms.sections.v3.SectionsService.QuerySections
1120
1118
  * @requiredField query
1121
1119
  */
1122
- declare function typedQuerySections(query: SectionQuery, options?: QuerySectionsOptions): Promise<NonNullablePaths<QuerySectionsResponse, `sections` | `sections.${number}.programId` | `sections.${number}.description.title` | `sections.${number}.state` | `sections.${number}.oldTotalSteps` | `sections.${number}.trialSection` | `sections.${number}.ordering` | `sections.${number}.delayInDays`, 5>>;
1120
+ declare function typedQuerySections(query: SectionQuery, options?: QuerySectionsOptions): Promise<NonNullablePaths<QuerySectionsResponse, `sections` | `sections.${number}.programId` | `sections.${number}.description.title` | `sections.${number}.oldTotalSteps` | `sections.${number}.trialSection` | `sections.${number}.ordering` | `sections.${number}.delayInDays`, 5>>;
1123
1121
  interface SectionQuerySpec extends QuerySpec {
1124
1122
  paging: 'cursor';
1125
1123
  wql: [
@@ -1129,7 +1127,7 @@ interface SectionQuerySpec extends QuerySpec {
1129
1127
  sort: 'NONE';
1130
1128
  },
1131
1129
  {
1132
- fields: ['_id', 'delayInDays', 'state', 'trialSection'];
1130
+ fields: ['_id', 'delayInDays', 'trialSection'];
1133
1131
  operators: '*';
1134
1132
  sort: 'BOTH';
1135
1133
  },
@@ -1208,7 +1206,7 @@ declare const utils: {
1208
1206
  * @applicableIdentity APP
1209
1207
  * @fqn wix.onlineprograms.sections.v3.SectionsService.ListSections
1210
1208
  */
1211
- declare function listSections(programId: string, options?: ListSectionsOptions): Promise<NonNullablePaths<ListSectionsResponse, `sections` | `sections.${number}.programId` | `sections.${number}.description.title` | `sections.${number}.state` | `sections.${number}.oldTotalSteps` | `sections.${number}.trialSection` | `sections.${number}.ordering` | `sections.${number}.delayInDays`, 5>>;
1209
+ declare function listSections(programId: string, options?: ListSectionsOptions): Promise<NonNullablePaths<ListSectionsResponse, `sections` | `sections.${number}.programId` | `sections.${number}.description.title` | `sections.${number}.oldTotalSteps` | `sections.${number}.trialSection` | `sections.${number}.ordering` | `sections.${number}.delayInDays`, 5>>;
1212
1210
  interface ListSectionsOptions {
1213
1211
  /** Compatibility option for existing integrations. Current section responses return the section title. */
1214
1212
  descriptionFieldSet?: DescriptionFieldSetWithLiterals;
@@ -1230,7 +1228,7 @@ interface ListSectionsOptions {
1230
1228
  * @applicableIdentity APP
1231
1229
  * @fqn wix.onlineprograms.sections.v3.SectionsService.CloneSection
1232
1230
  */
1233
- declare function cloneSection(sectionId: string, options?: CloneSectionOptions): Promise<NonNullablePaths<CloneSectionResponse, `section.programId` | `section.description.title` | `section.state` | `section.oldTotalSteps` | `section.trialSection` | `section.ordering` | `section.delayInDays`, 4>>;
1231
+ declare function cloneSection(sectionId: string, options?: CloneSectionOptions): Promise<NonNullablePaths<CloneSectionResponse, `section.programId` | `section.description.title` | `section.oldTotalSteps` | `section.trialSection` | `section.ordering` | `section.delayInDays`, 4>>;
1234
1232
  interface CloneSectionOptions {
1235
1233
  /**
1236
1234
  * Predefined sets of fields to return.
@@ -1250,7 +1248,7 @@ interface CloneSectionOptions {
1250
1248
  * @applicableIdentity APP
1251
1249
  * @fqn wix.onlineprograms.sections.v3.SectionsService.MoveSection
1252
1250
  */
1253
- declare function moveSection(options?: MoveSectionOptions): Promise<NonNullablePaths<MoveSectionResponse, `section.programId` | `section.description.title` | `section.state` | `section.oldTotalSteps` | `section.trialSection` | `section.ordering` | `section.delayInDays`, 4>>;
1251
+ declare function moveSection(options?: MoveSectionOptions): Promise<NonNullablePaths<MoveSectionResponse, `section.programId` | `section.description.title` | `section.oldTotalSteps` | `section.trialSection` | `section.ordering` | `section.delayInDays`, 4>>;
1254
1252
  interface MoveSectionOptions {
1255
1253
  /**
1256
1254
  * ID of the section to move.
@@ -1270,32 +1268,5 @@ interface MoveSectionOptions {
1270
1268
  */
1271
1269
  fields?: RequestedFieldsWithLiterals[];
1272
1270
  }
1273
- /**
1274
- * Publishes a section.
1275
- *
1276
- * Each time the section is updated, `revision` increments by 1. The current `revision` must be passed when publishing the section. This ensures you're working with the latest section and prevents unintended overwrites.
1277
- *
1278
- * Publishing sets the section's `state` to `PUBLISHED`.
1279
- * @public
1280
- * @documentationMaturity preview
1281
- * @permissionId ONLINE_PROGRAMS.SECTION_UPDATE
1282
- * @applicableIdentity APP
1283
- * @fqn wix.onlineprograms.sections.v3.SectionsService.PublishSection
1284
- */
1285
- declare function publishSection(options?: PublishSectionOptions): Promise<NonNullablePaths<PublishSectionResponse, `section.programId` | `section.description.title` | `section.state` | `section.oldTotalSteps` | `section.trialSection` | `section.ordering` | `section.delayInDays`, 4>>;
1286
- interface PublishSectionOptions {
1287
- /**
1288
- * ID of the section to publish.
1289
- * @format GUID
1290
- */
1291
- sectionId?: string;
1292
- /** Current revision of the section. */
1293
- revision?: string;
1294
- /**
1295
- * Predefined sets of fields to return.
1296
- * @maxSize 1
1297
- */
1298
- fields?: RequestedFieldsWithLiterals[];
1299
- }
1300
1271
 
1301
- export { type AccountInfo, type ActionEvent, type AddressLocation, type ApplicationError, type BulkActionMetadata, BulkActionType, type BulkActionTypeWithLiterals, type BulkCloneSectionRequest, type BulkCloneSectionResponse, type BulkCreateSectionMigrationRequest, type BulkCreateSectionMigrationResponse, type BulkCreateSectionRequest, type BulkCreateSectionResponse, type BulkCreateSectionsOptions, type BulkCreateSectionsRequest, type BulkCreateSectionsResponse, type BulkSectionResult, type CloneSectionOptions, type CloneSectionRequest, type CloneSectionResponse, type CommonQueryWithEntityContext, type CreateSectionOptions, type CreateSectionRequest, type CreateSectionResponse, type CursorPaging, type CursorPagingMetadata, type CursorQuery, type CursorQueryPagingMethodOneOf, type Cursors, type DeleteAllProgramSectionsRequest, type DeleteAllProgramSectionsResponse, type DeleteByFilterOperation, type DeleteByIdsOperation, type DeleteSectionRequest, type DeleteSectionResponse, type Description, DescriptionFieldSet, type DescriptionFieldSetWithLiterals, type DescriptionMediaOneOf, type DocumentImage, type DocumentPayload, type DocumentUpdateOperation, type DomainEvent, type DomainEventBodyOneOf, type Empty, type EntityCreatedEvent, type EntityDeletedEvent, type EntityUpdatedEvent, Enum, type EnumWithLiterals, type ExtendedFields, type FocalPoint, type GetSectionOptions, type GetSectionRequest, type GetSectionResponse, type IdentificationData, type IdentificationDataIdOneOf, type IndexDocument, type ItemMetadata, type ListSectionsOptions, type ListSectionsRequest, type ListSectionsResponse, type MessageEnvelope, type MoveSectionOptions, type MoveSectionRequest, type MoveSectionResponse, type PublishSectionOptions, type PublishSectionRequest, type PublishSectionResponse, type QuerySectionsOptions, type QuerySectionsRequest, type QuerySectionsResponse, RequestedFields, type RequestedFieldsWithLiterals, type RestoreInfo, type RestoreSectionFromTrashRequest, type RestoreSectionFromTrashResponse, type SearchIndexingNotification, SearchIndexingNotificationState, type SearchIndexingNotificationStateWithLiterals, type Section, type SectionCloned, type SectionDeleted, type SectionMoved, type SectionPublished, type SectionQuery, type SectionQuerySpec, type SectionUpdated, type SectionsQueryBuilder, type SectionsQueryResult, SortOrder, type SortOrderWithLiterals, type Sorting, State, type StateWithLiterals, type UpdateByFilterOperation, type UpdateDocumentsEvent, type UpdateDocumentsEventOperationOneOf, type UpdateExistingOperation, type UpdateSectionOptions, type UpdateSectionRequest, type UpdateSectionResponse, type VideoResolution, WebhookIdentityType, type WebhookIdentityTypeWithLiterals, bulkCreateSections, cloneSection, createSection, deleteSection, getSection, listSections, moveSection, publishSection, querySections, typedQuerySections, updateSection, utils };
1272
+ export { type AccountInfo, type ActionEvent, type AddressLocation, type ApplicationError, type BulkActionMetadata, BulkActionType, type BulkActionTypeWithLiterals, type BulkCloneSectionRequest, type BulkCloneSectionResponse, type BulkCreateSectionMigrationRequest, type BulkCreateSectionMigrationResponse, type BulkCreateSectionRequest, type BulkCreateSectionResponse, type BulkCreateSectionsOptions, type BulkCreateSectionsRequest, type BulkCreateSectionsResponse, type BulkSectionResult, type CloneSectionOptions, type CloneSectionRequest, type CloneSectionResponse, type CommonQueryWithEntityContext, type CreateSectionOptions, type CreateSectionRequest, type CreateSectionResponse, type CursorPaging, type CursorPagingMetadata, type CursorQuery, type CursorQueryPagingMethodOneOf, type Cursors, type DeleteAllProgramSectionsRequest, type DeleteAllProgramSectionsResponse, type DeleteByFilterOperation, type DeleteByIdsOperation, type DeleteSectionRequest, type DeleteSectionResponse, type Description, DescriptionFieldSet, type DescriptionFieldSetWithLiterals, type DescriptionMediaOneOf, type DocumentImage, type DocumentPayload, type DocumentUpdateOperation, type DomainEvent, type DomainEventBodyOneOf, type Empty, type EntityCreatedEvent, type EntityDeletedEvent, type EntityUpdatedEvent, Enum, type EnumWithLiterals, type ExtendedFields, type FocalPoint, type GetSectionOptions, type GetSectionRequest, type GetSectionResponse, type IdentificationData, type IdentificationDataIdOneOf, type IndexDocument, type ItemMetadata, type ListSectionsOptions, type ListSectionsRequest, type ListSectionsResponse, type MessageEnvelope, type MoveSectionOptions, type MoveSectionRequest, type MoveSectionResponse, type PublishSectionRequest, type PublishSectionResponse, type QuerySectionsOptions, type QuerySectionsRequest, type QuerySectionsResponse, RequestedFields, type RequestedFieldsWithLiterals, type RestoreInfo, type RestoreSectionFromTrashRequest, type RestoreSectionFromTrashResponse, type SearchIndexingNotification, SearchIndexingNotificationState, type SearchIndexingNotificationStateWithLiterals, type Section, type SectionCloned, type SectionDeleted, type SectionMoved, type SectionPublished, type SectionQuery, type SectionQuerySpec, type SectionUpdated, type SectionsQueryBuilder, type SectionsQueryResult, SortOrder, type SortOrderWithLiterals, type Sorting, State, type StateWithLiterals, type UpdateByFilterOperation, type UpdateDocumentsEvent, type UpdateDocumentsEventOperationOneOf, type UpdateExistingOperation, type UpdateSectionOptions, type UpdateSectionRequest, type UpdateSectionResponse, type VideoResolution, WebhookIdentityType, type WebhookIdentityTypeWithLiterals, bulkCreateSections, cloneSection, createSection, deleteSection, getSection, listSections, moveSection, querySections, typedQuerySections, updateSection, utils };
@@ -679,61 +679,6 @@ function moveSection(payload) {
679
679
  }
680
680
  return __moveSection;
681
681
  }
682
- function publishSection(payload) {
683
- function __publishSection({ host }) {
684
- const metadata = {
685
- entityFqdn: "wix.online_programs.v3.section",
686
- method: "PATCH",
687
- methodFqn: "wix.onlineprograms.sections.v3.SectionsService.PublishSection",
688
- packageName: PACKAGE_NAME,
689
- migrationOptions: {
690
- optInTransformResponse: true
691
- },
692
- url: resolveWixOnlineprogramsSectionsV3SectionsServiceUrl({
693
- protoPath: "/v3/sections/publish",
694
- data: payload,
695
- host
696
- }),
697
- data: payload,
698
- transformResponse: (payload2) => transformPaths(payload2, [
699
- {
700
- transformFn: transformRESTTimestampToSDKTimestamp,
701
- paths: [
702
- { path: "section.createdDate" },
703
- { path: "section.updatedDate" },
704
- { path: "section.description.image.urlExpirationDate" },
705
- { path: "section.description.video.urlExpirationDate" },
706
- {
707
- path: "section.description.video.resolutions.urlExpirationDate"
708
- },
709
- {
710
- path: "section.description.video.resolutions.poster.urlExpirationDate"
711
- },
712
- { path: "section.description.video.posters.urlExpirationDate" }
713
- ]
714
- },
715
- {
716
- transformFn: transformRESTFloatToSDKFloat,
717
- paths: [
718
- { path: "section.ordering" },
719
- { path: "section.description.image.focalPoint.x" },
720
- { path: "section.description.image.focalPoint.y" },
721
- {
722
- path: "section.description.video.resolutions.poster.focalPoint.x"
723
- },
724
- {
725
- path: "section.description.video.resolutions.poster.focalPoint.y"
726
- },
727
- { path: "section.description.video.posters.focalPoint.x" },
728
- { path: "section.description.video.posters.focalPoint.y" }
729
- ]
730
- }
731
- ])
732
- };
733
- return metadata;
734
- }
735
- return __publishSection;
736
- }
737
682
 
738
683
  // src/online-programs-v3-section-sections.universal.ts
739
684
  import { transformSDKImageToRESTImage } from "@wix/sdk-runtime/transformations/image";
@@ -1225,48 +1170,6 @@ async function moveSection2(options) {
1225
1170
  throw transformedError;
1226
1171
  }
1227
1172
  }
1228
- async function publishSection2(options) {
1229
- const { httpClient, sideEffects } = arguments[1];
1230
- const payload = renameKeysFromSDKRequestToRESTRequest({
1231
- sectionId: options?.sectionId,
1232
- revision: options?.revision,
1233
- fields: options?.fields
1234
- });
1235
- const reqOpts = publishSection(payload);
1236
- sideEffects?.onSiteCall?.();
1237
- try {
1238
- const result = await httpClient.request(reqOpts);
1239
- sideEffects?.onSuccess?.(result);
1240
- return renameKeysFromRESTResponseToSDKResponse(
1241
- transformPaths2(result.data, [
1242
- {
1243
- transformFn: transformRESTImageToSDKImage,
1244
- paths: [{ path: "section.description.image" }]
1245
- },
1246
- {
1247
- transformFn: transformRESTVideoV2ToSDKVideoV2,
1248
- paths: [{ path: "section.description.video" }]
1249
- }
1250
- ])
1251
- );
1252
- } catch (err) {
1253
- const transformedError = sdkTransformError(
1254
- err,
1255
- {
1256
- spreadPathsToArguments: {},
1257
- explicitPathsToArguments: {
1258
- sectionId: "$[0].sectionId",
1259
- revision: "$[0].revision",
1260
- fields: "$[0].fields"
1261
- },
1262
- singleArgumentUnchanged: false
1263
- },
1264
- ["options"]
1265
- );
1266
- sideEffects?.onError?.(err);
1267
- throw transformedError;
1268
- }
1269
- }
1270
1173
  export {
1271
1174
  BulkActionType,
1272
1175
  DescriptionFieldSet,
@@ -1283,7 +1186,6 @@ export {
1283
1186
  getSection2 as getSection,
1284
1187
  listSections2 as listSections,
1285
1188
  moveSection2 as moveSection,
1286
- publishSection2 as publishSection,
1287
1189
  querySections2 as querySections,
1288
1190
  typedQuerySections,
1289
1191
  updateSection2 as updateSection,