@financial-times/content-curation-client 6.3.0 → 7.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.cjs CHANGED
@@ -190,44 +190,48 @@ function readStringProperty(error, property) {
190
190
  return typeof value === "string" && value.length > 0 ? value : void 0;
191
191
  }
192
192
 
193
+ // src/internal/response-handling.ts
194
+ var _v4 = require('zod/v4');
195
+
193
196
  // src/schemas/response.ts
194
- var _zod = require('zod');
195
- var ApiErrorCode = _zod.z.enum([
197
+
198
+ var ApiErrorCode = _v4.z.enum([
196
199
  "UNAUTHORIZED",
197
200
  "NOT_FOUND",
198
201
  "INTERNAL_SERVER_ERROR",
199
202
  "INVALID_INPUT_DATA"
200
203
  ]);
201
- var BaseEnvelopeFields = _zod.z.object({
202
- statusCode: _zod.z.number(),
203
- requestId: _zod.z.string()
204
+ var BaseEnvelopeFields = _v4.z.object({
205
+ statusCode: _v4.z.number(),
206
+ requestId: _v4.z.string()
204
207
  });
205
- var ApiErrorPayloadSchema = _zod.z.object({
208
+ var ApiErrorPayloadSchema = _v4.z.object({
206
209
  code: ApiErrorCode,
207
- message: _zod.z.string(),
208
- details: _zod.z.string().optional(),
209
- path: _zod.z.string().optional(),
210
- timestamp: _zod.z.string().optional()
210
+ message: _v4.z.string(),
211
+ details: _v4.z.string().optional(),
212
+ path: _v4.z.string().optional(),
213
+ timestamp: _v4.z.string().optional()
211
214
  }).strict();
212
215
  var ApiErrorResponseSchema = BaseEnvelopeFields.extend({
213
- status: _zod.z.literal("error"),
216
+ status: _v4.z.literal("error"),
214
217
  error: ApiErrorPayloadSchema
215
218
  }).strict();
216
219
  function ApiSuccessResponseSchema(dataSchema) {
217
220
  return BaseEnvelopeFields.extend({
218
- status: _zod.z.literal("success"),
221
+ status: _v4.z.literal("success"),
219
222
  data: dataSchema
220
223
  }).strict();
221
224
  }
222
225
  function ApiResponseSchema(dataSchema) {
223
226
  const successSchema = ApiSuccessResponseSchema(dataSchema);
224
227
  const errorSchema = ApiErrorResponseSchema;
225
- return _zod.z.discriminatedUnion("status", [successSchema, errorSchema]);
228
+ return _v4.z.discriminatedUnion("status", [successSchema, errorSchema]);
226
229
  }
227
230
 
228
231
  // src/internal/response-handling.ts
229
232
  var GATEWAY_STATUS_CODES = /* @__PURE__ */ new Set([499, 502, 503]);
230
233
  var MAX_DIAGNOSTIC_BODY_LENGTH = 2e3;
234
+ var ApiSuccessEnvelopeCandidateSchema = ApiSuccessResponseSchema(_v4.z.unknown());
231
235
  function isGatewayStatusCode(statusCode) {
232
236
  return GATEWAY_STATUS_CODES.has(statusCode);
233
237
  }
@@ -271,8 +275,27 @@ function parseApiResponse(responseDataSchema, responseBody) {
271
275
  if (responseBody.json === void 0) {
272
276
  return null;
273
277
  }
274
- const parsedResponse = ApiResponseSchema(responseDataSchema).safeParse(responseBody.json);
275
- return parsedResponse.success ? parsedResponse.data : null;
278
+ if (hasOwnDataProperty(responseBody.json)) {
279
+ const parsedSuccess = ApiSuccessEnvelopeCandidateSchema.safeParse(responseBody.json);
280
+ if (!parsedSuccess.success) {
281
+ return null;
282
+ }
283
+ const parsedData = responseDataSchema.safeParse(parsedSuccess.data.data);
284
+ if (!parsedData.success) {
285
+ return null;
286
+ }
287
+ return {
288
+ status: "success",
289
+ statusCode: parsedSuccess.data.statusCode,
290
+ requestId: parsedSuccess.data.requestId,
291
+ data: parsedData.data
292
+ };
293
+ }
294
+ const parsedError = ApiErrorResponseSchema.safeParse(responseBody.json);
295
+ return parsedError.success ? parsedError.data : null;
296
+ }
297
+ function hasOwnDataProperty(value) {
298
+ return typeof value === "object" && value !== null && !Array.isArray(value) && Object.hasOwn(value, "data");
276
299
  }
277
300
  function parseApiErrorResponse(responseBody) {
278
301
  if (responseBody.json === void 0) {
@@ -416,7 +439,7 @@ function parseSuccessfulResponse(path, url, response, responseBody, responseData
416
439
  requestId: getResponseRequestId(response)
417
440
  });
418
441
  }
419
- if ("error" in parsedResponse) {
442
+ if (parsedResponse.status === "error") {
420
443
  throw new ApiServiceError(
421
444
  parsedResponse.error,
422
445
  parsedResponse.statusCode,
@@ -525,83 +548,83 @@ function trimTrailingSlashes(value) {
525
548
 
526
549
  // src/schemas/ftpink/legacyHubPage/index.ts
527
550
 
528
- var LegacyFlourishChildSchema = _zod.z.object({
529
- source: _zod.z.literal("flourish"),
530
- properties: _zod.z.object({
531
- id: _zod.z.string().min(1)
551
+ var LegacyFlourishChildSchema = _v4.z.object({
552
+ source: _v4.z.literal("flourish"),
553
+ properties: _v4.z.object({
554
+ id: _v4.z.string().min(1)
532
555
  // e.g. "visualisation/21901162"
533
556
  })
534
557
  });
535
- var LegacyListChildSchema = _zod.z.object({
536
- source: _zod.z.literal("list"),
537
- properties: _zod.z.object({
538
- id: _zod.z.string().uuid(),
539
- maxItems: _zod.z.number().optional()
558
+ var LegacyListChildSchema = _v4.z.object({
559
+ source: _v4.z.literal("list"),
560
+ properties: _v4.z.object({
561
+ id: _v4.z.string().uuid(),
562
+ maxItems: _v4.z.number().optional()
540
563
  })
541
564
  });
542
- var LegacyContentChildSchema = _zod.z.object({
543
- source: _zod.z.literal("content"),
544
- properties: _zod.z.object({
545
- ids: _zod.z.array(_zod.z.string()).nonempty()
565
+ var LegacyContentChildSchema = _v4.z.object({
566
+ source: _v4.z.literal("content"),
567
+ properties: _v4.z.object({
568
+ ids: _v4.z.array(_v4.z.string()).nonempty()
546
569
  })
547
570
  });
548
- var LegacyContainerChildSchema = _zod.z.discriminatedUnion("source", [
571
+ var LegacyContainerChildSchema = _v4.z.discriminatedUnion("source", [
549
572
  LegacyFlourishChildSchema,
550
573
  LegacyListChildSchema,
551
574
  LegacyContentChildSchema
552
575
  ]);
553
- var LegacyTopperSchema = _zod.z.object({
554
- type: _zod.z.literal("topper-basic"),
555
- properties: _zod.z.object({
556
- title: _zod.z.string(),
557
- sponsorText: _zod.z.string().optional(),
558
- sponsorImage: _zod.z.string().url().optional()
576
+ var LegacyTopperSchema = _v4.z.object({
577
+ type: _v4.z.literal("topper-basic"),
578
+ properties: _v4.z.object({
579
+ title: _v4.z.string(),
580
+ sponsorText: _v4.z.string().optional(),
581
+ sponsorImage: _v4.z.string().url().optional()
559
582
  })
560
583
  });
561
- var LegacyInfoBoxSchema = _zod.z.object({
562
- type: _zod.z.literal("info-box"),
563
- properties: _zod.z.object({
564
- bodyHTML: _zod.z.string(),
565
- title: _zod.z.string().optional()
584
+ var LegacyInfoBoxSchema = _v4.z.object({
585
+ type: _v4.z.literal("info-box"),
586
+ properties: _v4.z.object({
587
+ bodyHTML: _v4.z.string(),
588
+ title: _v4.z.string().optional()
566
589
  })
567
590
  });
568
- var LegacyContainerSchema = _zod.z.object({
569
- type: _zod.z.literal("container"),
570
- children: _zod.z.array(LegacyContainerChildSchema).min(1),
571
- properties: _zod.z.object({
572
- title: _zod.z.string().optional(),
573
- design: _zod.z.enum(["chart", "four-story", "freeform", "hero-lead"]).default("freeform"),
574
- backgroundColor: _zod.z.string().optional()
591
+ var LegacyContainerSchema = _v4.z.object({
592
+ type: _v4.z.literal("container"),
593
+ children: _v4.z.array(LegacyContainerChildSchema).min(1),
594
+ properties: _v4.z.object({
595
+ title: _v4.z.string().optional(),
596
+ design: _v4.z.enum(["chart", "four-story", "freeform", "hero-lead"]).default("freeform"),
597
+ backgroundColor: _v4.z.string().optional()
575
598
  })
576
599
  });
577
- var LegacyExperimentSchema = _zod.z.object({
578
- type: _zod.z.literal("experiment"),
579
- children: _zod.z.tuple([]),
580
- properties: _zod.z.object({
581
- experimentName: _zod.z.string(),
582
- id: _zod.z.string(),
583
- title: _zod.z.string().optional(),
584
- config: _zod.z.object({
585
- value: _zod.z.unknown().optional(),
600
+ var LegacyExperimentSchema = _v4.z.object({
601
+ type: _v4.z.literal("experiment"),
602
+ children: _v4.z.tuple([]),
603
+ properties: _v4.z.object({
604
+ experimentName: _v4.z.string(),
605
+ id: _v4.z.string(),
606
+ title: _v4.z.string().optional(),
607
+ config: _v4.z.object({
608
+ value: _v4.z.unknown().optional(),
586
609
  // Hub pages support experiments with HTML and Text.
587
610
  // For now we just support JSON. As we migrate pages, this may change.
588
- format: _zod.z.enum(["json"]).default("json")
611
+ format: _v4.z.enum(["json"]).default("json")
589
612
  }).partial().optional()
590
613
  })
591
614
  });
592
- var LegacyBlockSchema = _zod.z.discriminatedUnion("type", [
615
+ var LegacyBlockSchema = _v4.z.discriminatedUnion("type", [
593
616
  LegacyTopperSchema,
594
617
  LegacyInfoBoxSchema,
595
618
  LegacyContainerSchema,
596
619
  LegacyExperimentSchema
597
620
  ]);
598
- var LegacyPageStructureOutputSchema = _zod.z.object({
599
- uuid: _zod.z.string().uuid(),
600
- title: _zod.z.string(),
601
- conceptId: _zod.z.string().uuid().optional(),
602
- themeName: _zod.z.string().optional(),
603
- metaDescription: _zod.z.string().optional(),
604
- blocks: _zod.z.array(LegacyBlockSchema)
621
+ var LegacyPageStructureOutputSchema = _v4.z.object({
622
+ uuid: _v4.z.string().uuid(),
623
+ title: _v4.z.string(),
624
+ conceptId: _v4.z.string().uuid().optional(),
625
+ themeName: _v4.z.string().optional(),
626
+ metaDescription: _v4.z.string().optional(),
627
+ blocks: _v4.z.array(LegacyBlockSchema)
605
628
  });
606
629
 
607
630
  // src/schemas/ftpink/page/index.ts
@@ -609,46 +632,46 @@ var LegacyPageStructureOutputSchema = _zod.z.object({
609
632
 
610
633
  // src/schemas/prosemirror.ts
611
634
 
612
- var HrefSchema = _zod.z.string().refine((v) => /^(https?:\/\/|mailto:).+/.test(v), {
635
+ var HrefSchema = _v4.z.string().refine((v) => /^(https?:\/\/|mailto:).+/.test(v), {
613
636
  message: "Expected http(s):// or mailto: URL"
614
637
  });
615
- var ProseMirrorLinkMark = _zod.z.object({
616
- type: _zod.z.literal("link"),
617
- attrs: _zod.z.object({
638
+ var ProseMirrorLinkMark = _v4.z.object({
639
+ type: _v4.z.literal("link"),
640
+ attrs: _v4.z.object({
618
641
  href: HrefSchema
619
642
  })
620
643
  });
621
- var ProseMirrorMark = _zod.z.discriminatedUnion("type", [
644
+ var ProseMirrorMark = _v4.z.discriminatedUnion("type", [
622
645
  ProseMirrorLinkMark,
623
- _zod.z.object({ type: _zod.z.literal("bold") }),
624
- _zod.z.object({ type: _zod.z.literal("italic") }),
625
- _zod.z.object({ type: _zod.z.literal("underline") }),
626
- _zod.z.object({ type: _zod.z.literal("strike") })
646
+ _v4.z.object({ type: _v4.z.literal("bold") }),
647
+ _v4.z.object({ type: _v4.z.literal("italic") }),
648
+ _v4.z.object({ type: _v4.z.literal("underline") }),
649
+ _v4.z.object({ type: _v4.z.literal("strike") })
627
650
  ]);
628
- var ProseMirrorTextNode = _zod.z.object({
629
- type: _zod.z.literal("text"),
630
- text: _zod.z.string(),
631
- marks: _zod.z.array(ProseMirrorMark).optional()
651
+ var ProseMirrorTextNode = _v4.z.object({
652
+ type: _v4.z.literal("text"),
653
+ text: _v4.z.string(),
654
+ marks: _v4.z.array(ProseMirrorMark).optional()
632
655
  });
633
- var ProseMirrorParagraphNode = _zod.z.object({
634
- type: _zod.z.literal("paragraph"),
635
- content: _zod.z.array(ProseMirrorTextNode)
656
+ var ProseMirrorParagraphNode = _v4.z.object({
657
+ type: _v4.z.literal("paragraph"),
658
+ content: _v4.z.array(ProseMirrorTextNode)
636
659
  });
637
- var ProseMirrorNode = _zod.z.union([ProseMirrorParagraphNode, ProseMirrorTextNode]);
638
- var ProseMirrorDocSchema = _zod.z.object({
639
- type: _zod.z.literal("doc"),
640
- content: _zod.z.array(ProseMirrorNode).min(1, { message: "Document must contain at least one paragraph" })
660
+ var ProseMirrorNode = _v4.z.union([ProseMirrorParagraphNode, ProseMirrorTextNode]);
661
+ var ProseMirrorDocSchema = _v4.z.object({
662
+ type: _v4.z.literal("doc"),
663
+ content: _v4.z.array(ProseMirrorNode).min(1, { message: "Document must contain at least one paragraph" })
641
664
  });
642
665
 
643
666
  // src/schemas/ftpink/page/index.ts
644
- var HeadingSchema = _zod.z.object({
645
- text: _zod.z.string(),
646
- href: _zod.z.string().url().optional()
667
+ var HeadingSchema = _v4.z.object({
668
+ text: _v4.z.string(),
669
+ href: _v4.z.string().url().optional()
647
670
  });
648
- var BasePageItemProps = _zod.z.object({
671
+ var BasePageItemProps = _v4.z.object({
649
672
  heading: HeadingSchema.optional()
650
673
  });
651
- var ValidJSONStringSchema = _zod.z.string().refine(
674
+ var ValidJSONStringSchema = _v4.z.string().refine(
652
675
  (val) => {
653
676
  try {
654
677
  JSON.parse(val);
@@ -661,36 +684,36 @@ var ValidJSONStringSchema = _zod.z.string().refine(
661
684
  );
662
685
  function defineSliceSchema(options) {
663
686
  const { typeName, propsShape } = options;
664
- const BaseSchema = _zod.z.object({
665
- type: _zod.z.literal(typeName),
666
- hidden: _zod.z.boolean().optional(),
687
+ const BaseSchema = _v4.z.object({
688
+ type: _v4.z.literal(typeName),
689
+ hidden: _v4.z.boolean().optional(),
667
690
  properties: propsShape
668
691
  });
669
692
  const InputSchema = BaseSchema.extend({
670
- sliceId: _zod.z.string().uuid().optional()
693
+ sliceId: _v4.z.string().uuid().optional()
671
694
  });
672
695
  const OutputSchema = BaseSchema.extend({
673
- sliceId: _zod.z.string().uuid()
696
+ sliceId: _v4.z.string().uuid()
674
697
  });
675
698
  return { InputSchema, OutputSchema };
676
699
  }
677
700
  var InteractiveSlice = defineSliceSchema({
678
701
  typeName: "Interactive",
679
702
  propsShape: BasePageItemProps.extend({
680
- flourishDescription: _zod.z.string().optional(),
703
+ flourishDescription: _v4.z.string().optional(),
681
704
  // Optional description for the Flourish graphic
682
- flourishId: _zod.z.string().nonempty(),
683
- flourishAltText: _zod.z.string().nonempty(),
684
- storyUUID: _zod.z.string().uuid().optional(),
685
- theme: _zod.z.string().optional()
705
+ flourishId: _v4.z.string().nonempty(),
706
+ flourishAltText: _v4.z.string().nonempty(),
707
+ storyUUID: _v4.z.string().uuid().optional(),
708
+ theme: _v4.z.string().optional()
686
709
  })
687
710
  });
688
711
  var ExperimentSlice = defineSliceSchema({
689
712
  typeName: "Experiment",
690
713
  propsShape: BasePageItemProps.extend({
691
- experimentId: _zod.z.string().nonempty(),
714
+ experimentId: _v4.z.string().nonempty(),
692
715
  // Unique ID for the experiment
693
- experimentName: _zod.z.string().nonempty(),
716
+ experimentName: _v4.z.string().nonempty(),
694
717
  // Human-readable name of the experiment
695
718
  contentJson: ValidJSONStringSchema
696
719
  // The experiment’s JSON payload as a valid JSON string
@@ -699,9 +722,9 @@ var ExperimentSlice = defineSliceSchema({
699
722
  var StripSlice = defineSliceSchema({
700
723
  typeName: "Strip",
701
724
  propsShape: BasePageItemProps.extend({
702
- listId: _zod.z.string().uuid(),
725
+ listId: _v4.z.string().uuid(),
703
726
  // The ID of the strip to display
704
- maxStories: _zod.z.number().int().min(1).max(20)
727
+ maxStories: _v4.z.number().int().min(1).max(20)
705
728
  // Maximum number of stories to display in the strip
706
729
  })
707
730
  });
@@ -709,25 +732,25 @@ var TopperSlice = defineSliceSchema({
709
732
  typeName: "Topper",
710
733
  propsShape: BasePageItemProps.extend({
711
734
  description: ProseMirrorDocSchema,
712
- strapline: _zod.z.string().optional()
735
+ strapline: _v4.z.string().optional()
713
736
  })
714
737
  });
715
738
  var HeroSlice = defineSliceSchema({
716
739
  typeName: "Hero",
717
740
  propsShape: BasePageItemProps.extend({
718
- listId: _zod.z.string().uuid(),
741
+ listId: _v4.z.string().uuid(),
719
742
  // The ID of the spark list to display
720
- maxStories: _zod.z.number().int().min(1).max(20)
743
+ maxStories: _v4.z.number().int().min(1).max(20)
721
744
  // Maximum number of stories to display in the hero
722
745
  })
723
746
  });
724
747
  var StoryGroupSlice = defineSliceSchema({
725
748
  typeName: "StoryGroup",
726
749
  propsShape: BasePageItemProps.extend({
727
- storySlots: _zod.z.array(_zod.z.string().uuid()).nonempty()
750
+ storySlots: _v4.z.array(_v4.z.string().uuid()).nonempty()
728
751
  })
729
752
  });
730
- var SliceApiInputSchema = _zod.z.discriminatedUnion("type", [
753
+ var SliceApiInputSchema = _v4.z.discriminatedUnion("type", [
731
754
  InteractiveSlice.InputSchema,
732
755
  ExperimentSlice.InputSchema,
733
756
  StripSlice.InputSchema,
@@ -735,7 +758,7 @@ var SliceApiInputSchema = _zod.z.discriminatedUnion("type", [
735
758
  HeroSlice.InputSchema,
736
759
  StoryGroupSlice.InputSchema
737
760
  ]);
738
- var SliceApiOutputSchema = _zod.z.discriminatedUnion("type", [
761
+ var SliceApiOutputSchema = _v4.z.discriminatedUnion("type", [
739
762
  InteractiveSlice.OutputSchema,
740
763
  ExperimentSlice.OutputSchema,
741
764
  StripSlice.OutputSchema,
@@ -743,56 +766,56 @@ var SliceApiOutputSchema = _zod.z.discriminatedUnion("type", [
743
766
  HeroSlice.OutputSchema,
744
767
  StoryGroupSlice.OutputSchema
745
768
  ]);
746
- var BasePagePropertiesSchema = _zod.z.object({
747
- title: _zod.z.string(),
748
- pageId: _zod.z.string().uuid(),
749
- publicationId: _zod.z.string(),
750
- conceptId: _zod.z.string().uuid().optional(),
751
- metaDescription: _zod.z.string().optional(),
752
- pageTheme: _zod.z.string().optional(),
753
- sponsorText: _zod.z.string().optional(),
754
- sponsorImage: _zod.z.string().url().optional(),
755
- pageCategory: _zod.z.string().optional()
769
+ var BasePagePropertiesSchema = _v4.z.object({
770
+ title: _v4.z.string(),
771
+ pageId: _v4.z.string().uuid(),
772
+ publicationId: _v4.z.string(),
773
+ conceptId: _v4.z.string().uuid().optional(),
774
+ metaDescription: _v4.z.string().optional(),
775
+ pageTheme: _v4.z.string().optional(),
776
+ sponsorText: _v4.z.string().optional(),
777
+ sponsorImage: _v4.z.string().url().optional(),
778
+ pageCategory: _v4.z.string().optional()
756
779
  });
757
780
  var PageStructureOutputPropertiesSchema = BasePagePropertiesSchema.extend({
758
- lastPublishedDate: _zod.z.string().datetime().optional()
781
+ lastPublishedDate: _v4.z.string().datetime().optional()
759
782
  });
760
- var PageStructureInputSchema = _zod.z.object({
783
+ var PageStructureInputSchema = _v4.z.object({
761
784
  properties: BasePagePropertiesSchema,
762
- children: _zod.z.array(SliceApiInputSchema)
785
+ children: _v4.z.array(SliceApiInputSchema)
763
786
  });
764
- var PageStructureOutputSchema = _zod.z.object({
765
- type: _zod.z.literal("Page"),
766
- schemaVersion: _zod.z.number(),
787
+ var PageStructureOutputSchema = _v4.z.object({
788
+ type: _v4.z.literal("Page"),
789
+ schemaVersion: _v4.z.number(),
767
790
  properties: PageStructureOutputPropertiesSchema,
768
- children: _zod.z.array(SliceApiOutputSchema)
791
+ children: _v4.z.array(SliceApiOutputSchema)
769
792
  });
770
- var ListPagesOutputSchema = _zod.z.array(PageStructureOutputSchema);
793
+ var ListPagesOutputSchema = _v4.z.array(PageStructureOutputSchema);
771
794
 
772
795
  // src/schemas/ftpink/draft/index.ts
773
796
 
774
- var DraftContributorInputSchema = _zod.z.object({
775
- userId: _zod.z.string().min(1),
776
- displayName: _zod.z.string().min(1),
777
- email: _zod.z.string().email().optional()
797
+ var DraftContributorInputSchema = _v4.z.object({
798
+ userId: _v4.z.string().min(1),
799
+ displayName: _v4.z.string().min(1),
800
+ email: _v4.z.string().email().optional()
778
801
  });
779
802
  var DraftContributorSchema = DraftContributorInputSchema.extend({
780
- userId: _zod.z.string().min(1),
781
- displayName: _zod.z.string().min(1),
782
- firstTouchedAt: _zod.z.string().datetime(),
783
- lastTouchedAt: _zod.z.string().datetime()
803
+ userId: _v4.z.string().min(1),
804
+ displayName: _v4.z.string().min(1),
805
+ firstTouchedAt: _v4.z.string().datetime(),
806
+ lastTouchedAt: _v4.z.string().datetime()
784
807
  });
785
- var DraftMetadataSchema = _zod.z.object({
786
- draftId: _zod.z.string().uuid(),
787
- createdAt: _zod.z.string().datetime(),
788
- updatedAt: _zod.z.string().datetime(),
789
- contributors: _zod.z.array(DraftContributorSchema)
808
+ var DraftMetadataSchema = _v4.z.object({
809
+ draftId: _v4.z.string().uuid(),
810
+ createdAt: _v4.z.string().datetime(),
811
+ updatedAt: _v4.z.string().datetime(),
812
+ contributors: _v4.z.array(DraftContributorSchema)
790
813
  });
791
814
  var PageDraftSchema = DraftMetadataSchema.extend({
792
815
  structure: PageStructureOutputSchema
793
816
  });
794
817
  var DraftSchema = PageDraftSchema;
795
- var PersistPageDraftInputSchema = _zod.z.object({
818
+ var PersistPageDraftInputSchema = _v4.z.object({
796
819
  structure: PageStructureInputSchema,
797
820
  contributor: DraftContributorInputSchema
798
821
  });