exchange_config

package
v0.4.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 13, 2023 License: AGPL-3.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// MARKET_BTC_USD is the id for the BTC-USD market pair.
	MARKET_BTC_USD types.MarketId = 0
	// MARKET_ETH_USD is the id for the ETH-USD market pair.
	MARKET_ETH_USD types.MarketId = 1
	// MARKET_LINK_USD is the id for the LINK-USD market pair.
	MARKET_LINK_USD types.MarketId = 2
	// MARKET_MATIC_USD is the id for the MATIC-USD market pair.
	MARKET_MATIC_USD types.MarketId = 3
	// MARKET_CRV_USD is the id for the CRV-USD market pair.
	MARKET_CRV_USD types.MarketId = 4
	// MARKET_SOL_USD is the id for the SOL-USD market pair.
	MARKET_SOL_USD types.MarketId = 5
	// MARKET_ADA_USD is the id for the ADA-USD market pair.
	MARKET_ADA_USD types.MarketId = 6
	// MARKET_AVAX_USD is the id for the AVAX-USD market pair.
	MARKET_AVAX_USD types.MarketId = 7
	// MARKET_FIL_USD is the id for the FIL-USD market pair.
	MARKET_FIL_USD types.MarketId = 8
	// MARKET_LTC_USD is the id for the LTC-USD market pair.
	MARKET_LTC_USD types.MarketId = 9
	// MARKET_DOGE_USD is the id for the DOGE-USD market pair.
	MARKET_DOGE_USD types.MarketId = 10
	// MARKET_ATOM_USD is the id for the ATOM-USD market pair.
	MARKET_ATOM_USD types.MarketId = 11
	// MARKET_DOT_USD is the id for the DOT-USD market pair.
	MARKET_DOT_USD types.MarketId = 12
	// MARKET_UNI_USD is the id for the UNI-USD market pair.
	MARKET_UNI_USD types.MarketId = 13
	// MARKET_BCH_USD is the id for the BCH-USD market pair.
	MARKET_BCH_USD types.MarketId = 14
	// MARKET_TRX_USD is the id for the TRX-USD market pair.
	MARKET_TRX_USD types.MarketId = 15
	// MARKET_NEAR_USD is the id for the NEAR-USD market pair.
	MARKET_NEAR_USD types.MarketId = 16
	// MARKET_MKR_USD is the id for the MKR-USD market pair.
	MARKET_MKR_USD types.MarketId = 17
	// MARKET_XLM_USD is the id for the XLM-USD market pair.
	MARKET_XLM_USD types.MarketId = 18
	// MARKET_ETC_USD is the id for the ETC-USD market pair.
	MARKET_ETC_USD types.MarketId = 19
	// MARKET_COMP_USD is the id for the COMP-USD market pair.
	MARKET_COMP_USD types.MarketId = 20
	// MARKET_WLD_USD is the id for the WLD-USD market pair.
	MARKET_WLD_USD types.MarketId = 21
	// MARKET_APE_USD is the id for the APE-USD market pair.
	MARKET_APE_USD types.MarketId = 22
	// MARKET_APT_USD is the id for the APT-USD market pair.
	MARKET_APT_USD types.MarketId = 23
	// MARKET_ARB_USD is the id for the ARB-USD market pair.
	MARKET_ARB_USD types.MarketId = 24
	// MARKET_BLUR_USD is the id for the BLUR-USD market pair.
	MARKET_BLUR_USD types.MarketId = 25
	// MARKET_LDO_USD is the id for the LDO-USD market pair.
	MARKET_LDO_USD types.MarketId = 26
	// MARKET_OP_USD is the id for the OP-USD market pair.
	MARKET_OP_USD types.MarketId = 27
	// MARKET_PEPE_USD is the id for the PEPE-USD market pair.
	MARKET_PEPE_USD types.MarketId = 28
	// MARKET_SEI_USD is the id for the SEI-USD market pair.
	MARKET_SEI_USD types.MarketId = 29
	// MARKET_SHIB_USD is the id for the SHIB-USD market pair.
	MARKET_SHIB_USD types.MarketId = 30
	// MARKET_SUI_USD is the id for the SUI-USD market pair.
	MARKET_SUI_USD types.MarketId = 31
	// MARKET_XRP_USD is the id for the XRP-USD market pair.
	MARKET_XRP_USD types.MarketId = 32

	// Testing markets used in local, staging, dev
	// MARKET_TEST_USD is the id used for the TEST-USD market pair.
	MARKET_TEST_USD types.MarketId = 33

	// Non-trading markets.
	// MARKET_USDT_USD is the id for the USDT-USD market pair.
	MARKET_USDT_USD types.MarketId = 1_000_000
	// MARKET_DYDX_USD is the id for the DYDX-USD market pair.
	MARKET_DYDX_USD types.MarketId = 1_000_001
)

