@wix/packages 1.0.3 → 1.0.5

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.
@@ -196,22 +196,59 @@ interface ProductInstanceCycle {
196
196
  /** Duration of the billing cycle. Available only for `RECURRING` payments. */
197
197
  cycleDuration?: CycleInterval;
198
198
  }
199
+ interface MigrateSubscriptionToPackagesRequest {
200
+ /** Created package. */
201
+ productInstance?: ProductInstance;
202
+ /** Existing subscriptionId to migrate */
203
+ subscriptionId?: string | null;
204
+ /** User id of the migration - only for Immigrator */
205
+ userId?: string | null;
206
+ }
207
+ interface MigrateSubscriptionToPackagesResponse {
208
+ package?: Package;
209
+ }
210
+ interface CreatePackageRequest {
211
+ /** Idempotency key. */
212
+ idempotencyKey?: string | null;
213
+ /** External reference. For example, an external subscription ID. **Note:** This field is not validated by Wix. */
214
+ externalId?: string | null;
215
+ /** Wix services that are resold. */
216
+ products: ProductInstance[];
217
+ }
199
218
  interface CreatePackageResponse {
200
219
  /** Idempotency key. */
201
220
  idempotencyKey?: string | null;
202
221
  /** Created package. */
203
222
  package?: Package;
204
223
  }
224
+ interface CancelPackageRequest {
225
+ /** Idempotency key. */
226
+ idempotencyKey?: string | null;
227
+ /** ID of the package to cancel. */
228
+ _id: string;
229
+ }
205
230
  interface CancelPackageResponse {
206
231
  /** Idempotency key. */
207
232
  idempotencyKey?: string | null;
208
233
  /** Canceled package. */
209
234
  package?: Package;
210
235
  }
236
+ interface PackageCanceled {
237
+ /** Canceled package. */
238
+ package?: Package;
239
+ }
240
+ interface GetPackageRequest {
241
+ /** Package ID. */
242
+ _id: string;
243
+ }
211
244
  interface GetPackageResponse {
212
245
  /** Retrieved package. */
213
246
  package?: Package;
214
247
  }
