~singpolyma/sgx-jmp

ref: 48adae14cdd37c6b74b5b04bae279823fa85fd43 sgx-jmp/lib/call_attempt.rb -rw-r--r-- 2.3 KiB
Try auto top up / low balance notify when not enough balance for a call

There is an edge case where a customer might not have auto-topped up yet but
they don't have enough balance for this call, so try to charge their card first
before telling them the call is a no go.
Also supports limits on inbound calls
Outbound call logic for overages

If cannot find an acceptable rate for the number, cannot call.
If balance is too low, cannot call.
If too close to limit, warn.
Else, call.