API reference · Credits
This account's low balance line
GET/api/account/low-balanceSigned in session
The personal balance against the account's own line. Falling under it sends the credits.low_balance webhook event once; it re-arms when a deposit lifts the balance back to the line. Holds are not counted.
Answer 200
The line and where the balance stands.
| Field | Type | What it is |
|---|---|---|
| thresholdMicros | integer or null | The line, or null when none is set. |
| funded | boolean | False for an account on the house allowance, which has no balance to fall. |
| balanceMicros | integer or null | The settled balance, holds excluded; null when not funded. |
| low | boolean | The balance is under the line right now. |
| armed | boolean | The next fall below the line will send credits.low_balance. |
| firedAt | integer or null | |
| shortfallMicros | integer | What brings the balance back to the line, rounded up to the cent. |
| topUpPath | string | /billing/top-up, with ?amount= set to the shortfall when there is one. |
Errors
- 401OpenAI shaped error.
Every error answers in one shape, with its type, code and the field it names. The whole list is in the docs' Errors section.