Unkey · Schema
KeyCreditsRefill
Configuration for automatic credit refill behavior.
API KeysRate LimitingAuthenticationDeveloper PlatformAccess ControlIdentityAnalytics
Properties
| Name | Type | Description |
|---|---|---|
| interval | string | How often credits are automatically refilled. |
| amount | integer | Number of credits to add during each refill cycle. |
| refillDay | integer | Day of the month for monthly refills (1-31). Only required when interval is 'monthly'. For days beyond the month's length, refill occurs on the last day of the month. |
JSON Schema
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"$id": "#/components/schemas/KeyCreditsRefill",
"title": "KeyCreditsRefill",
"type": "object",
"description": "Configuration for automatic credit refill behavior.",
"properties": {
"interval": {
"type": "string",
"enum": [
"daily",
"monthly"
],
"x-speakeasy-unknown-values": "allow",
"description": "How often credits are automatically refilled.",
"example": "daily"
},
"amount": {
"type": "integer",
"format": "int64",
"minimum": 1,
"maximum": 9223372036854776000,
"description": "Number of credits to add during each refill cycle.",
"example": 1000
},
"refillDay": {
"type": "integer",
"minimum": 1,
"maximum": 31,
"description": "Day of the month for monthly refills (1-31).\nOnly required when interval is 'monthly'.\nFor days beyond the month's length, refill occurs on the last day of the month.\n",
"example": 15,
"x-go-type-skip-optional-pointer": true,
"x-go-type-skip-optional-pointer-with-omitzero": true
}
},
"required": [
"interval",
"amount"
],
"additionalProperties": false
}