Amux AI

sub2api Format

Last updated October 29, 2026

Compatible with the sub2api usage API, for new-api instances connected as a "Sub2API" channel and tools such as cc-switch.

Compatible with the sub2api usage API. Used in the following cases:

  • channel balance queries from new-api when this platform is connected as a "Sub2API" channel;
  • balance queries from tools such as cc-switch.
GEThttps://gateway.amux.ai/v1/usage

Authorization

header
AuthorizationstringRequired

Bearer <your Amux AI key> An Amux key created in the console. If you lose it, you can view it again on the keys page.

Response

200response

Balance.

401response

Missing or invalid key.

Modes

modeMeaningBalance fields returned
unrestrictedLimited only by the account balanceremaining, balance
quota_limitedLimited by key or workspace spend limitsremaining

remaining is the spendable amount of the current key, in USD.

If the spendable amount is unlimited, remaining and balance are omitted. sub2api uses -1 to indicate an unlimited balance, but new-api treats -1 as an actual balance, so this platform omits both fields instead.

Limitations

sub2api queries balances only for OAuth accounts and keys from certain official vendors. When this platform is added to sub2api as an API key account, sub2api does not query its balance.

cURL
curl https://gateway.amux.ai/v1/usage \
  -H "Authorization: Bearer $AMUX_API_KEY"
{
  "isValid": true,
  "mode": "unrestricted",
  "planName": "Amux",
  "unit": "USD",
  "remaining": 48.25,
  "balance": 48.25
}