@wix/auto_sdk_online-programs_sections 1.0.25 → 1.0.27

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.
@@ -1,13 +1,13 @@
1
1
  import { HttpClient, NonNullablePaths, MaybeContext, BuildRESTFunction } from '@wix/sdk-types';
2
2
  import { Section, CreateSectionOptions, BulkCreateSectionsOptions, BulkCreateSectionsResponse, GetSectionOptions, UpdateSectionOptions, ListSectionsOptions, ListSectionsResponse, CloneSectionOptions, CloneSectionResponse, MoveSectionOptions, MoveSectionResponse, SectionQuery, QuerySectionsOptions, typedQuerySections, SectionsQueryBuilder } from './index.typings.js';
3
- export { AccountInfo, ActionEvent, AddressLocation, ApplicationError, BulkActionMetadata, BulkActionType, BulkActionTypeWithLiterals, BulkCloneSectionRequest, BulkCloneSectionResponse, BulkCreateSectionMigrationRequest, BulkCreateSectionMigrationResponse, BulkCreateSectionRequest, BulkCreateSectionResponse, BulkCreateSectionsRequest, BulkSectionResult, CloneSectionRequest, CommonQueryWithEntityContext, CreateSectionRequest, CreateSectionResponse, CursorPaging, CursorPagingMetadata, CursorQuery, CursorQueryPagingMethodOneOf, Cursors, DeleteAllProgramSectionsRequest, DeleteAllProgramSectionsResponse, DeleteByFilterOperation, DeleteByIdsOperation, DeleteSectionRequest, DeleteSectionResponse, Description, DescriptionFieldSet, DescriptionFieldSetWithLiterals, DescriptionMediaOneOf, DocumentImage, DocumentPayload, DocumentUpdateOperation, DomainEvent, DomainEventBodyOneOf, Empty, EntityCreatedEvent, EntityDeletedEvent, EntityUpdatedEvent, Enum, EnumWithLiterals, ExtendedFields, FocalPoint, GetSectionRequest, GetSectionResponse, IdentificationData, IdentificationDataIdOneOf, IndexDocument, ItemMetadata, ListSectionsRequest, MessageEnvelope, MoveSectionRequest, PublishSectionRequest, PublishSectionResponse, QuerySectionsRequest, QuerySectionsResponse, RequestedFields, RequestedFieldsWithLiterals, RestoreInfo, RestoreSectionFromTrashRequest, RestoreSectionFromTrashResponse, SearchIndexingNotification, SearchIndexingNotificationState, SearchIndexingNotificationStateWithLiterals, SectionCloned, SectionDeleted, SectionMoved, SectionPublished, SectionQuerySpec, SectionUpdated, SectionsQueryResult, SortOrder, SortOrderWithLiterals, Sorting, State, StateWithLiterals, UpdateByFilterOperation, UpdateDocumentsEvent, UpdateDocumentsEventOperationOneOf, UpdateExistingOperation, UpdateSectionRequest, UpdateSectionResponse, VideoResolution, WebhookIdentityType, WebhookIdentityTypeWithLiterals, utils } from './index.typings.js';
3
+ export { AccountInfo, ActionEvent, AddressLocation, ApplicationError, BulkActionMetadata, BulkActionType, BulkActionTypeWithLiterals, BulkCloneSectionRequest, BulkCloneSectionResponse, BulkCreateSectionMigrationRequest, BulkCreateSectionMigrationResponse, BulkCreateSectionRequest, BulkCreateSectionResponse, BulkCreateSectionsRequest, BulkSectionResult, CloneSectionRequest, CommonQueryWithEntityContext, CreateSectionRequest, CreateSectionResponse, CursorPaging, CursorPagingMetadata, CursorQuery, CursorQueryPagingMethodOneOf, Cursors, DeleteAllProgramSectionsRequest, DeleteAllProgramSectionsResponse, DeleteByFilterOperation, DeleteByIdsOperation, DeleteSectionRequest, DeleteSectionResponse, Description, DescriptionFieldSet, DescriptionFieldSetWithLiterals, DocumentImage, DocumentPayload, DocumentUpdateOperation, DomainEvent, DomainEventBodyOneOf, Empty, EntityCreatedEvent, EntityDeletedEvent, EntityUpdatedEvent, Enum, EnumWithLiterals, ExtendedFields, GetSectionRequest, GetSectionResponse, IdentificationData, IdentificationDataIdOneOf, IndexDocument, ItemMetadata, ListSectionsRequest, MessageEnvelope, MoveSectionRequest, PublishSectionRequest, PublishSectionResponse, QuerySectionsRequest, QuerySectionsResponse, RequestedFields, RequestedFieldsWithLiterals, RestoreInfo, RestoreSectionFromTrashRequest, RestoreSectionFromTrashResponse, SearchIndexingNotification, SearchIndexingNotificationState, SearchIndexingNotificationStateWithLiterals, SectionCloned, SectionDeleted, SectionMoved, SectionPublished, SectionQuerySpec, SectionUpdated, SectionsQueryResult, SortOrder, SortOrderWithLiterals, Sorting, State, StateWithLiterals, UpdateByFilterOperation, UpdateDocumentsEvent, UpdateDocumentsEventOperationOneOf, UpdateExistingOperation, UpdateSectionRequest, UpdateSectionResponse, WebhookIdentityType, WebhookIdentityTypeWithLiterals, utils } from './index.typings.js';
4
4
 
