namespace CryptoExchange.Net.SharedApis { /// /// Symbol info /// public record SharedSpotSymbol { /// /// The trading mode of the symbol /// public TradingMode TradingMode { get; set; } /// /// Base asset of the symbol /// public string BaseAsset { get; set; } /// /// Quote asset of the symbol /// public string QuoteAsset { get; set; } /// /// The name of the symbol /// public string Name { get; set; } /// /// Minimal quantity of an order in the base asset /// public decimal? MinTradeQuantity { get; set; } /// /// Minimal notional value (quantity * price) of an order /// public decimal? MinNotionalValue { get; set; } /// /// Max quantity of an order in the base asset /// public decimal? MaxTradeQuantity { get; set; } /// /// Step by which the quantity should increase /// public decimal? QuantityStep { get; set; } /// /// Step by which the price should increase /// public decimal? PriceStep { get; set; } /// /// The max amount of decimal places for quantity /// public int? QuantityDecimals { get; set; } /// /// The max amount of decimal places for price /// public int? PriceDecimals { get; set; } /// /// The max amount of significant figures to use for price. For example with value of 5 these values are valid: 0.00001, 0.12300, 123.53, 12345, but this is not: 12345.1 /// public int? PriceSignificantFigures { get; set; } /// /// Whether the symbol is currently available for trading /// public bool Trading { get; set; } /// /// ctor /// public SharedSpotSymbol(string baseAsset, string quoteAsset, string symbol, bool trading, TradingMode? tradingMode = null) { TradingMode = tradingMode ?? TradingMode.Spot; BaseAsset = baseAsset; QuoteAsset = quoteAsset; Name = symbol; Trading = trading; } /// /// The SharedSymbol of this symbol /// /// public virtual SharedSymbol SharedSymbol => new SharedSymbol(TradingMode, BaseAsset.ToUpperInvariant(), QuoteAsset.ToUpperInvariant()) { SymbolName = Name }; } }