@rechargeapps/storefront-client 1.3.2 → 1.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/api/address.js +34 -9
- package/dist/cjs/api/address.js.map +1 -1
- package/dist/cjs/api/auth.js +34 -6
- package/dist/cjs/api/auth.js.map +1 -1
- package/dist/cjs/api/bundle.js +57 -20
- package/dist/cjs/api/bundle.js.map +1 -1
- package/dist/cjs/api/cdn.js +18 -6
- package/dist/cjs/api/cdn.js.map +1 -1
- package/dist/cjs/api/charge.js +34 -14
- package/dist/cjs/api/charge.js.map +1 -1
- package/dist/cjs/api/customer.js +21 -6
- package/dist/cjs/api/customer.js.map +1 -1
- package/dist/cjs/api/membership.js +24 -9
- package/dist/cjs/api/membership.js.map +1 -1
- package/dist/cjs/api/membershipProgram.js +6 -1
- package/dist/cjs/api/membershipProgram.js.map +1 -1
- package/dist/cjs/api/metafield.js +25 -10
- package/dist/cjs/api/metafield.js.map +1 -1
- package/dist/cjs/api/onetime.js +33 -13
- package/dist/cjs/api/onetime.js.map +1 -1
- package/dist/cjs/api/order.js +8 -3
- package/dist/cjs/api/order.js.map +1 -1
- package/dist/cjs/api/paymentMethod.js +18 -8
- package/dist/cjs/api/paymentMethod.js.map +1 -1
- package/dist/cjs/api/plan.js +8 -3
- package/dist/cjs/api/plan.js.map +1 -1
- package/dist/cjs/api/subscription.js +93 -43
- package/dist/cjs/api/subscription.js.map +1 -1
- package/dist/cjs/index.js +2 -0
- package/dist/cjs/index.js.map +1 -1
- package/dist/cjs/utils/bundle.js +43 -41
- package/dist/cjs/utils/bundle.js.map +1 -1
- package/dist/cjs/utils/init.js +3 -1
- package/dist/cjs/utils/init.js.map +1 -1
- package/dist/esm/api/address.js +34 -9
- package/dist/esm/api/address.js.map +1 -1
- package/dist/esm/api/auth.js +34 -7
- package/dist/esm/api/auth.js.map +1 -1
- package/dist/esm/api/bundle.js +57 -21
- package/dist/esm/api/bundle.js.map +1 -1
- package/dist/esm/api/cdn.js +18 -6
- package/dist/esm/api/cdn.js.map +1 -1
- package/dist/esm/api/charge.js +34 -14
- package/dist/esm/api/charge.js.map +1 -1
- package/dist/esm/api/customer.js +21 -6
- package/dist/esm/api/customer.js.map +1 -1
- package/dist/esm/api/membership.js +24 -9
- package/dist/esm/api/membership.js.map +1 -1
- package/dist/esm/api/membershipProgram.js +6 -1
- package/dist/esm/api/membershipProgram.js.map +1 -1
- package/dist/esm/api/metafield.js +25 -10
- package/dist/esm/api/metafield.js.map +1 -1
- package/dist/esm/api/onetime.js +33 -13
- package/dist/esm/api/onetime.js.map +1 -1
- package/dist/esm/api/order.js +8 -3
- package/dist/esm/api/order.js.map +1 -1
- package/dist/esm/api/paymentMethod.js +18 -8
- package/dist/esm/api/paymentMethod.js.map +1 -1
- package/dist/esm/api/plan.js +8 -3
- package/dist/esm/api/plan.js.map +1 -1
- package/dist/esm/api/subscription.js +93 -43
- package/dist/esm/api/subscription.js.map +1 -1
- package/dist/esm/index.js +2 -2
- package/dist/esm/utils/bundle.js +43 -41
- package/dist/esm/utils/bundle.js.map +1 -1
- package/dist/esm/utils/init.js +3 -1
- package/dist/esm/utils/init.js.map +1 -1
- package/dist/index.d.ts +237 -86
- package/dist/umd/recharge-client.min.js +8 -8
- package/package.json +9 -9
package/dist/index.d.ts
CHANGED
|
@@ -244,6 +244,236 @@ interface PaymentMethodListParams extends ListParams<PaymentMethodSortBy> {
|
|
|
244
244
|
include?: PaymentMethodIncludes[];
|
|
245
245
|
}
|
|
246
246
|
|
|
247
|
+
interface BundleSelectionAppProxy {
|
|
248
|
+
collectionId: string;
|
|
249
|
+
externalProductId: string;
|
|
250
|
+
externalVariantId: string;
|
|
251
|
+
quantity: number;
|
|
252
|
+
sellingPlan?: number;
|
|
253
|
+
shippingIntervalFrequency?: number;
|
|
254
|
+
shippingIntervalUnitType?: IntervalUnit;
|
|
255
|
+
discountedVariantId?: number;
|
|
256
|
+
}
|
|
257
|
+
interface BundleAppProxy {
|
|
258
|
+
externalVariantId: string;
|
|
259
|
+
externalProductId: string;
|
|
260
|
+
selections: BundleSelectionAppProxy[];
|
|
261
|
+
}
|
|
262
|
+
interface DynamicBundlePropertiesAppProxy {
|
|
263
|
+
_rc_bundle: string;
|
|
264
|
+
_rc_bundle_variant: string;
|
|
265
|
+
_rc_bundle_parent: string;
|
|
266
|
+
_rc_bundle_collection_id: string;
|
|
267
|
+
shipping_interval_frequency?: number;
|
|
268
|
+
shipping_interval_unit_type?: IntervalUnit;
|
|
269
|
+
}
|
|
270
|
+
interface DynamicBundleItemAppProxy {
|
|
271
|
+
id: string;
|
|
272
|
+
properties: DynamicBundlePropertiesAppProxy;
|
|
273
|
+
quantity: number;
|
|
274
|
+
selling_plan?: number;
|
|
275
|
+
}
|
|
276
|
+
interface BundleSelectionItem {
|
|
277
|
+
/** The unique numeric identifier for the item selection. */
|
|
278
|
+
id: number;
|
|
279
|
+
/** The collection id as it appears in the external e-commerce platform. */
|
|
280
|
+
collection_id: string;
|
|
281
|
+
/** The identifier of the external e-commerce platform. */
|
|
282
|
+
collection_source: 'shopify';
|
|
283
|
+
/** The date and time when this item was selected. */
|
|
284
|
+
created_at: IsoDateString;
|
|
285
|
+
/** The product id as it appears in the external e-commerce platform. This is the item which is going to be extracted when the Bundle is processed. */
|
|
286
|
+
external_product_id: string;
|
|
287
|
+
/** The variant id as it appears in the external e-commerce platform. This is the item which is going to be extracted when the Bundle is processed. */
|
|
288
|
+
external_variant_id: string;
|
|
289
|
+
/** The quantity of this product. */
|
|
290
|
+
quantity: number;
|
|
291
|
+
/** The date and time at which the item selection was most recently updated. */
|
|
292
|
+
updated_at: IsoDateString;
|
|
293
|
+
}
|
|
294
|
+
interface BundleSelection {
|
|
295
|
+
/** The unique numeric identifier for the BundleSelection. */
|
|
296
|
+
id: number;
|
|
297
|
+
/** The ID of the BundleVariant associated with the BundleSelection. */
|
|
298
|
+
bundle_variant_id: number;
|
|
299
|
+
/** The ID of the PurchaseItem associated with the BundleSelection. */
|
|
300
|
+
purchase_item_id: number;
|
|
301
|
+
/** The date and time when the contents were selected. */
|
|
302
|
+
created_at: IsoDateString;
|
|
303
|
+
/** The product id as it appears in the external e-commerce platform. The external_product_id of the Product record in Recharge, linking the BundleSelection to a Product associated with a Bundle. */
|
|
304
|
+
external_product_id: string;
|
|
305
|
+
/** The variant id as it appears in the external e-commerce platform. The external_variant_id of the Product record in Recharge, linking the BundleSelection to a Product associated with a Bundle. */
|
|
306
|
+
external_variant_id: string;
|
|
307
|
+
items: BundleSelectionItem[];
|
|
308
|
+
/** The date and time at which the BundleSelection was most recently updated. */
|
|
309
|
+
updated_at: IsoDateString;
|
|
310
|
+
}
|
|
311
|
+
type BundleSelectionItemRequiredCreateProps = 'collection_id' | 'collection_source' | 'external_product_id' | 'external_variant_id' | 'quantity';
|
|
312
|
+
interface CreateBundleSelectionRequest {
|
|
313
|
+
purchase_item_id: number;
|
|
314
|
+
items: Pick<BundleSelectionItem, BundleSelectionItemRequiredCreateProps>[];
|
|
315
|
+
}
|
|
316
|
+
interface UpdateBundleSelectionRequest extends CreateBundleSelectionRequest {
|
|
317
|
+
}
|
|
318
|
+
interface BundleSelectionsResponse {
|
|
319
|
+
next_cursor: null | string;
|
|
320
|
+
previous_cursor: null | string;
|
|
321
|
+
bundle_selections: BundleSelection[];
|
|
322
|
+
}
|
|
323
|
+
type BundleSelectionsSortBy = 'id-asc' | 'id-desc' | 'updated_at-asc' | 'updated_at-desc';
|
|
324
|
+
interface BundleSelectionListParams extends ListParams<BundleSelectionsSortBy> {
|
|
325
|
+
/** Filter BundleSelections by Subscription or Onetime ID. */
|
|
326
|
+
purchase_item_ids?: (string | number)[];
|
|
327
|
+
/** Filter BundleSelections by BundleVariants. */
|
|
328
|
+
bundle_variant_ids?: (string | number)[];
|
|
329
|
+
}
|
|
330
|
+
interface UpdateBundlePurchaseItem extends UpdateSubscriptionRequest {
|
|
331
|
+
external_product_id: {
|
|
332
|
+
ecommerce: string;
|
|
333
|
+
};
|
|
334
|
+
external_variant_id: {
|
|
335
|
+
ecommerce: string;
|
|
336
|
+
};
|
|
337
|
+
items: Pick<BundleSelectionItem, BundleSelectionItemRequiredCreateProps>[];
|
|
338
|
+
}
|
|
339
|
+
interface BundlePurchaseItem extends Subscription {
|
|
340
|
+
items: BundleSelectionItem[];
|
|
341
|
+
}
|
|
342
|
+
|
|
343
|
+
interface AddonSettings {
|
|
344
|
+
collectionId: string;
|
|
345
|
+
collectionHandle: string;
|
|
346
|
+
enabled: boolean;
|
|
347
|
+
}
|
|
348
|
+
interface AddToCartCallbackSettings {
|
|
349
|
+
type: 'none' | 'callback' | 'redirect';
|
|
350
|
+
value: string;
|
|
351
|
+
}
|
|
352
|
+
interface CrossSellsSettings {
|
|
353
|
+
collectionId: string;
|
|
354
|
+
collectionHandle: string;
|
|
355
|
+
enabled: boolean;
|
|
356
|
+
}
|
|
357
|
+
interface StepSettingsCommon {
|
|
358
|
+
description?: string;
|
|
359
|
+
disable?: boolean;
|
|
360
|
+
index: string;
|
|
361
|
+
name: string;
|
|
362
|
+
title: string;
|
|
363
|
+
}
|
|
364
|
+
type VariantSelector = {
|
|
365
|
+
optionsMeta: {
|
|
366
|
+
[key: string]: {
|
|
367
|
+
defaultImage: string;
|
|
368
|
+
content: string;
|
|
369
|
+
};
|
|
370
|
+
};
|
|
371
|
+
};
|
|
372
|
+
declare enum StepSettingsTypes {
|
|
373
|
+
VARIANT_SELECTOR = "variantSelector",
|
|
374
|
+
ALL_COLLECTIONS = "all-collections",
|
|
375
|
+
ADDONS = "addons",
|
|
376
|
+
SUMMARY = "summary",
|
|
377
|
+
CROSS_SELLS = "cross-sells"
|
|
378
|
+
}
|
|
379
|
+
type BundlePriceRule = 'fixed' | 'dynamic';
|
|
380
|
+
type VariantSelectorStepSetting = StepSettingsCommon & {
|
|
381
|
+
data?: VariantSelector;
|
|
382
|
+
type: StepSettingsTypes.VARIANT_SELECTOR;
|
|
383
|
+
};
|
|
384
|
+
type StepSettings = StepSettingsCommon & {
|
|
385
|
+
data?: Record<string, unknown>;
|
|
386
|
+
type: Exclude<StepSettingsTypes, StepSettingsTypes.VARIANT_SELECTOR>;
|
|
387
|
+
};
|
|
388
|
+
interface MultiStepSettings {
|
|
389
|
+
optionImages: string;
|
|
390
|
+
steps: [VariantSelectorStepSetting, ...StepSettings[]];
|
|
391
|
+
}
|
|
392
|
+
type BundleTemplateType = 'multi-step' | 'one-page' | 'custom' | 'none';
|
|
393
|
+
interface OnePageSettings {
|
|
394
|
+
frequencySelector: 'toggle' | 'dropdown';
|
|
395
|
+
}
|
|
396
|
+
interface BundleTemplateSettings {
|
|
397
|
+
multiStep?: MultiStepSettings;
|
|
398
|
+
onePage: OnePageSettings;
|
|
399
|
+
}
|
|
400
|
+
type WidgetVisibility = {
|
|
401
|
+
signup: boolean;
|
|
402
|
+
portal: boolean;
|
|
403
|
+
};
|
|
404
|
+
interface BundleProductLayoutSettings {
|
|
405
|
+
addons: AddonSettings;
|
|
406
|
+
addToCartCallback: AddToCartCallbackSettings;
|
|
407
|
+
collapsibleSections: boolean;
|
|
408
|
+
crossSells: CrossSellsSettings;
|
|
409
|
+
defaultFrequency: string;
|
|
410
|
+
defaultVariantId: string;
|
|
411
|
+
description: string;
|
|
412
|
+
filters: string[];
|
|
413
|
+
learnMoreModal: boolean;
|
|
414
|
+
published: boolean;
|
|
415
|
+
showStickyStatusBar: boolean;
|
|
416
|
+
showVariants: boolean;
|
|
417
|
+
template: BundleTemplateType;
|
|
418
|
+
templateSettings: BundleTemplateSettings;
|
|
419
|
+
title: string;
|
|
420
|
+
visibility: WidgetVisibility;
|
|
421
|
+
}
|
|
422
|
+
interface BundleVariantOptionSource {
|
|
423
|
+
id: number;
|
|
424
|
+
option_source_id: string;
|
|
425
|
+
position: number;
|
|
426
|
+
quantity_max: number | null;
|
|
427
|
+
quantity_min: number | null;
|
|
428
|
+
source_platform: 'shopify';
|
|
429
|
+
updated_at: IsoDateString;
|
|
430
|
+
created_at: IsoDateString;
|
|
431
|
+
}
|
|
432
|
+
interface BundleVariantSelectionDefault {
|
|
433
|
+
id: number;
|
|
434
|
+
quantity: number;
|
|
435
|
+
external_variant_id: string;
|
|
436
|
+
}
|
|
437
|
+
interface BundleVariantRange {
|
|
438
|
+
id: number;
|
|
439
|
+
quantity_max: number | null;
|
|
440
|
+
quantity_min: number;
|
|
441
|
+
updated_at: IsoDateString;
|
|
442
|
+
created_at: IsoDateString;
|
|
443
|
+
}
|
|
444
|
+
interface BundleVariant {
|
|
445
|
+
enabled: boolean;
|
|
446
|
+
external_variant_id: string;
|
|
447
|
+
id: number;
|
|
448
|
+
items_count: number;
|
|
449
|
+
option_sources: BundleVariantOptionSource[];
|
|
450
|
+
position: number;
|
|
451
|
+
selection_defaults: BundleVariantSelectionDefault[];
|
|
452
|
+
title: string;
|
|
453
|
+
ranges: BundleVariantRange[];
|
|
454
|
+
updated_at: IsoDateString;
|
|
455
|
+
created_at: IsoDateString;
|
|
456
|
+
}
|
|
457
|
+
interface BundleProduct {
|
|
458
|
+
custom_prices: boolean;
|
|
459
|
+
customization_window_disabled_message: string | null;
|
|
460
|
+
customization_window: number | null;
|
|
461
|
+
default_bundle_variant_id: number;
|
|
462
|
+
description: string | null;
|
|
463
|
+
external_product_id: string;
|
|
464
|
+
id: number;
|
|
465
|
+
is_customizable: boolean;
|
|
466
|
+
layout_settings_version: '2021-11';
|
|
467
|
+
max_quantity_per_variant: number | null;
|
|
468
|
+
reset_box_contents: boolean;
|
|
469
|
+
title: string;
|
|
470
|
+
updated_at: IsoDateString;
|
|
471
|
+
created_at: IsoDateString;
|
|
472
|
+
layout_settings: BundleProductLayoutSettings;
|
|
473
|
+
variants: BundleVariant[];
|
|
474
|
+
price_rule: BundlePriceRule | null;
|
|
475
|
+
}
|
|
476
|
+
|
|
247
477
|
type SubscriptionStatus = 'active' | 'cancelled' | 'expired';
|
|
248
478
|
interface Subscription {
|
|
249
479
|
/** Unique numeric identifier for the subscription. */
|
|
@@ -331,6 +561,8 @@ interface Subscription {
|
|
|
331
561
|
address?: Address;
|
|
332
562
|
customer?: Customer;
|
|
333
563
|
metafields?: Metafield[];
|
|
564
|
+
bundle_selections?: BundleSelection | null;
|
|
565
|
+
bundle_product?: BundleProduct | null;
|
|
334
566
|
};
|
|
335
567
|
}
|
|
336
568
|
interface SubscriptionsResponse {
|
|
@@ -338,7 +570,7 @@ interface SubscriptionsResponse {
|
|
|
338
570
|
previous_cursor: null | string;
|
|
339
571
|
subscriptions: Subscription[];
|
|
340
572
|
}
|
|
341
|
-
type SubscriptionIncludes = 'address' | 'customer' | 'metafields';
|
|
573
|
+
type SubscriptionIncludes = 'address' | 'customer' | 'metafields' | 'bundle_product' | 'bundle_selections';
|
|
342
574
|
interface GetSubscriptionOptions {
|
|
343
575
|
include?: SubscriptionIncludes[];
|
|
344
576
|
}
|
|
@@ -1052,6 +1284,8 @@ declare function sendPasswordlessCode(email: string, options?: PasswordlessOptio
|
|
|
1052
1284
|
declare function sendPasswordlessCodeAppProxy(email: string, options?: PasswordlessOptions): Promise<string>;
|
|
1053
1285
|
declare function validatePasswordlessCode(email: string, session_token: string, code: string): Promise<Session>;
|
|
1054
1286
|
declare function validatePasswordlessCodeAppProxy(email: string, session_token: string, code: string): Promise<Session>;
|
|
1287
|
+
/** @internal */
|
|
1288
|
+
declare function loginCustomerPortal(): Promise<Session>;
|
|
1055
1289
|
|
|
1056
1290
|
type Method = 'get' | 'post' | 'put' | 'delete';
|
|
1057
1291
|
type Request = <T>(method: Method, url: string, options?: RequestOptions) => Promise<T>;
|
|
@@ -1070,90 +1304,6 @@ interface RequestOptions extends GetRequestOptions, CRUDRequestOptions {
|
|
|
1070
1304
|
headers?: RequestHeaders;
|
|
1071
1305
|
}
|
|
1072
1306
|
|
|
1073
|
-
interface BundleSelectionAppProxy {
|
|
1074
|
-
collectionId: string;
|
|
1075
|
-
externalProductId: string;
|
|
1076
|
-
externalVariantId: string;
|
|
1077
|
-
quantity: number;
|
|
1078
|
-
sellingPlan?: number;
|
|
1079
|
-
shippingIntervalFrequency?: number;
|
|
1080
|
-
shippingIntervalUnitType?: IntervalUnit;
|
|
1081
|
-
discountedVariantId?: number;
|
|
1082
|
-
}
|
|
1083
|
-
interface BundleAppProxy {
|
|
1084
|
-
externalVariantId: string;
|
|
1085
|
-
externalProductId: string;
|
|
1086
|
-
selections: BundleSelectionAppProxy[];
|
|
1087
|
-
}
|
|
1088
|
-
interface DynamicBundlePropertiesAppProxy {
|
|
1089
|
-
_rc_bundle: string;
|
|
1090
|
-
_rc_bundle_variant: string;
|
|
1091
|
-
_rc_bundle_parent: string;
|
|
1092
|
-
_rc_bundle_collection_id: string;
|
|
1093
|
-
shipping_interval_frequency?: number;
|
|
1094
|
-
shipping_interval_unit_type?: IntervalUnit;
|
|
1095
|
-
}
|
|
1096
|
-
interface DynamicBundleItemAppProxy {
|
|
1097
|
-
id: string;
|
|
1098
|
-
properties: DynamicBundlePropertiesAppProxy;
|
|
1099
|
-
quantity: number;
|
|
1100
|
-
selling_plan?: number;
|
|
1101
|
-
}
|
|
1102
|
-
interface BundleSelectionItem {
|
|
1103
|
-
/** The unique numeric identifier for the item selection. */
|
|
1104
|
-
id: number;
|
|
1105
|
-
/** The collection id as it appears in the external e-commerce platform. */
|
|
1106
|
-
collection_id: string;
|
|
1107
|
-
/** The identifier of the external e-commerce platform. */
|
|
1108
|
-
collection_source: 'shopify';
|
|
1109
|
-
/** The date and time when this item was selected. */
|
|
1110
|
-
created_at: IsoDateString;
|
|
1111
|
-
/** The product id as it appears in the external e-commerce platform. This is the item which is going to be extracted when the Bundle is processed. */
|
|
1112
|
-
external_product_id: string;
|
|
1113
|
-
/** The variant id as it appears in the external e-commerce platform. This is the item which is going to be extracted when the Bundle is processed. */
|
|
1114
|
-
external_variant_id: string;
|
|
1115
|
-
/** The quantity of this product. */
|
|
1116
|
-
quantity: number;
|
|
1117
|
-
/** The date and time at which the item selection was most recently updated. */
|
|
1118
|
-
updated_at: IsoDateString;
|
|
1119
|
-
}
|
|
1120
|
-
interface BundleSelection {
|
|
1121
|
-
/** The unique numeric identifier for the BundleSelection. */
|
|
1122
|
-
id: number;
|
|
1123
|
-
/** The ID of the BundleVariant associated with the BundleSelection. */
|
|
1124
|
-
bundle_variant_id: number;
|
|
1125
|
-
/** The ID of the PurchaseItem associated with the BundleSelection. */
|
|
1126
|
-
purchase_item_id: number;
|
|
1127
|
-
/** The date and time when the contents were selected. */
|
|
1128
|
-
created_at: IsoDateString;
|
|
1129
|
-
/** The product id as it appears in the external e-commerce platform. The external_product_id of the Product record in Recharge, linking the BundleSelection to a Product associated with a Bundle. */
|
|
1130
|
-
external_product_id: string;
|
|
1131
|
-
/** The variant id as it appears in the external e-commerce platform. The external_variant_id of the Product record in Recharge, linking the BundleSelection to a Product associated with a Bundle. */
|
|
1132
|
-
external_variant_id: string;
|
|
1133
|
-
items: BundleSelectionItem[];
|
|
1134
|
-
/** The date and time at which the BundleSelection was most recently updated. */
|
|
1135
|
-
updated_at: IsoDateString;
|
|
1136
|
-
}
|
|
1137
|
-
type BundleSelectionItemRequiredCreateProps = 'collection_id' | 'collection_source' | 'external_product_id' | 'external_variant_id' | 'quantity';
|
|
1138
|
-
interface CreateBundleSelectionRequest {
|
|
1139
|
-
purchase_item_id: number;
|
|
1140
|
-
items: Pick<BundleSelectionItem, BundleSelectionItemRequiredCreateProps>[];
|
|
1141
|
-
}
|
|
1142
|
-
interface UpdateBundleSelectionRequest extends CreateBundleSelectionRequest {
|
|
1143
|
-
}
|
|
1144
|
-
interface BundleSelectionsResponse {
|
|
1145
|
-
next_cursor: null | string;
|
|
1146
|
-
previous_cursor: null | string;
|
|
1147
|
-
bundle_selections: BundleSelection[];
|
|
1148
|
-
}
|
|
1149
|
-
type BundleSelectionsSortBy = 'id-asc' | 'id-desc' | 'updated_at-asc' | 'updated_at-desc';
|
|
1150
|
-
interface BundleSelectionListParams extends ListParams<BundleSelectionsSortBy> {
|
|
1151
|
-
/** Filter BundleSelections by Subscription or Onetime ID. */
|
|
1152
|
-
purchase_item_ids?: (string | number)[];
|
|
1153
|
-
/** Filter BundleSelections by BundleVariants. */
|
|
1154
|
-
bundle_variant_ids?: (string | number)[];
|
|
1155
|
-
}
|
|
1156
|
-
|
|
1157
1307
|
type FirstOption = 'onetime' | 'autodeliver';
|
|
1158
1308
|
type PriceAdjustmentsType = 'percentage';
|
|
1159
1309
|
type StorefrontPurchaseOption = 'subscription_and_onetime' | 'subscription_only' | 'onetime_only' | 'inactive';
|
|
@@ -1890,6 +2040,7 @@ declare function listBundleSelections(session: Session, query?: BundleSelectionL
|
|
|
1890
2040
|
declare function createBundleSelection(session: Session, createRequest: CreateBundleSelectionRequest): Promise<BundleSelection>;
|
|
1891
2041
|
declare function updateBundleSelection(session: Session, id: string | number, updateRequest: UpdateBundleSelectionRequest): Promise<BundleSelection>;
|
|
1892
2042
|
declare function deleteBundleSelection(session: Session, id: string | number): Promise<void>;
|
|
2043
|
+
declare function updateBundle(session: Session, purchase_item_id: string | number, updateRequest: UpdateBundlePurchaseItem): Promise<BundlePurchaseItem>;
|
|
1893
2044
|
|
|
1894
2045
|
/** @internal Retrieves membership information for passed in id */
|
|
1895
2046
|
declare function getMembership(session: Session, id: string | number): Promise<Membership>;
|
|
@@ -1993,4 +2144,4 @@ declare const api: {
|
|
|
1993
2144
|
};
|
|
1994
2145
|
declare function initRecharge(opt?: InitOptions): void;
|
|
1995
2146
|
|
|
1996
|
-
export { ActivateMembershipRequest, Address, AddressIncludes, AddressListParams, AddressListResponse, AddressResponse, AddressSortBy, AnalyticsData, AssociatedAddress, BasicSubscriptionParams, BooleanLike, BooleanNumbers, BooleanString, BooleanStringNumbers, BundleAppProxy, BundleSelection, BundleSelectionAppProxy, BundleSelectionItem, BundleSelectionItemRequiredCreateProps, BundleSelectionListParams, BundleSelectionsResponse, BundleSelectionsSortBy, BundleTranslations, CDNBaseWidgetSettings, CDNBundleLayoutSettings, CDNBundleSettings, CDNBundleStep, CDNBundleStepOption, CDNBundleVariant, CDNBundleVariantOptionSource, CDNBundleVariantSelectionDefault, CDNPrices, CDNProduct, CDNProductAndSettings, CDNProductKeyObject, CDNProductOption, CDNProductOptionValue, CDNProductRaw, CDNProductResource, CDNProductsAndSettings, CDNProductsAndSettingsResource, CDNSellingPlan, CDNSellingPlanAllocations, CDNSellingPlanGroup, CDNStoreSettings, CDNSubscriptionOption, CDNVariant, CDNVariantOptionValue, CDNWidgetSettings, CDNWidgetSettingsRaw, CDNWidgetSettingsResource, CRUDRequestOptions, CancelMembershipRequest, CancelSubscriptionRequest, ChangeMembershipRequest, ChannelSettings, Charge, ChargeIncludes, ChargeListParams, ChargeListResponse, ChargeResponse, ChargeSortBy, ChargeStatus, ColorString, CreateAddressRequest, CreateBundleSelectionRequest, CreateMetafieldRequest, CreateOnetimeRequest, CreateSubscriptionRequest, Customer, CustomerDeliveryScheduleParams, CustomerDeliveryScheduleResponse, CustomerIncludes, CustomerPortalAccessResponse, Delivery, DeliveryLineItem, DeliveryOrder, DeliveryPaymentMethod, Discount, DynamicBundleItemAppProxy, DynamicBundlePropertiesAppProxy, ExternalAttributeSchema, ExternalId, ExternalTransactionId, FirstOption, GetAddressOptions, GetChargeOptions, GetCustomerOptions, GetMembershipProgramOptions, GetPaymentMethodOptions, GetRequestOptions, GetSubscriptionOptions, HTMLString, InitOptions, IntervalUnit, IsoDateString, LineItem, ListParams, LoginResponse, Membership, MembershipBenefit, MembershipIncludes, MembershipListParams, MembershipListResponse, MembershipProgram, MembershipProgramIncludes, MembershipProgramListParams, MembershipProgramListResponse, MembershipProgramResponse, MembershipProgramSortBy, MembershipProgramStatus, MembershipResponse, MembershipStatus, MembershipsSortBy, MergeAddressesRequest, Metafield, MetafieldOptionalCreateProps, MetafieldOwnerResource, MetafieldRequiredCreateProps, Method, Onetime, OnetimeListParams, OnetimeOptionalCreateProps, OnetimeRequiredCreateProps, OnetimesResponse, OnetimesSortBy, Order, OrderIncludes, OrderListParams, OrderSortBy, OrderStatus, OrderType, OrdersResponse, PasswordlessCodeResponse, PasswordlessOptions, PasswordlessValidateResponse, PaymentDetails, PaymentMethod, PaymentMethodIncludes, PaymentMethodListParams, PaymentMethodSortBy, PaymentMethodStatus, PaymentMethodsResponse, PaymentType, Plan, PlanListParams, PlanSortBy, PlanType, PlansResponse, PriceAdjustmentsType, ProcessorName, ProductImage, Property, Request, RequestHeaders, RequestOptions, Session, ShippingLine, SkipFutureChargeAddressRequest, SkipFutureChargeAddressResponse, StorefrontEnvironment, StorefrontOptions, StorefrontPurchaseOption, SubType, Subscription, SubscriptionIncludes, SubscriptionListParams, SubscriptionOptionalCreateProps, SubscriptionPreferences, SubscriptionRequiredCreateProps, SubscriptionSortBy, SubscriptionStatus, Subscription_2021_01, SubscriptionsResponse, TaxLine, Translations, UpdateAddressRequest, UpdateBundleSelectionRequest, UpdateCustomerRequest, UpdateMetafieldRequest, UpdateOnetimeRequest, UpdatePaymentMethodRequest, UpdateSubscriptionParams, UpdateSubscriptionRequest, UpdateSubscriptionsParams, UpdateSubscriptionsRequest, WidgetIconColor, WidgetTemplateType, activateMembership, activateSubscription, api, applyDiscountToAddress, applyDiscountToCharge, cancelMembership, cancelSubscription, changeMembership, createAddress, createBundleSelection, createMetafield, createOnetime, createSubscription, createSubscriptions, deleteAddress, deleteBundleSelection, deleteMetafield, deleteOnetime, getAddress, getBundleId, getBundleSelection, getCDNBundleSettings, getCDNProduct, getCDNProductAndSettings, getCDNProducts, getCDNProductsAndSettings, getCDNStoreSettings, getCDNWidgetSettings, getCharge, getCustomer, getCustomerPortalAccess, getDeliverySchedule, getDynamicBundleItems, getMembership, getMembershipProgram, getOnetime, getOrder, getPaymentMethod, getPlan, getSubscription, initRecharge, intervalUnit, listAddresses, listBundleSelections, listCharges, listMembershipPrograms, listMemberships, listOnetimes, listOrders, listPaymentMethods, listPlans, listSubscriptions, loginShopifyApi, loginShopifyAppProxy, membershipIncludes, mergeAddresses, processCharge, removeDiscountsFromAddress, removeDiscountsFromCharge, resetCDNCache, sendPasswordlessCode, sendPasswordlessCodeAppProxy, skipCharge, skipFutureCharge, skipSubscriptionCharge, unskipCharge, updateAddress, updateBundleSelection, updateCustomer, updateMetafield, updateOnetime, updatePaymentMethod, updateSubscription, updateSubscriptionAddress, updateSubscriptionChargeDate, updateSubscriptions, validateBundle, validateDynamicBundle, validatePasswordlessCode, validatePasswordlessCodeAppProxy };
|
|
2147
|
+
export { ActivateMembershipRequest, Address, AddressIncludes, AddressListParams, AddressListResponse, AddressResponse, AddressSortBy, AnalyticsData, AssociatedAddress, BasicSubscriptionParams, BooleanLike, BooleanNumbers, BooleanString, BooleanStringNumbers, BundleAppProxy, BundlePurchaseItem, BundleSelection, BundleSelectionAppProxy, BundleSelectionItem, BundleSelectionItemRequiredCreateProps, BundleSelectionListParams, BundleSelectionsResponse, BundleSelectionsSortBy, BundleTranslations, CDNBaseWidgetSettings, CDNBundleLayoutSettings, CDNBundleSettings, CDNBundleStep, CDNBundleStepOption, CDNBundleVariant, CDNBundleVariantOptionSource, CDNBundleVariantSelectionDefault, CDNPrices, CDNProduct, CDNProductAndSettings, CDNProductKeyObject, CDNProductOption, CDNProductOptionValue, CDNProductRaw, CDNProductResource, CDNProductsAndSettings, CDNProductsAndSettingsResource, CDNSellingPlan, CDNSellingPlanAllocations, CDNSellingPlanGroup, CDNStoreSettings, CDNSubscriptionOption, CDNVariant, CDNVariantOptionValue, CDNWidgetSettings, CDNWidgetSettingsRaw, CDNWidgetSettingsResource, CRUDRequestOptions, CancelMembershipRequest, CancelSubscriptionRequest, ChangeMembershipRequest, ChannelSettings, Charge, ChargeIncludes, ChargeListParams, ChargeListResponse, ChargeResponse, ChargeSortBy, ChargeStatus, ColorString, CreateAddressRequest, CreateBundleSelectionRequest, CreateMetafieldRequest, CreateOnetimeRequest, CreateSubscriptionRequest, Customer, CustomerDeliveryScheduleParams, CustomerDeliveryScheduleResponse, CustomerIncludes, CustomerPortalAccessResponse, Delivery, DeliveryLineItem, DeliveryOrder, DeliveryPaymentMethod, Discount, DynamicBundleItemAppProxy, DynamicBundlePropertiesAppProxy, ExternalAttributeSchema, ExternalId, ExternalTransactionId, FirstOption, GetAddressOptions, GetChargeOptions, GetCustomerOptions, GetMembershipProgramOptions, GetPaymentMethodOptions, GetRequestOptions, GetSubscriptionOptions, HTMLString, InitOptions, IntervalUnit, IsoDateString, LineItem, ListParams, LoginResponse, Membership, MembershipBenefit, MembershipIncludes, MembershipListParams, MembershipListResponse, MembershipProgram, MembershipProgramIncludes, MembershipProgramListParams, MembershipProgramListResponse, MembershipProgramResponse, MembershipProgramSortBy, MembershipProgramStatus, MembershipResponse, MembershipStatus, MembershipsSortBy, MergeAddressesRequest, Metafield, MetafieldOptionalCreateProps, MetafieldOwnerResource, MetafieldRequiredCreateProps, Method, Onetime, OnetimeListParams, OnetimeOptionalCreateProps, OnetimeRequiredCreateProps, OnetimesResponse, OnetimesSortBy, Order, OrderIncludes, OrderListParams, OrderSortBy, OrderStatus, OrderType, OrdersResponse, PasswordlessCodeResponse, PasswordlessOptions, PasswordlessValidateResponse, PaymentDetails, PaymentMethod, PaymentMethodIncludes, PaymentMethodListParams, PaymentMethodSortBy, PaymentMethodStatus, PaymentMethodsResponse, PaymentType, Plan, PlanListParams, PlanSortBy, PlanType, PlansResponse, PriceAdjustmentsType, ProcessorName, ProductImage, Property, Request, RequestHeaders, RequestOptions, Session, ShippingLine, SkipFutureChargeAddressRequest, SkipFutureChargeAddressResponse, StorefrontEnvironment, StorefrontOptions, StorefrontPurchaseOption, SubType, Subscription, SubscriptionIncludes, SubscriptionListParams, SubscriptionOptionalCreateProps, SubscriptionPreferences, SubscriptionRequiredCreateProps, SubscriptionSortBy, SubscriptionStatus, Subscription_2021_01, SubscriptionsResponse, TaxLine, Translations, UpdateAddressRequest, UpdateBundlePurchaseItem, UpdateBundleSelectionRequest, UpdateCustomerRequest, UpdateMetafieldRequest, UpdateOnetimeRequest, UpdatePaymentMethodRequest, UpdateSubscriptionParams, UpdateSubscriptionRequest, UpdateSubscriptionsParams, UpdateSubscriptionsRequest, WidgetIconColor, WidgetTemplateType, activateMembership, activateSubscription, api, applyDiscountToAddress, applyDiscountToCharge, cancelMembership, cancelSubscription, changeMembership, createAddress, createBundleSelection, createMetafield, createOnetime, createSubscription, createSubscriptions, deleteAddress, deleteBundleSelection, deleteMetafield, deleteOnetime, getAddress, getBundleId, getBundleSelection, getCDNBundleSettings, getCDNProduct, getCDNProductAndSettings, getCDNProducts, getCDNProductsAndSettings, getCDNStoreSettings, getCDNWidgetSettings, getCharge, getCustomer, getCustomerPortalAccess, getDeliverySchedule, getDynamicBundleItems, getMembership, getMembershipProgram, getOnetime, getOrder, getPaymentMethod, getPlan, getSubscription, initRecharge, intervalUnit, listAddresses, listBundleSelections, listCharges, listMembershipPrograms, listMemberships, listOnetimes, listOrders, listPaymentMethods, listPlans, listSubscriptions, loginCustomerPortal, loginShopifyApi, loginShopifyAppProxy, membershipIncludes, mergeAddresses, processCharge, removeDiscountsFromAddress, removeDiscountsFromCharge, resetCDNCache, sendPasswordlessCode, sendPasswordlessCodeAppProxy, skipCharge, skipFutureCharge, skipSubscriptionCharge, unskipCharge, updateAddress, updateBundle, updateBundleSelection, updateCustomer, updateMetafield, updateOnetime, updatePaymentMethod, updateSubscription, updateSubscriptionAddress, updateSubscriptionChargeDate, updateSubscriptions, validateBundle, validateDynamicBundle, validatePasswordlessCode, validatePasswordlessCodeAppProxy };
|