PresetOption

Object

The PresetOption object defines a preset measurement option for variants using "pills" or "dropdown" display styles. Each preset provides a specific measurement value with optional custom labeling and pricing.

Fields

FieldTypeDescription
valuenumberThe measurement value for this preset option. This is the quantity/amount that will be added to the cart when selected.
labelstring (optional)Custom label text displayed to customers (e.g., "Small Bunch", "Family Pack"). If not provided, the value with unit is displayed.
pricenumber (optional)Custom price override for this preset. If not provided, the price is calculated based on the base price per unit multiplied by the value. This feature is available in Premium plans.
Usage: PresetOption objects are used in the presets array within settings.onlineStore when the displayStyle is set to "pills" or "dropdown". The label and price fields are optional features available in higher-tier plans.
Related: This object is used in the presets array of the Variant object. It is used when the variant's displayStyle is set to "pills" or "dropdown" (see OnlineStoreDisplayStyle).