use serde::{Deserialize, Serialize};
#[derive(Serialize, Deserialize, Debug, Clone)]
pub struct MarketDepth {
pub price: f64,
pub quantity: f64,
}
#[derive(Serialize, Deserialize, Debug, Clone)]
pub struct GetMarketDepthResponse {
pub bids: Vec<MarketDepth>,
pub asks: Vec<MarketDepth>,
}
#[derive(Serialize, Deserialize, Debug, Clone)]
pub struct GetMarketPriceResponse {
pub price: f64,
}
#[derive(Serialize, Deserialize, Debug, Clone)]
pub struct Candlestick {
#[serde(rename = "t")]
pub timestamp: i64,
#[serde(rename = "s")]
pub symbol: String,
#[serde(rename = "o")]
pub open: f64,
#[serde(rename = "h")]
pub high: f64,
#[serde(rename = "l")]
pub low: f64,
#[serde(rename = "c")]
pub close: f64,
#[serde(rename = "v")]
pub volume: f64,
}
#[derive(Serialize, Deserialize, Debug, Clone)]
pub struct Trade {
pub time: String,
pub symbol: String,
pub open: f64,
pub high: f64,
pub low: f64,
pub close: f64,
pub volume: f64,
}
pub type GetAggregatedPriceResponse = Vec<Candlestick>;