Attributes
- idstring
Unique identifier for the object.
- objectstring
String representing the object’s type. Objects of the same type share the same value.
- amountobject
Amount of this credit grant.
- amount.
monetarynullable object The monetary amount.
- amount.
monetary. currencystring Three-letter ISO currency code, in lowercase. Must be a supported currency.
- amount.
monetary. valueinteger A positive integer representing the amount.
- amount.
typeenum The type of this amount. We currently only support
monetary
billing credits.Possible enum valuesmonetary
The amount is a monetary amount.
- applicability_
configobject Configuration specifying what this credit grant applies to. We currently only support
metered
prices that have a Billing Meter attached to them.- applicability_config.
scopeobject Specify the scope of this applicability config.
- applicability_config.
scope. price_ typenullable enum The price type that credit grants can apply to. We currently only support the
metered
price type. This refers to prices that have a Billing Meter attached to them. Cannot be used in combination withprices
.Possible enum valuesmetered
Credit grants being created can only apply to metered prices.
- applicability_config.
scope. pricesnullable array of objectsPreview feature The prices that credit grants can apply to. We currently only support
metered
prices. This refers to prices that have a Billing Meter attached to them. Cannot be used in combination withprice_
.type - applicability_config.
scope. prices. idnullable string Unique identifier for the object.
- categoryenum
The category of this credit grant. This is for tracking purposes and isn’t displayed to the customer.
Possible enum valuespaid
The credit grant was purchased by the customer for some amount.
promotional
The credit grant was given to the customer for free.
- createdtimestamp
Time at which the object was created. Measured in seconds since the Unix epoch.
- customerstringExpandable
ID of the customer receiving the billing credits.
- effective_
atnullable timestamp The time when the billing credits become effective-when they’re eligible for use.
- expires_
atnullable timestamp The time when the billing credits expire. If not present, the billing credits don’t expire.
- livemodeboolean
Has the value
true
if the object exists in live mode or the valuefalse
if the object exists in test mode. - metadataobject
Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format.
- namenullable string
A descriptive name shown in dashboard.
- prioritynullable integerPreview feature
The priority for applying this credit grant. The highest priority is 0 and the lowest is 100.
- test_
clocknullable stringExpandable ID of the test clock this credit grant belongs to.
- updatedtimestamp
Time at which the object was last updated. Measured in seconds since the Unix epoch.
- voided_
atnullable timestamp The time when this credit grant was voided. If not present, the credit grant hasn’t been voided.
{ "id": "credgr_test_61R9a6NUWsRmOW3RM41L6nFOS1ekDGHo", "object": "billing.credit_grant", "amount": { "monetary": { "currency": "usd", "value": 1000 }, "type": "monetary" }, "applicability_config": { "scope": { "price_type": "metered" } }, "category": "paid", "created": 1726620803, "customer": "cus_QrvQguzkIK8zTj", "effective_at": 1729297860, "expires_at": null, "livemode": false, "metadata": {}, "name": "Purchased Credits", "priority": 50, "test_clock": null, "updated": 1726620803, "voided_at": null}