All market ids must match with the genesis state.

Variables

View Source
var (
	// StaticMarketNames maps marketIds to their human-readable market names. This list is
	// used for generating market exchange config that is then read back into the daemon.
	StaticMarketNames = map[types.MarketId]string{
		MARKET_BTC_USD:   "BTC-USD",
		MARKET_ETH_USD:   "ETH-USD",
		MARKET_LINK_USD:  "LINK-USD",
		MARKET_MATIC_USD: "MATIC-USD",
		MARKET_CRV_USD:   "CRV-USD",
		MARKET_SOL_USD:   "SOL-USD",
		MARKET_ADA_USD:   "ADA-USD",
		MARKET_AVAX_USD:  "AVAX-USD",
		MARKET_FIL_USD:   "FIL-USD",
		MARKET_LTC_USD:   "LTC-USD",
		MARKET_DOGE_USD:  "DOGE-USD",
		MARKET_ATOM_USD:  "ATOM-USD",
		MARKET_DOT_USD:   "DOT-USD",
		MARKET_UNI_USD:   "UNI-USD",
		MARKET_BCH_USD:   "BCH-USD",
		MARKET_TRX_USD:   "TRX-USD",
		MARKET_NEAR_USD:  "NEAR-USD",
		MARKET_MKR_USD:   "MKR-USD",
		MARKET_XLM_USD:   "XLM-USD",
		MARKET_ETC_USD:   "ETC-USD",
		MARKET_COMP_USD:  "COMP-USD",
		MARKET_WLD_USD:   "WLD-USD",
		MARKET_APE_USD:   "APE-USD",
		MARKET_APT_USD:   "APT-USD",
		MARKET_ARB_USD:   "ARB-USD",
		MARKET_BLUR_USD:  "BLUR-USD",
		MARKET_LDO_USD:   "LDO-USD",
		MARKET_OP_USD:    "OP-USD",
		MARKET_PEPE_USD:  "PEPE-USD",
		MARKET_SEI_USD:   "SEI-USD",
		MARKET_SHIB_USD:  "SHIB-USD",
		MARKET_SUI_USD:   "SUI-USD",
		MARKET_XRP_USD:   "XRP-USD",
		MARKET_USDT_USD:  "USDT-USD",
	}
)
View Source
var (
	// TestnetExchangeMarketConfig maps exchange feed ids to exchange market config. This map is used to generate
	// the exchange config json used by the genesis state for testnet deploys.
	TestnetExchangeMarketConfig = map[types.ExchangeId]*types.MutableExchangeMarketConfig{
		exchange_common.EXCHANGE_ID_BINANCE: {
			Id: exchange_common.EXCHANGE_ID_BINANCE,

			MarketToMarketConfig: map[types.MarketId]types.MarketConfig{
				MARKET_DYDX_USD: {
					Ticker:         "DYDXUSDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_BTC_USD: {
					Ticker:         "BTCUSDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_ETH_USD: {
					Ticker:         "ETHUSDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_LINK_USD: {
					Ticker:         "LINKUSDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_MATIC_USD: {
					Ticker:         "MATICUSDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_CRV_USD: {
					Ticker:         "CRVUSDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_SOL_USD: {
					Ticker:         "SOLUSDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_ADA_USD: {
					Ticker:         "ADAUSDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_AVAX_USD: {
					Ticker:         "AVAXUSDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_FIL_USD: {
					Ticker:         "FILUSDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_LTC_USD: {
					Ticker:         "LTCUSDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_DOGE_USD: {
					Ticker:         "DOGEUSDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_ATOM_USD: {
					Ticker:         "ATOMUSDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_DOT_USD: {
					Ticker:         "DOTUSDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_UNI_USD: {
					Ticker:         "UNIUSDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_BCH_USD: {
					Ticker:         "BCHUSDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_TRX_USD: {
					Ticker:         "TRXUSDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_NEAR_USD: {
					Ticker:         "NEARUSDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_MKR_USD: {
					Ticker:         "MKRUSDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_XLM_USD: {
					Ticker:         "XLMUSDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_ETC_USD: {
					Ticker:         "ETCUSDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_COMP_USD: {
					Ticker:         "COMPUSDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_APE_USD: {
					Ticker:         "APEUSDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_APT_USD: {
					Ticker:         "APTUSDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_ARB_USD: {
					Ticker:         "ARBUSDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_LDO_USD: {
					Ticker:         "LDOUSDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_OP_USD: {
					Ticker:         "OPUSDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_PEPE_USD: {
					Ticker:         "PEPEUSDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_SEI_USD: {
					Ticker:         "SEIUSDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_SHIB_USD: {
					Ticker:         "SHIBUSDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_SUI_USD: {
					Ticker:         "SUIUSDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_WLD_USD: {
					Ticker:         "WLDUSDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_XRP_USD: {
					Ticker:         "XRPUSDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_USDT_USD: {
					Ticker: "USDCUSDT",
					Invert: true,
				},
			},
		},
		exchange_common.EXCHANGE_ID_KRAKEN: {
			Id: exchange_common.EXCHANGE_ID_KRAKEN,
			MarketToMarketConfig: map[types.MarketId]types.MarketConfig{
				MARKET_BTC_USD: {
					Ticker: "XXBTZUSD",
				},
				MARKET_ETH_USD: {
					Ticker: "XETHZUSD",
				},
				MARKET_LINK_USD: {
					Ticker: "LINKUSD",
				},
				MARKET_SOL_USD: {
					Ticker: "SOLUSD",
				},
				MARKET_ADA_USD: {
					Ticker: "ADAUSD",
				},
				MARKET_FIL_USD: {
					Ticker: "FILUSD",
				},
				MARKET_LTC_USD: {
					Ticker: "XLTCZUSD",
				},
				MARKET_ATOM_USD: {
					Ticker: "ATOMUSD",
				},
				MARKET_DOT_USD: {
					Ticker: "DOTUSD",
				},
				MARKET_BCH_USD: {
					Ticker: "BCHUSD",
				},
				MARKET_XLM_USD: {
					Ticker: "XXLMZUSD",
				},
				MARKET_APE_USD: {
					Ticker: "APEUSD",
				},
				MARKET_BLUR_USD: {
					Ticker: "BLURUSD",
				},
				MARKET_PEPE_USD: {
					Ticker: "PEPEUSD",
				},
				MARKET_SHIB_USD: {
					Ticker: "SHIBUSD",
				},
				MARKET_XRP_USD: {
					Ticker: "XXRPZUSD",
				},
				MARKET_UNI_USD: {
					Ticker: "UNIUSD",
				},
				MARKET_CRV_USD: {
					Ticker: "CRVUSD",
				},
				MARKET_COMP_USD: {
					Ticker: "COMPUSD",
				},
				MARKET_AVAX_USD: {
					Ticker: "AVAXUSD",
				},
				MARKET_DOGE_USD: {
					Ticker: "XDGUSD",
				},
				MARKET_LDO_USD: {
					Ticker: "LDOUSD",
				},
				MARKET_USDT_USD: {
					Ticker: "USDTZUSD",
				},
				MARKET_MATIC_USD: {
					Ticker: "MATICUSD",
				},
				MARKET_MKR_USD: {
					Ticker: "MKRUSD",
				},
				MARKET_TRX_USD: {
					Ticker: "TRXUSD",
				},
			},
		},
		exchange_common.EXCHANGE_ID_GATE: {
			Id: exchange_common.EXCHANGE_ID_GATE,
			MarketToMarketConfig: map[types.MarketId]types.MarketConfig{
				MARKET_DYDX_USD: {
					Ticker:         "DYDX_USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_MATIC_USD: {
					Ticker:         "MATIC_USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_CRV_USD: {
					Ticker:         "CRV_USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_ADA_USD: {
					Ticker:         "ADA_USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_DOGE_USD: {
					Ticker:         "DOGE_USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_DOT_USD: {
					Ticker:         "DOT_USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_UNI_USD: {
					Ticker:         "UNI_USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_BCH_USD: {
					Ticker:         "BCH_USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_TRX_USD: {
					Ticker:         "TRX_USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_NEAR_USD: {
					Ticker:         "NEAR_USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_ETC_USD: {
					Ticker:         "ETC_USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_APE_USD: {
					Ticker:         "APE_USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_APT_USD: {
					Ticker:         "APT_USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_ARB_USD: {
					Ticker:         "ARB_USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_BLUR_USD: {
					Ticker:         "BLUR_USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_FIL_USD: {
					Ticker:         "FIL_USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_OP_USD: {
					Ticker:         "OP_USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_PEPE_USD: {
					Ticker:         "PEPE_USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_SEI_USD: {
					Ticker:         "SEI_USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_SHIB_USD: {
					Ticker:         "SHIB_USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_SUI_USD: {
					Ticker:         "SUI_USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_WLD_USD: {
					Ticker:         "WLD_USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_XRP_USD: {
					Ticker:         "XRP_USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_AVAX_USD: {
					Ticker:         "AVAX_USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_ATOM_USD: {
					Ticker:         "ATOM_USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_COMP_USD: {
					Ticker:         "COMP_USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
			},
		},
		exchange_common.EXCHANGE_ID_BITSTAMP: {
			Id:                   exchange_common.EXCHANGE_ID_BITSTAMP,
			MarketToMarketConfig: map[types.MarketId]types.MarketConfig{},
		},
		exchange_common.EXCHANGE_ID_BYBIT: {
			Id: exchange_common.EXCHANGE_ID_BYBIT,
			MarketToMarketConfig: map[types.MarketId]types.MarketConfig{
				MARKET_DYDX_USD: {
					Ticker:         "DYDXUSDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_BTC_USD: {
					Ticker:         "BTCUSDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_ETH_USD: {
					Ticker:         "ETHUSDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_XRP_USD: {
					Ticker:         "XRPUSDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_LTC_USD: {
					Ticker:         "LTCUSDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_ATOM_USD: {
					Ticker:         "ATOMUSDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_UNI_USD: {
					Ticker:         "UNIUSDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_WLD_USD: {
					Ticker:         "WLDUSDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_APT_USD: {
					Ticker:         "APTUSDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_SOL_USD: {
					Ticker:         "SOLUSDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_DOGE_USD: {
					Ticker:         "DOGEUSDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_ADA_USD: {
					Ticker:         "ADAUSDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_XLM_USD: {
					Ticker:         "XLMUSDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_SHIB_USD: {
					Ticker:         "SHIBUSDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_LINK_USD: {
					Ticker:         "LINKUSDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_ARB_USD: {
					Ticker:         "ARBUSDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_SUI_USD: {
					Ticker:         "SUIUSDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_TRX_USD: {
					Ticker:         "TRXUSDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_SEI_USD: {
					Ticker:         "SEIUSDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_PEPE_USD: {
					Ticker:         "PEPEUSDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_AVAX_USD: {
					Ticker:         "AVAXUSDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_BCH_USD: {
					Ticker:         "BCHUSDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_DOT_USD: {
					Ticker:         "DOTUSDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_MATIC_USD: {
					Ticker:         "MATICUSDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_USDT_USD: {
					Ticker: "USDCUSDT",
					Invert: true,
				},
			},
		},
		exchange_common.EXCHANGE_ID_CRYPTO_COM: {
			Id:                   exchange_common.EXCHANGE_ID_CRYPTO_COM,
			MarketToMarketConfig: map[types.MarketId]types.MarketConfig{},
		},
		exchange_common.EXCHANGE_ID_HUOBI: {
			Id: exchange_common.EXCHANGE_ID_HUOBI,
			MarketToMarketConfig: map[types.MarketId]types.MarketConfig{
				MARKET_MATIC_USD: {
					Ticker:         "maticusdt",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_SOL_USD: {
					Ticker:         "solusdt",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_ADA_USD: {
					Ticker:         "adausdt",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_FIL_USD: {
					Ticker:         "filusdt",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_LTC_USD: {
					Ticker:         "ltcusdt",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_DOGE_USD: {
					Ticker:         "dogeusdt",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_BCH_USD: {
					Ticker:         "bchusdt",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_TRX_USD: {
					Ticker:         "trxusdt",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_APT_USD: {
					Ticker:         "aptusdt",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_ARB_USD: {
					Ticker:         "arbusdt",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_SEI_USD: {
					Ticker:         "seiusdt",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_SUI_USD: {
					Ticker:         "suiusdt",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_WLD_USD: {
					Ticker:         "wldusdt",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_XRP_USD: {
					Ticker:         "xrpusdt",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_AVAX_USD: {
					Ticker:         "avaxusdt",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_NEAR_USD: {
					Ticker:         "nearusdt",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_ETC_USD: {
					Ticker:         "etcusdt",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_BTC_USD: {
					Ticker:         "btcusdt",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_ETH_USD: {
					Ticker:         "ethusdt",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_USDT_USD: {
					Ticker:         "ethusdt",
					AdjustByMarket: newMarketIdWithValue(MARKET_ETH_USD),
					Invert:         true,
				},
			},
		},
		exchange_common.EXCHANGE_ID_KUCOIN: {
			Id: exchange_common.EXCHANGE_ID_KUCOIN,
			MarketToMarketConfig: map[types.MarketId]types.MarketConfig{
				MARKET_DYDX_USD: {
					Ticker:         "DYDX-USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_LINK_USD: {
					Ticker:         "LINK-USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_MATIC_USD: {
					Ticker:         "MATIC-USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_CRV_USD: {
					Ticker:         "CRV-USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_SOL_USD: {
					Ticker:         "SOL-USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_ADA_USD: {
					Ticker:         "ADA-USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_AVAX_USD: {
					Ticker:         "AVAX-USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_LTC_USD: {
					Ticker:         "LTC-USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_DOGE_USD: {
					Ticker:         "DOGE-USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_ATOM_USD: {
					Ticker:         "ATOM-USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_DOT_USD: {
					Ticker:         "DOT-USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_XLM_USD: {
					Ticker:         "XLM-USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_BCH_USD: {
					Ticker:         "BCH-USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_TRX_USD: {
					Ticker:         "TRX-USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_ARB_USD: {
					Ticker:         "ARB-USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_BLUR_USD: {
					Ticker:         "BLUR-USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_LDO_USD: {
					Ticker:         "LDO-USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_OP_USD: {
					Ticker:         "OP-USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_PEPE_USD: {
					Ticker:         "PEPE-USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_SEI_USD: {
					Ticker:         "SEI-USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_SHIB_USD: {
					Ticker:         "SHIB-USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_SUI_USD: {
					Ticker:         "SUI-USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_WLD_USD: {
					Ticker:         "WLD-USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_XRP_USD: {
					Ticker:         "XRP-USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_MKR_USD: {
					Ticker:         "MKR-USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_NEAR_USD: {
					Ticker:         "NEAR-USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_APE_USD: {
					Ticker:         "APE-USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_APT_USD: {
					Ticker:         "APT-USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_USDT_USD: {
					Ticker:         "BTC-USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_BTC_USD),
					Invert:         true,
				},
				MARKET_BTC_USD: {
					Ticker:         "BTC-USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_ETC_USD: {
					Ticker:         "ETC-USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_ETH_USD: {
					Ticker:         "ETH-USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_UNI_USD: {
					Ticker:         "UNI-USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
			},
		},
		exchange_common.EXCHANGE_ID_OKX: {
			Id: exchange_common.EXCHANGE_ID_OKX,
			MarketToMarketConfig: map[types.MarketId]types.MarketConfig{
				MARKET_DYDX_USD: {
					Ticker:         "DYDX-USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_BTC_USD: {
					Ticker:         "BTC-USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_ETH_USD: {
					Ticker:         "ETH-USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_LINK_USD: {
					Ticker:         "LINK-USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_MATIC_USD: {
					Ticker:         "MATIC-USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_CRV_USD: {
					Ticker:         "CRV-USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_SOL_USD: {
					Ticker:         "SOL-USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_AVAX_USD: {
					Ticker:         "AVAX-USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_FIL_USD: {
					Ticker:         "FIL-USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_LTC_USD: {
					Ticker:         "LTC-USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_DOGE_USD: {
					Ticker:         "DOGE-USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_DOT_USD: {
					Ticker:         "DOT-USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_UNI_USD: {
					Ticker:         "UNI-USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_BCH_USD: {
					Ticker:         "BCH-USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_TRX_USD: {
					Ticker:         "TRX-USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_ETC_USD: {
					Ticker:         "ETC-USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_APE_USD: {
					Ticker:         "APE-USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_ARB_USD: {
					Ticker:         "ARB-USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_BLUR_USD: {
					Ticker:         "BLUR-USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_OP_USD: {
					Ticker:         "OP-USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_PEPE_USD: {
					Ticker:         "PEPE-USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_SHIB_USD: {
					Ticker:         "SHIB-USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_SUI_USD: {
					Ticker:         "SUI-USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_WLD_USD: {
					Ticker:         "WLD-USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_XRP_USD: {
					Ticker:         "XRP-USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_COMP_USD: {
					Ticker:         "COMP-USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_MKR_USD: {
					Ticker:         "MKR-USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_APT_USD: {
					Ticker:         "APT-USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_ATOM_USD: {
					Ticker:         "ATOM-USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_ADA_USD: {
					Ticker:         "ADA-USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_LDO_USD: {
					Ticker: "LDO-USDT",
				},
				MARKET_USDT_USD: {
					Ticker: "USDC-USDT",
					Invert: true,
				},
				MARKET_XLM_USD: {
					Ticker:         "XLM-USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
			},
		},
		exchange_common.EXCHANGE_ID_MEXC: {
			MarketToMarketConfig: map[types.MarketId]types.MarketConfig{
				MARKET_DYDX_USD: {
					Ticker:         "DYDX_USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_BTC_USD: {
					Ticker:         "BTC_USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_SOL_USD: {
					Ticker:         "SOL_USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_LTC_USD: {
					Ticker:         "LTC_USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_APE_USD: {
					Ticker:         "APE_USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_APT_USD: {
					Ticker:         "APT_USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_ARB_USD: {
					Ticker:         "ARB_USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_BLUR_USD: {
					Ticker:         "BLUR_USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_FIL_USD: {
					Ticker:         "FIL_USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_LDO_USD: {
					Ticker:         "LDO_USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_OP_USD: {
					Ticker:         "OP_USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_PEPE_USD: {
					Ticker:         "PEPE_USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_SEI_USD: {
					Ticker:         "SEI_USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_SHIB_USD: {
					Ticker:         "SHIB_USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_SUI_USD: {
					Ticker:         "SUI_USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_WLD_USD: {
					Ticker:         "WLD_USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_XLM_USD: {
					Ticker:         "XLM_USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_XRP_USD: {
					Ticker:         "XRP_USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_ETH_USD: {
					Ticker:         "ETH_USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_ADA_USD: {
					Ticker:         "ADA_USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_LINK_USD: {
					Ticker:         "LINK_USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_TRX_USD: {
					Ticker:         "TRX_USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_DOGE_USD: {
					Ticker:         "DOGE_USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_MKR_USD: {
					Ticker:         "MKR_USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_NEAR_USD: {
					Ticker:         "NEAR_USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_ATOM_USD: {
					Ticker:         "ATOM_USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_BCH_USD: {
					Ticker:         "BCH_USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_COMP_USD: {
					Ticker:         "COMP_USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_CRV_USD: {
					Ticker:         "CRV_USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_DOT_USD: {
					Ticker:         "DOT_USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_ETC_USD: {
					Ticker:         "ETC_USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
				MARKET_MATIC_USD: {
					Ticker:         "MATIC_USDT",
					AdjustByMarket: newMarketIdWithValue(MARKET_USDT_USD),
				},
			},
		},
		exchange_common.EXCHANGE_ID_COINBASE_PRO: {
			Id: exchange_common.EXCHANGE_ID_COINBASE_PRO,
			MarketToMarketConfig: map[types.MarketId]types.MarketConfig{
				MARKET_BTC_USD: {
					Ticker: "BTC-USD",
				},
				MARKET_ETH_USD: {
					Ticker: "ETH-USD",
				},
				MARKET_LINK_USD: {
					Ticker: "LINK-USD",
				},
				MARKET_MATIC_USD: {
					Ticker: "MATIC-USD",
				},
				MARKET_CRV_USD: {
					Ticker: "CRV-USD",
				},
				MARKET_SOL_USD: {
					Ticker: "SOL-USD",
				},
				MARKET_ADA_USD: {
					Ticker: "ADA-USD",
				},
				MARKET_FIL_USD: {
					Ticker: "FIL-USD",
				},
				MARKET_LTC_USD: {
					Ticker: "LTC-USD",
				},
				MARKET_ATOM_USD: {
					Ticker: "ATOM-USD",
				},
				MARKET_UNI_USD: {
					Ticker: "UNI-USD",
				},
				MARKET_BCH_USD: {
					Ticker: "BCH-USD",
				},
				MARKET_NEAR_USD: {
					Ticker: "NEAR-USD",
				},
				MARKET_MKR_USD: {
					Ticker: "MKR-USD",
				},
				MARKET_XLM_USD: {
					Ticker: "XLM-USD",
				},
				MARKET_ETC_USD: {
					Ticker: "ETC-USD",
				},
				MARKET_COMP_USD: {
					Ticker: "COMP-USD",
				},
				MARKET_APE_USD: {
					Ticker: "APE-USD",
				},
				MARKET_APT_USD: {
					Ticker: "APT-USD",
				},
				MARKET_ARB_USD: {
					Ticker: "ARB-USD",
				},
				MARKET_BLUR_USD: {
					Ticker: "BLUR-USD",
				},
				MARKET_LDO_USD: {
					Ticker: "LDO-USD",
				},
				MARKET_OP_USD: {
					Ticker: "OP-USD",
				},
				MARKET_SEI_USD: {
					Ticker: "SEI-USD",
				},
				MARKET_SHIB_USD: {
					Ticker: "SHIB-USD",
				},
				MARKET_SUI_USD: {
					Ticker: "SUI-USD",
				},
				MARKET_XRP_USD: {
					Ticker: "XRP-USD",
				},
				MARKET_AVAX_USD: {
					Ticker: "AVAX-USD",
				},
				MARKET_DOGE_USD: {
					Ticker: "DOGE-USD",
				},
				MARKET_DOT_USD: {
					Ticker: "DOT-USD",
				},
				MARKET_USDT_USD: {
					Ticker: "USDT-USD",
				},
			},
		},
		exchange_common.EXCHANGE_ID_TEST_EXCHANGE: {
			Id: exchange_common.EXCHANGE_ID_TEST_EXCHANGE,
			MarketToMarketConfig: map[types.MarketId]types.MarketConfig{
				MARKET_BTC_USD: {
					Ticker: "BTC-USD",
				},
				MARKET_ETH_USD: {
					Ticker: "ETH-USD",
				},
				MARKET_LINK_USD: {
					Ticker: "LINK-USD",
				},
				MARKET_USDT_USD: {
					Ticker: "USDT-USD",
				},
			},
		},
		exchange_common.EXCHANGE_ID_TEST_VOLATILE_EXCHANGE: {
			Id: exchange_common.EXCHANGE_ID_TEST_VOLATILE_EXCHANGE,
			MarketToMarketConfig: map[types.MarketId]types.MarketConfig{
				MARKET_TEST_USD: {
					Ticker: "TEST-USD",
				},
			},
		},
	}
)

Functions

This section is empty.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL