Documentation Index
Fetch the complete documentation index at: https://mintlify.com/tripolskypetr/wallet-manager/llms.txt
Use this file to discover all available pages before exploring further.
fetchFiat returns the total USDT balance in your Binance spot account, summing both the freely available amount and any USDT currently locked in open BUY orders. It is the quickest way to inspect your capital position before deciding whether to place a new buy, and can be used to verify that enough USDT is present before calling commitBuy or commitTrade.
Signature
Parameters
A trading pair symbol used for queue routing, e.g.
"SOLUSDT". The symbol parameter is accepted to integrate with the per-symbol EventListener queue in WalletPublicService, but the underlying FETCH_FIAT_FN call fetches the full account USDT balance regardless of which symbol is passed. Any valid symbol from the supported list can be used.Return value
Promise<number> — the total USDT balance as a number: free + locked. Returns 0 if no USDT balance entry is found in the account (e.g. the account has never held USDT).
How the balance is computed
The underlyingFETCH_FIAT_FN reads the account balances from binance.account() and finds the USDT asset entry:
free— USDT available for new orders.locked— USDT currently reserved by open BUY orders on any symbol.
Relationship to commitBuy guard
Note thatcommitBuy’s balance guard checks only usdtBalance.free (not free + locked). fetchFiat returns the total, so the value it returns may be higher than what commitBuy would accept as available. To check exactly how much USDT commitBuy would see, inspect the free field directly via wallet.walletPrivateService in a debugging context.
Usage example
Because
symbol is used only for queue routing, you can call fetchFiat with any supported symbol — the returned balance is always the account-wide USDT total, not a symbol-specific allocation.