The serviceOptionsAndVariants
object links a service
(SDK | REST)
to its variants.
You can use it to offer customers different prices for a service,
depending on which choices they book.
ID of the serviceOptionsAndVariants
object.
ID of the service related to these options and variants.
Service options. Note that currently only a single option is supported per service.
Information about the service's variants.
Price of the cheapest service variant.
Price of the most expensive service variant.
Revision number, which increments by 1 each time the serviceOptionsAndVariants
object is updated.
To prevent conflicting changes,
the current revision must be passed when updating and deleting the serviceOptionsAndVariants
object.
Ignored when creating a serviceOptionsAndVariants
object.
Extensions enabling users to save custom data related to service options and variants.
title: Example of custom options and variants
{
"id": "82802f2e-a54f-404f-a1b2-de5a9a9b9885",
"serviceId": "7a5fa965-ba64-46a5-9fbb-76fde4401d28",
"options": {
"values": [
{
"id": "7fdf831a-145e-4f2c-83d8-dd0131a7fd05",
"type": "CUSTOM",
"customData": {
"name": "Client Type",
"choices": [
"Student",
"Adult"
]
}
}
]
},
"variants": {
"values": [
{
"choices": [
{
"optionId": "7fdf831a-145e-4f2c-83d8-dd0131a7fd05",
"custom": "Student"
}
],
"price": {
"value": "5",
"currency": "EUR"
}
},
{
"choices": [
{
"optionId": "7fdf831a-145e-4f2c-83d8-dd0131a7fd05",
"custom": "Adult"
}
],
"price": {
"value": "22",
"currency": "EUR"
}
}
]
},
"minPrice": {
"value": "5",
"currency": "EUR"
},
"maxPrice": {
"value": "22",
"currency": "EUR"
},
"revision": "1"
}