CometAPI CLI
Check your balance from the terminal with one command. See CometAPI CLI overview for installation.--source token for per-key details:
Personal access token
To query account balance and monthly usage, create a personal access token in Console → Personal Settings. Grant theUsage → View permission (usage:read) and store the token in COMETAPI_ACCESS_TOKEN.
Send the raw token in the Authorization header. Do not prefix it with Bearer.
Run the following command to print the balance, monthly usage, and monthly request count:
jq filter selects these fields:
balanceis the account balance.month_usageis usage for the current month.month_req_countis the request count for the current month.