Credit

As of · 0 account(s) · undefined cannot place a call right now · node node-a

Prepaid stops at zero

Money already paid in. Reserved is what is set aside for calls that are up but not yet billed — that is what stops a hundred simultaneous calls from each spending the same balance. When available reaches zero, new calls get 402 and calls in progress are cut off by a timer set when they were answered.

No prepaid accounts.

Postpaid stops at the credit limit

Money not yet paid. Unbilled is what has been spent since the cycle started. When the limit is reached, new calls get 403 — and calls already in progress keep running, because that is what a credit limit means. A limit of zero means no calls at all, not unlimited.

No postpaid accounts.

Hourly spend cap

The only control that acts in real time, and the only thing that protects a postpaid account from a stolen password. It counts money reserved, not money billed, so it bites while an attack is happening rather than minutes later when the calls are rated.

No account has an hourly spend cap.
A credit limit is a month of exposure. A stolen account spends a month's limit in an afternoon, and for a postpaid account this cap is the only control that acts in real time. Set customers.spend_cap_hour.

Refreshes every 20 seconds. On the command line: make credit-check, make credit-refused.