Skip to main content

parse_spot_account_position

Function parse_spot_account_position 

Source
pub fn parse_spot_account_position(
    msg: &BinanceSpotAccountPositionMsg,
    account_id: AccountId,
    ts_init: UnixNanos,
) -> Result<AccountState>
Expand description

Converts a Binance Spot account position update to a Nautilus account state.

§Errors

Returns an error if a balance’s free and locked amounts overflow when added, or if an amount cannot be represented as money. No account state is returned when any balance fails.