# Discounts, minimums and caps

> The adjustments that modify a charge calculation, the exact order in which they apply and the base on which tax is calculated.

Source: https://app.relvoerp.com/docs/product/en/commitments-discounts/

A contract rarely bills list price. Relvo has three adjustments, and the result depends on the order in which they apply — which is why that order is fixed and not configurable.

## Calculation order

```
1. Usage aggregation
2. Usage discount          → reduces the QUANTITY
3. Pricing model           → adjusted quantity to AMOUNT
4. Amount or % discount    → reduces the SUBTOTAL
5. Minimum                 → true-up if the subtotal fell below the floor
6. Cap                     → trim if the subtotal exceeded the ceiling
7. Taxes                   → on the already-adjusted subtotal
```

> **Key rule: All adjustments are pre-tax**
>
> Discounts, minimums and caps operate on the subtotal before taxes. Tax is calculated on the **already-adjusted** subtotal, never on the original amount.
>
> With a USD 1,000 charge, a USD 100 discount and 19% VAT (IVA): subtotal USD 900 → VAT USD 171 → total USD 1,071. **Not** USD 1,000 − 100 + VAT on 1,000.

## Discounts

| Type | What it acts on | When it applies | Scope |
| --- | --- | --- | --- |
| **Usage** | The measured quantity | Before pricing | Exactly one charge |
| **Amount** | The subtotal | After pricing | One or more charges |
| **Percentage** | The subtotal | After pricing | One or more charges |

### Usage discount

Reduces the billable units before the pricing model sees them. With 100 calls and a discount of 10, 90 are billed — and those 90 run through the pricing tiers as usual.

It is the right tool for promotional free units or for absorbing usage that has already been committed.

### Amount discount

Subtracts a fixed amount from the subtotal. **It never makes the charge negative**: the discount is limited to the charge amount. A USD 500 discount on a USD 300 charge reduces it to zero, not to −200.

### Percentage discount

Reduces the subtotal by a proportion. 10% off USD 1,000 leaves USD 900.

> **Key rule: One discount per charge, per phase**
>
> A given charge does not stack two discounts in the same phase. If the commercial agreement combines several, express it as the resulting net discount. Relvo rejects the ambiguous configuration instead of deciding for you in what order to stack them.

> **Shortcut: A usage discount is not the same as free units**
>
> Free units (`free_units`) are part of the **charge** definition and are always deducted. A usage discount is a **contract** adjustment, negotiated with a specific customer and visible as such. Commercially they are different things, and keeping them separate lets you answer "how much did we discount this customer?" without taking the pricing apart.

## Minimums

A minimum guarantees a billing floor. If the period's charges fall below that floor, a **true-up** for the difference is added.

```
true_up = max( minimum_amount − billed_amount, 0 )
```

The minimum applies to the set of charges it covers — not charge by charge — and is evaluated in each period of those charges.

**Example: A slow month under a minimum commitment**

Monthly minimum of USD 1,000. The customer used USD 620 and has a 10% discount on usage.

| Step | Amount |
| --- | --- |
| Priced usage | USD 620.00 |
| 10% discount | − USD 62.00 |
| Subtotal before minimum | USD 558.00 |
| True-up to the minimum | + USD 442.00 |
| **Billable subtotal** | **USD 1,000.00** |
| VAT 19% | USD 190.00 |
| **Total** | **USD 1,190.00** |

The true-up comes in **after** the discount. If it came in before, the discount would eat into the committed floor and the minimum would protect nothing.

The true-up can be shown as a separate line on the invoice or consolidated into the charge. It is a presentation decision: the invoiced amount is the same. Showing it separately is usually preferable, because the customer sees why their invoice does not match their usage.

## Caps

A cap limits the amount for a period. If the charges exceed the ceiling, the ceiling is billed.

```
billable = min( billed_amount, maximum_amount )
```

The excess **does not carry over** to the next period: it is discarded. That is what makes the cap a real protection for the customer rather than a deferral of the charge.

> **Key rule: The cap can never be lower than the minimum**
>
> Relvo validates that `cap ≥ minimum` when the phase is saved. A contract with a USD 1,000 floor and a USD 800 ceiling describes no possible agreement, and it is rejected at configuration time instead of producing unpredictable amounts at invoicing.

**Example: Minimum and cap on the same charge**

Minimum USD 500, cap USD 1,000.

| Priced usage | After the minimum | After the cap | Billed |
| --- | --- | --- | --- |
| USD 300 | USD 500 (true-up +200) | USD 500 | **USD 500** |
| USD 700 | USD 700 | USD 700 | **USD 700** |
| USD 1,500 | USD 1,500 | USD 1,000 (−500) | **USD 1,000** |

## Revenue impact

The amount recognized is the pre-tax billable amount: a minimum's true-up is recognized as revenue in the same period, and the excess trimmed by a cap does not exist as revenue.

- [Charges and pricing](https://app.relvoerp.com/docs/product/en/pricing.md): The six pricing models and their formulas.
- [Contracts and phases](https://app.relvoerp.com/docs/product/en/contracts.md): Where adjustments live and how they change between phases.
- [Reporting and metrics](https://app.relvoerp.com/docs/product/en/reporting.md): How adjustments show up in revenue analysis.
