> ## Documentation Index
> Fetch the complete documentation index at: https://docs.alura.io/llms.txt
> Use this file to discover all available pages before exploring further.

# credits_exhausted

> API credits exhausted. HTTP 402, not retryable.

**HTTP 402: API credits exhausted.** Retrying the same request gives the same error. Errors never cost API credits.

The workspace has used its API credits for the month. The body adds `upgrade_url`, `credits_needed`, `credits_remaining` and `resets_at` (the start of the next month, UTC). Alura answers 402 rather than 429 so AI assistants do not retry it on their own.

**What to do:** Upgrade the plan or wait for the monthly reset.

```json Response theme={null}
{
  "type": "https://docs.alura.io/errors/credits_exhausted",
  "title": "API credits exhausted",
  "status": 402,
  "code": "credits_exhausted",
  "detail": "API credits exhausted",
  "suggestion": "Upgrade the plan or wait for the monthly reset.",
  "retryable": false,
  "request_id": "req_01JQ5W3H8M2N4P6R8T0V2X4Z6B"
}
```

The response is `application/problem+json` (RFC 9457) and has a `Request-Id` header with the same `request_id`. See [all errors](/api-reference/errors).


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.