dub 0.71.2 → 0.71.4

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.
Files changed (130) hide show
  1. package/README.md +43 -29
  2. package/dist/commonjs/funcs/analyticsRetrieve.js +0 -1
  3. package/dist/commonjs/funcs/analyticsRetrieve.js.map +1 -1
  4. package/dist/commonjs/funcs/eventsList.js +0 -1
  5. package/dist/commonjs/funcs/eventsList.js.map +1 -1
  6. package/dist/commonjs/lib/config.d.ts +3 -3
  7. package/dist/commonjs/lib/config.js +3 -3
  8. package/dist/commonjs/models/components/analyticstoplinks.d.ts +6 -2
  9. package/dist/commonjs/models/components/analyticstoplinks.d.ts.map +1 -1
  10. package/dist/commonjs/models/components/analyticstoplinks.js +2 -1
  11. package/dist/commonjs/models/components/analyticstoplinks.js.map +1 -1
  12. package/dist/commonjs/models/components/partneranalyticstoplinks.d.ts +6 -2
  13. package/dist/commonjs/models/components/partneranalyticstoplinks.d.ts.map +1 -1
  14. package/dist/commonjs/models/components/partneranalyticstoplinks.js +2 -1
  15. package/dist/commonjs/models/components/partneranalyticstoplinks.js.map +1 -1
  16. package/dist/commonjs/models/operations/createpartner.d.ts +56 -56
  17. package/dist/commonjs/models/operations/createpartner.d.ts.map +1 -1
  18. package/dist/commonjs/models/operations/createpartner.js +87 -93
  19. package/dist/commonjs/models/operations/createpartner.js.map +1 -1
  20. package/dist/commonjs/models/operations/listevents.d.ts +58 -105
  21. package/dist/commonjs/models/operations/listevents.d.ts.map +1 -1
  22. package/dist/commonjs/models/operations/listevents.js +13 -45
  23. package/dist/commonjs/models/operations/listevents.js.map +1 -1
  24. package/dist/commonjs/models/operations/listpartners.d.ts +56 -56
  25. package/dist/commonjs/models/operations/listpartners.d.ts.map +1 -1
  26. package/dist/commonjs/models/operations/listpartners.js +93 -88
  27. package/dist/commonjs/models/operations/listpartners.js.map +1 -1
  28. package/dist/commonjs/models/operations/retrieveanalytics.d.ts +58 -105
  29. package/dist/commonjs/models/operations/retrieveanalytics.d.ts.map +1 -1
  30. package/dist/commonjs/models/operations/retrieveanalytics.js +13 -47
  31. package/dist/commonjs/models/operations/retrieveanalytics.js.map +1 -1
  32. package/dist/commonjs/models/operations/retrievepartneranalytics.d.ts +1 -1
  33. package/dist/commonjs/sdk/customers.d.ts +6 -6
  34. package/dist/commonjs/sdk/customers.d.ts.map +1 -1
  35. package/dist/commonjs/sdk/customers.js +8 -8
  36. package/dist/commonjs/sdk/customers.js.map +1 -1
  37. package/dist/commonjs/sdk/domains.d.ts +10 -10
  38. package/dist/commonjs/sdk/domains.d.ts.map +1 -1
  39. package/dist/commonjs/sdk/domains.js +13 -13
  40. package/dist/commonjs/sdk/domains.js.map +1 -1
  41. package/dist/commonjs/sdk/folders.d.ts +10 -10
  42. package/dist/commonjs/sdk/folders.d.ts.map +1 -1
  43. package/dist/commonjs/sdk/folders.js +13 -13
  44. package/dist/commonjs/sdk/folders.js.map +1 -1
  45. package/dist/commonjs/sdk/links.d.ts +19 -19
  46. package/dist/commonjs/sdk/links.d.ts.map +1 -1
  47. package/dist/commonjs/sdk/links.js +24 -24
  48. package/dist/commonjs/sdk/links.js.map +1 -1
  49. package/dist/commonjs/sdk/partners.d.ts +10 -10
  50. package/dist/commonjs/sdk/partners.d.ts.map +1 -1
  51. package/dist/commonjs/sdk/partners.js +13 -13
  52. package/dist/commonjs/sdk/partners.js.map +1 -1
  53. package/dist/commonjs/sdk/tags.d.ts +10 -10
  54. package/dist/commonjs/sdk/tags.d.ts.map +1 -1
  55. package/dist/commonjs/sdk/tags.js +13 -13
  56. package/dist/commonjs/sdk/tags.js.map +1 -1
  57. package/dist/esm/funcs/analyticsRetrieve.js +0 -1
  58. package/dist/esm/funcs/analyticsRetrieve.js.map +1 -1
  59. package/dist/esm/funcs/eventsList.js +0 -1
  60. package/dist/esm/funcs/eventsList.js.map +1 -1
  61. package/dist/esm/lib/config.d.ts +3 -3
  62. package/dist/esm/lib/config.js +3 -3
  63. package/dist/esm/models/components/analyticstoplinks.d.ts +6 -2
  64. package/dist/esm/models/components/analyticstoplinks.d.ts.map +1 -1
  65. package/dist/esm/models/components/analyticstoplinks.js +2 -1
  66. package/dist/esm/models/components/analyticstoplinks.js.map +1 -1
  67. package/dist/esm/models/components/partneranalyticstoplinks.d.ts +6 -2
  68. package/dist/esm/models/components/partneranalyticstoplinks.d.ts.map +1 -1
  69. package/dist/esm/models/components/partneranalyticstoplinks.js +2 -1
  70. package/dist/esm/models/components/partneranalyticstoplinks.js.map +1 -1
  71. package/dist/esm/models/operations/createpartner.d.ts +56 -56
  72. package/dist/esm/models/operations/createpartner.d.ts.map +1 -1
  73. package/dist/esm/models/operations/createpartner.js +71 -77
  74. package/dist/esm/models/operations/createpartner.js.map +1 -1
  75. package/dist/esm/models/operations/listevents.d.ts +58 -105
  76. package/dist/esm/models/operations/listevents.d.ts.map +1 -1
  77. package/dist/esm/models/operations/listevents.js +12 -43
  78. package/dist/esm/models/operations/listevents.js.map +1 -1
  79. package/dist/esm/models/operations/listpartners.d.ts +56 -56
  80. package/dist/esm/models/operations/listpartners.d.ts.map +1 -1
  81. package/dist/esm/models/operations/listpartners.js +77 -72
  82. package/dist/esm/models/operations/listpartners.js.map +1 -1
  83. package/dist/esm/models/operations/retrieveanalytics.d.ts +58 -105
  84. package/dist/esm/models/operations/retrieveanalytics.d.ts.map +1 -1
  85. package/dist/esm/models/operations/retrieveanalytics.js +12 -45
  86. package/dist/esm/models/operations/retrieveanalytics.js.map +1 -1
  87. package/dist/esm/models/operations/retrievepartneranalytics.d.ts +1 -1
  88. package/dist/esm/sdk/customers.d.ts +6 -6
  89. package/dist/esm/sdk/customers.d.ts.map +1 -1
  90. package/dist/esm/sdk/customers.js +8 -8
  91. package/dist/esm/sdk/customers.js.map +1 -1
  92. package/dist/esm/sdk/domains.d.ts +10 -10
  93. package/dist/esm/sdk/domains.d.ts.map +1 -1
  94. package/dist/esm/sdk/domains.js +13 -13
  95. package/dist/esm/sdk/domains.js.map +1 -1
  96. package/dist/esm/sdk/folders.d.ts +10 -10
  97. package/dist/esm/sdk/folders.d.ts.map +1 -1
  98. package/dist/esm/sdk/folders.js +13 -13
  99. package/dist/esm/sdk/folders.js.map +1 -1
  100. package/dist/esm/sdk/links.d.ts +19 -19
  101. package/dist/esm/sdk/links.d.ts.map +1 -1
  102. package/dist/esm/sdk/links.js +24 -24
  103. package/dist/esm/sdk/links.js.map +1 -1
  104. package/dist/esm/sdk/partners.d.ts +10 -10
  105. package/dist/esm/sdk/partners.d.ts.map +1 -1
  106. package/dist/esm/sdk/partners.js +13 -13
  107. package/dist/esm/sdk/partners.js.map +1 -1
  108. package/dist/esm/sdk/tags.d.ts +10 -10
  109. package/dist/esm/sdk/tags.d.ts.map +1 -1
  110. package/dist/esm/sdk/tags.js +13 -13
  111. package/dist/esm/sdk/tags.js.map +1 -1
  112. package/examples/package-lock.json +1 -1
  113. package/jsr.json +1 -1
  114. package/package.json +1 -1
  115. package/src/funcs/analyticsRetrieve.ts +0 -1
  116. package/src/funcs/eventsList.ts +0 -1
  117. package/src/lib/config.ts +3 -3
  118. package/src/models/components/analyticstoplinks.ts +8 -3
  119. package/src/models/components/partneranalyticstoplinks.ts +8 -3
  120. package/src/models/operations/createpartner.ts +233 -194
  121. package/src/models/operations/listevents.ts +70 -140
  122. package/src/models/operations/listpartners.ts +194 -231
  123. package/src/models/operations/retrieveanalytics.ts +70 -140
  124. package/src/models/operations/retrievepartneranalytics.ts +1 -1
  125. package/src/sdk/customers.ts +14 -14
  126. package/src/sdk/domains.ts +24 -24
  127. package/src/sdk/folders.ts +24 -24
  128. package/src/sdk/links.ts +36 -36
  129. package/src/sdk/partners.ts +23 -23
  130. package/src/sdk/tags.ts +24 -24
