The Retrieve credit
endpoint allows you to check the total amount of credit available and how much has been used. This is useful for monitoring your API usage and ensuring you have sufficient credit for future tasks.
API Endpoint
To retrieve your credit information, send a GET
request to the following URL:
GET https://api.genaifactory.ai/v1/credit
Headers
Ensure that your request includes the following header:
Name
Type
Required
Description
formacloud-api-key
string
Yes
API key required for authenticating your request.
Response Body
The response will provide details about your credit usage:
Name
Type
Required
Description
total_credit
number
Yes
The total amount of credit allocated for tasks.
used_credit
number
Yes
The amount of credit used by tasks.
Example Request
Example Response
Success Response (Status Code 200)
Failure Response (Status Code 4XX)