How does Sandwich calculate Wallet balance?
Wallet Balance = Net Asset Value (NAV) - Unrealized Profit and Loss (UPnL)
Wallet Balance = Net Asset Value (NAV) - Unrealized Profit and Loss (UPnL)
If this information is available from the exchange via API, Sandwich will display the UPnL and RPnL as reported by the exchange. Otherwise, Sandwich calculates the UPnL by using the Mark Price. If the Mark Price is unavailable, then the Last Price is used.
Leverage and Margin mode options are controlled directly by the exchanges. Every exchange has a unique way of handling Leverage and Margin mode which means that specific functionality differs across exchanges.
Sandwich uses WebSockets and rest requests to retrieve data on your accounts from the exchange. If Sandwich cannot connect to the exchange for any reason, or if the connection is unstable, your Balances may not load, or may become outdated, or you may see values different to those you expect.
Sandwich uses WebSockets and rest requests to retrieve data on your accounts from the exchange. If Sandwich cannot connect to the exchange for any reason, or if the connection is unstable, your Balances may not load, or may become outdated.
Every exchange has a unique way of handling Leverage and Margin mode which means that specific functionality differs across exchanges. Read the full answer to see detailed descriptions of the functionality offered by each exchange