Billing Summary
Query your quota and usage summary.
GET /api/user/billing/summary
Returns your current user-level quota summary including total quota, used quota, and remaining quota. This endpoint requires authentication.
Parameters#
No request body is required.
| Parameter | Type | Required | Description |
|---|---|---|---|
| None | — | — | This is a GET request with no query parameters required. |
Authentication#
This route accepts either:
- a dashboard login session, or
- a Bearer token in the
Authorizationheader
In both cases, the response is calculated for the authenticated account user. It is not a per-token usage breakdown.
Response#
{
"success": true,
"message": "",
"data": {
"total_quota": 1000000,
"used_quota": 250000,
"remaining_quota": 750000
}
}| Field | Type | Description |
|---|---|---|
success | boolean | Whether the request was successful. |
message | string | Additional information message. |
data.total_quota | number | Total quota allocated to your account. |
data.used_quota | number | Total quota consumed. |
data.remaining_quota | number | Remaining available quota. |
Example Requests#
cURL#
curl https://ai.pofano.com/api/user/billing/summary \
-H "Authorization: Bearer YOUR_API_KEY"Python#
import requests
response = requests.get(
"https://ai.pofano.com/api/user/billing/summary",
headers={
"Authorization": "Bearer YOUR_API_KEY"
}
)
print(response.json())Notes#
- This endpoint is part of the account API surface under
/api/user/**, not the OpenAI-compatible relay surface. - If the authenticated user context is invalid, the server can return a standard error response such as
{ "success": false, "message": "invalid user" }.
Pofano