ExCcxt.Market (ex_ccxt v0.1.1)

Represents market information for a trading pair on a cryptocurrency exchange.

A market contains metadata about a trading pair including fees, limits, precision, and trading capabilities. This struct is returned by market-related functions such as ExCcxt.fetch_markets/1 and ExCcxt.load_markets/2.

Fields

  • :symbol - Trading pair symbol (e.g., "BTC/USDT")
  • :base - Base currency code (e.g., "BTC")
  • :quote - Quote currency code (e.g., "USDT")
  • :active - Whether the market is currently active for trading
  • :type - Market type (e.g., "spot", "future", "option")
  • :spot - Whether this is a spot market
  • :margin - Whether margin trading is available
  • :future - Whether this is a futures market
  • :option - Whether this is an options market
  • :contract - Whether this is a contract market
  • :swap - Whether this is a perpetual swap market
  • :maker - Maker fee rate (as decimal, e.g., 0.001 for 0.1%)
  • :taker - Taker fee rate (as decimal, e.g., 0.001 for 0.1%)
  • :percentage - Whether fees are percentage-based
  • :tier_based - Whether fees are tier-based
  • :precision - Price and amount precision information
  • :limits - Trading limits for amounts and prices
  • :info - Raw exchange-specific market data

Summary

Types

t()

@type t() :: %ExCcxt.Market{
  active: boolean() | nil,
  base: String.t() | nil,
  base_id: String.t() | nil,
  contract: boolean() | nil,
  fee_currency: String.t() | nil,
  future: boolean() | nil,
  id: String.t() | nil,
  info: map() | nil,
  limits: map() | nil,
  maker: float() | nil,
  margin: boolean() | nil,
  option: boolean() | nil,
  percentage: boolean() | nil,
  precision: map() | nil,
  quote: String.t() | nil,
  quote_id: String.t() | nil,
  spot: boolean() | nil,
  swap: boolean() | nil,
  symbol: String.t() | nil,
  taker: float() | nil,
  tier_based: boolean() | nil,
  type: String.t() | nil
}