> For the complete documentation index, see [llms.txt](https://docs.yoplanning.support/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.yoplanning.support/en/yoplanning-academy/yoplanning-parametrage/tarifs-gestion-et-parametrage/module-marketing-dans-yoplanning/creer-une-regle-de-panier.md).

# Create a shopping cart rule

### What is the purpose of this feature?

The shopping cart rule allows you to **automatically offer a targeted promotion** when a customer adds one or more products to their cart. It is visually displayed in the cart with a call-to-action button to encourage purchase.

Example :

> “Add a stand-up paddle rental at -50%” → The customer clicks on *Take advantage of this offer* and adds the option with the defined discount.

It's a powerful tool for increasing average order value and implementing **smart cross-selling**.

***

### How do I access the feature?

1. Log in to Yoplanning.pro.
2. In the left menu, click on `Configuration`.
3. Select `Booking Module`.
4. Click on `Shopping cart rules`.

### Steps to create a shopping cart rule

1. **Click on "Add a rule"**.
2. **Rule name**: choose an internal name (not visible to clients).
3. **Condition of application**:
   * Select one or more **trigger products** (products which, once in the cart, will activate the rule).
   * Optional: define a minimum quantity.
   * ⚠️ Important: The quantity refers to the **number of sessions** and not the number of people. For example, if a customer adds **two paddleboarding lessons to their basket**, the rule may be triggered, even if it's for only one person.
4. **Marketing action**:
   * Select the **beneficiary product** (the one that will benefit from the discount).
   * Choose the **type of promotion** (e.g., -50%).
   * ⚠️ If the discount is in **euros** (and not a percentage), be careful: it could result in a **negative final price** if the discount value is higher than the product price. We recommend testing each rule before publishing.
5. **Message displayed to the customer**:
   * Write a short, compelling sentence. Example: "Add a half-price SUP rental to complement your activity!"
6. **Save the rule**.

***

### What the customer sees

As soon as the triggering product is added to the cart, the customer sees a notification appear in the cart:

* ✅ Message type: *"Promotions are available!"*
* 🏷️ Offer details: 50% off SUP rentals
* 🔘 Clickable button: \&#xNAN;*"Take advantage →"* which directly adds the promotional product to the cart.

***

### Best practices

* Use a **clear** and persuasive message.
* Offer **logically complementary** products (cross-selling).
* Don't overload the interface with too many rules running in parallel.
* Test the rule in the booking module to see the rendering on the client side.

### Common problems

| Issue                             | Solution                                                               |
| --------------------------------- | ---------------------------------------------------------------------- |
| The rule is not activated         | Check that the trigger product is in the cart                          |
| The "Enjoy" button is not working | Make sure the beneficiary product is active and sold online            |
| The discount does not apply       | Check the discount settings in the rule (type, percentage, conditions) |


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.yoplanning.support/en/yoplanning-academy/yoplanning-parametrage/tarifs-gestion-et-parametrage/module-marketing-dans-yoplanning/creer-une-regle-de-panier.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
