Checking API usage and balance
Manage your Muzaic API usage and view your current monthly balance via the /accountDetails endpoint.
Using accountDetails endpoint
Returns detailed information about the API account
Account details retrieved successfully
123My API AccountRemaining tokens in account
1000Tokens used this period
500Account plan type
premiumAccount expiration date
2024-12-31T23:59:59ZAccount creation date
2024-01-01T00:00:00ZUnauthorized
Account not found
GET /accountDetails HTTP/1.1
Host: m10.muzaic.ai
MuzaicAPI-Secret-Key: YOUR_API_KEY
Accept: */*
{
"accountId": 123,
"name": "My API Account",
"tokensRemaining": 1000,
"tokensUsed": 500,
"plan": "premium",
"expiresAt": "2024-12-31T23:59:59Z",
"createdAt": "2024-01-01T00:00:00Z"
}Response handling
When making a request to an endpoint, you can retrieve several pieces of information:
apiVersion: Indicates the current version of the Muzaic API.secretKey: The user's secret key for authentication.freeTokensAvailable: Shows if there are free tokens available (greater than 0) for the account holder.totalUsedTokens: Provides information on the lifetime usage of tokens.currentBalance: Helps estimate the cost for the next billing cycle.
Example response
Last updated
Was this helpful?