@@ -124,7 +124,7 @@ export const ListPartnersStatus = {
124
124
  */
125
125
  export type ListPartnersStatus = ClosedEnum<typeof ListPartnersStatus>;
126
126
 
127
- export type ListPartnersLinks = {
127
+ export type Links = {
128
128
  /**
129
129
  * The unique ID of the short link.
130
130
  */
@@ -170,7 +170,7 @@ export type ListPartnersLinks = {
170
170
  /**
171
171
  * If the partner was banned from the program, this is the reason for the ban.
172
172
  */
173
- export const ListPartnersBannedReason = {
173
+ export const BannedReason = {
174
174
  TosViolation: "tos_violation",
175
175
  InappropriateContent: "inappropriate_content",
176
176
  FakeTraffic: "fake_traffic",
@@ -181,11 +181,9 @@ export const ListPartnersBannedReason = {
181
181
  /**
182
182
  * If the partner was banned from the program, this is the reason for the ban.
183
183
  */
184
- export type ListPartnersBannedReason = ClosedEnum<
185
- typeof ListPartnersBannedReason
186
- >;
184
+ export type BannedReason = ClosedEnum<typeof BannedReason>;
187
185
 
188
- export type Fields8 = {
186
+ export type Eight = {
189
187
  key: string;
190
188
  label: string;
191
189
  required: boolean;
@@ -194,7 +192,7 @@ export type Fields8 = {
194
192
  type: "phone";
195
193
  };
196
194
 
197
- export type Fields7 = {
195
+ export type Seven = {
198
196
  key: string;
199
197
  label: string;
200
198
  required: boolean;
@@ -203,22 +201,22 @@ export type Fields7 = {
203
201
  type: "number";
204
202
  };
205
203
 
206
- export type ListPartnersFieldsPartnersOptions = {
204
+ export type FieldsOptions = {
207
205
  label: string;
208
206
  value: string;
209
207
  };
210
208
 
211
- export type Fields6 = {
209
+ export type Six = {
212
210
  key: string;
213
211
  label: string;
214
212
  required: boolean;
215
213
  locked: boolean;
216
214
  position: number;
217
215
  type: "multiSelect";
218
- options: Array<ListPartnersFieldsPartnersOptions>;
216
+ options: Array<FieldsOptions>;
219
217
  };
220
218
 
221
- export type Fields5 = {
219
+ export type Five = {
222
220
  key: string;
223
221
  label: string;
224
222
  required: boolean;
@@ -227,7 +225,7 @@ export type Fields5 = {
227
225
  type: "date";
228
226
  };
229
227
 
230
- export type ListPartnersFields4 = {
228
+ export type Fields4 = {
231
229
  key: string;
232
230
  label: string;
233
231
  required: boolean;
@@ -236,70 +234,63 @@ export type ListPartnersFields4 = {
236
234
  type: "country";
237
235
  };
238
236
 
239
- export type ListPartnersFieldsOptions = {
237
+ export type Options = {
240
238
  label: string;
241
239
  value: string;
242
240
  };
243
241
 
244
- export type ListPartnersFields3 = {
242
+ export type Fields3 = {
245
243
  key: string;
246
244
  label: string;
247
245
  required: boolean;
248
246
  locked: boolean;
249
247
  position: number;
250
248
  type: "select";
251
- options: Array<ListPartnersFieldsOptions>;
249
+ options: Array<Options>;
252
250
  };
253
251
 
254
- export type ListPartnersFieldsPartnersConstraints = {
252
+ export type FieldsConstraints = {
255
253
  maxLength?: number | undefined;
256
254
  };
257
255
 
258
- export type ListPartnersFields2 = {
256
+ export type Fields2 = {
259
257
  key: string;
260
258
  label: string;
261
259
  required: boolean;
262
260
  locked: boolean;
263
261
  position: number;
264
262
  type: "textarea";
265
- constraints?: ListPartnersFieldsPartnersConstraints | undefined;
263
+ constraints?: FieldsConstraints | undefined;
266
264
  };
267
265
 
268
- export type ListPartnersFieldsConstraints = {
266
+ export type Constraints = {
269
267
  maxLength?: number | undefined;
270
268
  pattern?: string | undefined;
271
269
  };
272
270
 
273
- export type ListPartnersFields1 = {
271
+ export type Fields1 = {
274
272
  key: string;
275
273
  label: string;
276
274
  required: boolean;
277
275
  locked: boolean;
278
276
  position: number;
279
277
  type: "text";
280
- constraints?: ListPartnersFieldsConstraints | undefined;
278
+ constraints?: Constraints | undefined;
281
279
  };
282
280
 
283
- export type ListPartnersFields =
284
- | ListPartnersFields1
285
- | ListPartnersFields2
286
- | ListPartnersFields3
287
- | ListPartnersFields4
288
- | Fields5
289
- | Fields6
290
- | Fields7
291
- | Fields8;
292
-
293
- export type ListPartnersReferralFormData = {
281
+ export type Fields =
282
+ | Fields1
283
+ | Fields2
284
+ | Fields3
285
+ | Fields4
286
+ | Five
287
+ | Six
288
+ | Seven
289
+ | Eight;
290
+
291
+ export type ReferralFormData = {
294
292
  fields: Array<
295
- | ListPartnersFields1
296
- | ListPartnersFields2
297
- | ListPartnersFields3
298
- | ListPartnersFields4
299
- | Fields5
300
- | Fields6
301
- | Fields7
302
- | Fields8
293
+ Fields1 | Fields2 | Fields3 | Fields4 | Five | Six | Seven | Eight
303
294
  >;
304
295
  };
305
296
 
@@ -372,7 +363,7 @@ export type ListPartnersResponseBody = {
372
363
  /**
373
364
  * The partner's referral links in this program.
374
365
  */
375
- links: Array<ListPartnersLinks> | null;
366
+ links: Array<Links> | null;
376
367
  /**
377
368
  * The total commissions paid to the partner for their referrals
378
369
  */
@@ -392,8 +383,8 @@ export type ListPartnersResponseBody = {
392
383
  /**
393
384
  * If the partner was banned from the program, this is the reason for the ban.
394
385
  */
395
- bannedReason?: ListPartnersBannedReason | null | undefined;
396
- referralFormData?: ListPartnersReferralFormData | null | undefined;
386
+ bannedReason?: BannedReason | null | undefined;
387
+ referralFormData?: ReferralFormData | null | undefined;
397
388
  /**
398
389
  * The total number of clicks on the partner's links
399
390
  */
@@ -529,41 +520,37 @@ export const ListPartnersStatus$inboundSchema: z.ZodNativeEnum<
529
520
  > = z.nativeEnum(ListPartnersStatus);
530
521
 
531
522
  /** @internal */
532
- export const ListPartnersLinks$inboundSchema: z.ZodType<
533
- ListPartnersLinks,
534
- z.ZodTypeDef,
535
- unknown
536
- > = z.object({
537
- id: z.string(),
538
- domain: z.string(),
539
- key: z.string(),
540
- shortLink: z.string(),
541
- url: z.string(),
542
- clicks: z.number().default(0),
543
- leads: z.number().default(0),
544
- conversions: z.number().default(0),
545
- sales: z.number().default(0),
546
- saleAmount: z.number().default(0),
547
- });
523
+ export const Links$inboundSchema: z.ZodType<Links, z.ZodTypeDef, unknown> = z
524
+ .object({
525
+ id: z.string(),
526
+ domain: z.string(),
527
+ key: z.string(),
528
+ shortLink: z.string(),
529
+ url: z.string(),
530
+ clicks: z.number().default(0),
531
+ leads: z.number().default(0),
532
+ conversions: z.number().default(0),
533
+ sales: z.number().default(0),
534
+ saleAmount: z.number().default(0),
535
+ });
548
536
 
549
- export function listPartnersLinksFromJSON(
537
+ export function linksFromJSON(
550
538
  jsonString: string,
551
- ): SafeParseResult<ListPartnersLinks, SDKValidationError> {
539
+ ): SafeParseResult<Links, SDKValidationError> {
552
540
  return safeParse(
553
541
  jsonString,
554
- (x) => ListPartnersLinks$inboundSchema.parse(JSON.parse(x)),
555
- `Failed to parse 'ListPartnersLinks' from JSON`,
542
+ (x) => Links$inboundSchema.parse(JSON.parse(x)),
543
+ `Failed to parse 'Links' from JSON`,
556
544
  );
557
545
  }
558
546
 
559
547
  /** @internal */
560
- export const ListPartnersBannedReason$inboundSchema: z.ZodNativeEnum<
561
- typeof ListPartnersBannedReason
562
- > = z.nativeEnum(ListPartnersBannedReason);
548
+ export const BannedReason$inboundSchema: z.ZodNativeEnum<typeof BannedReason> =
549
+ z.nativeEnum(BannedReason);
563
550
 
564
551
  /** @internal */
565
- export const Fields8$inboundSchema: z.ZodType<Fields8, z.ZodTypeDef, unknown> =
566
- z.object({
552
+ export const Eight$inboundSchema: z.ZodType<Eight, z.ZodTypeDef, unknown> = z
553
+ .object({
567
554
  key: z.string(),
568
555
  label: z.string(),
569
556
  required: z.boolean(),
@@ -572,19 +559,19 @@ export const Fields8$inboundSchema: z.ZodType<Fields8, z.ZodTypeDef, unknown> =
572
559
  type: z.literal("phone"),
573
560
  });
574
561
 
575
- export function fields8FromJSON(
562
+ export function eightFromJSON(
576
563
  jsonString: string,
577
- ): SafeParseResult<Fields8, SDKValidationError> {
564
+ ): SafeParseResult<Eight, SDKValidationError> {
578
565
  return safeParse(
579
566
  jsonString,
580
- (x) => Fields8$inboundSchema.parse(JSON.parse(x)),
581
- `Failed to parse 'Fields8' from JSON`,
567
+ (x) => Eight$inboundSchema.parse(JSON.parse(x)),
568
+ `Failed to parse 'Eight' from JSON`,
582
569
  );
583
570
  }
584
571
 
585
572
  /** @internal */
586
- export const Fields7$inboundSchema: z.ZodType<Fields7, z.ZodTypeDef, unknown> =
587
- z.object({
573
+ export const Seven$inboundSchema: z.ZodType<Seven, z.ZodTypeDef, unknown> = z
574
+ .object({
588
575
  key: z.string(),
589
576
  label: z.string(),
590
577
  required: z.boolean(),
@@ -593,19 +580,19 @@ export const Fields7$inboundSchema: z.ZodType<Fields7, z.ZodTypeDef, unknown> =
593
580
  type: z.literal("number"),
594
581
  });
595
582
 
596
- export function fields7FromJSON(
583
+ export function sevenFromJSON(
597
584
  jsonString: string,
598
- ): SafeParseResult<Fields7, SDKValidationError> {
585
+ ): SafeParseResult<Seven, SDKValidationError> {
599
586
  return safeParse(
600
587
  jsonString,
601
- (x) => Fields7$inboundSchema.parse(JSON.parse(x)),
602
- `Failed to parse 'Fields7' from JSON`,
588
+ (x) => Seven$inboundSchema.parse(JSON.parse(x)),
589
+ `Failed to parse 'Seven' from JSON`,
603
590
  );
604
591
  }
605
592
 
606
593
  /** @internal */
607
- export const ListPartnersFieldsPartnersOptions$inboundSchema: z.ZodType<
608
- ListPartnersFieldsPartnersOptions,
594
+ export const FieldsOptions$inboundSchema: z.ZodType<
595
+ FieldsOptions,
609
596
  z.ZodTypeDef,
610
597
  unknown
611
598
  > = z.object({
@@ -613,43 +600,41 @@ export const ListPartnersFieldsPartnersOptions$inboundSchema: z.ZodType<
613
600
  value: z.string(),
614
601
  });
615
602
 
616
- export function listPartnersFieldsPartnersOptionsFromJSON(
603
+ export function fieldsOptionsFromJSON(
617
604
  jsonString: string,
618
- ): SafeParseResult<ListPartnersFieldsPartnersOptions, SDKValidationError> {
605
+ ): SafeParseResult<FieldsOptions, SDKValidationError> {
619
606
  return safeParse(
620
607
  jsonString,
621
- (x) => ListPartnersFieldsPartnersOptions$inboundSchema.parse(JSON.parse(x)),
622
- `Failed to parse 'ListPartnersFieldsPartnersOptions' from JSON`,
608
+ (x) => FieldsOptions$inboundSchema.parse(JSON.parse(x)),
609
+ `Failed to parse 'FieldsOptions' from JSON`,
623
610
  );
624
611
  }
625
612
 
626
613
  /** @internal */
627
- export const Fields6$inboundSchema: z.ZodType<Fields6, z.ZodTypeDef, unknown> =
628
- z.object({
614
+ export const Six$inboundSchema: z.ZodType<Six, z.ZodTypeDef, unknown> = z
615
+ .object({
629
616
  key: z.string(),
630
617
  label: z.string(),
631
618
  required: z.boolean(),
632
619
  locked: z.boolean(),
633
620
  position: z.number().int(),
634
621
  type: z.literal("multiSelect"),
635
- options: z.array(
636
- z.lazy(() => ListPartnersFieldsPartnersOptions$inboundSchema),
637
- ),
622
+ options: z.array(z.lazy(() => FieldsOptions$inboundSchema)),
638
623
  });
639
624
 
640
- export function fields6FromJSON(
625
+ export function sixFromJSON(
641
626
  jsonString: string,
642
- ): SafeParseResult<Fields6, SDKValidationError> {
627
+ ): SafeParseResult<Six, SDKValidationError> {
643
628
  return safeParse(
644
629
  jsonString,
645
- (x) => Fields6$inboundSchema.parse(JSON.parse(x)),
646
- `Failed to parse 'Fields6' from JSON`,
630
+ (x) => Six$inboundSchema.parse(JSON.parse(x)),
631
+ `Failed to parse 'Six' from JSON`,
647
632
  );
648
633
  }
649
634
 
650
635
  /** @internal */
651
- export const Fields5$inboundSchema: z.ZodType<Fields5, z.ZodTypeDef, unknown> =
652
- z.object({
636
+ export const Five$inboundSchema: z.ZodType<Five, z.ZodTypeDef, unknown> = z
637
+ .object({
653
638
  key: z.string(),
654
639
  label: z.string(),
655
640
  required: z.boolean(),
@@ -658,134 +643,120 @@ export const Fields5$inboundSchema: z.ZodType<Fields5, z.ZodTypeDef, unknown> =
658
643
  type: z.literal("date"),
659
644
  });
660
645
 
661
- export function fields5FromJSON(
646
+ export function fiveFromJSON(
662
647
  jsonString: string,
663
- ): SafeParseResult<Fields5, SDKValidationError> {
648
+ ): SafeParseResult<Five, SDKValidationError> {
664
649
  return safeParse(
665
650
  jsonString,
666
- (x) => Fields5$inboundSchema.parse(JSON.parse(x)),
667
- `Failed to parse 'Fields5' from JSON`,
651
+ (x) => Five$inboundSchema.parse(JSON.parse(x)),
652
+ `Failed to parse 'Five' from JSON`,
668
653
  );
669
654
  }
670
655
 
671
656
  /** @internal */
672
- export const ListPartnersFields4$inboundSchema: z.ZodType<
673
- ListPartnersFields4,
674
- z.ZodTypeDef,
675
- unknown
676
- > = z.object({
677
- key: z.string(),
678
- label: z.string(),
679
- required: z.boolean(),
680
- locked: z.boolean(),
681
- position: z.number().int(),
682
- type: z.literal("country"),
683
- });
657
+ export const Fields4$inboundSchema: z.ZodType<Fields4, z.ZodTypeDef, unknown> =
658
+ z.object({
659
+ key: z.string(),
660
+ label: z.string(),
661
+ required: z.boolean(),
662
+ locked: z.boolean(),
663
+ position: z.number().int(),
664
+ type: z.literal("country"),
665
+ });
684
666
 
685
- export function listPartnersFields4FromJSON(
667
+ export function fields4FromJSON(
686
668
  jsonString: string,
687
- ): SafeParseResult<ListPartnersFields4, SDKValidationError> {
669
+ ): SafeParseResult<Fields4, SDKValidationError> {
688
670
  return safeParse(
689
671
  jsonString,
690
- (x) => ListPartnersFields4$inboundSchema.parse(JSON.parse(x)),
691
- `Failed to parse 'ListPartnersFields4' from JSON`,
672
+ (x) => Fields4$inboundSchema.parse(JSON.parse(x)),
673
+ `Failed to parse 'Fields4' from JSON`,
692
674
  );
693
675
  }
694
676
 
695
677
  /** @internal */
696
- export const ListPartnersFieldsOptions$inboundSchema: z.ZodType<
697
- ListPartnersFieldsOptions,
698
- z.ZodTypeDef,
699
- unknown
700
- > = z.object({
701
- label: z.string(),
702
- value: z.string(),
703
- });
678
+ export const Options$inboundSchema: z.ZodType<Options, z.ZodTypeDef, unknown> =
679
+ z.object({
680
+ label: z.string(),
681
+ value: z.string(),
682
+ });
704
683
 
705
- export function listPartnersFieldsOptionsFromJSON(
684
+ export function optionsFromJSON(
706
685
  jsonString: string,
707
- ): SafeParseResult<ListPartnersFieldsOptions, SDKValidationError> {
686
+ ): SafeParseResult<Options, SDKValidationError> {
708
687
  return safeParse(
709
688
  jsonString,
710
- (x) => ListPartnersFieldsOptions$inboundSchema.parse(JSON.parse(x)),
711
- `Failed to parse 'ListPartnersFieldsOptions' from JSON`,
689
+ (x) => Options$inboundSchema.parse(JSON.parse(x)),
690
+ `Failed to parse 'Options' from JSON`,
712
691
  );
713
692
  }
714
693
 
715
694
  /** @internal */
716
- export const ListPartnersFields3$inboundSchema: z.ZodType<
717
- ListPartnersFields3,
718
- z.ZodTypeDef,
719
- unknown
720
- > = z.object({
721
- key: z.string(),
722
- label: z.string(),
723
- required: z.boolean(),
724
- locked: z.boolean(),
725
- position: z.number().int(),
726
- type: z.literal("select"),
727
- options: z.array(z.lazy(() => ListPartnersFieldsOptions$inboundSchema)),
728
- });
695
+ export const Fields3$inboundSchema: z.ZodType<Fields3, z.ZodTypeDef, unknown> =
696
+ z.object({
697
+ key: z.string(),
698
+ label: z.string(),
699
+ required: z.boolean(),
700
+ locked: z.boolean(),
701
+ position: z.number().int(),
702
+ type: z.literal("select"),
703
+ options: z.array(z.lazy(() => Options$inboundSchema)),
704
+ });
729
705
 
730
- export function listPartnersFields3FromJSON(
706
+ export function fields3FromJSON(
731
707
  jsonString: string,
732
- ): SafeParseResult<ListPartnersFields3, SDKValidationError> {
708
+ ): SafeParseResult<Fields3, SDKValidationError> {
733
709
  return safeParse(
734
710
  jsonString,
735
- (x) => ListPartnersFields3$inboundSchema.parse(JSON.parse(x)),
736
- `Failed to parse 'ListPartnersFields3' from JSON`,
711
+ (x) => Fields3$inboundSchema.parse(JSON.parse(x)),
712
+ `Failed to parse 'Fields3' from JSON`,
737
713
  );
738
714
  }
739
715
 
740
716
  /** @internal */
741
- export const ListPartnersFieldsPartnersConstraints$inboundSchema: z.ZodType<
742
- ListPartnersFieldsPartnersConstraints,
717
+ export const FieldsConstraints$inboundSchema: z.ZodType<
718
+ FieldsConstraints,
743
719
  z.ZodTypeDef,
744
720
  unknown
745
721
  > = z.object({
746
722
  maxLength: z.number().int().optional(),
747
723
  });
748
724
 
749
- export function listPartnersFieldsPartnersConstraintsFromJSON(
725
+ export function fieldsConstraintsFromJSON(
750
726
  jsonString: string,
751
- ): SafeParseResult<ListPartnersFieldsPartnersConstraints, SDKValidationError> {
727
+ ): SafeParseResult<FieldsConstraints, SDKValidationError> {
752
728
  return safeParse(
753
729
  jsonString,
754
- (x) =>
755
- ListPartnersFieldsPartnersConstraints$inboundSchema.parse(JSON.parse(x)),
756
- `Failed to parse 'ListPartnersFieldsPartnersConstraints' from JSON`,
730
+ (x) => FieldsConstraints$inboundSchema.parse(JSON.parse(x)),
731
+ `Failed to parse 'FieldsConstraints' from JSON`,
757
732
  );
758
733
  }
759
734
 
760
735
  /** @internal */
761
- export const ListPartnersFields2$inboundSchema: z.ZodType<
762
- ListPartnersFields2,
763
- z.ZodTypeDef,
764
- unknown
765
- > = z.object({
766
- key: z.string(),
767
- label: z.string(),
768
- required: z.boolean(),
769
- locked: z.boolean(),
770
- position: z.number().int(),
771
- type: z.literal("textarea"),
772
- constraints: z.lazy(() => ListPartnersFieldsPartnersConstraints$inboundSchema)
773
- .optional(),
774
- });
736
+ export const Fields2$inboundSchema: z.ZodType<Fields2, z.ZodTypeDef, unknown> =
737
+ z.object({
738
+ key: z.string(),
739
+ label: z.string(),
740
+ required: z.boolean(),
741
+ locked: z.boolean(),
742
+ position: z.number().int(),
743
+ type: z.literal("textarea"),
744
+ constraints: z.lazy(() => FieldsConstraints$inboundSchema).optional(),
745
+ });
775
746
 
776
- export function listPartnersFields2FromJSON(
747
+ export function fields2FromJSON(
777
748
  jsonString: string,
778
- ): SafeParseResult<ListPartnersFields2, SDKValidationError> {
749
+ ): SafeParseResult<Fields2, SDKValidationError> {
779
750
  return safeParse(
780
751
  jsonString,
781
- (x) => ListPartnersFields2$inboundSchema.parse(JSON.parse(x)),
782
- `Failed to parse 'ListPartnersFields2' from JSON`,
752
+ (x) => Fields2$inboundSchema.parse(JSON.parse(x)),
753
+ `Failed to parse 'Fields2' from JSON`,
783
754
  );
784
755
  }
785
756
 
786
757
  /** @internal */
787
- export const ListPartnersFieldsConstraints$inboundSchema: z.ZodType<
788
- ListPartnersFieldsConstraints,
758
+ export const Constraints$inboundSchema: z.ZodType<
759
+ Constraints,
789
760
  z.ZodTypeDef,
790
761
  unknown
791
762
  > = z.object({
@@ -793,95 +764,88 @@ export const ListPartnersFieldsConstraints$inboundSchema: z.ZodType<
793
764
  pattern: z.string().optional(),
794
765
  });
795
766
 
796
- export function listPartnersFieldsConstraintsFromJSON(
767
+ export function constraintsFromJSON(
797
768
  jsonString: string,
798
- ): SafeParseResult<ListPartnersFieldsConstraints, SDKValidationError> {
769
+ ): SafeParseResult<Constraints, SDKValidationError> {
799
770
  return safeParse(
800
771
  jsonString,
801
- (x) => ListPartnersFieldsConstraints$inboundSchema.parse(JSON.parse(x)),
802
- `Failed to parse 'ListPartnersFieldsConstraints' from JSON`,
772
+ (x) => Constraints$inboundSchema.parse(JSON.parse(x)),
773
+ `Failed to parse 'Constraints' from JSON`,
803
774
  );
804
775
  }
805
776
 
806
777
  /** @internal */
807
- export const ListPartnersFields1$inboundSchema: z.ZodType<
808
- ListPartnersFields1,
809
- z.ZodTypeDef,
810
- unknown
811
- > = z.object({
812
- key: z.string(),
813
- label: z.string(),
814
- required: z.boolean(),
815
- locked: z.boolean(),
816
- position: z.number().int(),
817
- type: z.literal("text"),
818
- constraints: z.lazy(() => ListPartnersFieldsConstraints$inboundSchema)
819
- .optional(),
820
- });
778
+ export const Fields1$inboundSchema: z.ZodType<Fields1, z.ZodTypeDef, unknown> =
779
+ z.object({
780
+ key: z.string(),
781
+ label: z.string(),
782
+ required: z.boolean(),
783
+ locked: z.boolean(),
784
+ position: z.number().int(),
785
+ type: z.literal("text"),
786
+ constraints: z.lazy(() => Constraints$inboundSchema).optional(),
787
+ });
821
788
 
822
- export function listPartnersFields1FromJSON(
789
+ export function fields1FromJSON(
823
790
  jsonString: string,
824
- ): SafeParseResult<ListPartnersFields1, SDKValidationError> {
791
+ ): SafeParseResult<Fields1, SDKValidationError> {
825
792
  return safeParse(
826
793
  jsonString,
827
- (x) => ListPartnersFields1$inboundSchema.parse(JSON.parse(x)),
828
- `Failed to parse 'ListPartnersFields1' from JSON`,
794
+ (x) => Fields1$inboundSchema.parse(JSON.parse(x)),
795
+ `Failed to parse 'Fields1' from JSON`,
829
796
  );
830
797
  }
831
798
 
832
799
  /** @internal */
833
- export const ListPartnersFields$inboundSchema: z.ZodType<
834
- ListPartnersFields,
835
- z.ZodTypeDef,
836
- unknown
837
- > = z.union([
838
- z.lazy(() => ListPartnersFields1$inboundSchema),
839
- z.lazy(() => ListPartnersFields2$inboundSchema),
840
- z.lazy(() => ListPartnersFields3$inboundSchema),
841
- z.lazy(() => ListPartnersFields4$inboundSchema),
842
- z.lazy(() => Fields5$inboundSchema),
843
- z.lazy(() => Fields6$inboundSchema),
844
- z.lazy(() => Fields7$inboundSchema),
845
- z.lazy(() => Fields8$inboundSchema),
846
- ]);
847
-
848
- export function listPartnersFieldsFromJSON(
800
+ export const Fields$inboundSchema: z.ZodType<Fields, z.ZodTypeDef, unknown> = z
801
+ .union([
802
+ z.lazy(() => Fields1$inboundSchema),
803
+ z.lazy(() => Fields2$inboundSchema),
804
+ z.lazy(() => Fields3$inboundSchema),
805
+ z.lazy(() => Fields4$inboundSchema),
806
+ z.lazy(() => Five$inboundSchema),
807
+ z.lazy(() => Six$inboundSchema),
808
+ z.lazy(() => Seven$inboundSchema),
809
+ z.lazy(() => Eight$inboundSchema),
810
+ ]);
811
+
812
+ export function fieldsFromJSON(
849
813
  jsonString: string,
850
- ): SafeParseResult<ListPartnersFields, SDKValidationError> {
814
+ ): SafeParseResult<Fields, SDKValidationError> {
851
815
  return safeParse(
852
816
  jsonString,
853
- (x) => ListPartnersFields$inboundSchema.parse(JSON.parse(x)),
854
- `Failed to parse 'ListPartnersFields' from JSON`,
817
+ (x) => Fields$inboundSchema.parse(JSON.parse(x)),
818
+ `Failed to parse 'Fields' from JSON`,
855
819
  );
856
820
  }
857
821
 
858
822
  /** @internal */
859
- export const ListPartnersReferralFormData$inboundSchema: z.ZodType<
860
- ListPartnersReferralFormData,
823
+ export const ReferralFormData$inboundSchema: z.ZodType<
824
+ ReferralFormData,
861
825
  z.ZodTypeDef,
862
826
  unknown
863
827
  > = z.object({
864
828
  fields: z.array(
865
829
  z.union([
866
- z.lazy(() => ListPartnersFields1$inboundSchema),
867
- z.lazy(() => ListPartnersFields2$inboundSchema),
868
- z.lazy(() => ListPartnersFields3$inboundSchema),
869
- z.lazy(() => ListPartnersFields4$inboundSchema),
870
- z.lazy(() => Fields5$inboundSchema),
871
- z.lazy(() => Fields6$inboundSchema),
872
- z.lazy(() => Fields7$inboundSchema),
873
- z.lazy(() => Fields8$inboundSchema),
830
+ z.lazy(() => Fields1$inboundSchema),
831
+ z.lazy(() => Fields2$inboundSchema),
832
+ z.lazy(() => Fields3$inboundSchema),
833
+ z.lazy(() => Fields4$inboundSchema),
834
+ z.lazy(() => Five$inboundSchema),
835
+ z.lazy(() => Six$inboundSchema),
836
+ z.lazy(() => Seven$inboundSchema),
837
+ z.lazy(() => Eight$inboundSchema),
874
838
  ]),
875
839
  ),
876
840
  });
877
841
 
878
- export function listPartnersReferralFormDataFromJSON(
842
+ export function referralFormDataFromJSON(
879
843
  jsonString: string,
880
- ): SafeParseResult<ListPartnersReferralFormData, SDKValidationError> {
844
+ ): SafeParseResult<ReferralFormData, SDKValidationError> {
881
845
  return safeParse(
882
846
  jsonString,
883
- (x) => ListPartnersReferralFormData$inboundSchema.parse(JSON.parse(x)),
884
- `Failed to parse 'ListPartnersReferralFormData' from JSON`,
847
+ (x) => ReferralFormData$inboundSchema.parse(JSON.parse(x)),
848
+ `Failed to parse 'ReferralFormData' from JSON`,
885
849
  );
886
850
  }
887
851
 
@@ -908,7 +872,7 @@ export const ListPartnersResponseBody$inboundSchema: z.ZodType<
908
872
  tenantId: z.nullable(z.string()),
909
873
  createdAt: z.string(),
910
874
  status: ListPartnersStatus$inboundSchema,
911
- links: z.nullable(z.array(z.lazy(() => ListPartnersLinks$inboundSchema))),
875
+ links: z.nullable(z.array(z.lazy(() => Links$inboundSchema))),
912
876
  totalCommissions: z.number().default(0),
913
877
  clickRewardId: z.nullable(z.string()).optional(),
914
878
  leadRewardId: z.nullable(z.string()).optional(),
@@ -916,10 +880,9 @@ export const ListPartnersResponseBody$inboundSchema: z.ZodType<
916
880
  discountId: z.nullable(z.string()).optional(),
917
881
  applicationId: z.nullable(z.string()).optional(),
918
882
  bannedAt: z.nullable(z.string()).optional(),
919
- bannedReason: z.nullable(ListPartnersBannedReason$inboundSchema).optional(),
920
- referralFormData: z.nullable(
921
- z.lazy(() => ListPartnersReferralFormData$inboundSchema),
922
- ).optional(),
883
+ bannedReason: z.nullable(BannedReason$inboundSchema).optional(),
884
+ referralFormData: z.nullable(z.lazy(() => ReferralFormData$inboundSchema))
885
+ .optional(),
923
886
  totalClicks: z.number().default(0),
924
887
  totalLeads: z.number().default(0),
925
888
  totalConversions: z.number().default(0),