Create Grant
Create a grant directly for a metered entitlement, crediting the customer’s balance immediately. The entitlement must belong to an active v1 subscription.
Authorizations
API key authentication
Path Parameters
The unique identifier of the entitlement
^ent_[a-zA-Z0-9]+$Body
The number of credits to grant.
Idempotency key to prevent duplicate grants. Must be unique per entitlement.
255When the grant becomes effective. Defaults to now.
When the grant expires. If omitted, the grant does not expire.
Maximum balance carried over at the entitlement's reset boundary. If omitted, the entire balance rolls over until consumed or expired. Set to 0 to discard any remaining balance at each reset. Ignored when the target entitlement has no usagePeriod (one-time entitlement) — one-time entitlements have no reset boundary, so this field has no effect.
0 <= x <= 999999999999Minimum balance at the entitlement's reset boundary; balances below this are floored up. Defaults to 0 (no floor). Ignored when the target entitlement has no usagePeriod (one-time entitlement).
0 <= x <= 999999999999Response
Grant successfully created.
grant Unique identifier for the grant.
^grt_[a-zA-Z0-9]+$The entitlement this grant belongs to.
^ent_[a-zA-Z0-9]+$The number of credits granted.
When the grant becomes effective.
When the grant was created.
The recurrence interval (ISO 8601 duration) if this is a recurring grant. Null for one-time grants.
The idempotency key used when creating this grant. Null if not provided.
When the grant expires. Null means no expiration.
When the grant was voided. Null means the grant is active.
Maximum balance carried over at the entitlement's reset boundary. A value of 999999999999 represents effectively unlimited rollover (the default for direct and purchase grants). A value of 0 means any remaining balance is discarded at each reset.
Minimum balance at the entitlement's reset boundary; balances below this are floored up. 0 means no floor.