For the complete documentation index, see llms.txt. This page is also available as Markdown.

Checkbox Add-ons and Conditional Quantity

Add-ons in a journey render as checkbox rows rather than cards with a select button, and one of them — the billing step — reveals a quantity input only once the add-on is checked. This page covers where add-ons come from, what controls whether a given add-on is shown or selectable, and exactly when the quantity field appears.

Where add-ons come from

Add-ons are product set items with a classification. The canonical values are base, addon, and optional. Journey renderers split the set into plan cards (base) and add-on checkboxes (addon). optional is a valid stored value and the server's add-on selection helper treats it as an add-on, but the journey renderers filter on addon only — so classify anything you want to appear as a checkbox as addon.

What the buyer sees

Each add-on row is a checkbox with the product's name, its price, and its description. Selection is held per set item and written into the journey context as addOn_<productId> set to "true" or "false"; the server resolves rate plans from those flags at order time.

Dependencies on the set item gate availability. A requires dependency disables the checkbox until its target is selected and shows "Requires name" inline; an excluded_by dependency disables it while its target is selected and shows "Cannot be combined with name". Exclusions are evaluated in both directions, so selecting an item can disable an add-on that excludes it.

When the quantity field appears

In the journey billing step, a checked add-on expands to reveal a Quantity number input with a minimum of 1. That is the whole visibility rule: checked shows it, unchecked hides it and clears the stored value. There is no per-item "allow quantity" toggle to configure.

The value persists as addonQty_<productId>, hydrated from the journey context so a prefilled URL keeps the quantity the buyer arrived with, and it flows into the order summary total and the cart line.

Item-level visibility

Separately from selection, a set item carries a visibility value in its metadata: always (the default) or active_trial_only. The product set editor shows these as Always shown and Only during an active trial. The gate is enforced server-side in the customer available-plans path, where active_trial_only items are dropped unless the customer is currently trialling or already on that item.

Gotchas

  • Only the billing step has the quantity input. The dynamic pricing page's add-on list and the trial signup add-on list are checkbox-only; a quantity set elsewhere is not editable there.

  • Quantity is keyed by product id. Two set items pointing at the same product share one value.

  • Bundle members are hidden. When a set defines bundles, member items are suppressed and only the bundle's face item renders.

Last updated

Was this helpful?