Lists billing active and inactive alerts
Parameters
- alert_
typeenum Filter results to only include this type of alert.
Possible enum valuesusage_
threshold Use
usage_
if you intend for an alert to fire when a usage threshold on a meter is crossed.threshold - meterstring
Filter results to only include alerts with the given meter.
More parameters
- ending_
beforestring A cursor for use in pagination.
ending_
is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting withbefore obj_
, your subsequent call can includebar ending_
in order to fetch the previous page of the list.before=obj_ bar - limitinteger
A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- starting_
afterstring A cursor for use in pagination.
starting_
is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending withafter obj_
, your subsequent call can includefoo starting_
in order to fetch the next page of the list.after=obj_ foo
Returns
Returns a list of billing alerts
{ "data": [ { "id": "alrt_12345", "object": "billing.alert", "title": "API Request usage alert", "livemode": true, "alert_type": "usage_threshold", "usage_threshold": { "gte": 10000, "meter": "mtr_12345", "recurrence": "one_time" }, "status": "active" }, { "id": "alrt_67890", "object": "billing.alert", "title": "API Request usage alert", "livemode": true, "alert_type": "usage_threshold", "usage_threshold": { "gte": 120, "meter": "mtr_67890", "recurrence": "one_time" }, "status": "active" } ]}