Skip to main content

Check balance

GET /v1/balance returns the balance owned by the supplied API key. It accepts no user or account selector, calls no image service, and costs nothing.
Use pricing=current for your account’s current purchase rate and four-decimal credit display. The public rate is $0.15. Accounts with an approved private rate receive their own rate. Without the parameter, the response retains credit_usd: "0.17" and a one-decimal display for compatibility with older CLI/MCP versions. That legacy rate is not the price of a new purchase. The DreamLayer-Credit-Price-USD header reports the account’s current purchase rate in either mode. Neither mode changes stored funds or usage charges. The snapshot is serialized with credit reservation, settlement, and restoration. Balances cannot be negative. Responses use Cache-Control: private, no-store, Pragma: no-cache, and Vary: Authorization, so shared caches must not retain one account’s balance. Compare available with the complete order quote in credits to decide affordability. Do not add the displayed funding buckets to calculate available funds. Other account, rate, spend, or concurrency limits can still refuse a submit. Handle the documented error contract on every request. Current balances round down to four decimal credits; stored funds keep their exact precision. New sprite charges round upward to four decimals after the whole price is calculated. For example, a public 12-frame sprite with its background kept costs $0.44 in reference dollars, or 2.9334 API credits. Restorations return the original hold to its original funding buckets. All rounding here is in credits, not dollars. A current available balance of 2.9333 cannot cover 2.9334 credits; 2.9334 can. Legacy balance reads round down to one decimal and may understate affordability for new fractional charges. Use pricing=current for spending decisions. A later reservation can still change availability before submission. Promotional and purchased balances are floored independently, while available is the floored combined total. It can exceed the sum of the displayed buckets by 0.0001 in current mode, or 0.1 in legacy mode. That difference reflects preserved fractions, not newly granted credits.