fashn-logo
FASHNAI

Credits Balance

The Credits endpoint allows you to retrieve your current FASHN API credits balance. The response includes your total credits, the on-demand credits you've purchased, and any credits from an existing API plan.

Credit Usage
  • On-Demand Credits: Credits you buy on demand from Billing
  • Subscription Credits: Credits from an existing API plan, if your account has one
  • Total Credits: Combined balance of subscription + on-demand credits

Request

Check your current credits balance by making a GET request to the credits endpoint:

GEThttps://api.fashn.ai/v1/credits

Call this endpoint whenever you need to know how many credits you have remaining.

Request Examples

curl -X GET https://api.fashn.ai/v1/credits \
     -H "Authorization: Bearer YOUR_API_KEY"

Response

Example response payload

{
  "credits": {
    "total": 234,
    "subscription": 100,
    "on_demand": 134
  }
}

Response Fields

creditsobject

Container object for all credit information.

totalinteger

Your total available credits (subscription + on-demand credits combined).

subscriptioninteger

Credits from an existing API plan. These credits reset monthly based on the plan's billing cycle. The value is 0 if your account has no active API plan.

on_demandinteger

Credits you bought on demand. If you also have subscription credits, those are used first.

Rate Limits

The credits endpoint has its own specific rate limit:

EndpointLimit
/v1/credits30 requests per 10 seconds

For other endpoints, see the default rate limits in API Fundamentals.

On this page