About the Bookings Pricing API

The Bookings Pricing API allows you to preview and calculate the price of a booking. Use this API to retrieve booking pricing details when building a custom checkout flow or displaying booking cost outside the Wix site.

With the Bookings Pricing API you can:

  • Preview pricing: Estimate the cost of booking line items before creating the actual booking.
  • Price calculation: Determine the final price of existing bookings.

Price consistency

In most situations, the preview price and calculated price are identical when using the same booking parameters. However, the final amount charged to customers during eCommerce checkout may differ from both the preview and calculated base prices due to:

  • Discounts and coupons: Promotional codes or automatic discounts applied at checkout time.
  • Booking fees: Cancellation fees or other booking-related charges that may be added to orders.
  • Payment processing: Additional charges from payment providers or currency conversion fees.
  • Time-sensitive pricing: The business changes the service price between calling Preview Price and Calculate Price.

Service pricing options

Wix Bookings allows Wix users to offer their services for a fixed price, for free, or a varied price based on which variant the customer signs up for. Learn more about service payments.

Before you begin

Note the following points before starting to code:

  • Install Wix Bookings on a site before you can use the Pricing API.
  • You can only preview the price for line items belonging to the same service. You can't use Preview Price if line items belong to different services.
  • If the business uses a Pricing Service Provider Plugin, Preview Price calls fail completely. The plugin overrides standard Wix Bookings pricing logic, and preview functionality isn't supported with custom pricing providers.
  • When a Pricing Service Provider Plugin is installed, Calculate Price gets its response directly from the external provider instead of using Wix Bookings' standard pricing calculation logic.
  • Currently, you can't check whether a specific site is using a Pricing Service Provider Plugin before making API calls.

Use cases

Terminology

  • Base price: The fundamental price of a booking before additional taxes, fees, or charges are applied during the eCommerce checkout process. This is the price calculated by the Pricing API that serves as the foundation for the final customer charge.
  • Booking line item: A booking consists of separate line items for each service variant. For example, in a booking where a customer signs up for 1 child and 3 adults, there are 2 booking line items: one for the variant child with {"numberOfParticipants": 1} and another for the variant adult with {"numberOfParticipants": 3}.
  • Service choices: Custom choices that customers can select when booking a service, such as age groups or equipment types, each potentially having different pricing.
  • Varied Pricing: A pricing model that adjusts the cost of a service based on specific factors, such as the type of equipment booked or the customer's age. For example, seniors may receive a discount, while the business might charge more if its most experienced staff member provides the service.
  • Pricing Service Provider Plugin: An external service that completely overrides Wix Bookings' standard pricing logic. When installed, Preview Price fails and Calculate Price returns responses from the external provider instead of Wix's calculations.

For a comprehensive glossary of Wix Bookings terms, see Terminology.

Did this help?