API Reference
Credits API
Read your Kensa credit balance and credit transaction history with the API.
Every generation costs credits. When a generation starts, its price is reserved (frozen). It is charged when the video completes and returned if the generation fails. Credits that expire soonest are used first. Prices per model are on AI Models.
All paths are relative to https://www.kensa.cc/api/v1 and need an API key (see API Overview).
Get your balance
GET /credit/balance{
"success": true,
"data": {
"availableCredits": 2452,
"frozenCredits": 13,
"usedCredits": 400,
"totalCredits": 2865,
"expiringSoon": 0,
"plan": "BUSINESS"
}
}| Field | Description |
|---|---|
availableCredits | Credits you can spend now |
frozenCredits | Credits reserved for generations that are still running |
usedCredits | Credits already charged from your current credit packages |
totalCredits | Credits granted in your current credit packages |
expiringSoon | Available credits that expire within 7 days |
plan | Your plan: FREE, BASIC, PRO or BUSINESS (Ultimate) |
The response also includes your subscription's activeProductId, subscriptionStatus and currentPeriodEnd.
Get your transactions
GET /credit/history?limit=20&offset=0| Parameter | Default | Description |
|---|---|---|
limit | 20 | Transactions per page |
offset | 0 | Number of transactions to skip; pass the previous page's nextCursor |
type | Only one type: NEW_USER, ORDER_PAY, SUBSCRIPTION, VIDEO_CONSUME, REFUND, EXPIRED or SYSTEM_ADJUST |
{
"success": true,
"data": {
"transactions": [
{
"id": "1024",
"userId": "usr_123",
"credits": -13,
"balanceAfter": 2452,
"transType": "video_generate",
"videoUuid": "vid_V1StGXR8_Z5jdHi6B-myT",
"remark": null,
"createdAt": "2026-09-28T10:03:00.000Z"
}
],
"total": 57,
"hasMore": true,
"nextCursor": "20"
}
}Transactions are sorted newest first. In the response, transType is lowercase:
transType | Filter value | Meaning |
|---|---|---|
new_user | NEW_USER | Free credits for a new account |
order_pay | ORDER_PAY | Credit pack purchase |
subscription | SUBSCRIPTION | Credits from a subscription |
video_generate | VIDEO_CONSUME | Credits charged for a generation |
video_refund | REFUND | Credits returned |
expired | EXPIRED | Credits that expired |
admin_adjust | SYSTEM_ADJUST | Manual adjustment by Kensa |