@salable/sdk 1.0.7 → 1.0.8

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.
@@ -117,11 +117,11 @@ export interface BatchReceiptActionsResponseSchema_data_results extends Parsable
117
117
  export type BatchReceiptActionsResponseSchema_data_results_status = string;
118
118
  export interface BatchSubscriptionActionsRequestSchema extends Parsable {
119
119
  /**
120
- * The action property
120
+ * The action to perform on all provided subscriptions. One of `cancel`, `enable-auto-renew`, `disable-auto-renew`, `delete`. The `delete` action is only available in test mode.
121
121
  */
122
122
  action?: BatchSubscriptionActionsRequestSchema_action | null;
123
123
  /**
124
- * The subscriptionIds property
124
+ * The IDs of the subscriptions to apply the action to. Maximum of 100 IDs per request.
125
125
  */
126
126
  subscriptionIds?: string[] | null;
127
127
  }
@@ -2780,21 +2780,24 @@ export interface CreatePlanResponseSchema_data extends Parsable {
2780
2780
  }
2781
2781
  export interface CreatePortalRequestSchema extends Parsable {
2782
2782
  /**
2783
- * The features property
2783
+ * The portal features to enable for this session.
2784
2784
  */
2785
2785
  features?: CreatePortalRequestSchema_features | null;
2786
2786
  /**
2787
- * The returnUrl property
2787
+ * The URL to redirect customers to after they have finished managing their subscription in the portal.
2788
2788
  */
2789
2789
  returnUrl?: string | null;
2790
2790
  }
2791
+ /**
2792
+ * The portal features to enable for this session.
2793
+ */
2791
2794
  export interface CreatePortalRequestSchema_features extends Parsable {
2792
2795
  /**
2793
2796
  * Enables a customer to update their personal information.
2794
2797
  */
2795
2798
  customerUpdate?: CreatePortalRequestSchema_features_customerUpdate | null;
2796
2799
  /**
2797
- * Enables a customer to view invoice history.
2800
+ * Enables a customer to view their invoice history.
2798
2801
  */
2799
2802
  invoiceHistory?: CreatePortalRequestSchema_features_invoiceHistory | null;
2800
2803
  /**
@@ -2802,7 +2805,7 @@ export interface CreatePortalRequestSchema_features extends Parsable {
2802
2805
  */
2803
2806
  paymentMethodUpdate?: CreatePortalRequestSchema_features_paymentMethodUpdate | null;
2804
2807
  /**
2805
- * The subscriptionCancel property
2808
+ * Enables a customer to cancel their subscription.
2806
2809
  */
2807
2810
  subscriptionCancel?: CreatePortalRequestSchema_features_subscriptionCancel | null;
2808
2811
  }
