Query User Balance
Query the current credit balance of your user account in real-time.
Use Cases
Dashboard Display
Show real-time account balance in your application dashboard
Balance Alerts
Set up notifications when credits fall below a threshold
Recharge Reminders
Prompt users to top up credits before running out
Usage Tracking
Monitor credit consumption and track spending patterns
Important Notes
Real-time Balance: The balance returned reflects your current credit amount at the time of the request.
Rate Limiting: Avoid excessive polling. Cache the balance and refresh only when necessary (e.g., after completing a generation task).
Credit Deduction: Credits are deducted only when generation tasks complete successfully. Failed tasks do not consume credits.
All API endpoints require Bearer Token authentication
Get your API Key:
Visit the API Key Management Page to get your API Key
Add it to the request header:
Authorization: Bearer YOUR_API_KEY
Balance retrieved successfully