Parameters
1 query
Query parameters
· 1customerIdstringRequiredContact external ID.
abc123def456ghijReturns the customer's unspent credits sliced into buckets by their expiration date. FIFO-aware: each bucket reports only what is still unspent of the underlying source credit(s), not the original face value. Buckets are ordered: overdue first (past expiration but not yet processed by the cron), then by date ascending, never-expires last. A non-zero outstandingDebt reports a negative running balance that has not yet been paid off.
1 query
customerIdstringRequiredContact external ID.
abc123def456ghij1 status code documented
totalAmountnumberRequiredSum of all buckets — matches shop__contact.credit when outstandingDebt is 0.
363677totalAmountMoneynumberRequiredSum of all bucket money values.
363677outstandingDebtnumberRequiredUnpaid debt not yet absorbed by a positive credit. > 0 means the customer is in the red.
00currencystringRequiredISO 4217 code of the organisation default currency used for all *Money fields.
CZKbucketsobject[]RequiredBuckets ordered: overdue first, then by date ascending, never-expires last.
expirationDatestring | nullRequiredCalendar date when the credits in this bucket expire. null = bucket holds credits with no scheduled expiration.
YYYY-MM-DD calendar date.
2026-06-13overduebooleanRequiredTrue when the expiration date is in the past but the cron has not yet processed it. The next cron tick will sweep these.
falsefalseamountnumberRequiredTotal unspent credits in this bucket.
36amountMoneynumberRequiredTotal money value in this bucket (scaled proportionally).
36sourcesobject[]RequiredcreditIdnumberRequiredInternal id of the source credit.
8422creditExternalIdstringRequiredExternal (16-char) id of the source credit — link target for drill-down.
4L0jcnkzA8SPW1gEoriginalAmountnumberRequiredFace value of the source credit before any FIFO consumption.
300amountnumberRequiredUnspent portion of the source credit contributed to this bucket.
36amountMoneynumberRequiredMoney value scaled proportionally to amount.
36expirationAtstring | nullRequiredExact expiration timestamp of the source credit. null when the bucket is the never-expires bucket.
Exact ISO timestamp of the source credit expiration.
{
"totalAmount": 36,
"totalAmountMoney": 36,
"outstandingDebt": 0,
"currency": "CZK",
"buckets": [
{
"overdue": false,
"amount": 36,
"amountMoney": 36,
"sources": [
{
"creditId": 8422,
"creditExternalId": "4L0jcnkzA8SPW1gE",
"originalAmount": 300,
"amount": 36,
"amountMoney": 36
}
]
}
]
}GET /bff/contact-credit/expiration-breakdown
curl -X GET "https://api.bizkithub.com/bff/contact-credit/expiration-breakdown?customerId=abc123def456ghij" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer YOUR_API_KEY"All BizKitHub public API endpoints require authentication via API key.