Skip to main content

When this fires

The async usage processor watches every credit deduction. When a batch of usage moves the remaining credits (plan plus purchased) from above to at-or-below 10% of the credits granted at the last period reset, this event fires once. It does not re-fire while the balance stays low, and the next period reset re-arms it. If a single burst of usage jumps straight past zero, only credits.depleted fires. Use it to prompt the customer to buy a credit pack before they hit zero.

Body

application/json
id
string
required
event
string
required
Allowed value: "credits.low"
timestamp
string
required
organizationId
string
required
mode
enum<string>
required
Available options:
live,
sandbox
apiVersion
string
required
data
object
required

Response

200

Return any 2xx status code to acknowledge receipt of the event.