import { PreviewPriceRequest as PreviewPriceRequest$1, PreviewPriceResponse as PreviewPriceResponse$1, CalculatePriceRequest as CalculatePriceRequest$1, CalculatePriceResponse as CalculatePriceResponse$1 } from './index.typings.js'; import '@wix/sdk-types'; interface PriceInfo extends PriceInfoTotalPriceOneOf { /** Calculated total price. Available if the [service's](https://dev.wix.com/docs/api-reference/business-solutions/bookings/services/services-v2/introduction) `payment.rateType` is `FIXED`, `VARIED`, or `NO_FEE`. */ calculatedPrice?: number; /** * Description of the total price. * Available if the [service's](https://dev.wix.com/docs/api-reference/business-solutions/bookings/services/services-v2/introduction) `payment.rateType` is `CUSTOM`. * @deprecated Description of the total price. * Available if the [service's](https://dev.wix.com/docs/api-reference/business-solutions/bookings/services/services-v2/introduction) `payment.rateType` is `CUSTOM`. * @replacedBy price_description_info.original * @targetRemovalDate 2025-01-10 */ priceDescription?: string; /** * Description of the total price. * Available if the [service's](https://dev.wix.com/docs/api-reference/business-solutions/bookings/services/services-v2/introduction) `payment.rateType` is `CUSTOM`. */ priceDescriptionInfo?: PriceDescriptionInfo; /** * List of line items, including the number of participants and the price per participant. * @maxSize 20 */ bookingLineItems?: BookingLineItem[]; /** * Total deposit the customer must pay when booking the service. * Available if the [service's](https://dev.wix.com/docs/api-reference/business-solutions/bookings/services/services-v2/introduction) `payment.options.deposit` is set to `true`. */ deposit?: number | null; } /** @oneof */ interface PriceInfoTotalPriceOneOf { /** Calculated total price. Available if the [service's](https://dev.wix.com/docs/api-reference/business-solutions/bookings/services/services-v2/introduction) `payment.rateType` is `FIXED`, `VARIED`, or `NO_FEE`. */ calculatedPrice?: number; /** * Description of the total price. * Available if the [service's](https://dev.wix.com/docs/api-reference/business-solutions/bookings/services/services-v2/introduction) `payment.rateType` is `CUSTOM`. * @deprecated Description of the total price. * Available if the [service's](https://dev.wix.com/docs/api-reference/business-solutions/bookings/services/services-v2/introduction) `payment.rateType` is `CUSTOM`. * @replacedBy price_description_info.original * @targetRemovalDate 2025-01-10 */ priceDescription?: string; /** * Description of the total price. * Available if the [service's](https://dev.wix.com/docs/api-reference/business-solutions/bookings/services/services-v2/introduction) `payment.rateType` is `CUSTOM`. */ priceDescriptionInfo?: PriceDescriptionInfo; } interface BookingLineItem { /** * [Service ID](https://dev.wix.com/docs/rest/business-solutions/bookings/services/services-v2/introduction). * * Required parameter in: * - [Preview Price](https://dev.wix.com/docs/api-reference/business-solutions/bookings/pricing/pricing-api/preview-price) for all service types. All line items must have the same service ID. * - [Calculate Price](https://dev.wix.com/docs/api-reference/business-solutions/bookings/pricing/pricing-api/calculate-price) when using Wix Bookings' default pricing logic. Optional in Calculate Price when using a Pricing Service Provider Plugin. * @format GUID */ serviceId?: string | null; /** * [Resource ID](https://dev.wix.com/docs/rest/business-solutions/bookings/resources/resources-v2/introduction). * * Required parameter in: * - [Calculate Price](https://dev.wix.com/docs/api-reference/business-solutions/bookings/pricing/pricing-api/calculate-price) for all service types ([service types](https://dev.wix.com/docs/rest/business-solutions/bookings/services/services-v2/about-service-types)). * - [Preview Price](https://dev.wix.com/docs/api-reference/business-solutions/bookings/pricing/pricing-api/preview-price) for appointment-based services and classes. Optional in Preview Price for courses. * @format GUID */ resourceId?: string | null; /** * __Deprecated.__ Use `serviceChoices.choices` instead. * * Service choices selected by the customer when booking. * @deprecated __Deprecated.__ Use `serviceChoices.choices` instead. * * Service choices selected by the customer when booking. * @replacedBy service_choices.choices * @targetRemovalDate 2026-08-31 */ choices?: ServiceChoice[]; /** * __Deprecated.__ Use `serviceChoices.numberOfParticipants` instead. * * Number of participants for the line item. * @min 1 * @deprecated __Deprecated.__ Use `serviceChoices.numberOfParticipants` instead. * * Number of participants for the line item. * @replacedBy service_choices.number_of_participants * @targetRemovalDate 2026-08-31 */ numberOfParticipants?: number | null; /** * __Deprecated.__ Use `serviceChoices.pricePerParticipant` instead. * * Price per participant for the line item. * @readonly * @deprecated __Deprecated.__ Use `serviceChoices.pricePerParticipant` instead. * * Price per participant for the line item. * @replacedBy service_choices.price_per_participant * @targetRemovalDate 2026-08-31 */ pricePerParticipant?: number | null; /** * Service choices selected by the customer when booking. * Choices are specific values for service options that may affect pricing. For example, the option `ageGroup` may have choices like `child`, `student`, `adult`, and `senior`, each with different pricing. * Refer to the [Service Options and Variants API](https://dev.wix.com/docs/api-reference/business-solutions/bookings/services/service-options-and-variants/introduction) for more details. * @maxSize 20 */ serviceChoices?: PricingServiceChoices[]; } interface ServiceChoice extends ServiceChoiceChoiceOneOf { /** * Value for one of the choices in the [`CustomServiceOption.choices`](https://example.com) list. * Choices are specific values for an option the customer can choose to book. For example, * the option `ageGroup` may have these choices: `child`, `student`, `adult`, and `senior`. * Each choice may have a different price. */ custom?: string; duration?: Duration; /** * ID of the corresponding option for the choice. For example, the choice `child` * could correspond to the option `ageGroup`. In this case, `optionId` is the ID * for the `ageGroup` option. * @format GUID */ optionId?: string; } /** @oneof */ interface ServiceChoiceChoiceOneOf { /** * Value for one of the choices in the [`CustomServiceOption.choices`](https://example.com) list. * Choices are specific values for an option the customer can choose to book. For example, * the option `ageGroup` may have these choices: `child`, `student`, `adult`, and `senior`. * Each choice may have a different price. */ custom?: string; duration?: Duration; } interface Duration { /** * Duration of the service in minutes. * Min: 1 minute, Max: 30 days, 23 hours, and 59 minutes * @min 1 * @max 44639 */ minutes?: number; /** * Name of the duration option. * Defaults to the formatted duration e.g. "1 hour, 30 minutes". * @maxLength 255 */ name?: string | null; } interface PricingServiceChoices { /** * Number of participants for this service variant. * @min 1 */ numberOfParticipants?: number | null; /** * Service choices selected by these participants. * Each choice represents a specific value for a service option. * For example, age group, duration, or equipment type. * @maxSize 5 */ choices?: ServiceChoice[]; /** * Price per participant for this service variant. * @readonly */ pricePerParticipant?: number | null; } interface PriceDescriptionInfo { /** * Price description in the site's main language. * Refer to the [Site Properties API](https://dev.wix.com/docs/api-reference/business-management/site-properties/properties/introduction) for more details. * @maxLength 50 */ original?: string; /** * Translated price description. * Available if the booking was made in a secondary language. * @maxLength 50 */ translated?: string | null; } interface PreviewPriceRequest { /** * Booking line items to preview pricing for. * All line items must belong to the same [service](https://dev.wix.com/docs/rest/business-solutions/bookings/services/services-v2/introduction). * @minSize 1 * @maxSize 20 */ bookingLineItems: BookingLineItem[]; } interface PreviewPriceResponse { /** Pricing information including individual line item costs and total estimated price. */ priceInfo?: PriceInfo; } interface CalculatePriceRequest { /** * Existing [booking](https://dev.wix.com/docs/rest/business-solutions/bookings/bookings/bookings-writer-v2/introduction) to calculate the base price for. * Must include `bookedEntity` details and participant information. */ booking: Booking; } /** An entity representing a scheduled appointment, class session, or course. */ interface Booking extends BookingParticipantsInfoOneOf { /** * Total number of participants. * When creating a booking, use this field only if the relevant service has fixed pricing and doesn't offer [variants and options](https://dev.wix.com/docs/rest/business-solutions/bookings/services/service-options-and-variants/introduction). * @min 1 */ totalParticipants?: number; /** * Information about the booked service choices and participant count for each choice. * When creating a booking, use this field only if the booking includes multiple [service variants](https://dev.wix.com/docs/rest/business-solutions/bookings/services/service-options-and-variants/introduction). * * For example, use this for a spa package booking that includes different service levels: * - 2 participants chose "Standard Package". * - 1 participant chose "VIP Package". */ participantsChoices?: ParticipantChoices; /** * Booking ID. * @format GUID * @readonly */ id?: string | null; /** * An object describing the bookable entity - either a specific time slot or a recurring schedule. * * The structure depends on the type of service being booked: * * __For appointment services__: Use `slot` to book a specific time slot with a * service provider. Appointments are typically one-time sessions at a specific date and time. * * __For class services__: Use `slot` to book a specific class session. Classes * are individual sessions that can have multiple participants. * * __For course services__: Use `schedule` to book an entire course consisting of * multiple sessions over time. Courses are recurring, multi-session offerings. * * Choose the appropriate field based on your service type and booking requirements. */ bookedEntity?: BookedEntity; /** * Contact details of the site visitor or [member](https://dev.wix.com/docs/api-reference/crm/members-contacts/members/members/introduction) * making the booking. */ contactDetails?: ContactDetails; /** * Additional custom fields submitted with the booking form. * Deprecated due to Bookings integrating with Wix Forms. * You can call Wix Forms' [Get Submission](https://dev.wix.com/docs/api-reference/crm/forms/form-submissions/get-submission) specifying `formSubmissionId` as the `id` to get the submitted booking form data. * Read more about the [Bookings Forms integration](https://dev.wix.com/docs/api-reference/business-solutions/bookings/wix-forms-integration). * @deprecated Additional custom fields submitted with the booking form. * Deprecated due to Bookings integrating with Wix Forms. * You can call Wix Forms' [Get Submission](https://dev.wix.com/docs/api-reference/crm/forms/form-submissions/get-submission) specifying `formSubmissionId` as the `id` to get the submitted booking form data. * Read more about the [Bookings Forms integration](https://dev.wix.com/docs/api-reference/business-solutions/bookings/wix-forms-integration). * @replacedBy form_submission_id * @targetRemovalDate 2026-03-31 */ additionalFields?: CustomFormField[]; /** * Booking status. A booking is automatically confirmed if the service allows it * and an eCommerce order is created. It is automatically declined if there is a * double booking and the customer hasn't paid or is eligible for an automatic * refund. Currently, only payments with pricing plans are automatically refundable. */ status?: BookingStatusWithLiterals; /** * The payment status of the booking. This field automatically syncs with the * `paymentStatus` of the corresponding [eCommerce order](https://dev.wix.com/docs/api-reference/business-solutions/e-commerce/orders/introduction) * when customers use Wix eCommerce checkout. * * ### Integration patterns * * __When using Wix eCommerce checkout__: Wix Bookings automatically syncs the payment status based on the eCommerce order's payment status. * Do not manually update this field. * * __When using custom payment flows__: You can manually update the payment status with [Confirm Booking or Decline Booking](https://dev.wix.com/docs/api-reference/business-solutions/bookings/bookings/bookings-writer-v2/confirm-or-decline-booking) to reflect the customer's payment state. * * __For membership/pricing plan payments__: Wix Bookings automatically manages the payment status when customers pay with an active [pricing plan](https://dev.wix.com/docs/api-reference/business-solutions/pricing-plans/pricing-plans/introduction) subscription. * * All payment statuses are supported for every booking `status`. */ paymentStatus?: PaymentStatusWithLiterals; /** * Payment option selected by the customer. If the customer hasn't completed their checkout, they may still change the payment method. Must be one of the payment options offered by the [service](https://dev.wix.com/docs/api-reference/business-solutions/bookings/services/services-v2/introduction), unless `skipSelectedPaymentOptionValidation` is `true`. * * When the customer pays with a [Wix eCommerce checkout](https://dev.wix.com/docs/api-reference/business-solutions/e-commerce/checkout/introduction), this field is required. * Otherwise, the Create Booking call fails. * For custom checkouts, you don't have to specify this field. */ selectedPaymentOption?: SelectedPaymentOptionWithLiterals; /** * Date and time the booking was created in `YYYY-MM-DDThh:mm:ss.sssZ` format. * @readonly */ createdDate?: Date | null; /** External user ID that you can provide. */ externalUserId?: string | null; /** * Revision number to be used when updating, rescheduling, or cancelling the booking. * Increments by 1 each time the booking is updated, rescheduled, or canceled. To prevent conflicting changes, the current revision must be specified when updating the booking. */ revision?: string | null; /** * ID of the creator of the booking. * If `appId` and another ID are present, the other ID takes precedence. * @readonly */ createdBy?: IdentificationData; /** * The start date of the booking in `YYYY-MM-DDThh:mm:ss.sssZ` format. * For a slot, this is the start date of the slot. For a schedule, this is the start date of the first session. * @readonly */ startDate?: Date | null; /** * The end date of the booking in `YYYY-MM-DDThh:mm:ss.sssZ` format. * For a slot, this is the end date of the slot. For a schedule, this is the end date of the last session. * @readonly */ endDate?: Date | null; /** * Date and time the booking was updated in `YYYY-MM-DDThh:mm:ss.sssZ` format. * @readonly */ updatedDate?: Date | null; /** * Custom field data for this object. * Extended fields must be configured in the app dashboard before they can be accessed with API calls. */ extendedFields?: ExtendedFields; /** * Whether this booking overlaps with another confirmed booking. Returned * only if set to `true`. * @readonly */ doubleBooked?: boolean | null; /** * ID of the [form submission](https://dev.wix.com/docs/rest/crm/forms/form-submissions/introduction) * associated with this booking. * @format GUID */ formSubmissionId?: string | null; /** * ID of the [form](https://dev.wix.com/docs/rest/crm/forms/form-schemas/form-object) * associated with this booking. The value depends on how the * booking was created: * - For bookings created with Create Booking or Bulk Create Booking, `formId` * is identical to ID of the booking form that's associated with the relevant * service. * - For bookings created via Create Multi Service Booking, `formId` is set to * `00000000-0000-0000-0000-000000000000` (the default booking form ID). * @format GUID * @readonly */ formId?: string | null; /** * List of [add-ons](https://dev.wix.com/docs/api-reference/business-solutions/bookings/services/add-ons/introduction) associated with the booking. * @maxSize 21 */ bookedAddOns?: BookedAddOn[]; /** * ID of the app that's associated with the booking. * Inherited from the `appId` of the service associated with the booking. * Bookings are displayed in Wix Bookings only if they are associated with the Wix Bookings app ID or have no associated app ID. * For bookings from Wix apps, the following values apply: * - Wix Bookings: `"13d21c63-b5ec-5912-8397-c3a5ddb27a97"` * - Wix Services: `"cc552162-24a4-45e0-9695-230c4931ef40"` * - Wix Meetings: `"6646a75c-2027-4f49-976c-58f3d713ed0f"` * [Full list of apps created by Wix](https://dev.wix.com/docs/api-reference/articles/work-with-wix-apis/platform/about-apps-created-by-wix). * * @format GUID * @readonly */ appId?: string | null; /** * ID of the app that created the booking. This field is used for analytics, auditing, and tracking creation sources. * This read-only field is automatically populated during booking creation by checking these sources in order: * 1. The caller's App ID from the request identity context (external app or server identity). * 2. The booking's `appId` field (inherited from the service's `appId`). * 3. The Wix Bookings App ID (`13d21c63-b5ec-5912-8397-c3a5ddb27a97`) as the final fallback. * * @format GUID * @readonly */ createdByAppId?: string | null; /** * Whether the customer chooses to pay only the deposit amount upfront. * * - `true`: The customer pays only the deposit amount upfront. * - `false`: The customer pays the full price upfront. * * Used only when `selectedPaymentOption` is `ONLINE` and the [service](https://dev.wix.com/docs/api-reference/business-solutions/bookings/services/services-v2/introduction) has a deposit amount set. * * When the service supports deposit payments and `fullUpfrontPaymentAllowed` is `false`, this field must be `true`. * When the service supports deposit payments and `fullUpfrontPaymentAllowed` is `true`, this field can be `true` or `false`. */ depositSelected?: boolean | null; } /** @oneof */ interface BookingParticipantsInfoOneOf { /** * Total number of participants. * When creating a booking, use this field only if the relevant service has fixed pricing and doesn't offer [variants and options](https://dev.wix.com/docs/rest/business-solutions/bookings/services/service-options-and-variants/introduction). * @min 1 */ totalParticipants?: number; /** * Information about the booked service choices and participant count for each choice. * When creating a booking, use this field only if the booking includes multiple [service variants](https://dev.wix.com/docs/rest/business-solutions/bookings/services/service-options-and-variants/introduction). * * For example, use this for a spa package booking that includes different service levels: * - 2 participants chose "Standard Package". * - 1 participant chose "VIP Package". */ participantsChoices?: ParticipantChoices; } /** * Type of multi-service booking. * Defines how individual bookings within a multi-service package are scheduled relative to each other. */ declare enum MultiServiceBookingType { /** * Bookings must be scheduled back-to-back. * Each booking starts when the previous one ends, with no gaps between them. */ SEQUENTIAL_BOOKINGS = "SEQUENTIAL_BOOKINGS", /** * Bookings can be scheduled separately. * Each booking can be at different times, not necessarily consecutive. * Not currently supported. */ SEPARATE_BOOKINGS = "SEPARATE_BOOKINGS", /** * Bookings occur at the same time. * All bookings in the package are scheduled for the same time slot. * Not currently supported. */ PARALLEL_BOOKINGS = "PARALLEL_BOOKINGS" } /** @enumType */ type MultiServiceBookingTypeWithLiterals = MultiServiceBookingType | 'SEQUENTIAL_BOOKINGS' | 'SEPARATE_BOOKINGS' | 'PARALLEL_BOOKINGS'; interface BookedEntity extends BookedEntityItemOneOf { /** * [Booked slot](https://dev.wix.com/docs/rest/business-solutions/bookings/bookings-and-time-slots/time-slots/availability-calendar/query-availability). * * Specify `slot` when creating bookings for: * - __Appointment-based services__: Individual sessions with service providers (consultations, treatments). * Wix Bookings creates a new session when the booking is confirmed. * - __Class services__: Group sessions at specific times (fitness classes, workshops). * Wix Bookings links the booking to an existing scheduled session. * * For course services, specify `schedule` instead of `slot`. */ slot?: BookedSlot; /** * [Booked schedule](https://dev.wix.com/docs/rest/business-management/calendar/schedules-v3/introduction). * * Specify `schedule` when creating bookings for: * - __Course services__: Multi-session offerings spanning weeks or months (educational courses, training programs). * Wix Bookings enrolls participants in all sessions defined by the course schedule. */ schedule?: BookedSchedule; /** * Session title at the time of booking. If there is no pre-existing session, * for example for appointment-based services, Wix Bookings sets `title` to the service name. * @readonly * @maxLength 6000 */ title?: string | null; /** * List of tags for the booking. * * - "INDIVIDUAL": For bookings of appointment-based services. Including when the appointment is for a group of participants. * - "GROUP": For bookings of individual class sessions. * - "COURSE": For course bookings. */ tags?: string[] | null; } /** @oneof */ interface BookedEntityItemOneOf { /** * [Booked slot](https://dev.wix.com/docs/rest/business-solutions/bookings/bookings-and-time-slots/time-slots/availability-calendar/query-availability). * * Specify `slot` when creating bookings for: * - __Appointment-based services__: Individual sessions with service providers (consultations, treatments). * Wix Bookings creates a new session when the booking is confirmed. * - __Class services__: Group sessions at specific times (fitness classes, workshops). * Wix Bookings links the booking to an existing scheduled session. * * For course services, specify `schedule` instead of `slot`. */ slot?: BookedSlot; /** * [Booked schedule](https://dev.wix.com/docs/rest/business-management/calendar/schedules-v3/introduction). * * Specify `schedule` when creating bookings for: * - __Course services__: Multi-session offerings spanning weeks or months (educational courses, training programs). * Wix Bookings enrolls participants in all sessions defined by the course schedule. */ schedule?: BookedSchedule; } interface BookedSlot { /** * Session ID. For class bookings, this is the ID of the existing session. * For appointment bookings, this field is typically empty during booking creation and gets populated when the booking is confirmed. * * __Migration Guidance__: Replace usage of this field with `eventId` from the [Time Slots V2 API](https://dev.wix.com/docs/api-reference/business-solutions/bookings/time-slots/time-slots-v2/introduction). * You can follow [these sample flows](https://dev.wix.com/docs/api-reference/business-solutions/bookings/end-to-end-booking-flows) for step-by-step guidance about determining availability and creating bookings. * @deprecated Session ID. For class bookings, this is the ID of the existing session. * For appointment bookings, this field is typically empty during booking creation and gets populated when the booking is confirmed. * * __Migration Guidance__: Replace usage of this field with `eventId` from the [Time Slots V2 API](https://dev.wix.com/docs/api-reference/business-solutions/bookings/time-slots/time-slots-v2/introduction). * You can follow [these sample flows](https://dev.wix.com/docs/api-reference/business-solutions/bookings/end-to-end-booking-flows) for step-by-step guidance about determining availability and creating bookings. * @replacedBy event_id * @targetRemovalDate 2026-03-31 */ sessionId?: string | null; /** Service ID. */ serviceId?: string; /** Schedule ID. */ scheduleId?: string; /** * ID of the corresponding [event](https://dev.wix.com/docs/rest/business-management/calendar/events-v3/introduction). * Available for both appointment and class bookings, not available for course bookings. * For appointment-based services, Wix Bookings automatically populates `eventId` when the booking `status` changes to `CONFIRMED`. * For class bookings, Wix Bookings automatically populates `eventId` upon booking creation. * @minLength 36 * @maxLength 250 */ eventId?: string | null; /** The start time of this slot in `YYYY-MM-DDThh:mm:ss`, `YYYY-MM-DDThh:mm:ss:SSS`, or `YYYY-MM-DDThh:mm:ss:SSSZZ` [ISO-8601 format](https://en.wikipedia.org/wiki/ISO_8601). For example, `2026-01-30T13:30:00`, `2026-01-30T13:30:00:000`, or `2026-01-30T13:30:00:000-05:00`. */ startDate?: string | null; /** The end time of this slot in `YYYY-MM-DDThh:mm:ss`, `YYYY-MM-DDThh:mm:ss:SSS`, or `YYYY-MM-DDThh:mm:ss:SSSZZ` [ISO-8601 format](https://en.wikipedia.org/wiki/ISO_8601). For example, `2026-01-30T13:30:00`, `2026-01-30T13:30:00:000`, or `2026-01-30T13:30:00:000-05:00`. */ endDate?: string | null; /** * Time zone in [IANA tz database format](https://en.wikipedia.org/wiki/Tz_database). * For example, `America/New_York` or `UTC`. This is the time zone in which the slot was shown to the customer at the time of booking. Wix Bookings ensures that the slot is always displayed in this same time zone to the customer, including when they view or edit their booking in the future. */ timezone?: string | null; /** * [Primary resource](https://dev.wix.com/docs/rest/business-solutions/bookings/resources/resources-v2/introduction) for the booking. * For example, the [staff member](https://dev.wix.com/docs/rest/business-solutions/bookings/staff-members/introduction) providing the service. */ resource?: BookedResource; /** Location where the session takes place. */ location?: Location; /** * Information about how the customer has selected resources for the booking. * Each resource type may have a different selection method. * Check `resource` for resource details. * @maxSize 3 */ resourceSelections?: ResourceSelection[]; } interface BookedResource { /** * ID of the booking's primary resource. * @format GUID */ id?: string; /** * Resource's name at the time of booking. * @maxLength 40 */ name?: string | null; /** * Resource's email at the time of booking. * @maxLength 500 */ email?: string | null; /** * ID of the schedule belonging to the booking's primary resource. * @format GUID */ scheduleId?: string | null; } declare enum ResourceTransparency { OPAQUE = "OPAQUE", TRANSPARENT = "TRANSPARENT" } /** @enumType */ type ResourceTransparencyWithLiterals = ResourceTransparency | 'OPAQUE' | 'TRANSPARENT'; interface Location { /** * Business location ID. Available only for locations that are business locations, * meaning the `location_type` is `"OWNER_BUSINESS"`. * @format GUID */ id?: string | null; /** Location name. */ name?: string | null; /** The full address of this location. */ formattedAddress?: string | null; /** * The full translated address of this location. * @maxLength 512 */ formattedAddressTranslated?: string | null; /** Location type. */ locationType?: LocationTypeWithLiterals; } declare enum LocationType { /** Undefined location type. */ UNDEFINED = "UNDEFINED", /** The business address, as set in the site’s general settings. */ OWNER_BUSINESS = "OWNER_BUSINESS", /** The address as set when creating the service. */ OWNER_CUSTOM = "OWNER_CUSTOM", /** The address as set for the individual session. */ CUSTOM = "CUSTOM" } /** @enumType */ type LocationTypeWithLiterals = LocationType | 'UNDEFINED' | 'OWNER_BUSINESS' | 'OWNER_CUSTOM' | 'CUSTOM'; /** TODO: should we import it from services-2? */ interface PhoneCall { /** Whether the service is delivered via phone call. */ enabled?: boolean | null; } interface ResourceSelection { /** * ID of the [resource type](https://dev.wix.com/docs/api-reference/business-solutions/bookings/resources/resource-types-v2/introduction). * @format GUID */ resourceTypeId?: string | null; /** Information about how the customer has selected the resource for this resource type. */ selectionMethod?: SelectionMethodWithLiterals; } declare enum SelectionMethod { /** The customer explicitly chose a particular resource. */ SPECIFIC_RESOURCE = "SPECIFIC_RESOURCE", /** The customer explicitly chose "any available resource" for this resource type. */ ANY_RESOURCE = "ANY_RESOURCE", /** The customer wasn't offered a resource selection or agreement option for this resource type. */ NO_SELECTION = "NO_SELECTION" } /** @enumType */ type SelectionMethodWithLiterals = SelectionMethod | 'SPECIFIC_RESOURCE' | 'ANY_RESOURCE' | 'NO_SELECTION'; interface BookedSchedule { /** [Schedule ID](https://dev.wix.com/docs/rest/business-management/calendar/schedules-v3/introduction). */ scheduleId?: string; /** * Booked service ID. * @format GUID */ serviceId?: string | null; /** * [Location](https://dev.wix.com/docs/rest/business-management/locations/introduction) where the schedule's sessions take place. * @readonly */ location?: Location; /** * Time zone in [IANA tz database format](https://en.wikipedia.org/wiki/Tz_database). * For example, `America/New_York` or `UTC`. This is the time zone in which the schedule was shown to the customer at the time of booking. Wix Bookings ensures that the schedule is always displayed in this same time zone to the customer, including when they view or edit their booking in the future. */ timezone?: string | null; /** * Start time of the first session related to the booking in `YYYY-MM-DDThh:mm:ss`, `YYYY-MM-DDThh:mm:ss:SSS`, or `YYYY-MM-DDThh:mm:ss:SSSZZ` [ISO-8601 format](https://en.wikipedia.org/wiki/ISO_8601). For example, `2026-01-30T13:30:00`, `2026-01-30T13:30:00:000`, or `2026-01-30T13:30:00:000-05:00`. * @readonly */ firstSessionStart?: string | null; /** * End time of the last session related to the booking in `YYYY-MM-DDThh:mm:ss`, `YYYY-MM-DDThh:mm:ss:SSS`, or `YYYY-MM-DDThh:mm:ss:SSSZZ` [ISO-8601 format](https://en.wikipedia.org/wiki/ISO_8601). For example, `2026-01-30T13:30:00`, `2026-01-30T13:30:00:000`, or `2026-01-30T13:30:00:000-05:00`. * @readonly */ lastSessionEnd?: string | null; } interface ContactDetails { /** * Contact ID. * @format GUID */ contactId?: string | null; /** * Contact's first name. When populated from a standard booking form, this * property corresponds to the `name` field. */ firstName?: string | null; /** Contact's last name. */ lastName?: string | null; /** * Contact's email. If no [contact](https://dev.wix.com/docs/rest/crm/members-contacts/contacts/contacts/contact-v4/contact-object) * with this email exist, a new contact is created. * Used to validate coupon usage limitations per contact. If not specified, * the coupon usage limitation will not be enforced. (Coupon usage limitation * validation is not supported yet). * @format EMAIL */ email?: string | null; /** Contact's phone number. */ phone?: string | null; /** Contact's full address. */ fullAddress?: Address; /** * Contact's time zone. * @deprecated Contact's time zone. * @targetRemovalDate 2026-03-31 */ timeZone?: string | null; /** * Contact's country in [ISO 3166-1 alpha-2 code](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2) * format. * @format COUNTRY */ countryCode?: string | null; } /** Physical address */ interface Address extends AddressStreetOneOf { /** Street name, number and apartment number. */ streetAddress?: StreetAddress; /** Main address line, usually street and number, as free text. */ addressLine?: string | null; /** * Country code. * @format COUNTRY */ country?: string | null; /** Subdivision. Usually state, region, prefecture or province code, according to [ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2). */ subdivision?: string | null; /** City name. */ city?: string | null; /** Zip/postal code. */ postalCode?: string | null; /** Free text providing more detailed address info. Usually contains Apt, Suite, and Floor. */ addressLine2?: string | null; /** A string containing the full address of this location. */ formattedAddress?: string | null; /** Free text to help find the address. */ hint?: string | null; /** Coordinates of the physical address. */ geocode?: AddressLocation; /** Country full name. */ countryFullname?: string | null; /** Multi-level subdivisions from top to bottom. */ subdivisions?: Subdivision[]; } /** @oneof */ interface AddressStreetOneOf { /** Street name, number and apartment number. */ streetAddress?: StreetAddress; /** Main address line, usually street and number, as free text. */ addressLine?: string | null; } interface StreetAddress { /** Street number. */ number?: string; /** Street name. */ name?: string; /** Apartment number. */ apt?: string; } interface AddressLocation { /** Address latitude. */ latitude?: number | null; /** Address longitude. */ longitude?: number | null; } interface Subdivision { /** Subdivision code. Usually state, region, prefecture or province code, according to [ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2). */ code?: string; /** Subdivision full name. */ name?: string; } interface CustomFormField { /** * ID of the form field as defined in the form. * @format GUID */ id?: string; /** Value that was submitted for this field. */ value?: string | null; /** * Form field's label at the time of submission. * @readonly */ label?: string | null; valueType?: ValueTypeWithLiterals; } declare enum ValueType { /** Short text. This is the default value type. */ SHORT_TEXT = "SHORT_TEXT", /** Long text. */ LONG_TEXT = "LONG_TEXT", /** A text that represents the check box value. If selected the value is `true`, otherwise `false`. */ CHECK_BOX = "CHECK_BOX" } /** @enumType */ type ValueTypeWithLiterals = ValueType | 'SHORT_TEXT' | 'LONG_TEXT' | 'CHECK_BOX'; /** Booking status. */ declare enum BookingStatus { /** The booking was created, but the customer hasn't completed the related eCommerce order yet. */ CREATED = "CREATED", /** The merchant has confirmed the booking and it appears in the business calendar. Merchants can set up their [services](https://dev.wix.com/docs/rest/business-solutions/bookings/services/services-v2/introduction) to automatically confirm all `PENDING` bookings. */ CONFIRMED = "CONFIRMED", /** * The customer has canceled the booking. Depending on the relevant service's [policy snapshot](https://dev.wix.com/docs/rest/business-solutions/bookings/policies/booking-policy-snapshots/introduction) * they may have to pay a [cancellation fee](https://dev.wix.com/docs/rest/business-solutions/bookings/pricing/booking-fees/introduction). */ CANCELED = "CANCELED", /** The merchant must manually confirm the booking before it appears in the business calendar. */ PENDING = "PENDING", /** The merchant has declined the booking before the customer was charged. */ DECLINED = "DECLINED", /** Currently, you can't call [Register to Waitlist](https://dev.wix.com/docs/rest/business-solutions/bookings/bookings/waitlist/register-to-waitlist) for course or appointment bookings, even though this is supported in live sites. */ WAITING_LIST = "WAITING_LIST" } /** @enumType */ type BookingStatusWithLiterals = BookingStatus | 'CREATED' | 'CONFIRMED' | 'CANCELED' | 'PENDING' | 'DECLINED' | 'WAITING_LIST'; /** * Payment status. * Automatically updated when using eCommerce checkout APIs. */ declare enum PaymentStatus { /** Undefined payment status. */ UNDEFINED = "UNDEFINED", /** The booking isn't paid. */ NOT_PAID = "NOT_PAID", /** The booking is fully paid. */ PAID = "PAID", /** The booking is partially paid. */ PARTIALLY_PAID = "PARTIALLY_PAID", /** The booking is refunded. */ REFUNDED = "REFUNDED", /** The booking is free of charge. */ EXEMPT = "EXEMPT" } /** @enumType */ type PaymentStatusWithLiterals = PaymentStatus | 'UNDEFINED' | 'NOT_PAID' | 'PAID' | 'PARTIALLY_PAID' | 'REFUNDED' | 'EXEMPT'; /** * Selected payment option. * * One of the payment options offered by the service. * This field is set when the user selects an option during booking. * If left undefined, the payment option is resolved by the service configuration on checkout. */ declare enum SelectedPaymentOption { /** Undefined payment option. */ UNDEFINED = "UNDEFINED", /** Offline payment. */ OFFLINE = "OFFLINE", /** Online payment. */ ONLINE = "ONLINE", /** Payment using a Wix Pricing Plan. */ MEMBERSHIP = "MEMBERSHIP", /** * Customers can pay only in person with a Wix Pricing Plan, while the Wix user * must manually redeem the pricing plan in the dashboard. */ MEMBERSHIP_OFFLINE = "MEMBERSHIP_OFFLINE" } /** @enumType */ type SelectedPaymentOptionWithLiterals = SelectedPaymentOption | 'UNDEFINED' | 'OFFLINE' | 'ONLINE' | 'MEMBERSHIP' | 'MEMBERSHIP_OFFLINE'; interface BookingSource { /** Platform from which a booking was created. */ platform?: PlatformWithLiterals; /** Actor that created this booking. */ actor?: ActorWithLiterals; /** * Wix site ID of the application that created the booking. * @format GUID * @readonly */ appDefId?: string | null; /** * Name of the application that created the booking, as saved in Wix Developers Center at the time of booking. * @readonly */ appName?: string | null; } declare enum Platform { UNDEFINED_PLATFORM = "UNDEFINED_PLATFORM", WEB = "WEB", MOBILE_APP = "MOBILE_APP" } /** @enumType */ type PlatformWithLiterals = Platform | 'UNDEFINED_PLATFORM' | 'WEB' | 'MOBILE_APP'; declare enum Actor { UNDEFINED_ACTOR = "UNDEFINED_ACTOR", BUSINESS = "BUSINESS", CUSTOMER = "CUSTOMER" } /** @enumType */ type ActorWithLiterals = Actor | 'UNDEFINED_ACTOR' | 'BUSINESS' | 'CUSTOMER'; interface ParticipantNotification { /** * Whether to send a message about the changes to the customer. * * Default: `false` */ notifyParticipants?: boolean; /** Custom message to send to the participants about the changes to the booking. */ message?: string | null; /** * Information about the delivery channels used to send the notification. * For example, `{"channels": "SMS" }`, `{"channels": "EMAIL" }`, or `{"channels": "EMAIL, SMS" }`. */ metadata?: Record; } interface IdentificationData extends IdentificationDataIdOneOf { /** * ID of a site visitor that has not logged in to the site. * @format GUID */ anonymousVisitorId?: string; /** * ID of a site visitor that has logged in to the site. * @format GUID */ memberId?: string; /** * ID of a Wix user (site owner, contributor, etc.). * @format GUID */ wixUserId?: string; /** * ID of an app. * @format GUID */ appId?: string; /** * ID of of a contact in the site's [CRM by Ascend](https://www.wix.com/ascend/crm) system. * @format GUID */ contactId?: string | null; } /** @oneof */ interface IdentificationDataIdOneOf { /** * ID of a site visitor that has not logged in to the site. * @format GUID */ anonymousVisitorId?: string; /** * ID of a site visitor that has logged in to the site. * @format GUID */ memberId?: string; /** * ID of a Wix user (site owner, contributor, etc.). * @format GUID */ wixUserId?: string; /** * ID of an app. * @format GUID */ appId?: string; } declare enum IdentityType { UNKNOWN = "UNKNOWN", ANONYMOUS_VISITOR = "ANONYMOUS_VISITOR", MEMBER = "MEMBER", WIX_USER = "WIX_USER", APP = "APP" } /** @enumType */ type IdentityTypeWithLiterals = IdentityType | 'UNKNOWN' | 'ANONYMOUS_VISITOR' | 'MEMBER' | 'WIX_USER' | 'APP'; /** * Settings that control booking flow behavior and override default business rules. * * These settings allow administrators to bypass standard validation checks * and policies when creating, confirming, rescheduling, or canceling bookings. * Most settings require elevated permissions to use. * * Use flow control settings to handle special scenarios like: * - Emergency bookings outside normal business hours * - Admin-initiated bookings that bypass availability checks * - Custom payment flows that don't use standard eCommerce checkout * - Overriding cancellation or rescheduling policies in exceptional cases */ interface FlowControlSettings { /** Whether availability is checked when creating or confirming the booking. */ skipAvailabilityValidation?: boolean; /** * Whether the booking's `status` is automatically updated to `CONFIRMED` when * the customer completes the [eCommerce checkout](https://dev.wix.com/docs/rest/business-solutions/e-commerce/checkout/introduction), * regardless of whether the relevant service requires manual business confirmation. */ skipBusinessConfirmation?: boolean; /** * Whether the customer is allowed to pay with a payment method that isn't * supported for the relevant service. */ skipSelectedPaymentOptionValidation?: boolean; /** * Whether the customer receives an automatic refund if there's a double booking * conflict. Only available if the customer has paid with a * pricing plan. */ withRefund?: boolean | null; /** * Whether [add-on](https://dev.wix.com/docs/api-reference/business-solutions/bookings/services/add-ons/introduction) validations are skipped when creating a booking. * For example, customers can choose an add-on from an [add-on group](https://dev.wix.com/docs/api-reference/business-solutions/bookings/services/services-v2/about-add-on-groups) that's not associated with the service or choose more than the maximum number of different add-ons from a group. * The calling [identity](https://dev.wix.com/docs/build-apps/develop-your-app/access/about-identities) must have `BOOKINGS.MANAGE_ADDONS` permissions when specifying `true`. * * Default: `false`. */ skipAddOnValidation?: boolean | null; } interface ExtendedFields { /** * Extended field data. Each key corresponds to the namespace of the app that created the extended fields. * The value of each key is structured according to the schema defined when the extended fields were configured. * * You can only access fields for which you have the appropriate permissions. * * Learn more about [extended fields](https://dev.wix.com/docs/rest/articles/getting-started/extended-fields). */ namespaces?: Record>; } interface ParticipantChoices { /** * Information about the booked service choices. Includes the number of participants. * @minSize 1 * @maxSize 20 */ serviceChoices?: ServiceChoices[]; } interface ServiceChoices { /** * Number of participants for this [variant](https://dev.wix.com/docs/rest/business-solutions/bookings/services/service-options-and-variants/introduction). * @min 1 */ numberOfParticipants?: number | null; /** * Service choices for these participants. * @maxSize 5 */ choices?: ServiceChoice[]; } interface MultiServiceBookingInfo { /** * Multi-service booking ID. * @format GUID * @readonly */ id?: string | null; /** Type of the multi-service booking. */ type?: MultiServiceBookingTypeWithLiterals; } interface BookedAddOn { /** * The ID of the add-on. * @format GUID */ id?: string; /** * The ID of the add-on group. * @format GUID */ groupId?: string; /** * The add-on duration in minutes at the time of booking. * Populated for duration-based add-ons. * @min 1 * @max 1440 * @readonly */ durationInMinutes?: number | null; /** * The quantity of booked add-ons. * For duration-based add-ons, `quantity` is not applicable. * If `quantity` is provided as `1` for a duration-based add-on, it will be accepted but the value will be cleared. * If any other value is provided, an `INVALID_ARGUMENT` error will be returned with the message: "Invalid AddOn details: either duration or quantity must be set correctly". * @min 1 * @max 1000 */ quantity?: number | null; /** * Add-on `name` at the time of booking. * @maxLength 100 * @readonly */ name?: string | null; /** * Add-on name translated to the language the customer used during booking. * @maxLength 100 * @readonly */ nameTranslated?: string | null; } interface CalculatePriceResponse { /** Information about each line item's base price and the total base price. */ priceInfo?: PriceInfo; } /** @docsIgnore */ type PreviewPriceApplicationErrors = { code?: 'INVALID_SERVICE_ID'; description?: string; data?: Record; } | { code?: 'NUMBER_OF_PARTICIPANTS_NOT_FOUND'; description?: string; data?: Record; } | { code?: 'FAILED_RESOLVING_SERVICE'; description?: string; data?: Record; }; /** @docsIgnore */ type CalculatePriceApplicationErrors = { code?: 'INVALID_BOOKING'; description?: string; data?: Record; } | { code?: 'NUMBER_OF_PARTICIPANTS_NOT_FOUND'; description?: string; data?: Record; } | { code?: 'FAILED_RESOLVING_SERVICE'; description?: string; data?: Record; } | { code?: 'ERROR_CONTACTING_PRICING_PROVIDER'; description?: string; data?: Record; } | { code?: 'MULTIPLE_PRICING_PROVIDERS_FOUND'; description?: string; data?: Record; }; type __PublicMethodMetaInfo = { getUrl: (context: any) => string; httpMethod: K; path: string; pathParams: M; __requestType: T; __originalRequestType: S; __responseType: Q; __originalResponseType: R; }; declare function previewPrice(): __PublicMethodMetaInfo<'POST', {}, PreviewPriceRequest$1, PreviewPriceRequest, PreviewPriceResponse$1, PreviewPriceResponse>; declare function calculatePrice(): __PublicMethodMetaInfo<'POST', {}, CalculatePriceRequest$1, CalculatePriceRequest, CalculatePriceResponse$1, CalculatePriceResponse>; export { Actor as ActorOriginal, type ActorWithLiterals as ActorWithLiteralsOriginal, type AddressLocation as AddressLocationOriginal, type Address as AddressOriginal, type AddressStreetOneOf as AddressStreetOneOfOriginal, type BookedAddOn as BookedAddOnOriginal, type BookedEntityItemOneOf as BookedEntityItemOneOfOriginal, type BookedEntity as BookedEntityOriginal, type BookedResource as BookedResourceOriginal, type BookedSchedule as BookedScheduleOriginal, type BookedSlot as BookedSlotOriginal, type BookingLineItem as BookingLineItemOriginal, type Booking as BookingOriginal, type BookingParticipantsInfoOneOf as BookingParticipantsInfoOneOfOriginal, type BookingSource as BookingSourceOriginal, BookingStatus as BookingStatusOriginal, type BookingStatusWithLiterals as BookingStatusWithLiteralsOriginal, type CalculatePriceApplicationErrors as CalculatePriceApplicationErrorsOriginal, type CalculatePriceRequest as CalculatePriceRequestOriginal, type CalculatePriceResponse as CalculatePriceResponseOriginal, type ContactDetails as ContactDetailsOriginal, type CustomFormField as CustomFormFieldOriginal, type Duration as DurationOriginal, type ExtendedFields as ExtendedFieldsOriginal, type FlowControlSettings as FlowControlSettingsOriginal, type IdentificationDataIdOneOf as IdentificationDataIdOneOfOriginal, type IdentificationData as IdentificationDataOriginal, IdentityType as IdentityTypeOriginal, type IdentityTypeWithLiterals as IdentityTypeWithLiteralsOriginal, type Location as LocationOriginal, LocationType as LocationTypeOriginal, type LocationTypeWithLiterals as LocationTypeWithLiteralsOriginal, type MultiServiceBookingInfo as MultiServiceBookingInfoOriginal, MultiServiceBookingType as MultiServiceBookingTypeOriginal, type MultiServiceBookingTypeWithLiterals as MultiServiceBookingTypeWithLiteralsOriginal, type ParticipantChoices as ParticipantChoicesOriginal, type ParticipantNotification as ParticipantNotificationOriginal, PaymentStatus as PaymentStatusOriginal, type PaymentStatusWithLiterals as PaymentStatusWithLiteralsOriginal, type PhoneCall as PhoneCallOriginal, Platform as PlatformOriginal, type PlatformWithLiterals as PlatformWithLiteralsOriginal, type PreviewPriceApplicationErrors as PreviewPriceApplicationErrorsOriginal, type PreviewPriceRequest as PreviewPriceRequestOriginal, type PreviewPriceResponse as PreviewPriceResponseOriginal, type PriceDescriptionInfo as PriceDescriptionInfoOriginal, type PriceInfo as PriceInfoOriginal, type PriceInfoTotalPriceOneOf as PriceInfoTotalPriceOneOfOriginal, type PricingServiceChoices as PricingServiceChoicesOriginal, type ResourceSelection as ResourceSelectionOriginal, ResourceTransparency as ResourceTransparencyOriginal, type ResourceTransparencyWithLiterals as ResourceTransparencyWithLiteralsOriginal, SelectedPaymentOption as SelectedPaymentOptionOriginal, type SelectedPaymentOptionWithLiterals as SelectedPaymentOptionWithLiteralsOriginal, SelectionMethod as SelectionMethodOriginal, type SelectionMethodWithLiterals as SelectionMethodWithLiteralsOriginal, type ServiceChoiceChoiceOneOf as ServiceChoiceChoiceOneOfOriginal, type ServiceChoice as ServiceChoiceOriginal, type ServiceChoices as ServiceChoicesOriginal, type StreetAddress as StreetAddressOriginal, type Subdivision as SubdivisionOriginal, ValueType as ValueTypeOriginal, type ValueTypeWithLiterals as ValueTypeWithLiteralsOriginal, type __PublicMethodMetaInfo, calculatePrice, previewPrice };