> For the complete documentation index, see [llms.txt](https://penida.gitbook.io/cowlendar-help/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://penida.gitbook.io/cowlendar-help/how-to.../how-to-use-advanced-service-settings-booking-rules.md).

# How to use advanced service settings (Booking Rules)?

{% hint style="warning" %}
This feature requires a bit of thinking and planning before settings up. You will want to be clear on how you want service limits to affect each other and possible "edge cases".
{% endhint %}

### Why would i want apply specific "Booking rules" in Cowlendar?

You might be offering two services which use the same room in your building. This means that if Service 1 is booked then Service 2 should automatically close out because now the room will be used for Service 1.&#x20;

You almost might still want to accept more booking on Service 1 while still keeping Service 2 closed. Which means a global limit of 1 per time slot will not work.

Thankfully due to Cowlendar latest advanced settings which allows the incorporation of "special rules" this can be accomplished!

<figure><img src="/files/ByGvFmWDkhnPXCqWV0FW" alt=""><figcaption></figcaption></figure>

How would a service rule between Service A and Service B in Cowlendar work?

Lets assume that from the screenshot above Plants for all is Service A and Business Coaching With Me is Service B.

#### In the rule we state:

* If there is 1 booking made in a timeslot of Service 1 then close that timeslot in Service 2 while still keeping the timeslot open in Service 1 until it's own limit is reached.

<figure><img src="/files/yvTzPY2fg7ujghy245DF" alt=""><figcaption></figcaption></figure>

* If you want this rule to be enabled both ways then toggle on "Share the same rule in both directions".
* This means if Service 1 has a limit of 20 then 19 people can still book but Service 2 is closed because of this rule.

### Steps to create booking rules in Cowlendar:

1. In your Shopify admin dashboard look for at the left hand panel and click on the **Apps** tab.
2. Click on **Cowlendar.**
3. Click on **Settings.**
4. Click on **Advanced Settings.**

<figure><img src="/files/TPmv2jhWme4an9yiNmn6" alt=""><figcaption></figcaption></figure>

### Booking rules explained:

* **Booking rule type:**
  * Service Rule: Select this if you want to impact the availiability of a service based on the bookings of another service.
    * So if Service 1 is booked then impact the availability of Service 2 based on rule.
  * Team member rule: Select this if you want to impact the availability of a teammate based on the bookings of another teammate.
    * So if Teammate A is booked impact the availability of Teammate B based on rule.
* Service 1 / Service 2 or Teammate 1 / Teammate 2:
  * These are the two services or teammates you want to have a rule between.
* Share the same rule in both directions:
  * Select this if you want the rule to be applied from A -> B and also B -> A
* Rule
  * Number of Bookings:
    * Determines how many books will trigger the rule
  * Count bookings by:
    * Timeslot or Calendar dates

{% hint style="warning" %}
Understand the overall rule is to close based on X limit. You can play around with this to make this as dynamic as possible.
{% endhint %}
