openlimits-binance 0.3.0

Binance implementation for OpenLimits.
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
use serde::Deserialize;
use serde::Serialize;
use rust_decimal::prelude::Decimal;
use super::shared::string_to_decimal;

/// This struct represents the account update balance
#[derive(Debug, Serialize, Deserialize, Clone)]
#[serde(rename_all = "camelCase")]
pub struct AccountUpdateBalance {
    #[serde(rename = "a")]
    pub asset: String,
    #[serde(rename = "f", with = "string_to_decimal")]
    pub free: Decimal,
    #[serde(rename = "l", with = "string_to_decimal")]
    pub locked: Decimal,
}