跳转到内容
#0511
Containers

The rental API refuses to charge more than you approved

Procurement approved $275 for a 30-day server. The provisioning script sends max_charge_cents: 27500 with the rental request. If the listing's live total is still $275, the rental goes through, the General Balance is debited once, and an invoice is generated. If the price moved since the approval, the API returns 409 CHARGE_EXCEEDS_MAX and charges nothing. Leave the field out entirely and you get 409 CHARGE_CONFIRMATION_REQUIRED: also nothing charged.

The ceiling is the purchase order. The script can't round up, can't absorb a setup fee nobody saw, can't renew at a number nobody signed. Extensions work the same way: POST /api/v1/rentals/{id}/extend takes the ceiling too.

On a metered cloud, the approval is a forecast and the bill is the verdict. Here the approval is a parameter, and the API enforces it.

The purchase order is a field, and the server refuses to exceed it.