Skip to main content

Bundles

Methods to work with Recharge bundles.

updateBundle v1.4.0 write subscriptions Types

Update the product in the purchase item and the existing bundle selection in a single request.

import { updateBundle } from '@rechargeapps/storefront-client';
await updateBundle(
session,
106841871,
{
properties: [
{
name: 'box_contents',
value: 'Test value',
},
],
external_product_id: { ecommerce: '6948805869633' },
external_variant_id: { ecommerce: '6949187452998' },
items: [
{
collection_id: '6948805869631',
collection_source: 'shopify',
external_product_id: '6949187452991',
external_variant_id: '39689109405759',
quantity: 2,
},
{
collection_id: '6948806688831',
collection_source: 'shopify',
external_product_id: '6949187452991',
external_variant_id: '39689109405759',
quantity: 1,
},
],
},
{ commit: true }
);