> To build or manage a Wix site with an AI agent, follow https://www.wix.com/headless/skill.md
> It builds a new Wix site or puts your own site online, from a prompt, and keeps changing it afterwards. The pages are code in any web technology, and Wix runs the backend.
> It works through the Wix plugin (the Wix MCP and the Wix skills), the Wix CLI or no Wix login, and puts the site live on Wix hosting or on another host.
> Business features include a store, bookings, events and tickets, a restaurant, a blog, forms, members and many more.
> Read the Wix skills online at https://www.wix.com/skills
> 
> Portal Navigation:
> 
> - Append `.md` to any URL under `https://dev.wix.com/docs/` to get its markdown version.
> - Pages are either content pages (article or reference text) or menu pages (a list of links to child pages).
> - To get a menu page, truncate any URL to a parent path and append `.md` (e.g. `https://dev.wix.com/docs/sdk.md`, `https://dev.wix.com/docs/sdk/core-modules.md`).
> - If a reference page seems to be missing its schema (parameters, return types, or type definitions), append `?schema=true` to its `.md` URL (e.g. `https://dev.wix.com/docs/contexts/contexts/stores/category-info/use-category-info-context.md?schema=true`).
> - Top-level index of all portals: https://dev.wix.com/docs/llms.txt
> - Full concatenated docs: https://dev.wix.com/docs/llms-full.txt

## Resource: Sample Flows

## Article: Sample Flows

## Article Link: https://dev.wix.com/docs/api-reference/business-solutions/bookings/policies/booking-policy-service-plugin/sample-flows.md

## Article Content:

# Booking Policy Service Plugin: Sample Flows

This article presents possible use cases and corresponding sample flows that you can support. It provides a useful starting point as you plan your implementation.

## Limit early bookings

Your custom booking app could prevent customers from booking more than 7 days in advance. The app implements the Booking Policy service plugin to enforce this limit.

1. A customer visits the booking page to view available times.
1. Wix calls your implementation of [List Booking Policies](invalid-url) with the relevant service IDs.
1. Your implementation returns a policy with `limitEarlyBooking.enabled` set to `true` and `limitEarlyBooking.earliestBookingInMinutes` set to `10080` (7 days).
1. Wix calculates which time slots violate this policy and populates the `bookingPolicyViolations` property.
1. The booking calendar displays only time slots within the 7-day window as available.

## Allow booking up until session start

A fitness studio wants to allow customers to book classes until the exact start time. Your app implements the Booking Policy service plugin to disable late booking restrictions.

1. A customer visits the class schedule to book an upcoming class.
1. Wix calls your implementation of [List Booking Policies](invalid-url) with the class service IDs.
1. Your implementation returns a policy with `limitLateBooking.enabled` set to `false`.
1. Wix calculates time slot availability without late booking restrictions.
1. The booking calendar allows customers to book any class that hasn't started yet.

## Disable online booking for specific services

A salon offers certain premium services that require phone booking only. Your app implements the Booking Policy service plugin to disable online booking for these services.

1. A customer browses the salon's services.
1. Wix calls your implementation of [List Booking Policies](invalid-url) with the service IDs.
1. For premium services, your implementation returns a policy with `onlineBooking.enabled` set to `false`.
1. Wix marks these time slots with a policy violation.
1. The booking calendar indicates that online booking is unavailable for premium services.