The Service Options and Variants API lets you manage custom options for services
(SDK | REST).
You can configure options based on:
- The staff member
(SDK | REST)
providing the service.
- Appointment duration.
- A custom parameter, such as customer age or equipment type.
Each option includes a list of choices that customers can select when booking a
service. A service variant is a unique combination of all choices made by the
customer during booking. Only a single option is permitted per
service, meaning a variant corresponds directly to 1 choice from that option.
Note the following before coding:
- Only 1
serviceOptionsAndVariants
object is allowed per service.
- Only 1 option is supported per
serviceOptionsAndVariants
object.
- Variants aren't automatically calculated from the specified option and choices
in the Create Service Options and Variants call
(SDK | REST).
Instead, you must manually define all variants when calling
Create Service Options and Variants.
- After configuring a staff member-based option for a service, Wix Bookings
automatically adds a new choice and variant when a new staff member is added
to the service. Each new variant uses the service’s
payment.varied.defaultPrice
. Staff member-based choices and variants are
automatically deleted if a staff member is removed from the service or the
entire business.
- Create staff member-based service variants (SDK | REST).
- Create service variants based on booked equipment (SDK | REST).
- Option: A modification of a service based on staff member, event duration,
or custom parameters (like customer age). Each option includes a list of
supported choices that customers select when booking. Services can have
only 1 option.
- Choice: A specific value for a service option. For example, the option
ageGroup
may include choices like child
, student
, adult
, and senior
,
each potentially priced differently.
- Variant: A unique combination of all choices made by the customer when
booking. For example,
{"time": "afternoon", "ageGroup": "adult", "equipment": "kettlebells"}
.
Note that since a service can currently only have 1 option, variants are
limited to that option and its choices.
For a comprehensive glossary of Wix Bookings terms, see Terminology
(SDK | REST).
- About service payments
(SDK | REST).
- Pricing API
(SDK | REST):
Preview and calculate the price for a booking.
- Pricing Provider service plugin
(REST):
Implement custom pricing logic.