@@ -2811,21 +2814,21 @@ export interface CreatePortalRequestSchema_features extends Parsable {
2811
2814
  */
2812
2815
  export interface CreatePortalRequestSchema_features_customerUpdate extends Parsable {
2813
2816
  /**
2814
- * Define what you want to allow customers to be able to update.
2817
+ * The customer fields that can be updated. Accepted values: `name`, `email`, `address`, `phone`, `shipping`.
2815
2818
  */
2816
2819
  allowedUpdates?: CreatePortalRequestSchema_features_customerUpdate_allowedUpdates[] | null;
2817
2820
  /**
2818
- * The enabled property
2821
+ * Whether to enable this feature in the portal.
2819
2822
  */
2820
2823
  enabled?: boolean | null;
2821
2824
  }
2822
2825
  export type CreatePortalRequestSchema_features_customerUpdate_allowedUpdates = (typeof CreatePortalRequestSchema_features_customerUpdate_allowedUpdatesObject)[keyof typeof CreatePortalRequestSchema_features_customerUpdate_allowedUpdatesObject];
2823
2826
  /**
2824
- * Enables a customer to view invoice history.
2827
+ * Enables a customer to view their invoice history.
2825
2828
  */
2826
2829
  export interface CreatePortalRequestSchema_features_invoiceHistory extends Parsable {
2827
2830
  /**
2828
- * The enabled property
2831
+ * Whether to enable this feature in the portal.
2829
2832
  */
2830
2833
  enabled?: boolean | null;
2831
2834
  }
@@ -2834,17 +2837,20 @@ export interface CreatePortalRequestSchema_features_invoiceHistory extends Parsa
2834
2837
  */
2835
2838
  export interface CreatePortalRequestSchema_features_paymentMethodUpdate extends Parsable {
2836
2839
  /**
2837
- * The enabled property
2840
+ * Whether to enable this feature in the portal.
2838
2841
  */
2839
2842
  enabled?: boolean | null;
2840
2843
  }
2844
+ /**
2845
+ * Enables a customer to cancel their subscription.
2846
+ */
2841
2847
  export interface CreatePortalRequestSchema_features_subscriptionCancel extends Parsable {
2842
2848
  /**
2843
- * The enabled property
2849
+ * Whether to enable this feature in the portal.
2844
2850
  */
2845
2851
  enabled?: boolean | null;
2846
2852
  /**
2847
- * "now" - cancels the subscription immediately. "end" - schedules the subscription to cancel at the end of the billing period.
2853
+ * `now` cancels the subscription immediately. `end` schedules cancellation at the end of the current billing period.
2848
2854
  */
2849
2855
  when?: CreatePortalRequestSchema_features_subscriptionCancel_when | null;
2850
2856
  }
@@ -17620,73 +17626,79 @@ export interface UpdateProductResponseSchema_data extends Parsable {
17620
17626
  }
17621
17627
  export interface UpdateSubscriptionItemsRequestSchema extends Parsable {
17622
17628
  /**
17623
- * The items property
17629
+ * The list of plan changes to apply to the subscription.
17624
17630
  */
17625
17631
  items?: (UpdateSubscriptionItemsRequestSchema_itemsMember1 | UpdateSubscriptionItemsRequestSchema_itemsMember2 | UpdateSubscriptionItemsRequestSchema_itemsMember3)[] | null;
17626
17632
  /**
17627
- * The proration property
17633
+ * Controls how Stripe handles proration when items change mid-billing-period. Required for paid subscriptions; not applicable to Salable-only subscriptions. One of `always_invoice`, `create_prorations`, `none`.
17628
17634
  */
17629
17635
  proration?: UpdateSubscriptionItemsRequestSchema_proration | null;
17630
17636
  }
17631
17637
  export type UpdateSubscriptionItemsRequestSchema_items = UpdateSubscriptionItemsRequestSchema_itemsMember1 | UpdateSubscriptionItemsRequestSchema_itemsMember2 | UpdateSubscriptionItemsRequestSchema_itemsMember3;
17632
17638
  export interface UpdateSubscriptionItemsRequestSchema_itemsMember1 extends Parsable {
17633
17639
  /**
17634
- * The action property
17640
+ * Remove the specified plan from the subscription.
17635
17641
  */
17636
17642
  action?: string | null;
17637
17643
  /**
17638
- * The planId property
17644
+ * The ID of the plan to act on.
17639
17645
  */
17640
17646
  planId?: string | null;
17641
17647
  }
17642
17648
  export interface UpdateSubscriptionItemsRequestSchema_itemsMember2 extends Parsable {
17643
17649
  /**
17644
- * The action property
17650
+ * Add a new plan to the subscription.
17645
17651
  */
17646
17652
  action?: string | null;
17647
17653
  /**
17648
- * The grantee property
17654
+ * Your internal identifier for the entity that will receive access to the added plan. Required for non-per-seat plans.
17649
17655
  */
17650
17656
  grantee?: string | null;
17651
17657
  /**
17652
- * The metadata property
17658
+ * Per-line-item quantity overrides, keyed by line item ID.
17653
17659
  */
17654
17660
  metadata?: UpdateSubscriptionItemsRequestSchema_itemsMember2_metadata | null;
17655
17661
  /**
17656
- * The planId property
17662
+ * The ID of the plan to act on.
17657
17663
  */
17658
17664
  planId?: string | null;
17659
17665
  }
17666
+ /**
17667
+ * Per-line-item quantity overrides, keyed by line item ID.
17668
+ */
17660
17669
  export interface UpdateSubscriptionItemsRequestSchema_itemsMember2_metadata extends AdditionalDataHolder, Parsable {
17661
17670
  }
17662
17671
  export interface UpdateSubscriptionItemsRequestSchema_itemsMember3 extends Parsable {
17663
17672
  /**
17664
- * The action property
17673
+ * Replace the specified plan with a different plan, preserving the existing grantee group.
17665
17674
  */
17666
17675
  action?: string | null;
17667
17676
  /**
17668
- * The metadata property
17677
+ * Per-line-item quantity overrides, keyed by line item ID.
17669
17678
  */
17670
17679
  metadata?: UpdateSubscriptionItemsRequestSchema_itemsMember3_metadata | null;
17671
17680
  /**
17672
- * The newPlanId property
17681
+ * The ID of the plan to replace the existing plan with.
17673
17682
  */
17674
17683
  newPlanId?: string | null;
17675
17684
  /**
17676
- * The planId property
17685
+ * The ID of the plan to act on.
17677
17686
  */
17678
17687
  planId?: string | null;
17679
17688
  }
17689
+ /**
17690
+ * Per-line-item quantity overrides, keyed by line item ID.
17691
+ */
17680
17692
  export interface UpdateSubscriptionItemsRequestSchema_itemsMember3_metadata extends AdditionalDataHolder, Parsable {
17681
17693
  }
17682
17694
  export type UpdateSubscriptionItemsRequestSchema_proration = (typeof UpdateSubscriptionItemsRequestSchema_prorationObject)[keyof typeof UpdateSubscriptionItemsRequestSchema_prorationObject];
17683
17695
  export interface UpdateSubscriptionPlanLineItemSchema extends Parsable {
17684
17696
  /**
17685
- * The proration property
17697
+ * Controls how Stripe handles proration when the quantity changes mid-billing-period. One of `always_invoice`, `create_prorations`, `none`.
17686
17698
  */
17687
17699
  proration?: UpdateSubscriptionPlanLineItemSchema_proration | null;
17688
17700
  /**
17689
- * The quantity property
17701
+ * The new quantity for this subscription plan line item. Must be within the line item's minimum and maximum allowed quantities, and cannot be less than the number of current grantees on the attached group.
17690
17702
  */
17691
17703
  quantity?: number | null;
17692
17704
  }
@@ -17708,6 +17720,9 @@ export declare const BatchCartActionsRequestSchema_actionObject: {
17708
17720
  export declare const BatchReceiptActionsRequestSchema_actionObject: {
17709
17721
  readonly Delete: "delete";
17710
17722
  };
17723
+ /**
17724
+ * The action to perform on all provided subscriptions. One of `cancel`, `enable-auto-renew`, `disable-auto-renew`, `delete`. The `delete` action is only available in test mode.
17725
+ */
17711
17726
  export declare const BatchSubscriptionActionsRequestSchema_actionObject: {
17712
17727
  readonly Cancel: "cancel";
17713
17728
  readonly EnableAutoRenew: "enable-auto-renew";
@@ -17874,7 +17889,7 @@ export declare const CreatePortalRequestSchema_features_customerUpdate_allowedUp
17874
17889
  readonly Shipping: "shipping";
17875
17890
  };
17876
17891
  /**
17877
- * "now" - cancels the subscription immediately. "end" - schedules the subscription to cancel at the end of the billing period.
17892
+ * `now` cancels the subscription immediately. `end` schedules cancellation at the end of the current billing period.
17878
17893
  */
17879
17894
  export declare const CreatePortalRequestSchema_features_subscriptionCancel_whenObject: {
17880
17895
  readonly Now: "now";
@@ -18385,11 +18400,17 @@ export declare const UpdateProductRequestSchema_settings_cardPrefillPreferenceOb
18385
18400
  readonly Always: "always";
18386
18401
  readonly Choice: "choice";
18387
18402
  };
18403
+ /**
18404
+ * Controls how Stripe handles proration when items change mid-billing-period. Required for paid subscriptions; not applicable to Salable-only subscriptions. One of `always_invoice`, `create_prorations`, `none`.
18405
+ */
18388
18406
  export declare const UpdateSubscriptionItemsRequestSchema_prorationObject: {
18389
18407
  readonly Always_invoice: "always_invoice";
18390
18408
  readonly Create_prorations: "create_prorations";
18391
18409
  readonly None: "none";
18392
18410
  };
18411
+ /**
18412
+ * Controls how Stripe handles proration when the quantity changes mid-billing-period. One of `always_invoice`, `create_prorations`, `none`.
18413
+ */
18393
18414
  export declare const UpdateSubscriptionPlanLineItemSchema_prorationObject: {
18394
18415
  readonly Always_invoice: "always_invoice";
18395
18416
  readonly Create_prorations: "create_prorations";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@salable/sdk",
3
- "version": "1.0.7",
3
+ "version": "1.0.8",
4
4
  "description": "",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/index.es.js",