product.isPackagewhich is a boolean field indicating whether this product is a package and therefore contains sub-products.
option.packageIncludesa list of the sub-products in groups on the option level.
Standard Productsthis package is configured to allow you to pick 1 premium product and 5 standard products from the includes list.
includeobject are as follows:
packageIncludeIdthat must be used in future operations involving this include. More on this below.
limitis greater than 1, up to the total limit set by
idof the product this include represents.
idof the option this include represents.
packageBookingsis actually a full booking object, and will include all the fields you would otherwise include when making a booking (including for capabilities like custom questions, extras, hotel pickup, etc.). The only difference is the fields
unitItemswhich would normally be required are ignored, that's because the package booking knows the product and option from the
packageIncludeIdvalue and the
unitItemsare ALWAYS fixed to be the same as the
unitItemsof the parent booking.
packageBookingsarray with the includes you have chosen.
unitItemsarray this will only add to the list of package bookings, so you can call it it multiple times and it'll add package bookings each time without deleting the list already in there. To remove existing package bookings you have to DELETE them.
packageBookingsand give these as separate vouchers to the guests.
uuidvalue just as you would any normal booking.