# Order within a budget

- Sentence the person signs: Order quote:Q-1042: 1180.00 EUR
- Kind of approval: Act for a company
- Who decides: A buyer at Initech
- Service: Umbrella Supply, a wholesaler
- Level: L2
- Capability: supply:order
- State: Live on the demo, with simulated identity

Initech's buyer wants office paper at contract price. The buyer's agent can compare quotes all day. Placing the order commits the company, and the wholesaler needs to know that the buyer may do that.

## The limits that apply

| Limit | Set by | Value on the demo |
|---|---|---|
| What a buyer may approve | Initech, in the buyer's signed mandate | Up to 15 000 EUR per order |
| What Initech may order | Umbrella, in Initech's customer settings | 12 000 EUR per month |
| How strong the identity must be | Umbrella, on the order route | Level 2 |

Each limit is checked by the side that set it. Neither side needs an account in the other's systems.

## What happens

1. The buyer joins Initech's organisation with a passkey. The company signs a mandate tied to that passkey, valid 30 days.
2. The agent asks for quotes. This is a reversible write at level 1.
3. The agent places the order. Umbrella answers `401` with a sentence naming the quote and the amount.
4. On the approval page, the buyer chooses "For Initech SA (Buyer)" and signs.
5. Umbrella checks the buyer's signature, Initech's mandate and the monthly budget, then accepts the order.

## What cannot happen

- **An order above the mandate.** The approval page says what the mandate does not allow.
- **A slow overspend.** Orders count against the monthly budget. The order that passes it is refused with `budget_exceeded`.
- **An order from a leaver.** Removing the person from the directory revokes every approval they gave for the company.

Initech's account requires a company mandate. To try the flow without one, order for Hooli, whose buyers approve as themselves. The quote and the amount in the sentence above are illustrative.

Source: https://allowedby.com/use-cases/purchase-orders
