Skip to content

Adjust build credits

POST
/admin/customers/{id}/build-credits
curl --request POST \
--url https://api.reflexdb.cloud/v1/admin/customers/2489E9AD-2EE2-8E00-8EC9-32D5F69181C0/build-credits \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{ "amount": 1, "reason": "example", "expiresAt": "2026-04-15T12:00:00Z" }'

Admin only — grant or deduct build credits for a customer. Positive amount adds bonus credits above the plan limit; negative amount reduces them.

id
required
string format: uuid

Customer ID

Media type application/json
object
amount
required

Credits to add (positive) or remove (negative). Must be non-zero.

integer
reason

Optional reason for the adjustment

string
expiresAt

Optional expiration date (ISO 8601). Expired adjustments stop counting.

string format: date-time
Example generated
{
"amount": 1,
"reason": "example",
"expiresAt": "2026-04-15T12:00:00Z"
}

Default Response

Media type application/json
object
id
required
string format: uuid
customerId
required
string format: uuid
amount
required
integer
reason
string
nullable
expiresAt
string format: date-time
nullable
totalAdjustment
required

Net non-expired adjustment across all entries for this customer

integer
Example generated
{
"id": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0",
"customerId": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0",
"amount": 1,
"reason": "example",
"expiresAt": "2026-04-15T12:00:00Z",
"totalAdjustment": 1
}

Default Response

Media type application/json
Error
object
error
required
string
message
string
Example generated
{
"error": "example",
"message": "example"
}

Default Response

Media type application/json
Error
object
error
required
string
message
string
Example generated
{
"error": "example",
"message": "example"
}