248
+ interface QueryPackagesRequest {
249
+ /** Query options. See [API Query Language](https://dev.wix.com/api/rest/getting-started/api-query-language) for more details. */
250
+ query: QueryV2;
251
+ }
215
252
  interface QueryV2 extends QueryV2PagingMethodOneOf {
216
253
  /** Paging options to limit and skip the number of items. */
217
254
  paging?: Paging;
@@ -298,233 +335,913 @@ interface Cursors {
298
335
  /** Cursor pointing to the previous page in the list of results. */
299
336
  prev?: string | null;
300
337
  }
338
+ interface AssignProductInstanceToSiteRequest {
339
+ /** Idempotency key. */
340
+ idempotencyKey?: string | null;
341
+ /** ID of the product instance to assign to a site. */
342
+ instanceId: string;
343
+ /** ID of the site to which the product instance is assigned. */
344
+ siteId: string;
345
+ }
301
346
  interface AssignProductInstanceToSiteResponse {
302
347
  /** Idempotency key. */
303
348
  idempotencyKey?: string | null;
304
349
  /** Updated package that includes the assigned product instance. */
305
350
  package?: Package;
306
351
  }
352
+ interface AssignedProductInstanceToSite {
353
+ /** Updated package. */
354
+ package?: Package;
355
+ /**
356
+ * ID of the product instance that was assigned to the site.
357
+ * @readonly
358
+ */
359
+ productInstanceId?: string;
360
+ /**
361
+ * ID of the site the product instance was assigned to.
362
+ * @readonly
363
+ */
364
+ siteId?: string;
365
+ }
366
+ interface UnassignProductInstanceFromSiteRequest {
367
+ /** Idempotency key. */
368
+ idempotencyKey?: string | null;
369
+ /** ID of the product instance to unassign from a site. */
370
+ instanceId: string;
371
+ }
307
372
  interface UnassignProductInstanceFromSiteResponse {
308
373
  /** Idempotency key. */
309
374
  idempotencyKey?: string | null;
310
375
  /** Updated package that includes the unassigned product instance. */
311
376
  package?: Package;
312
377
  }
378
+ interface UnassignedProductInstanceFromSite {
379
+ /** Updated package. */
380
+ package?: Package;
381
+ /**
382
+ * ID of the product instance that was unassigned from the site.
383
+ * @readonly
384
+ */
385
+ productInstanceId?: string;
386
+ /**
387
+ * MetasiteId of the site the product instance was unassigned from.
388
+ * @readonly
389
+ */
390
+ metaSiteId?: string;
391
+ }
392
+ interface CancelProductInstanceRequest {
393
+ /** Idempotency key. */
394
+ idempotencyKey?: string | null;
395
+ /** ID of the product instance to cancel. */
396
+ instanceId: string;
397
+ }
313
398
  interface CancelProductInstanceResponse {
314
399
  /** Idempotency key. */
315
400
  idempotencyKey?: string | null;
316
401
  /** Updated package that includes the previously included the canceled product instance. */
317
402
  package?: Package;
318
403
  }
404
+ interface ProductInstanceCanceled {
405
+ /** Updated package. */
406
+ package?: Package;
407
+ /**
408
+ * ID of the product instance that was canceled.
409
+ * @readonly
410
+ */
411
+ productInstanceId?: string;
412
+ }
413
+ interface AdjustProductInstanceSpecificationsRequest {
414
+ /** Idempotency key. */
415
+ idempotencyKey?: string | null;
416
+ /** ID of the product instance to adjust. */
417
+ instanceId: string;
418
+ /**
419
+ * ID of the product to replace the original instance. Required in case you don't
420
+ * provide a new `billingInfo` object.
421
+ */
422
+ catalogProductId?: string | null;
423
+ /**
424
+ * Information about the billing cycle. Required in case you don't provide a new
425
+ * `catalogProductId`. The new billing cycle must be supported for the service.
426
+ * Contact the [Wix B2B sales team](mailto:bizdev@wix.com) for
427
+ * information about a service's supported billing cycles. If
428
+ * you adjust the billing cycle for a product instance with `RECURRING`
429
+ * payments, you must also provide `billingInfo.cycleDuration.unit`.
430
+ */
431
+ billingInfo?: ProductInstanceCycle;
432
+ /**
433
+ * Discount code indicating that the reseller provisioned the product instance
434
+ * during a sale. Ignored when you don't pass a new `catalogProductId` as well.
435
+ * In case you pass a code that isn't valid, the call succeeds and
436
+ * no discount is applied to the product instance. Wix doesn't guarantee that a
437
+ * discount code reduces the price between Wix and the reseller, even when it's
438
+ * valid. You can't add a discount code after you've created the
439
+ * product instance. Contact the [Wix B2B sales team](mailto:bizdev@wix.com) for
440
+ * more information about supported codes.
441
+ *
442
+ * Max: 25 characters
443
+ */
444
+ discountCode?: string | null;
445
+ }
319
446
  interface AdjustProductInstanceSpecificationsResponse {
320
447
  /** Idempotency key. */
321
448
  idempotencyKey?: string | null;
322
449
  /** Updated package that includes the adjusted product instance. */
323
450
  package?: Package;
324
451
  }
325
- interface UpdatePackageResponse {
326
- /** Idempotency Key */
327
- idempotencyKey?: string | null;
328
- /** Updated Package */
452
+ interface AdjustedProductInstanceSpecifications {
453
+ /** Updated package. */
329
454
  package?: Package;
455
+ /**
456
+ * ID of the product instance to adjust.
457
+ * @readonly
458
+ */
459
+ productInstanceId?: string;
460
+ }
461
+ interface SubscriptionEvent extends SubscriptionEventEventOneOf {
462
+ /** Triggered when a subscription is created. */
463
+ created?: SubscriptionCreated;
464
+ /**
465
+ * Triggered when a subscription is assigned to a Wix site, including the initial
466
+ * assignment of a floating subscription or a re-assignement from a different site.
467
+ */
468
+ assigned?: SubscriptionAssigned;
469
+ /** Triggered when a subscription is canceled. */
470
+ cancelled?: SubscriptionCancelled;
471
+ /** Triggered when the subscription's auto renew is turned on. */
472
+ autoRenewTurnedOn?: SubscriptionAutoRenewTurnedOn;
473
+ /** Triggered when the subscription's auto renew is turned off. */
474
+ autoRenewTurnedOff?: SubscriptionAutoRenewTurnedOff;
475
+ /**
476
+ * Triggered when a subscription is unassigned from a Wix site and becomes
477
+ * floating.
478
+ */
479
+ unassigned?: SubscriptionUnassigned;
480
+ /**
481
+ * Triggered when a subscription is transferred from one Wix account to another.
482
+ * A transfer includes cancelling the original subscription and creating a new
483
+ * subscription for the target account. The event returns both the original
484
+ * and the new subscription.
485
+ */
486
+ transferred?: SubscriptionTransferred;
487
+ /** Triggered when a recurring charge succeeds for a subscription. */
488
+ recurringChargeSucceeded?: RecurringChargeSucceeded;
489
+ /**
490
+ * Triggered when a subscription was updated including when its product has been
491
+ * up- or downgraded or the billing cycle is changed.
492
+ */
493
+ contractSwitched?: ContractSwitched;
494
+ /**
495
+ * Triggered when a subscription gets close to the end of its billing cycle.
496
+ * The exact number of days is defined in the billing system.
497
+ */
498
+ nearEndOfPeriod?: SubscriptionNearEndOfPeriod;
499
+ /**
500
+ * Triggered when a subscription is updated and the change doesn't happen
501
+ * immediately but at the end of the current billing cycle.
502
+ */
503
+ pendingChange?: SubscriptionPendingChange;
504
+ /** ID of the subscription's event. */
505
+ eventId?: string | null;
506
+ /**
507
+ * Date and time of the event in
508
+ * [UTC datetime](https://en.wikipedia.org/wiki/Coordinated_Universal_Time)
509
+ * `YYYY-MM-DDThh:mm:ss.sssZ` format.
510
+ */
511
+ eventDate?: Date;
512
+ }
513
+ /** @oneof */
514
+ interface SubscriptionEventEventOneOf {
515
+ /** Triggered when a subscription is created. */
516
+ created?: SubscriptionCreated;
517
+ /**
518
+ * Triggered when a subscription is assigned to a Wix site, including the initial
519
+ * assignment of a floating subscription or a re-assignement from a different site.
520
+ */
521
+ assigned?: SubscriptionAssigned;
522
+ /** Triggered when a subscription is canceled. */
523
+ cancelled?: SubscriptionCancelled;
524
+ /** Triggered when the subscription's auto renew is turned on. */
525
+ autoRenewTurnedOn?: SubscriptionAutoRenewTurnedOn;
526
+ /** Triggered when the subscription's auto renew is turned off. */
527
+ autoRenewTurnedOff?: SubscriptionAutoRenewTurnedOff;
528
+ /**
529
+ * Triggered when a subscription is unassigned from a Wix site and becomes
530
+ * floating.
531
+ */
532
+ unassigned?: SubscriptionUnassigned;
533
+ /**
534
+ * Triggered when a subscription is transferred from one Wix account to another.
535
+ * A transfer includes cancelling the original subscription and creating a new
536
+ * subscription for the target account. The event returns both the original
537
+ * and the new subscription.
538
+ */
539
+ transferred?: SubscriptionTransferred;
540
+ /** Triggered when a recurring charge succeeds for a subscription. */
541
+ recurringChargeSucceeded?: RecurringChargeSucceeded;
542
+ /**
543
+ * Triggered when a subscription was updated including when its product has been
544
+ * up- or downgraded or the billing cycle is changed.
545
+ */
546
+ contractSwitched?: ContractSwitched;
547
+ /**
548
+ * Triggered when a subscription gets close to the end of its billing cycle.
549
+ * The exact number of days is defined in the billing system.
550
+ */
551
+ nearEndOfPeriod?: SubscriptionNearEndOfPeriod;
552
+ /**
553
+ * Triggered when a subscription is updated and the change doesn't happen
554
+ * immediately but at the end of the current billing cycle.
555
+ */
556
+ pendingChange?: SubscriptionPendingChange;
557
+ }
558
+ /** Triggered when a subscription is created. */
559
+ interface SubscriptionCreated {
560
+ /** Created subscription. */
561
+ subscription?: Subscription;
562
+ /** Metadata for the `created` event. */
563
+ metadata?: Record<string, string>;
564
+ /**
565
+ * Subscription reactivation data.
566
+ * A subscription can be reactivated for example if it was incorrectly canceled because of fraud and then reactivated
567
+ * by the billing system
568
+ */
569
+ reactivationData?: ReactivationData;
570
+ }
571
+ /**
572
+ * A subscription holds information about a Premium product that a Wix account
573
+ * owner has purchased including details about the billing.
574
+ */
575
+ interface Subscription {
576
+ /** ID of the subscription. */
577
+ _id?: string;
578
+ /** ID of the Wix account that purchased the subscription. */
579
+ userId?: string;
580
+ /**
581
+ * ID of the [product](https://bo.wix.com/wix-docs/rest/premium/premium-product-catalog-v2/products/product-object)
582
+ * for which the subscription was purchased.
583
+ */
584
+ productId?: string;
585
+ /**
586
+ * Date and time the subscription was created in
587
+ * [UTC datetime](https://en.wikipedia.org/wiki/Coordinated_Universal_Time)
588
+ * `YYYY-MM-DDThh:mm:ss.sssZ` format.
589
+ */
590
+ createdAt?: Date;
591
+ /**
592
+ * Date and time the subscription was last updated in
593
+ * [UTC datetime](https://en.wikipedia.org/wiki/Coordinated_Universal_Time)
594
+ * `YYYY-MM-DDThh:mm:ss.sssZ` format.
595
+ */
596
+ updatedAt?: Date;
597
+ /**
598
+ * ID of the metasite that the subscription is assigned to.
599
+ * Available only when the subscription is assigned to a Wix site.
600
+ * Subscriptions for account level products can't be assigned to a Wix site.
601
+ */
602
+ metaSiteId?: string | null;
603
+ /** Information about the system that manages the subscription's billing. */
604
+ billingReference?: BillingReference;
605
+ /** Information about the billing cycle of the subscription. */
606
+ cycle?: Cycle;
607
+ /**
608
+ * Subscription status.
609
+ *
610
+ * + `UNKNOWN`: Default status.
611
+ * + `AUTO_RENEW_ON`: Subscription is active and automatically renews at the end of the current billing cycle.
612
+ * + `AUTO_RENEW_OFF`: Subscription is active but expires at the end of the current billing cycle.
613
+ * + `MANUAL_RECURRING`: Subscription is active and renews at the end of the current billing cycle, in case the customer takes an action related to the payment.
614
+ * + `CANCELLED`: Subscription isn't active because it has been canceled.
615
+ * + `TRANSFERRED`: Subscription isn't active because it has been transferred to a different account. A different active subscription was created for the target account.
616
+ */
617
+ status?: SubscriptionStatus;
618
+ /**
619
+ * Date and time the subscription was last transferred from one Wix account to
620
+ * another in
621
+ * [UTC datetime](https://en.wikipedia.org/wiki/Coordinated_Universal_Time)
622
+ * `YYYY-MM-DDThh:mm:ss.sssZ` format.
623
+ */
624
+ transferredAt?: Date;
625
+ /**
626
+ * ID of the [product type](https://bo.wix.com/wix-docs/rest/premium/premium-product-catalog-v2/product-types/product-type-object)
627
+ * that the product, for which the subscription was purchased, belongs to.
628
+ */
629
+ productTypeId?: string;
630
+ /** Version number, which increments by 1 each time the subscription is updated. */
631
+ version?: number;
632
+ /**
633
+ * Whether the subscription is active. Includes the statuses
634
+ * `"AUTO_RENEW_ON"`, `"AUTO_RENEW_OFF"`, and `"MANUAL_RECURRING"`.
635
+ */
636
+ active?: boolean;
637
+ /**
638
+ * Date and time the subscription was originally created in
639
+ * [UTC datetime](https://en.wikipedia.org/wiki/Coordinated_Universal_Time)
640
+ * `YYYY-MM-DDThh:mm:ss.sssZ` format.
641
+ * Differs from `createdAt` in case the subscription was originally created for a different Wix account and has been transferred.
642
+ */
643
+ originalCreationDate?: Date;
644
+ /** Custom metadata about the subscription. */
645
+ metadata?: Record<string, string>;
646
+ /**
647
+ * 2-letter country code in
648
+ * [ISO-3166 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2#Officially_assigned_code_elements)
649
+ * format.
650
+ */
651
+ countryCode?: string | null;
652
+ }
653
+ interface BillingReference {
654
+ /**
655
+ * Name of the billing system that manages the subscription.
656
+ *
657
+ * + `"UNKNOWN"`: Default value.
658
+ * + `"SBS"`: [Wix Billing](https://github.com/wix-p/premium-billing/tree/master/sbs).
659
+ * + `"LICENSER"`:
660
+ * + `"BASS"`: [Billing and Subscriptions System](https://dev.wix.com/docs/rest/internal-only/premium/subscriptions-by-billing-by-wix/introduction).
661
+ * + `"RESELLER"`: [External Reseller](https://dev.wix.com/api/rest/account-level-apis/resellers/introduction).
662
+ */
663
+ providerName?: ProviderName;
664
+ /** Current provider reference ID. */
665
+ providerReferenceId?: string | null;
666
+ /** Previous provider reference IDs. Used for when a subscription is extended, specifically for domains. */
667
+ previousProviderReferenceIds?: string[];
668
+ }
669
+ declare enum ProviderName {
670
+ UNKNOWN = "UNKNOWN",
671
+ SBS = "SBS",
672
+ LICENSER = "LICENSER",
673
+ BASS = "BASS",
674
+ RESELLER = "RESELLER",
675
+ RECURRING_INVOICES = "RECURRING_INVOICES"
676
+ }
677
+ interface Cycle extends CycleCycleSelectorOneOf {
678
+ /** repetitive interval */
679
+ interval?: Interval;
680
+ /** one time */
681
+ oneTime?: OneTime;
682
+ }
683
+ /** @oneof */
684
+ interface CycleCycleSelectorOneOf {
685
+ /** repetitive interval */
686
+ interval?: Interval;
687
+ /** one time */
688
+ oneTime?: OneTime;
689
+ }
690
+ interface Interval {
691
+ /** interval unit of measure */
692
+ unit?: IntervalUnit;
693
+ /** number of interval */
694
+ count?: number;
695
+ }
696
+ declare enum IntervalUnit {
697
+ /** unknown interval unit */
698
+ UNKNOWN = "UNKNOWN",
699
+ /** day */
700
+ DAY = "DAY",
701
+ /** week */
702
+ WEEK = "WEEK",
703
+ /** month */
704
+ MONTH = "MONTH",
705
+ /** year */
706
+ YEAR = "YEAR"
707
+ }
708
+ interface OneTime {
709
+ }
710
+ declare enum SubscriptionStatus {
711
+ UNKNOWN = "UNKNOWN",
712
+ AUTO_RENEW_ON = "AUTO_RENEW_ON",
713
+ AUTO_RENEW_OFF = "AUTO_RENEW_OFF",
714
+ MANUAL_RECURRING = "MANUAL_RECURRING",
715
+ CANCELLED = "CANCELLED",
716
+ TRANSFERRED = "TRANSFERRED"
717
+ }
718
+ /** Triggered when a subscription is reactivated. */
719
+ interface ReactivationData {
720
+ reactivationReason?: ReactivationReasonEnum;
721
+ /**
722
+ * In the event of reactivation after chargeback dispute, the subscription may be extended according to the
723
+ * number of days it was inactive during the time of resolving the dispute
724
+ */
725
+ newEndOfPeriod?: Date;
726
+ /** The original end date, before the inactive period. */
727
+ oldEndOfPeriod?: Date;
728
+ /** The difference in days between the new new_end_of_period and old_end_of_period */
729
+ differenceInDays?: number | null;
730
+ }
731
+ /** Reason for subscription reactivation */
732
+ declare enum ReactivationReasonEnum {
733
+ UNKNOWN = "UNKNOWN",
734
+ /**
735
+ * Subscription was reactivated due to billing status change from CANCELED to ACTIVE, for example if it was incorrectly
736
+ * canceled because of suspicion of fraud
737
+ */
738
+ BILLING_STATUS_CHANGE = "BILLING_STATUS_CHANGE",
739
+ /** Subscription was reactivated after a chargeback dispute */
740
+ REACTIVATED_AFTER_CHARGEBACK = "REACTIVATED_AFTER_CHARGEBACK"
741
+ }
742
+ /**
743
+ * Triggered when a subscription is assigned to a Wix site, including the initial
744
+ * assignment of a floating subscription or a re-assignement from a different site.
745
+ */
746
+ interface SubscriptionAssigned {
747
+ /** Assigned subscription. */
748
+ subscription?: Subscription;
749
+ /** ID of the metasite that the subscription has been assigned to before the update. */
750
+ previousMetaSiteId?: string | null;
751
+ }
752
+ /** Triggered when a subscription is canceled. */
753
+ interface SubscriptionCancelled {
754
+ /** Canceled subscription. */
755
+ subscription?: Subscription;
756
+ /** Details about the cancellation including who canceled the subscription and why. */
757
+ cancellationDetails?: CancellationDetails;
758
+ /**
759
+ * Whether the subscription is canceled immediately or expires at the end of the current billing cycle.
760
+ *
761
+ * Default: `false`
762
+ */
763
+ immediateCancel?: boolean;
764
+ /** Whether the subscription was canceled during the free trial period. */
765
+ canceledInFreeTrial?: boolean;
766
+ }
767
+ /** Information about the cancellation flow including who canceled the subscription and why it was canceled. */
768
+ interface CancellationDetails {
769
+ /**
770
+ * Cancellation code.
771
+ *
772
+ * Values supported for cancellations on behalf of the billing system: `-1`, `-2`, `-3`, `-4`, `-5`, `-6`, `-7`, `-8`.
773
+ * For cancellations on behalf of the site owner or the service provider `cancellationCode`
774
+ * is taken from the request of
775
+ * [Cancel Immediately Offline](https://bo.wix.com/wix-docs/rest/premium/premium-subscriptions-manager/cancel-immediately-offline).
776
+ *
777
+ * + `-1`: The subscription has been cancelled by the billing system but none of the listed cancellation reasons applies.
778
+ * + `-2`: There were payment problems.
779
+ * + `-3`: There was a chargeback.
780
+ * + `-4`: Customer support has canceled the subscription and issued a refund.
781
+ * + `-5`: The site owner has changed their existing subscription.
782
+ * + `-6`: The subscription has been transferred to a different Wix account.
783
+ * + `-7`: The subscription has been canceled because the site owner hasn't manually authenticated the recurring payment during the subscription's grace period. For example, site owners must manually confirm recurring payments within 40 days when paying with boleto.
784
+ * + `-8`: The Wix account that the subscription belonged to has been deleted.
785
+ */
786
+ cancellationCode?: number | null;
787
+ /**
788
+ * Cancellation reason. For cancellations on behalf of the site owner or the service provider `cancellationReason`
789
+ * is taken from the request of
790
+ * [Cancel Immediately Offline](https://bo.wix.com/wix-docs/rest/premium/premium-subscriptions-manager/cancel-immediately-offline).
791
+ * For cancellations on behalf of the billing system `cancellationReason` is `null` or an empty string.
792
+ */
793
+ cancellationReason?: string | null;
794
+ /**
795
+ * Initiator of the cancellation. For `"USER_REQUESTED"` and `"APP_MANAGED"`,
796
+ * `cancellationCode` and `cancellationReason` are taken from the request of
797
+ * [Cancel Immediately](https://bo.wix.com/wix-docs/rest/premium/premium-subscriptions-manager/cancel-immediately)
798
+ * or [Cancel Immediately Offline](https://bo.wix.com/wix-docs/rest/premium/premium-subscriptions-manager/cancel-immediately-offline).
799
+ * For `"PASSIVE"`, cancellations `cancellationCode` is automatically calculated and `cancellationReason`
800
+ * is `null` or an empty string.
801
+ *
802
+ * + `"UNKNOWN`: Default value.
803
+ * + `"USER_REQUESTED"`: The Wix account owner has canceled the subscription.
804
+ * + `"APP_MANAGED"`: The service provider has canceled the subscription.
805
+ * + `"PASSIVE"`: The billing system has canceled the subscription. For example, in case of payment failure or fraud.
806
+ */
807
+ initiator?: Initiator;
808
+ }
809
+ declare enum Initiator {
810
+ UNKNOWN = "UNKNOWN",
811
+ USER_REQUESTED = "USER_REQUESTED",
812
+ APP_MANAGED = "APP_MANAGED",
813
+ PASSIVE = "PASSIVE"
814
+ }
815
+ /** Triggered when the subscription's auto renew is turned on. */
816
+ interface SubscriptionAutoRenewTurnedOn {
817
+ /** Subscription for which auto renew is turned on. */
818
+ subscription?: Subscription;
819
+ /**
820
+ * Supported values: `USER`, `APP`.
821
+ *
822
+ * Information about who turned auto renew on.
823
+ * + `"USER"`: The site owner who purchased the subscription has turned auto renew on.
824
+ * + `"APP"`: The service provider has turned auto renew on.
825
+ */
826
+ initiator?: string | null;
827
+ }
828
+ /** Triggered when the subscription's auto renew is turned off. */
829
+ interface SubscriptionAutoRenewTurnedOff {
830
+ /** Subscription for which auto renew is turned off. */
831
+ subscription?: Subscription;
832
+ /** Details about the cancellation including who canceled the subscription and why. */
833
+ cancellationDetails?: CancellationDetails;
834
+ /**
835
+ * Whether the subscription is immediately canceled or expires at the end of the current billing cycle.
836
+ *
837
+ * Default: `false`
838
+ */
839
+ immediateCancel?: boolean;
840
+ }
841
+ /**
842
+ * Triggered when a subscription is unassigned from a Wix site and becomes
843
+ * floating.
844
+ */
845
+ interface SubscriptionUnassigned {
846
+ /** Unassigned subscription. */
847
+ subscription?: Subscription;
848
+ /** ID of the metasite that the subscription has been assigned to before the event. */
849
+ previousMetaSiteId?: string;
850
+ /**
851
+ * Reason why the subscription is unassigned.
852
+ *
853
+ * + `"UNKNOWN"`: Default value.
854
+ * + `"USER_REQUESTED"`: The Wix account owner has unassigned the subscription.
855
+ * + `"REPLACED_BY_ANOTHER_SUBSCRIPTION"`: A different subscription that replaces this subscription is assigned to the site.
856
+ */
857
+ unassignReason?: UnassignReason;
858
+ }
859
+ declare enum UnassignReason {
860
+ UNKNOWN = "UNKNOWN",
861
+ USER_REQUESTED = "USER_REQUESTED",
862
+ REPLACED_BY_ANOTHER_SUBSCRIPTION = "REPLACED_BY_ANOTHER_SUBSCRIPTION"
863
+ }
864
+ /**
865
+ * Triggered when a subscription is transferred from one Wix account to another.
866
+ * A transfer includes cancelling the original subscription and creating a new
867
+ * subscription for the target account. The event returns both the original
868
+ * and the new subscription.
869
+ */
870
+ interface SubscriptionTransferred {
871
+ /** Original subscription that was canceled for the transfer. */
872
+ originSubscription?: Subscription;
873
+ /** Newly created subscription for the target account. */
874
+ targetSubscription?: Subscription;
875
+ }
876
+ /** Triggered when a recurring charge succeeds for a subscription. */
877
+ interface RecurringChargeSucceeded {
878
+ /** Subscription for which the recurring charge has succeeded. */
879
+ subscription?: Subscription;
880
+ /** Indication that there was a successful charge at the end of the free trial period */
881
+ freeTrialPeriodEnd?: boolean;
882
+ }
883
+ /**
884
+ * Triggered when a subscription was updated including when its product has been
885
+ * up- or downgraded or the billing cycle is changed.
886
+ */
887
+ interface ContractSwitched {
888
+ /** Updated subscription. */
889
+ subscription?: Subscription;
890
+ /** Billing cycle before the update. */
891
+ previousCycle?: Cycle;
892
+ /** ID of the product belonging to the subscription before the update. */
893
+ previousProductId?: string;
894
+ /** ID of the product type that the subscription's original product belonged to before the update. */
895
+ previousProductTypeId?: string;
896
+ /**
897
+ * Update type. __Note__: Doesn't include information about a product adjustment.
898
+ * For that purpose, see `productAdjustment`.
899
+ *
900
+ * + `"NOT_APPLICABLE"`: Default value.
901
+ * + `"ADDITIONAL_QUANTITY"`: An increased usage quota is added to the subscription. For example, a second mailbox is added to a subscription that previously included a single mailbox.
902
+ * + `"CREDIT_UNUSED_PERIOD"`: The subscription is upgraded and the new price is less than the regular price. The new price applies to every billing cycle, not just the first cycle.
903
+ * + `"REFUND_PRICE_DIFF"`: Not implemented.
904
+ * + `"ADJUST_PERIOD_END"`: Not implemented.
905
+ * + `"DOWNGRADE_GRACE_PERIOD"`: For downgrades during the grace period. In this situation, the site owner hasn’t paid yet and must immediately pay for the downgraded subscription.
906
+ * + `"FULL_AMOUNT_PERIOD"`: For upgrades in which the site owner retains unused benefits. For example, site owners upgrading a Facebook Ads subscription retain their unused FB Ads credit. The unused credit is added to the new credit.
907
+ * + `"END_OF_PERIOD"`: The subscription's billing current cycle is extended because of a downgrade.
908
+ * + `"PENDING_CHANGES"`: The subscription's billing is updated, but the change doesn't apply immediately. Instead, the update becomes effective at the end of current billing cycle.
909
+ * + `"DOWNGRADE_RENEWAL"`: The subscription is downgraded because of a declined payment. This prevents subscriptions from churning.
910
+ */
911
+ contractSwitchType?: ContractSwitchType;
912
+ /**
913
+ * ID of the metasite the subscription has been assigned to previously.
914
+ * Available only in case the subscription is assigned to a different site.
915
+ */
916
+ previousMetaSiteId?: string | null;
917
+ /**
918
+ * Update reason.
919
+ *
920
+ * + `"PRICE_INCREASE"`: The subscription's price has been increased.
921
+ * + `"EXTERNAL_PROVIDER_TRIGGER"`: Any reason other than a price increase.
922
+ */
923
+ contractSwitchReason?: ContractSwitchReason;
924
+ /** Information about the price update. Available only for updates with a price increase. */
925
+ productPriceIncreaseData?: ProductPriceIncreaseData;
926
+ /**
927
+ * Information about a product adjustment. For example, a downgrade.
928
+ * __Note__: This isn't the same as `contractSwitchType`.
929
+ *
930
+ * + `NOT_APPLICABLE`: There is no information about whether the product has been up- or downgraded.
931
+ * + `DOWNGRADE`: The product has been downgraded.
932
+ */
933
+ productAdjustment?: ProductAdjustment;
934
+ }
935
+ /** Copied from SBS */
936
+ declare enum ContractSwitchType {
937
+ NOT_APPLICABLE = "NOT_APPLICABLE",
938
+ ADDITIONAL_QUANTITY = "ADDITIONAL_QUANTITY",
939
+ CREDIT_UNUSED_PERIOD = "CREDIT_UNUSED_PERIOD",
940
+ REFUND_PRICE_DIFF = "REFUND_PRICE_DIFF",
941
+ ADJUST_PERIOD_END = "ADJUST_PERIOD_END",
942
+ DOWNGRADE_GRACE_PERIOD = "DOWNGRADE_GRACE_PERIOD",
943
+ FULL_AMOUNT_PERIOD = "FULL_AMOUNT_PERIOD",
944
+ END_OF_PERIOD = "END_OF_PERIOD",
945
+ PENDING_CHANGES = "PENDING_CHANGES",
946
+ DOWNGRADE_RENEWAL = "DOWNGRADE_RENEWAL"
947
+ }
948
+ declare enum ContractSwitchReason {
949
+ EXTERNAL_PROVIDER_TRIGGER = "EXTERNAL_PROVIDER_TRIGGER",
950
+ PRICE_INCREASE = "PRICE_INCREASE"
951
+ }
952
+ /** Triggered when a subscription's price is increased. */
953
+ interface ProductPriceIncreaseData {
954
+ /** Price of the subscription before the update. */
955
+ previousPrice?: string | null;
956
+ /** A value that is used in order to select the correct email template to send the user regarding the price increase. */
957
+ emailTemplateSelector?: string | null;
958
+ /** Used to differentiate between migration segments. Does not have to be unique per segment. */
959
+ segmentName?: string | null;
960
+ /** Used to determine how the price increase was triggered. */
961
+ priceIncreaseTrigger?: PriceIncreaseTrigger;
962
+ }
963
+ /** Reason for Price Increase Trigger */
964
+ declare enum PriceIncreaseTrigger {
965
+ NEAR_RENEWAL = "NEAR_RENEWAL",
966
+ RECURRING_SUCCESS = "RECURRING_SUCCESS",
967
+ MANUAL = "MANUAL"
968
+ }
969
+ /** Triggered when a subscription's product is adusted. */
970
+ declare enum ProductAdjustment {
971
+ /** flag to show that the ContractSwitchedEvent is not applicable / needed */
972
+ NOT_APPLICABLE = "NOT_APPLICABLE",
973
+ /** flag to show that the ContractSwitchedEvent is a Downgrade */
974
+ DOWNGRADE = "DOWNGRADE"
975
+ }
976
+ /**
977
+ * Triggered when a subscription gets close to the end of its billing cycle.
978
+ * The exact number of days is defined in the billing system.
979
+ */
980
+ interface SubscriptionNearEndOfPeriod {
981
+ /** Subscription that got close to the end of its billing cycle. */
982
+ subscription?: Subscription;
983
+ /** Whether the subscription is within the free trial period. */
984
+ inFreeTrial?: boolean;
985
+ }
986
+ /**
987
+ * Triggered when a subscription is updated and the change doesn't happen
988
+ * immediately but at the end of the current billing cycle.
989
+ */
990
+ interface SubscriptionPendingChange {
991
+ /** Subscription for which a pending update is triggered. */
992
+ subscription?: Subscription;
993
+ }
994
+ interface Empty {
995
+ }
996
+ interface ProductInstanceUpdated {
997
+ /** Updated package. */
998
+ package?: Package;
999
+ /**
1000
+ * ID of the product instance that was adjusted.
1001
+ * @readonly
1002
+ */
1003
+ productInstanceId?: string;
1004
+ }
1005
+ interface DomainEvent extends DomainEventBodyOneOf {
1006
+ createdEvent?: EntityCreatedEvent;
1007
+ updatedEvent?: EntityUpdatedEvent;
1008
+ deletedEvent?: EntityDeletedEvent;
1009
+ actionEvent?: ActionEvent;
1010
+ /**
1011
+ * Unique event ID.
1012
+ * Allows clients to ignore duplicate webhooks.
1013
+ */
1014
+ _id?: string;
1015
+ /**
1016
+ * Assumes actions are also always typed to an entity_type
1017
+ * Example: wix.stores.catalog.product, wix.bookings.session, wix.payments.transaction
1018
+ */
1019
+ entityFqdn?: string;
1020
+ /**
1021
+ * This is top level to ease client code dispatching of messages (switch on entity_fqdn+slug)
1022
+ * This is although the created/updated/deleted notion is duplication of the oneof types
1023
+ * Example: created/updated/deleted/started/completed/email_opened
1024
+ */
1025
+ slug?: string;
1026
+ /** ID of the entity associated with the event. */
1027
+ entityId?: string;
1028
+ /** Event timestamp in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601) format and UTC time. For example: 2020-04-26T13:57:50.699Z */
1029
+ eventTime?: Date;
1030
+ /**
1031
+ * Whether the event was triggered as a result of a privacy regulation application
1032
+ * (for example, GDPR).
1033
+ */
1034
+ triggeredByAnonymizeRequest?: boolean | null;
1035
+ /** If present, indicates the action that triggered the event. */
1036
+ originatedFrom?: string | null;
1037
+ /**
1038
+ * A sequence number defining the order of updates to the underlying entity.
1039
+ * For example, given that some entity was updated at 16:00 and than again at 16:01,
1040
+ * it is guaranteed that the sequence number of the second update is strictly higher than the first.
1041
+ * As the consumer, you can use this value to ensure that you handle messages in the correct order.
1042
+ * To do so, you will need to persist this number on your end, and compare the sequence number from the
1043
+ * message against the one you have stored. Given that the stored number is higher, you should ignore the message.
1044
+ */
1045
+ entityEventSequence?: string | null;
1046
+ }
1047
+ /** @oneof */
1048
+ interface DomainEventBodyOneOf {
1049
+ createdEvent?: EntityCreatedEvent;
1050
+ updatedEvent?: EntityUpdatedEvent;
1051
+ deletedEvent?: EntityDeletedEvent;
1052
+ actionEvent?: ActionEvent;
1053
+ }
1054
+ interface EntityCreatedEvent {
1055
+ entity?: string;
1056
+ }
1057
+ interface RestoreInfo {
1058
+ deletedDate?: Date;
1059
+ }
1060
+ interface EntityUpdatedEvent {
1061
+ /**
1062
+ * Since platformized APIs only expose PATCH and not PUT we can't assume that the fields sent from the client are the actual diff.
1063
+ * This means that to generate a list of changed fields (as opposed to sent fields) one needs to traverse both objects.
1064
+ * We don't want to impose this on all developers and so we leave this traversal to the notification recipients which need it.
1065
+ */
1066
+ currentEntity?: string;
1067
+ }
1068
+ interface EntityDeletedEvent {
1069
+ /** Entity that was deleted */
1070
+ deletedEntity?: string | null;
1071
+ }
1072
+ interface ActionEvent {
1073
+ body?: string;
1074
+ }
1075
+ interface FailureReportRequest {
1076
+ /** ID of the product instance that failed. */
1077
+ instanceId?: string;
1078
+ /** Failure reason. */
1079
+ reason?: FailureReason;
1080
+ }
1081
+ interface ProductInstanceFailed {
1082
+ /** Updated package. */
1083
+ package?: Package;
1084
+ /**
1085
+ * ID of the product instance that `FAILED`.
1086
+ * @readonly
1087
+ */
1088
+ productInstanceId?: string;
1089
+ /** Failure reason. */
1090
+ reason?: FailureReason;
1091
+ }
1092
+ interface Task {
1093
+ key?: TaskKey;
1094
+ executeAt?: Date;
1095
+ payload?: string | null;
1096
+ }
1097
+ interface TaskKey {
1098
+ appId?: string;
1099
+ instanceId?: string;
1100
+ subjectId?: string | null;
1101
+ }
1102
+ interface TaskAction extends TaskActionActionOneOf {
1103
+ complete?: Complete;
1104
+ cancel?: Cancel;
1105
+ reschedule?: Reschedule;
1106
+ }
1107
+ /** @oneof */
1108
+ interface TaskActionActionOneOf {
1109
+ complete?: Complete;
1110
+ cancel?: Cancel;
1111
+ reschedule?: Reschedule;
1112
+ }
1113
+ interface Complete {
1114
+ }
1115
+ interface Cancel {
1116
+ }
1117
+ interface Reschedule {
1118
+ executeAt?: Date;
1119
+ payload?: string | null;
1120
+ }
1121
+ interface UpdateProductInstanceRequest {
1122
+ /** ID of the product instance to update. */
1123
+ instanceId?: string;
1124
+ status?: Status;
1125
+ countryCode?: string | null;
1126
+ /** Which field to update, currently only status and countryCode are supported. */
1127
+ fieldToUpdate?: FieldToUpdate;
1128
+ }
1129
+ declare enum FieldToUpdate {
1130
+ STATUS = "STATUS",
1131
+ COUNTRY_CODE = "COUNTRY_CODE"
1132
+ }
1133
+ interface UpdateProductInstanceResponse {
1134
+ /** Updated Product Instance */
1135
+ productInstance?: ProductInstance;
1136
+ }
1137
+ interface UpdatePackageExternalIdRequest {
1138
+ /** The id of the package that we want to update. */
1139
+ packageId: string;
1140
+ /** The external id that will be assigned to the package. */
1141
+ externalId: string;
1142
+ }
1143
+ interface UpdatePackageExternalIdResponse {
1144
+ /** Updated Package */
1145
+ updatedPackage?: Package;
1146
+ }
1147
+ interface CountPackagesRequest {
1148
+ /** Filter on what packages to count */
1149
+ filter?: Record<string, any> | null;
1150
+ }
1151
+ interface CountPackagesResponse {
1152
+ /** Number of packages */
1153
+ count?: number;
1154
+ }
1155
+ interface MessageEnvelope {
1156
+ /** App instance ID. */
1157
+ instanceId?: string | null;
1158
+ /** Event type. */
1159
+ eventType?: string;
1160
+ /** The identification type and identity data. */
1161
+ identity?: IdentificationData;
1162
+ /** Stringify payload. */
1163
+ data?: string;
1164
+ }
1165
+ interface IdentificationData extends IdentificationDataIdOneOf {
1166
+ /** ID of a site visitor that has not logged in to the site. */
1167
+ anonymousVisitorId?: string;
1168
+ /** ID of a site visitor that has logged in to the site. */
1169
+ memberId?: string;
1170
+ /** ID of a Wix user (site owner, contributor, etc.). */
1171
+ wixUserId?: string;
1172
+ /** ID of an app. */
1173
+ appId?: string;
1174
+ /** @readonly */
1175
+ identityType?: WebhookIdentityType;
1176
+ }
1177
+ /** @oneof */
1178
+ interface IdentificationDataIdOneOf {
1179
+ /** ID of a site visitor that has not logged in to the site. */
1180
+ anonymousVisitorId?: string;
1181
+ /** ID of a site visitor that has logged in to the site. */
1182
+ memberId?: string;
1183
+ /** ID of a Wix user (site owner, contributor, etc.). */
1184
+ wixUserId?: string;
1185
+ /** ID of an app. */
1186
+ appId?: string;
1187
+ }
1188
+ declare enum WebhookIdentityType {
1189
+ UNKNOWN = "UNKNOWN",
1190
+ ANONYMOUS_VISITOR = "ANONYMOUS_VISITOR",
1191
+ MEMBER = "MEMBER",
1192
+ WIX_USER = "WIX_USER",
1193
+ APP = "APP"
1194
+ }
1195
+ interface CycleIntervalNonNullableFields {
1196
+ unit: IntervalIntervalUnit;
1197
+ count: number;
1198
+ }
1199
+ interface ProductInstanceCycleNonNullableFields {
1200
+ type: CycleDescriptorType;
1201
+ cycleDuration?: CycleIntervalNonNullableFields;
1202
+ }
1203
+ interface FailureReasonNonNullableFields {
1204
+ code: FailureReasonFailureReason;
1205
+ message: string;
1206
+ }
1207
+ interface ProductInstanceNonNullableFields {
1208
+ billingInfo?: ProductInstanceCycleNonNullableFields;
1209
+ instanceId: string;
1210
+ catalogProductId: string;
1211
+ status: Status;
1212
+ failure?: FailureReasonNonNullableFields;
1213
+ }
1214
+ interface PackageNonNullableFields {
1215
+ _id: string;
1216
+ accountId: string;
1217
+ productInstances: ProductInstanceNonNullableFields[];
330
1218
  }
331
1219
  interface CreatePackageResponseNonNullableFields {
332
- package?: {
333
- _id: string;
334
- accountId: string;
335
- productInstances: {
336
- billingInfo?: {
337
- type: CycleDescriptorType;
338
- cycleDuration?: {
339
- unit: IntervalIntervalUnit;
340
- count: number;
341
- };
342
- };
343
- instanceId: string;
344
- catalogProductId: string;
345
- status: Status;
346
- failure?: {
347
- code: FailureReasonFailureReason;
348
- message: string;
349
- };
350
- }[];
351
- };
1220
+ package?: PackageNonNullableFields;
352
1221
  }
353
1222
  interface CancelPackageResponseNonNullableFields {
354
- package?: {
355
- _id: string;
356
- accountId: string;
357
- productInstances: {
358
- billingInfo?: {
359
- type: CycleDescriptorType;
360
- cycleDuration?: {
361
- unit: IntervalIntervalUnit;
362
- count: number;
363
- };
364
- };
365
- instanceId: string;
366
- catalogProductId: string;
367
- status: Status;
368
- failure?: {
369
- code: FailureReasonFailureReason;
370
- message: string;
371
- };
372
- }[];
373
- };
1223
+ package?: PackageNonNullableFields;
374
1224
  }
375
1225
  interface GetPackageResponseNonNullableFields {
376
- package?: {
377
- _id: string;
378
- accountId: string;
379
- productInstances: {
380
- billingInfo?: {
381
- type: CycleDescriptorType;
382
- cycleDuration?: {
383
- unit: IntervalIntervalUnit;
384
- count: number;
385
- };
386
- };
387
- instanceId: string;
388
- catalogProductId: string;
389
- status: Status;
390
- failure?: {
391
- code: FailureReasonFailureReason;
392
- message: string;
393
- };
394
- }[];
395
- };
1226
+ package?: PackageNonNullableFields;
396
1227
  }
397
1228
  interface QueryPackagesResponseNonNullableFields {
398
- packages: {
399
- _id: string;
400
- accountId: string;
401
- productInstances: {
402
- billingInfo?: {
403
- type: CycleDescriptorType;
404
- cycleDuration?: {
405
- unit: IntervalIntervalUnit;
406
- count: number;
407
- };
408
- };
409
- instanceId: string;
410
- catalogProductId: string;
411
- status: Status;
412
- failure?: {
413
- code: FailureReasonFailureReason;
414
- message: string;
415
- };
416
- }[];
417
- }[];
1229
+ packages: PackageNonNullableFields[];
418
1230
  }
419
1231
  interface AssignProductInstanceToSiteResponseNonNullableFields {
420
- package?: {
421
- _id: string;
422
- accountId: string;
423
- productInstances: {
424
- billingInfo?: {
425
- type: CycleDescriptorType;
426
- cycleDuration?: {
427
- unit: IntervalIntervalUnit;
428
- count: number;
429
- };
430
- };
431
- instanceId: string;
432
- catalogProductId: string;
433
- status: Status;
434
- failure?: {
435
- code: FailureReasonFailureReason;
436
- message: string;
437
- };
438
- }[];
439
- };
1232
+ package?: PackageNonNullableFields;
440
1233
  }
441
1234
  interface UnassignProductInstanceFromSiteResponseNonNullableFields {
442
- package?: {
443
- _id: string;
444
- accountId: string;
445
- productInstances: {
446
- billingInfo?: {
447
- type: CycleDescriptorType;
448
- cycleDuration?: {
449
- unit: IntervalIntervalUnit;
450
- count: number;
451
- };
452
- };
453
- instanceId: string;
454
- catalogProductId: string;
455
- status: Status;
456
- failure?: {
457
- code: FailureReasonFailureReason;
458
- message: string;
459
- };
460
- }[];
461
- };
1235
+ package?: PackageNonNullableFields;
462
1236
  }
463
1237
  interface CancelProductInstanceResponseNonNullableFields {
464
- package?: {
465
- _id: string;
466
- accountId: string;
467
- productInstances: {
468
- billingInfo?: {
469
- type: CycleDescriptorType;
470
- cycleDuration?: {
471
- unit: IntervalIntervalUnit;
472
- count: number;
473
- };
474
- };
475
- instanceId: string;
476
- catalogProductId: string;
477
- status: Status;
478
- failure?: {
479
- code: FailureReasonFailureReason;
480
- message: string;
481
- };
482
- }[];
483
- };
1238
+ package?: PackageNonNullableFields;
484
1239
  }
485
1240
  interface AdjustProductInstanceSpecificationsResponseNonNullableFields {
486
- package?: {
487
- _id: string;
488
- accountId: string;
489
- productInstances: {
490
- billingInfo?: {
491
- type: CycleDescriptorType;
492
- cycleDuration?: {
493
- unit: IntervalIntervalUnit;
494
- count: number;
495
- };
496
- };
497
- instanceId: string;
498
- catalogProductId: string;
499
- status: Status;
500
- failure?: {
501
- code: FailureReasonFailureReason;
502
- message: string;
503
- };
504
- }[];
505
- };
506
- }
507
- interface UpdatePackageResponseNonNullableFields {
508
- package?: {
509
- _id: string;
510
- accountId: string;
511
- productInstances: {
512
- billingInfo?: {
513
- type: CycleDescriptorType;
514
- cycleDuration?: {
515
- unit: IntervalIntervalUnit;
516
- count: number;
517
- };
518
- };
519
- instanceId: string;
520
- catalogProductId: string;
521
- status: Status;
522
- failure?: {
523
- code: FailureReasonFailureReason;
524
- message: string;
525
- };
526
- }[];
527
- };
1241
+ package?: PackageNonNullableFields;
1242
+ }
1243
+ interface UpdatePackageExternalIdResponseNonNullableFields {
1244
+ updatedPackage?: PackageNonNullableFields;
528
1245
  }
529
1246
  interface CreatePackageOptions {
530
1247
  /** Idempotency key. */
@@ -595,17 +1312,16 @@ interface AdjustProductInstanceSpecificationsOptions {
595
1312
  */
596
1313
  discountCode?: string | null;
597
1314
  }
598
- interface UpdatePackageOptions {
599
- /** Idempotency Key */
600
- idempotencyKey?: string | null;
601
- /** Updated Package */
602
- package?: Package;
1315
+ interface UpdatePackageExternalIdOptions {
1316
+ /** The external id that will be assigned to the package. */
1317
+ externalId: string;
603
1318
  }
604
1319
 
605
1320
  type RESTFunctionDescriptor<T extends (...args: any[]) => any = (...args: any[]) => any> = (httpClient: HttpClient) => T;
606
1321
  interface HttpClient {
607
1322
  request<TResponse, TData = any>(req: RequestOptionsFactory<TResponse, TData>): Promise<HttpResponse<TResponse>>;
608
- fetchWithAuth: (url: string | URL, init?: RequestInit) => Promise<Response>;
1323
+ fetchWithAuth: typeof fetch;
1324
+ wixAPIFetch: (relativeUrl: string, options: RequestInit) => Promise<Response>;
609
1325
  }
610
1326
  type RequestOptionsFactory<TResponse = any, TData = any> = (context: any) => RequestOptions<TResponse, TData>;
611
1327
  type HttpResponse<T = any> = {
@@ -635,28 +1351,156 @@ declare global {
635
1351
  }
636
1352
  }
637
1353
 
638
- declare function createPackage$1(httpClient: HttpClient): (options?: CreatePackageOptions) => Promise<CreatePackageResponse & CreatePackageResponseNonNullableFields>;
639
- declare function createPackageV2$1(httpClient: HttpClient): (options?: CreatePackageV2Options) => Promise<CreatePackageResponse & CreatePackageResponseNonNullableFields>;
640
- declare function cancelPackage$1(httpClient: HttpClient): (_id: string, options?: CancelPackageOptions) => Promise<CancelPackageResponse & CancelPackageResponseNonNullableFields>;
641
- declare function getPackage$1(httpClient: HttpClient): (_id: string) => Promise<GetPackageResponse & GetPackageResponseNonNullableFields>;
642
- declare function queryPackages$1(httpClient: HttpClient): (query: QueryV2) => Promise<QueryPackagesResponse & QueryPackagesResponseNonNullableFields>;
643
- declare function assignProductInstanceToSite$1(httpClient: HttpClient): (identifiers: AssignProductInstanceToSiteIdentifiers, options?: AssignProductInstanceToSiteOptions) => Promise<AssignProductInstanceToSiteResponse & AssignProductInstanceToSiteResponseNonNullableFields>;
644
- declare function unassignProductInstanceFromSite$1(httpClient: HttpClient): (instanceId: string, options?: UnassignProductInstanceFromSiteOptions) => Promise<UnassignProductInstanceFromSiteResponse & UnassignProductInstanceFromSiteResponseNonNullableFields>;
645
- declare function cancelProductInstance$1(httpClient: HttpClient): (instanceId: string, options?: CancelProductInstanceOptions) => Promise<CancelProductInstanceResponse & CancelProductInstanceResponseNonNullableFields>;
646
- declare function adjustProductInstanceSpecifications$1(httpClient: HttpClient): (instanceId: string, options?: AdjustProductInstanceSpecificationsOptions) => Promise<AdjustProductInstanceSpecificationsResponse & AdjustProductInstanceSpecificationsResponseNonNullableFields>;
647
- declare function updatePackage$1(httpClient: HttpClient): (options?: UpdatePackageOptions) => Promise<UpdatePackageResponse & UpdatePackageResponseNonNullableFields>;
1354
+ declare function createRESTModule<T extends RESTFunctionDescriptor>(descriptor: T, elevated?: boolean): BuildRESTFunction<T> & T;
648
1355
 
649
- declare const createPackage: BuildRESTFunction<typeof createPackage$1>;
650
- declare const createPackageV2: BuildRESTFunction<typeof createPackageV2$1>;
651
- declare const cancelPackage: BuildRESTFunction<typeof cancelPackage$1>;
652
- declare const getPackage: BuildRESTFunction<typeof getPackage$1>;
653
- declare const queryPackages: BuildRESTFunction<typeof queryPackages$1>;
654
- declare const assignProductInstanceToSite: BuildRESTFunction<typeof assignProductInstanceToSite$1>;
655
- declare const unassignProductInstanceFromSite: BuildRESTFunction<typeof unassignProductInstanceFromSite$1>;
656
- declare const cancelProductInstance: BuildRESTFunction<typeof cancelProductInstance$1>;
657
- declare const adjustProductInstanceSpecifications: BuildRESTFunction<typeof adjustProductInstanceSpecifications$1>;
658
- declare const updatePackage: BuildRESTFunction<typeof updatePackage$1>;
1356
+ declare const createPackage: ReturnType<typeof createRESTModule<typeof publicCreatePackage>>;
1357
+ declare const createPackageV2: ReturnType<typeof createRESTModule<typeof publicCreatePackageV2>>;
1358
+ declare const cancelPackage: ReturnType<typeof createRESTModule<typeof publicCancelPackage>>;
1359
+ declare const getPackage: ReturnType<typeof createRESTModule<typeof publicGetPackage>>;
1360
+ declare const queryPackages: ReturnType<typeof createRESTModule<typeof publicQueryPackages>>;
1361
+ declare const assignProductInstanceToSite: ReturnType<typeof createRESTModule<typeof publicAssignProductInstanceToSite>>;
1362
+ declare const unassignProductInstanceFromSite: ReturnType<typeof createRESTModule<typeof publicUnassignProductInstanceFromSite>>;
1363
+ declare const cancelProductInstance: ReturnType<typeof createRESTModule<typeof publicCancelProductInstance>>;
1364
+ declare const adjustProductInstanceSpecifications: ReturnType<typeof createRESTModule<typeof publicAdjustProductInstanceSpecifications>>;
1365
+ declare const updatePackageExternalId: ReturnType<typeof createRESTModule<typeof publicUpdatePackageExternalId>>;
659
1366
 
1367
+ type context_ActionEvent = ActionEvent;
1368
+ type context_AdjustProductInstanceSpecificationsOptions = AdjustProductInstanceSpecificationsOptions;
1369
+ type context_AdjustProductInstanceSpecificationsRequest = AdjustProductInstanceSpecificationsRequest;
1370
+ type context_AdjustProductInstanceSpecificationsResponse = AdjustProductInstanceSpecificationsResponse;
1371
+ type context_AdjustProductInstanceSpecificationsResponseNonNullableFields = AdjustProductInstanceSpecificationsResponseNonNullableFields;
1372
+ type context_AdjustedProductInstanceSpecifications = AdjustedProductInstanceSpecifications;
1373
+ type context_AssignProductInstanceToSiteIdentifiers = AssignProductInstanceToSiteIdentifiers;
1374
+ type context_AssignProductInstanceToSiteOptions = AssignProductInstanceToSiteOptions;
1375
+ type context_AssignProductInstanceToSiteRequest = AssignProductInstanceToSiteRequest;
1376
+ type context_AssignProductInstanceToSiteResponse = AssignProductInstanceToSiteResponse;
1377
+ type context_AssignProductInstanceToSiteResponseNonNullableFields = AssignProductInstanceToSiteResponseNonNullableFields;
1378
+ type context_AssignedProductInstanceToSite = AssignedProductInstanceToSite;
1379
+ type context_BillingReference = BillingReference;
1380
+ type context_Cancel = Cancel;
1381
+ type context_CancelPackageOptions = CancelPackageOptions;
1382
+ type context_CancelPackageRequest = CancelPackageRequest;
1383
+ type context_CancelPackageResponse = CancelPackageResponse;
1384
+ type context_CancelPackageResponseNonNullableFields = CancelPackageResponseNonNullableFields;
1385
+ type context_CancelProductInstanceOptions = CancelProductInstanceOptions;
1386
+ type context_CancelProductInstanceRequest = CancelProductInstanceRequest;
1387
+ type context_CancelProductInstanceResponse = CancelProductInstanceResponse;
1388
+ type context_CancelProductInstanceResponseNonNullableFields = CancelProductInstanceResponseNonNullableFields;
1389
+ type context_CancellationDetails = CancellationDetails;
1390
+ type context_Complete = Complete;
1391
+ type context_ContractSwitchReason = ContractSwitchReason;
1392
+ declare const context_ContractSwitchReason: typeof ContractSwitchReason;
1393
+ type context_ContractSwitchType = ContractSwitchType;
1394
+ declare const context_ContractSwitchType: typeof ContractSwitchType;
1395
+ type context_ContractSwitched = ContractSwitched;
1396
+ type context_CountPackagesRequest = CountPackagesRequest;
1397
+ type context_CountPackagesResponse = CountPackagesResponse;
1398
+ type context_CreatePackageOptions = CreatePackageOptions;
1399
+ type context_CreatePackageRequest = CreatePackageRequest;
1400
+ type context_CreatePackageResponse = CreatePackageResponse;
1401
+ type context_CreatePackageResponseNonNullableFields = CreatePackageResponseNonNullableFields;
1402
+ type context_CreatePackageV2Options = CreatePackageV2Options;
1403
+ type context_CursorPaging = CursorPaging;
1404
+ type context_Cursors = Cursors;
1405
+ type context_Cycle = Cycle;
1406
+ type context_CycleCycleSelectorOneOf = CycleCycleSelectorOneOf;
1407
+ type context_CycleDescriptorType = CycleDescriptorType;
1408
+ declare const context_CycleDescriptorType: typeof CycleDescriptorType;
1409
+ type context_CycleInterval = CycleInterval;
1410
+ type context_DomainEvent = DomainEvent;
1411
+ type context_DomainEventBodyOneOf = DomainEventBodyOneOf;
1412
+ type context_Empty = Empty;
1413
+ type context_EntityCreatedEvent = EntityCreatedEvent;
1414
+ type context_EntityDeletedEvent = EntityDeletedEvent;
1415
+ type context_EntityUpdatedEvent = EntityUpdatedEvent;
1416
+ type context_FailureReason = FailureReason;
1417
+ type context_FailureReasonFailureReason = FailureReasonFailureReason;
1418
+ declare const context_FailureReasonFailureReason: typeof FailureReasonFailureReason;
1419
+ type context_FailureReportRequest = FailureReportRequest;
1420
+ type context_FieldToUpdate = FieldToUpdate;
1421
+ declare const context_FieldToUpdate: typeof FieldToUpdate;
1422
+ type context_GetPackageRequest = GetPackageRequest;
1423
+ type context_GetPackageResponse = GetPackageResponse;
1424
+ type context_GetPackageResponseNonNullableFields = GetPackageResponseNonNullableFields;
1425
+ type context_IdentificationData = IdentificationData;
1426
+ type context_IdentificationDataIdOneOf = IdentificationDataIdOneOf;
1427
+ type context_Initiator = Initiator;
1428
+ declare const context_Initiator: typeof Initiator;
1429
+ type context_Interval = Interval;
1430
+ type context_IntervalIntervalUnit = IntervalIntervalUnit;
1431
+ declare const context_IntervalIntervalUnit: typeof IntervalIntervalUnit;
1432
+ type context_IntervalUnit = IntervalUnit;
1433
+ declare const context_IntervalUnit: typeof IntervalUnit;
1434
+ type context_MessageEnvelope = MessageEnvelope;
1435
+ type context_MigrateSubscriptionToPackagesRequest = MigrateSubscriptionToPackagesRequest;
1436
+ type context_MigrateSubscriptionToPackagesResponse = MigrateSubscriptionToPackagesResponse;
1437
+ type context_OneTime = OneTime;
1438
+ type context_Package = Package;
1439
+ type context_PackageCanceled = PackageCanceled;
1440
+ type context_Paging = Paging;
1441
+ type context_PagingMetadataV2 = PagingMetadataV2;
1442
+ type context_PriceIncreaseTrigger = PriceIncreaseTrigger;
1443
+ declare const context_PriceIncreaseTrigger: typeof PriceIncreaseTrigger;
1444
+ type context_ProductAdjustment = ProductAdjustment;
1445
+ declare const context_ProductAdjustment: typeof ProductAdjustment;
1446
+ type context_ProductInstance = ProductInstance;
1447
+ type context_ProductInstanceCanceled = ProductInstanceCanceled;
1448
+ type context_ProductInstanceContractDetailsOneOf = ProductInstanceContractDetailsOneOf;
1449
+ type context_ProductInstanceCycle = ProductInstanceCycle;
1450
+ type context_ProductInstanceFailed = ProductInstanceFailed;
1451
+ type context_ProductInstanceUpdated = ProductInstanceUpdated;
1452
+ type context_ProductPriceIncreaseData = ProductPriceIncreaseData;
1453
+ type context_ProviderName = ProviderName;
1454
+ declare const context_ProviderName: typeof ProviderName;
1455
+ type context_QueryPackagesRequest = QueryPackagesRequest;
1456
+ type context_QueryPackagesResponse = QueryPackagesResponse;
1457
+ type context_QueryPackagesResponseNonNullableFields = QueryPackagesResponseNonNullableFields;
1458
+ type context_QueryV2 = QueryV2;
1459
+ type context_QueryV2PagingMethodOneOf = QueryV2PagingMethodOneOf;
1460
+ type context_ReactivationData = ReactivationData;
1461
+ type context_ReactivationReasonEnum = ReactivationReasonEnum;
1462
+ declare const context_ReactivationReasonEnum: typeof ReactivationReasonEnum;
1463
+ type context_RecurringChargeSucceeded = RecurringChargeSucceeded;
1464
+ type context_Reschedule = Reschedule;
1465
+ type context_RestoreInfo = RestoreInfo;
1466
+ type context_SortOrder = SortOrder;
1467
+ declare const context_SortOrder: typeof SortOrder;
1468
+ type context_Sorting = Sorting;
1469
+ type context_Status = Status;
1470
+ declare const context_Status: typeof Status;
1471
+ type context_Subscription = Subscription;
1472
+ type context_SubscriptionAssigned = SubscriptionAssigned;
1473
+ type context_SubscriptionAutoRenewTurnedOff = SubscriptionAutoRenewTurnedOff;
1474
+ type context_SubscriptionAutoRenewTurnedOn = SubscriptionAutoRenewTurnedOn;
1475
+ type context_SubscriptionCancelled = SubscriptionCancelled;
1476
+ type context_SubscriptionCreated = SubscriptionCreated;
1477
+ type context_SubscriptionEvent = SubscriptionEvent;
1478
+ type context_SubscriptionEventEventOneOf = SubscriptionEventEventOneOf;
1479
+ type context_SubscriptionNearEndOfPeriod = SubscriptionNearEndOfPeriod;
1480
+ type context_SubscriptionPendingChange = SubscriptionPendingChange;
1481
+ type context_SubscriptionStatus = SubscriptionStatus;
1482
+ declare const context_SubscriptionStatus: typeof SubscriptionStatus;
1483
+ type context_SubscriptionTransferred = SubscriptionTransferred;
1484
+ type context_SubscriptionUnassigned = SubscriptionUnassigned;
1485
+ type context_Task = Task;
1486
+ type context_TaskAction = TaskAction;
1487
+ type context_TaskActionActionOneOf = TaskActionActionOneOf;
1488
+ type context_TaskKey = TaskKey;
1489
+ type context_UnassignProductInstanceFromSiteOptions = UnassignProductInstanceFromSiteOptions;
1490
+ type context_UnassignProductInstanceFromSiteRequest = UnassignProductInstanceFromSiteRequest;
1491
+ type context_UnassignProductInstanceFromSiteResponse = UnassignProductInstanceFromSiteResponse;
1492
+ type context_UnassignProductInstanceFromSiteResponseNonNullableFields = UnassignProductInstanceFromSiteResponseNonNullableFields;
1493
+ type context_UnassignReason = UnassignReason;
1494
+ declare const context_UnassignReason: typeof UnassignReason;
1495
+ type context_UnassignedProductInstanceFromSite = UnassignedProductInstanceFromSite;
1496
+ type context_UpdatePackageExternalIdOptions = UpdatePackageExternalIdOptions;
1497
+ type context_UpdatePackageExternalIdRequest = UpdatePackageExternalIdRequest;
1498
+ type context_UpdatePackageExternalIdResponse = UpdatePackageExternalIdResponse;
1499
+ type context_UpdatePackageExternalIdResponseNonNullableFields = UpdatePackageExternalIdResponseNonNullableFields;
1500
+ type context_UpdateProductInstanceRequest = UpdateProductInstanceRequest;
1501
+ type context_UpdateProductInstanceResponse = UpdateProductInstanceResponse;
1502
+ type context_WebhookIdentityType = WebhookIdentityType;
1503
+ declare const context_WebhookIdentityType: typeof WebhookIdentityType;
660
1504
  declare const context_adjustProductInstanceSpecifications: typeof adjustProductInstanceSpecifications;
661
1505
  declare const context_assignProductInstanceToSite: typeof assignProductInstanceToSite;
662
1506
  declare const context_cancelPackage: typeof cancelPackage;
@@ -666,9 +1510,9 @@ declare const context_createPackageV2: typeof createPackageV2;
666
1510
  declare const context_getPackage: typeof getPackage;
667
1511
  declare const context_queryPackages: typeof queryPackages;
668
1512
  declare const context_unassignProductInstanceFromSite: typeof unassignProductInstanceFromSite;
669
- declare const context_updatePackage: typeof updatePackage;
1513
+ declare const context_updatePackageExternalId: typeof updatePackageExternalId;
670
1514
  declare namespace context {
671
- export { context_adjustProductInstanceSpecifications as adjustProductInstanceSpecifications, context_assignProductInstanceToSite as assignProductInstanceToSite, context_cancelPackage as cancelPackage, context_cancelProductInstance as cancelProductInstance, context_createPackage as createPackage, context_createPackageV2 as createPackageV2, context_getPackage as getPackage, context_queryPackages as queryPackages, context_unassignProductInstanceFromSite as unassignProductInstanceFromSite, context_updatePackage as updatePackage };
1515
+ export { type context_ActionEvent as ActionEvent, type context_AdjustProductInstanceSpecificationsOptions as AdjustProductInstanceSpecificationsOptions, type context_AdjustProductInstanceSpecificationsRequest as AdjustProductInstanceSpecificationsRequest, type context_AdjustProductInstanceSpecificationsResponse as AdjustProductInstanceSpecificationsResponse, type context_AdjustProductInstanceSpecificationsResponseNonNullableFields as AdjustProductInstanceSpecificationsResponseNonNullableFields, type context_AdjustedProductInstanceSpecifications as AdjustedProductInstanceSpecifications, type context_AssignProductInstanceToSiteIdentifiers as AssignProductInstanceToSiteIdentifiers, type context_AssignProductInstanceToSiteOptions as AssignProductInstanceToSiteOptions, type context_AssignProductInstanceToSiteRequest as AssignProductInstanceToSiteRequest, type context_AssignProductInstanceToSiteResponse as AssignProductInstanceToSiteResponse, type context_AssignProductInstanceToSiteResponseNonNullableFields as AssignProductInstanceToSiteResponseNonNullableFields, type context_AssignedProductInstanceToSite as AssignedProductInstanceToSite, type context_BillingReference as BillingReference, type context_Cancel as Cancel, type context_CancelPackageOptions as CancelPackageOptions, type context_CancelPackageRequest as CancelPackageRequest, type context_CancelPackageResponse as CancelPackageResponse, type context_CancelPackageResponseNonNullableFields as CancelPackageResponseNonNullableFields, type context_CancelProductInstanceOptions as CancelProductInstanceOptions, type context_CancelProductInstanceRequest as CancelProductInstanceRequest, type context_CancelProductInstanceResponse as CancelProductInstanceResponse, type context_CancelProductInstanceResponseNonNullableFields as CancelProductInstanceResponseNonNullableFields, type context_CancellationDetails as CancellationDetails, type context_Complete as Complete, context_ContractSwitchReason as ContractSwitchReason, context_ContractSwitchType as ContractSwitchType, type context_ContractSwitched as ContractSwitched, type context_CountPackagesRequest as CountPackagesRequest, type context_CountPackagesResponse as CountPackagesResponse, type context_CreatePackageOptions as CreatePackageOptions, type context_CreatePackageRequest as CreatePackageRequest, type context_CreatePackageResponse as CreatePackageResponse, type context_CreatePackageResponseNonNullableFields as CreatePackageResponseNonNullableFields, type context_CreatePackageV2Options as CreatePackageV2Options, type context_CursorPaging as CursorPaging, type context_Cursors as Cursors, type context_Cycle as Cycle, type context_CycleCycleSelectorOneOf as CycleCycleSelectorOneOf, context_CycleDescriptorType as CycleDescriptorType, type context_CycleInterval as CycleInterval, type context_DomainEvent as DomainEvent, type context_DomainEventBodyOneOf as DomainEventBodyOneOf, type context_Empty as Empty, type context_EntityCreatedEvent as EntityCreatedEvent, type context_EntityDeletedEvent as EntityDeletedEvent, type context_EntityUpdatedEvent as EntityUpdatedEvent, type context_FailureReason as FailureReason, context_FailureReasonFailureReason as FailureReasonFailureReason, type context_FailureReportRequest as FailureReportRequest, context_FieldToUpdate as FieldToUpdate, type context_GetPackageRequest as GetPackageRequest, type context_GetPackageResponse as GetPackageResponse, type context_GetPackageResponseNonNullableFields as GetPackageResponseNonNullableFields, type context_IdentificationData as IdentificationData, type context_IdentificationDataIdOneOf as IdentificationDataIdOneOf, context_Initiator as Initiator, type context_Interval as Interval, context_IntervalIntervalUnit as IntervalIntervalUnit, context_IntervalUnit as IntervalUnit, type context_MessageEnvelope as MessageEnvelope, type context_MigrateSubscriptionToPackagesRequest as MigrateSubscriptionToPackagesRequest, type context_MigrateSubscriptionToPackagesResponse as MigrateSubscriptionToPackagesResponse, type context_OneTime as OneTime, type context_Package as Package, type context_PackageCanceled as PackageCanceled, type context_Paging as Paging, type context_PagingMetadataV2 as PagingMetadataV2, context_PriceIncreaseTrigger as PriceIncreaseTrigger, context_ProductAdjustment as ProductAdjustment, type context_ProductInstance as ProductInstance, type context_ProductInstanceCanceled as ProductInstanceCanceled, type context_ProductInstanceContractDetailsOneOf as ProductInstanceContractDetailsOneOf, type context_ProductInstanceCycle as ProductInstanceCycle, type context_ProductInstanceFailed as ProductInstanceFailed, type context_ProductInstanceUpdated as ProductInstanceUpdated, type context_ProductPriceIncreaseData as ProductPriceIncreaseData, context_ProviderName as ProviderName, type context_QueryPackagesRequest as QueryPackagesRequest, type context_QueryPackagesResponse as QueryPackagesResponse, type context_QueryPackagesResponseNonNullableFields as QueryPackagesResponseNonNullableFields, type context_QueryV2 as QueryV2, type context_QueryV2PagingMethodOneOf as QueryV2PagingMethodOneOf, type context_ReactivationData as ReactivationData, context_ReactivationReasonEnum as ReactivationReasonEnum, type context_RecurringChargeSucceeded as RecurringChargeSucceeded, type context_Reschedule as Reschedule, type context_RestoreInfo as RestoreInfo, context_SortOrder as SortOrder, type context_Sorting as Sorting, context_Status as Status, type context_Subscription as Subscription, type context_SubscriptionAssigned as SubscriptionAssigned, type context_SubscriptionAutoRenewTurnedOff as SubscriptionAutoRenewTurnedOff, type context_SubscriptionAutoRenewTurnedOn as SubscriptionAutoRenewTurnedOn, type context_SubscriptionCancelled as SubscriptionCancelled, type context_SubscriptionCreated as SubscriptionCreated, type context_SubscriptionEvent as SubscriptionEvent, type context_SubscriptionEventEventOneOf as SubscriptionEventEventOneOf, type context_SubscriptionNearEndOfPeriod as SubscriptionNearEndOfPeriod, type context_SubscriptionPendingChange as SubscriptionPendingChange, context_SubscriptionStatus as SubscriptionStatus, type context_SubscriptionTransferred as SubscriptionTransferred, type context_SubscriptionUnassigned as SubscriptionUnassigned, type context_Task as Task, type context_TaskAction as TaskAction, type context_TaskActionActionOneOf as TaskActionActionOneOf, type context_TaskKey as TaskKey, type context_UnassignProductInstanceFromSiteOptions as UnassignProductInstanceFromSiteOptions, type context_UnassignProductInstanceFromSiteRequest as UnassignProductInstanceFromSiteRequest, type context_UnassignProductInstanceFromSiteResponse as UnassignProductInstanceFromSiteResponse, type context_UnassignProductInstanceFromSiteResponseNonNullableFields as UnassignProductInstanceFromSiteResponseNonNullableFields, context_UnassignReason as UnassignReason, type context_UnassignedProductInstanceFromSite as UnassignedProductInstanceFromSite, type context_UpdatePackageExternalIdOptions as UpdatePackageExternalIdOptions, type context_UpdatePackageExternalIdRequest as UpdatePackageExternalIdRequest, type context_UpdatePackageExternalIdResponse as UpdatePackageExternalIdResponse, type context_UpdatePackageExternalIdResponseNonNullableFields as UpdatePackageExternalIdResponseNonNullableFields, type context_UpdateProductInstanceRequest as UpdateProductInstanceRequest, type context_UpdateProductInstanceResponse as UpdateProductInstanceResponse, context_WebhookIdentityType as WebhookIdentityType, context_adjustProductInstanceSpecifications as adjustProductInstanceSpecifications, context_assignProductInstanceToSite as assignProductInstanceToSite, context_cancelPackage as cancelPackage, context_cancelProductInstance as cancelProductInstance, context_createPackage as createPackage, context_createPackageV2 as createPackageV2, context_getPackage as getPackage, context_queryPackages as queryPackages, context_unassignProductInstanceFromSite as unassignProductInstanceFromSite, context_updatePackageExternalId as updatePackageExternalId };
672
1516
  }
673
1517
 
674
1518
  export { context as packages };