5
5
  declare function createSection$1(httpClient: HttpClient): CreateSectionSignature;
6
6
  interface CreateSectionSignature {
7
7
  /**
8
8
  * Creates a section.
9
9
  *
10
- * The section is added to the program identified by `section.program_id`. Provide that program ID in the request. Set `section.description.title` for the section title. `section.description.details`, `section.description.image`, and `section.description.video` are deprecated backward-compatibility fields. The stored ordering value is assigned automatically.
10
+ * The section is added to the program identified by `section.program_id`. Provide that program ID in the request. Set `section.description.title` for the section title. The stored ordering value is assigned automatically.
11
11
  *
12
12
  * To create multiple sections in a single API call, call [Bulk Create Sections](https://dev.wix.com/docs/api-reference/business-management/online-programs/sections/bulk-create-sections).
13
13
  * @param - Section to create. Must include `section.program_id`.
@@ -20,7 +20,7 @@ interface BulkCreateSectionsSignature {
20
20
  /**
21
21
  * Creates up to 100 sections in a single API call.
22
22
  *
23
- * All sections in the request must include `program_id` and belong to the same program. Set `description.title` for each section title. `description.details`, `description.image`, and `description.video` are deprecated backward-compatibility fields. The stored ordering values are assigned automatically.
23
+ * All sections in the request must include `program_id` and belong to the same program. Set `description.title` for each section title. The stored ordering values are assigned automatically.
24
24
  *
25
25
  * To create a single section, call [Create Section](https://dev.wix.com/docs/api-reference/business-management/online-programs/sections/create-section).
26
26
  * @param - List of sections to create. Each section must include `program_id`, and all sections must belong to the same program.
@@ -162,27 +162,12 @@ function createSection(payload) {
162
162
  transformFn: import_timestamp.transformSDKTimestampToRESTTimestamp,
163
163
  paths: [
164
164
  { path: "section.createdDate" },
165
- { path: "section.updatedDate" },
166
- { path: "section.description.image.urlExpirationDate" },
167
- { path: "section.description.video.urlExpirationDate" },
168
- { path: "section.description.video.resolutions.urlExpirationDate" },
169
- {
170
- path: "section.description.video.resolutions.poster.urlExpirationDate"
171
- },
172
- { path: "section.description.video.posters.urlExpirationDate" }
165
+ { path: "section.updatedDate" }
173
166
  ]
174
167
  },
175
168
  {
176
169
  transformFn: import_float.transformSDKFloatToRESTFloat,
177
- paths: [
178
- { path: "section.ordering" },
179
- { path: "section.description.image.focalPoint.x" },
180
- { path: "section.description.image.focalPoint.y" },
181
- { path: "section.description.video.resolutions.poster.focalPoint.x" },
182
- { path: "section.description.video.resolutions.poster.focalPoint.y" },
183
- { path: "section.description.video.posters.focalPoint.x" },
184
- { path: "section.description.video.posters.focalPoint.y" }
185
- ]
170
+ paths: [{ path: "section.ordering" }]
186
171
  }
187
172
  ]);
188
173
  const metadata = {
@@ -204,33 +189,12 @@ function createSection(payload) {
204
189
  transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
205
190
  paths: [
206
191
  { path: "section.createdDate" },
207
- { path: "section.updatedDate" },
208
- { path: "section.description.image.urlExpirationDate" },
209
- { path: "section.description.video.urlExpirationDate" },
210
- {
211
- path: "section.description.video.resolutions.urlExpirationDate"
212
- },
213
- {
214
- path: "section.description.video.resolutions.poster.urlExpirationDate"
215
- },
216
- { path: "section.description.video.posters.urlExpirationDate" }
192
+ { path: "section.updatedDate" }
217
193
  ]
218
194
  },
219
195
  {
220
196
  transformFn: import_float2.transformRESTFloatToSDKFloat,
221
- paths: [
222
- { path: "section.ordering" },
223
- { path: "section.description.image.focalPoint.x" },
224
- { path: "section.description.image.focalPoint.y" },
225
- {
226
- path: "section.description.video.resolutions.poster.focalPoint.x"
227
- },
228
- {
229
- path: "section.description.video.resolutions.poster.focalPoint.y"
230
- },
231
- { path: "section.description.video.posters.focalPoint.x" },
232
- { path: "section.description.video.posters.focalPoint.y" }
233
- ]
197
+ paths: [{ path: "section.ordering" }]
234
198
  }
235
199
  ])
236
200
  };
@@ -245,31 +209,12 @@ function bulkCreateSections(payload) {
245
209
  transformFn: import_timestamp.transformSDKTimestampToRESTTimestamp,
246
210
  paths: [
247
211
  { path: "sections.createdDate" },
248
- { path: "sections.updatedDate" },
249
- { path: "sections.description.image.urlExpirationDate" },
250
- { path: "sections.description.video.urlExpirationDate" },
251
- { path: "sections.description.video.resolutions.urlExpirationDate" },
252
- {
253
- path: "sections.description.video.resolutions.poster.urlExpirationDate"
254
- },
255
- { path: "sections.description.video.posters.urlExpirationDate" }
212
+ { path: "sections.updatedDate" }
256
213
  ]
257
214
  },
258
215
  {
259
216
  transformFn: import_float.transformSDKFloatToRESTFloat,
260
- paths: [
261
- { path: "sections.ordering" },
262
- { path: "sections.description.image.focalPoint.x" },
263
- { path: "sections.description.image.focalPoint.y" },
264
- {
265
- path: "sections.description.video.resolutions.poster.focalPoint.x"
266
- },
267
- {
268
- path: "sections.description.video.resolutions.poster.focalPoint.y"
269
- },
270
- { path: "sections.description.video.posters.focalPoint.x" },
271
- { path: "sections.description.video.posters.focalPoint.y" }
272
- ]
217
+ paths: [{ path: "sections.ordering" }]
273
218
  }
274
219
  ]);
275
220
  const metadata = {
@@ -291,35 +236,12 @@ function bulkCreateSections(payload) {
291
236
  transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
292
237
  paths: [
293
238
  { path: "results.item.createdDate" },
294
- { path: "results.item.updatedDate" },
295
- { path: "results.item.description.image.urlExpirationDate" },
296
- { path: "results.item.description.video.urlExpirationDate" },
297
- {
298
- path: "results.item.description.video.resolutions.urlExpirationDate"
299
- },
300
- {
301
- path: "results.item.description.video.resolutions.poster.urlExpirationDate"
302
- },
303
- {
304
- path: "results.item.description.video.posters.urlExpirationDate"
305
- }
239
+ { path: "results.item.updatedDate" }
306
240
  ]
307
241
  },
308
242
  {
309
243
  transformFn: import_float2.transformRESTFloatToSDKFloat,
310
- paths: [
311
- { path: "results.item.ordering" },
312
- { path: "results.item.description.image.focalPoint.x" },
313
- { path: "results.item.description.image.focalPoint.y" },
314
- {
315
- path: "results.item.description.video.resolutions.poster.focalPoint.x"
316
- },
317
- {
318
- path: "results.item.description.video.resolutions.poster.focalPoint.y"
319
- },
320
- { path: "results.item.description.video.posters.focalPoint.x" },
321
- { path: "results.item.description.video.posters.focalPoint.y" }
322
- ]
244
+ paths: [{ path: "results.item.ordering" }]
323
245
  }
324
246
  ])
325
247
  };
@@ -348,33 +270,12 @@ function getSection(payload) {
348
270
  transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
349
271
  paths: [
350
272
  { path: "section.createdDate" },
351
- { path: "section.updatedDate" },
352
- { path: "section.description.image.urlExpirationDate" },
353
- { path: "section.description.video.urlExpirationDate" },
354
- {
355
- path: "section.description.video.resolutions.urlExpirationDate"
356
- },
357
- {
358
- path: "section.description.video.resolutions.poster.urlExpirationDate"
359
- },
360
- { path: "section.description.video.posters.urlExpirationDate" }
273
+ { path: "section.updatedDate" }
361
274
  ]
362
275
  },
363
276
  {
364
277
  transformFn: import_float2.transformRESTFloatToSDKFloat,
365
- paths: [
366
- { path: "section.ordering" },
367
- { path: "section.description.image.focalPoint.x" },
368
- { path: "section.description.image.focalPoint.y" },
369
- {
370
- path: "section.description.video.resolutions.poster.focalPoint.x"
371
- },
372
- {
373
- path: "section.description.video.resolutions.poster.focalPoint.y"
374
- },
375
- { path: "section.description.video.posters.focalPoint.x" },
376
- { path: "section.description.video.posters.focalPoint.y" }
377
- ]
278
+ paths: [{ path: "section.ordering" }]
378
279
  }
379
280
  ])
380
281
  };
@@ -393,27 +294,12 @@ function updateSection(payload) {
393
294
  transformFn: import_timestamp.transformSDKTimestampToRESTTimestamp,
394
295
  paths: [
395
296
  { path: "section.createdDate" },
396
- { path: "section.updatedDate" },
397
- { path: "section.description.image.urlExpirationDate" },
398
- { path: "section.description.video.urlExpirationDate" },
399
- { path: "section.description.video.resolutions.urlExpirationDate" },
400
- {
401
- path: "section.description.video.resolutions.poster.urlExpirationDate"
402
- },
403
- { path: "section.description.video.posters.urlExpirationDate" }
297
+ { path: "section.updatedDate" }
404
298
  ]
405
299
  },
406
300
  {
407
301
  transformFn: import_float.transformSDKFloatToRESTFloat,
408
- paths: [
409
- { path: "section.ordering" },
410
- { path: "section.description.image.focalPoint.x" },
411
- { path: "section.description.image.focalPoint.y" },
412
- { path: "section.description.video.resolutions.poster.focalPoint.x" },
413
- { path: "section.description.video.resolutions.poster.focalPoint.y" },
414
- { path: "section.description.video.posters.focalPoint.x" },
415
- { path: "section.description.video.posters.focalPoint.y" }
416
- ]
302
+ paths: [{ path: "section.ordering" }]
417
303
  }
418
304
  ]);
419
305
  const metadata = {
@@ -435,33 +321,12 @@ function updateSection(payload) {
435
321
  transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
436
322
  paths: [
437
323
  { path: "section.createdDate" },
438
- { path: "section.updatedDate" },
439
- { path: "section.description.image.urlExpirationDate" },
440
- { path: "section.description.video.urlExpirationDate" },
441
- {
442
- path: "section.description.video.resolutions.urlExpirationDate"
443
- },
444
- {
445
- path: "section.description.video.resolutions.poster.urlExpirationDate"
446
- },
447
- { path: "section.description.video.posters.urlExpirationDate" }
324
+ { path: "section.updatedDate" }
448
325
  ]
449
326
  },
450
327
  {
451
328
  transformFn: import_float2.transformRESTFloatToSDKFloat,
452
- paths: [
453
- { path: "section.ordering" },
454
- { path: "section.description.image.focalPoint.x" },
455
- { path: "section.description.image.focalPoint.y" },
456
- {
457
- path: "section.description.video.resolutions.poster.focalPoint.x"
458
- },
459
- {
460
- path: "section.description.video.resolutions.poster.focalPoint.y"
461
- },
462
- { path: "section.description.video.posters.focalPoint.x" },
463
- { path: "section.description.video.posters.focalPoint.y" }
464
- ]
329
+ paths: [{ path: "section.ordering" }]
465
330
  }
466
331
  ])
467
332
  };
@@ -520,33 +385,12 @@ function querySections(payload) {
520
385
  transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
521
386
  paths: [
522
387
  { path: "sections.createdDate" },
523
- { path: "sections.updatedDate" },
524
- { path: "sections.description.image.urlExpirationDate" },
525
- { path: "sections.description.video.urlExpirationDate" },
526
- {
527
- path: "sections.description.video.resolutions.urlExpirationDate"
528
- },
529
- {
530
- path: "sections.description.video.resolutions.poster.urlExpirationDate"
531
- },
532
- { path: "sections.description.video.posters.urlExpirationDate" }
388
+ { path: "sections.updatedDate" }
533
389
  ]
534
390
  },
535
391
  {
536
392
  transformFn: import_float2.transformRESTFloatToSDKFloat,
537
- paths: [
538
- { path: "sections.ordering" },
539
- { path: "sections.description.image.focalPoint.x" },
540
- { path: "sections.description.image.focalPoint.y" },
541
- {
542
- path: "sections.description.video.resolutions.poster.focalPoint.x"
543
- },
544
- {
545
- path: "sections.description.video.resolutions.poster.focalPoint.y"
546
- },
547
- { path: "sections.description.video.posters.focalPoint.x" },
548
- { path: "sections.description.video.posters.focalPoint.y" }
549
- ]
393
+ paths: [{ path: "sections.ordering" }]
550
394
  }
551
395
  ])
552
396
  };
@@ -575,33 +419,12 @@ function listSections(payload) {
575
419
  transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
576
420
  paths: [
577
421
  { path: "sections.createdDate" },
578
- { path: "sections.updatedDate" },
579
- { path: "sections.description.image.urlExpirationDate" },
580
- { path: "sections.description.video.urlExpirationDate" },
581
- {
582
- path: "sections.description.video.resolutions.urlExpirationDate"
583
- },
584
- {
585
- path: "sections.description.video.resolutions.poster.urlExpirationDate"
586
- },
587
- { path: "sections.description.video.posters.urlExpirationDate" }
422
+ { path: "sections.updatedDate" }
588
423
  ]
589
424
  },
590
425
  {
591
426
  transformFn: import_float2.transformRESTFloatToSDKFloat,
592
- paths: [
593
- { path: "sections.ordering" },
594
- { path: "sections.description.image.focalPoint.x" },
595
- { path: "sections.description.image.focalPoint.y" },
596
- {
597
- path: "sections.description.video.resolutions.poster.focalPoint.x"
598
- },
599
- {
600
- path: "sections.description.video.resolutions.poster.focalPoint.y"
601
- },
602
- { path: "sections.description.video.posters.focalPoint.x" },
603
- { path: "sections.description.video.posters.focalPoint.y" }
604
- ]
427
+ paths: [{ path: "sections.ordering" }]
605
428
  }
606
429
  ])
607
430
  };
@@ -630,33 +453,12 @@ function cloneSection(payload) {
630
453
  transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
631
454
  paths: [
632
455
  { path: "section.createdDate" },
633
- { path: "section.updatedDate" },
634
- { path: "section.description.image.urlExpirationDate" },
635
- { path: "section.description.video.urlExpirationDate" },
636
- {
637
- path: "section.description.video.resolutions.urlExpirationDate"
638
- },
639
- {
640
- path: "section.description.video.resolutions.poster.urlExpirationDate"
641
- },
642
- { path: "section.description.video.posters.urlExpirationDate" }
456
+ { path: "section.updatedDate" }
643
457
  ]
644
458
  },
645
459
  {
646
460
  transformFn: import_float2.transformRESTFloatToSDKFloat,
647
- paths: [
648
- { path: "section.ordering" },
649
- { path: "section.description.image.focalPoint.x" },
650
- { path: "section.description.image.focalPoint.y" },
651
- {
652
- path: "section.description.video.resolutions.poster.focalPoint.x"
653
- },
654
- {
655
- path: "section.description.video.resolutions.poster.focalPoint.y"
656
- },
657
- { path: "section.description.video.posters.focalPoint.x" },
658
- { path: "section.description.video.posters.focalPoint.y" }
659
- ]
461
+ paths: [{ path: "section.ordering" }]
660
462
  }
661
463
  ])
662
464
  };
@@ -685,33 +487,12 @@ function moveSection(payload) {
685
487
  transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
686
488
  paths: [
687
489
  { path: "section.createdDate" },
688
- { path: "section.updatedDate" },
689
- { path: "section.description.image.urlExpirationDate" },
690
- { path: "section.description.video.urlExpirationDate" },
691
- {
692
- path: "section.description.video.resolutions.urlExpirationDate"
693
- },
694
- {
695
- path: "section.description.video.resolutions.poster.urlExpirationDate"
696
- },
697
- { path: "section.description.video.posters.urlExpirationDate" }
490
+ { path: "section.updatedDate" }
698
491
  ]
699
492
  },
700
493
  {
701
494
  transformFn: import_float2.transformRESTFloatToSDKFloat,
702
- paths: [
703
- { path: "section.ordering" },
704
- { path: "section.description.image.focalPoint.x" },
705
- { path: "section.description.image.focalPoint.y" },
706
- {
707
- path: "section.description.video.resolutions.poster.focalPoint.x"
708
- },
709
- {
710
- path: "section.description.video.resolutions.poster.focalPoint.y"
711
- },
712
- { path: "section.description.video.posters.focalPoint.x" },
713
- { path: "section.description.video.posters.focalPoint.y" }
714
- ]
495
+ paths: [{ path: "section.ordering" }]
715
496
  }
716
497
  ])
717
498
  };
@@ -721,10 +502,6 @@ function moveSection(payload) {
721
502
  }
722
503
 
723
504
  // src/online-programs-v3-section-sections.universal.ts
724
- var import_image = require("@wix/sdk-runtime/transformations/image");
725
- var import_image2 = require("@wix/sdk-runtime/transformations/image");
726
- var import_video_v2 = require("@wix/sdk-runtime/transformations/video-v2");
727
- var import_video_v22 = require("@wix/sdk-runtime/transformations/video-v2");
728
505
  var import_transform_paths2 = require("@wix/sdk-runtime/transformations/transform-paths");
729
506
  var import_query_builder_utils = require("@wix/sdk-runtime/query-builder-utils");
730
507
  var State = /* @__PURE__ */ ((State2) => {
@@ -778,39 +555,16 @@ var WebhookIdentityType = /* @__PURE__ */ ((WebhookIdentityType2) => {
778
555
  })(WebhookIdentityType || {});
779
556
  async function createSection2(section, options) {
780
557
  const { httpClient, sideEffects } = arguments[2];
781
- const payload = (0, import_transform_paths2.transformPaths)(
782
- (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
783
- section,
784
- fields: options?.fields
785
- }),
786
- [
787
- {
788
- transformFn: import_image.transformSDKImageToRESTImage,
789
- paths: [{ path: "section.description.image" }]
790
- },
791
- {
792
- transformFn: import_video_v2.transformSDKVideoV2ToRESTVideoV2,
793
- paths: [{ path: "section.description.video" }]
794
- }
795
- ]
796
- );
558
+ const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
559
+ section,
560
+ fields: options?.fields
561
+ });
797
562
  const reqOpts = createSection(payload);
798
563
  sideEffects?.onSiteCall?.();
799
564
  try {
800
565
  const result = await httpClient.request(reqOpts);
801
566
  sideEffects?.onSuccess?.(result);
802
- return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(
803
- (0, import_transform_paths2.transformPaths)(result.data, [
804
- {
805
- transformFn: import_image2.transformRESTImageToSDKImage,
806
- paths: [{ path: "section.description.image" }]
807
- },
808
- {
809
- transformFn: import_video_v22.transformRESTVideoV2ToSDKVideoV2,
810
- paths: [{ path: "section.description.video" }]
811
- }
812
- ])
813
- )?.section;
567
+ return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(result.data)?.section;
814
568
  } catch (err) {
815
569
  const transformedError = (0, import_transform_error.transformError)(
816
570
  err,
@@ -827,39 +581,16 @@ async function createSection2(section, options) {
827
581
  }
828
582
  async function bulkCreateSections2(sections, options) {
829
583
  const { httpClient, sideEffects } = arguments[2];
830
- const payload = (0, import_transform_paths2.transformPaths)(
831
- (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
832
- sections,
833
- fields: options?.fields
834
- }),
835
- [
836
- {
837
- transformFn: import_image.transformSDKImageToRESTImage,
838
- paths: [{ path: "sections.description.image" }]
839
- },
840
- {
841
- transformFn: import_video_v2.transformSDKVideoV2ToRESTVideoV2,
842
- paths: [{ path: "sections.description.video" }]
843
- }
844
- ]
845
- );
584
+ const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
585
+ sections,
586
+ fields: options?.fields
587
+ });
846
588
  const reqOpts = bulkCreateSections(payload);
847
589
  sideEffects?.onSiteCall?.();
848
590
  try {
849
591
  const result = await httpClient.request(reqOpts);
850
592
  sideEffects?.onSuccess?.(result);
851
- return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(
852
- (0, import_transform_paths2.transformPaths)(result.data, [
853
- {
854
- transformFn: import_image2.transformRESTImageToSDKImage,
855
- paths: [{ path: "results.item.description.image" }]
856
- },
857
- {
858
- transformFn: import_video_v22.transformRESTVideoV2ToSDKVideoV2,
859
- paths: [{ path: "results.item.description.video" }]
860
- }
861
- ])
862
- );
593
+ return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(result.data);
863
594
  } catch (err) {
864
595
  const transformedError = (0, import_transform_error.transformError)(
865
596
  err,
@@ -886,18 +617,7 @@ async function getSection2(sectionId, options) {
886
617
  try {
887
618
  const result = await httpClient.request(reqOpts);
888
619
  sideEffects?.onSuccess?.(result);
889
- return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(
890
- (0, import_transform_paths2.transformPaths)(result.data, [
891
- {
892
- transformFn: import_image2.transformRESTImageToSDKImage,
893
- paths: [{ path: "section.description.image" }]
894
- },
895
- {
896
- transformFn: import_video_v22.transformRESTVideoV2ToSDKVideoV2,
897
- paths: [{ path: "section.description.video" }]
898
- }
899
- ])
900
- )?.section;
620
+ return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(result.data)?.section;
901
621
  } catch (err) {
902
622
  const transformedError = (0, import_transform_error.transformError)(
903
623
  err,
@@ -918,39 +638,16 @@ async function getSection2(sectionId, options) {
918
638
  }
919
639
  async function updateSection2(_id, options) {
920
640
  const { httpClient, sideEffects } = arguments[2];
921
- const payload = (0, import_transform_paths2.transformPaths)(
922
- (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
923
- section: { ...options?.section, id: _id },
924
- fields: options?.fields
925
- }),
926
- [
927
- {
928
- transformFn: import_image.transformSDKImageToRESTImage,
929
- paths: [{ path: "section.description.image" }]
930
- },
931
- {
932
- transformFn: import_video_v2.transformSDKVideoV2ToRESTVideoV2,
933
- paths: [{ path: "section.description.video" }]
934
- }
935
- ]
936
- );
641
+ const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
642
+ section: { ...options?.section, id: _id },
643
+ fields: options?.fields
644
+ });
937
645
  const reqOpts = updateSection(payload);
938
646
  sideEffects?.onSiteCall?.();
939
647
  try {
940
648
  const result = await httpClient.request(reqOpts);
941
649
  sideEffects?.onSuccess?.(result);
942
- return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(
943
- (0, import_transform_paths2.transformPaths)(result.data, [
944
- {
945
- transformFn: import_image2.transformRESTImageToSDKImage,
946
- paths: [{ path: "section.description.image" }]
947
- },
948
- {
949
- transformFn: import_video_v22.transformRESTVideoV2ToSDKVideoV2,
950
- paths: [{ path: "section.description.video" }]
951
- }
952
- ])
953
- )?.section;
650
+ return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(result.data)?.section;
954
651
  } catch (err) {
955
652
  const transformedError = (0, import_transform_error.transformError)(
956
653
  err,
@@ -1019,16 +716,7 @@ function querySections2(options) {
1019
716
  },
1020
717
  responseTransformer: ({ data }) => {
1021
718
  const transformedData = (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(
1022
- (0, import_transform_paths2.transformPaths)(data, [
1023
- {
1024
- transformFn: import_image2.transformRESTImageToSDKImage,
1025
- paths: [{ path: "sections.description.image" }]
1026
- },
1027
- {
1028
- transformFn: import_video_v22.transformRESTVideoV2ToSDKVideoV2,
1029
- paths: [{ path: "sections.description.video" }]
1030
- }
1031
- ])
719
+ (0, import_transform_paths2.transformPaths)(data, [])
1032
720
  );
1033
721
  return {
1034
722
  items: transformedData?.sections,
@@ -1058,18 +746,7 @@ async function typedQuerySections(query, options) {
1058
746
  try {
1059
747
  const result = await httpClient.request(reqOpts);
1060
748
  sideEffects?.onSuccess?.(result);
1061
- return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(
1062
- (0, import_transform_paths2.transformPaths)(result.data, [
1063
- {
1064
- transformFn: import_image2.transformRESTImageToSDKImage,
1065
- paths: [{ path: "sections.description.image" }]
1066
- },
1067
- {
1068
- transformFn: import_video_v22.transformRESTVideoV2ToSDKVideoV2,
1069
- paths: [{ path: "sections.description.video" }]
1070
- }
1071
- ])
1072
- );
749
+ return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(result.data);
1073
750
  } catch (err) {
1074
751
  const transformedError = (0, import_transform_error.transformError)(
1075
752
  err,
@@ -1099,18 +776,7 @@ async function listSections2(programId, options) {
1099
776
  try {
1100
777
  const result = await httpClient.request(reqOpts);
1101
778
  sideEffects?.onSuccess?.(result);
1102
- return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(
1103
- (0, import_transform_paths2.transformPaths)(result.data, [
1104
- {
1105
- transformFn: import_image2.transformRESTImageToSDKImage,
1106
- paths: [{ path: "sections.description.image" }]
1107
- },
1108
- {
1109
- transformFn: import_video_v22.transformRESTVideoV2ToSDKVideoV2,
1110
- paths: [{ path: "sections.description.video" }]
1111
- }
1112
- ])
1113
- );
779
+ return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(result.data);
1114
780
  } catch (err) {
1115
781
  const transformedError = (0, import_transform_error.transformError)(
1116
782
  err,
@@ -1140,18 +806,7 @@ async function cloneSection2(sectionId, options) {
1140
806
  try {
1141
807
  const result = await httpClient.request(reqOpts);
1142
808
  sideEffects?.onSuccess?.(result);
1143
- return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(
1144
- (0, import_transform_paths2.transformPaths)(result.data, [
1145
- {
1146
- transformFn: import_image2.transformRESTImageToSDKImage,
1147
- paths: [{ path: "section.description.image" }]
1148
- },
1149
- {
1150
- transformFn: import_video_v22.transformRESTVideoV2ToSDKVideoV2,
1151
- paths: [{ path: "section.description.video" }]
1152
- }
1153
- ])
1154
- );
809
+ return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(result.data);
1155
810
  } catch (err) {
1156
811
  const transformedError = (0, import_transform_error.transformError)(
1157
812
  err,
@@ -1179,18 +834,7 @@ async function moveSection2(options) {
1179
834
  try {
1180
835
  const result = await httpClient.request(reqOpts);
1181
836
  sideEffects?.onSuccess?.(result);
1182
- return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(
1183
- (0, import_transform_paths2.transformPaths)(result.data, [
1184
- {
1185
- transformFn: import_image2.transformRESTImageToSDKImage,
1186
- paths: [{ path: "section.description.image" }]
1187
- },
1188
- {
1189
- transformFn: import_video_v22.transformRESTVideoV2ToSDKVideoV2,
1190
- paths: [{ path: "section.description.video" }]
1191
- }
1192
- ])
1193
- );
837
+ return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(result.data);
1194
838
  } catch (err) {
1195
839
  const transformedError = (0, import_transform_error.transformError)(
1196
840
  err,