# Give product for free if the cart value is above $X

We have covered a slightly more elaborate set of examples on the video to better illustrate some concepts.&#x20;

{% embed url="<https://drive.google.com/file/d/1fq6lM9Ork_iMZfEKNl9bNCjkJ9DYPBhM/view?usp=sharing>" %}

Let's assume the case where you would want to give a product in the user's cart for free when the total value of the cart is above a certain threshold. Here's how you would build that using the Dollar Discounts rule builder.

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

{% hint style="info" %}
Notice how we have set the then condition to check for the line quantity = 1, this is to ensure that the discount is only applied to that particular vairant only if it has a single quantity in the cart. \
\
This way you can limit discount abuse and prevent your discount from being exploited. You can also leverage discount / line application strategies to add further limits.
{% endhint %}


---

# Agent Instructions: 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:

```
GET https://help.dollarlabs.io/dollarlabs-ultimate-discounts/discount-engine-v1/examples-v1/product-discount-examples-v1/give-product-for-free-if-the-cart-value-is-above-usdx.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
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.
