Skip to content

Instantly share code, notes, and snippets.

@thecodingrobot
Last active August 18, 2018 02:34
Show Gist options
  • Save thecodingrobot/c96fc84778372283aa764b71c17a5b8e to your computer and use it in GitHub Desktop.
Save thecodingrobot/c96fc84778372283aa764b71c17a5b8e to your computer and use it in GitHub Desktop.
BINANCE:ETHBTC
BINANCE:LTCBTC
BINANCE:BNBBTC
BINANCE:NEOBTC
BINANCE:BCCBTC
BINANCE:GASBTC
BINANCE:HSRBTC
BINANCE:MCOBTC
BINANCE:WTCBTC
BINANCE:LRCBTC
BINANCE:QTUMBTC
BINANCE:YOYOBTC
BINANCE:OMGBTC
BINANCE:ZRXBTC
BINANCE:STRATBTC
BINANCE:SNGLSBTC
BINANCE:BQXBTC
BINANCE:KNCBTC
BINANCE:FUNBTC
BINANCE:SNMBTC
BINANCE:IOTABTC
BINANCE:LINKBTC
BINANCE:XVGBTC
BINANCE:SALTBTC
BINANCE:MDABTC
BINANCE:MTLBTC
BINANCE:SUBBTC
BINANCE:EOSBTC
BINANCE:SNTBTC
BINANCE:ETCBTC
BINANCE:MTHBTC
BINANCE:ENGBTC
BINANCE:DNTBTC
BINANCE:ZECBTC
BINANCE:BNTBTC
BINANCE:ASTBTC
BINANCE:DASHBTC
BINANCE:OAXBTC
BINANCE:ICNBTC
BINANCE:BTGBTC
BINANCE:EVXBTC
BINANCE:REQBTC
BINANCE:VIBBTC
BINANCE:TRXBTC
BINANCE:POWRBTC
BINANCE:ARKBTC
BINANCE:XRPBTC
BINANCE:MODBTC
BINANCE:ENJBTC
BINANCE:STORJBTC
BINANCE:VENBTC
BINANCE:KMDBTC
BINANCE:RCNBTC
BINANCE:NULSBTC
BINANCE:RDNBTC
BINANCE:XMRBTC
BINANCE:DLTBTC
BINANCE:AMBBTC
BINANCE:BATBTC
BINANCE:BCPTBTC
BINANCE:ARNBTC
BINANCE:GVTBTC
BINANCE:CDTBTC
BINANCE:GXSBTC
BINANCE:POEBTC
BINANCE:QSPBTC
BINANCE:BTSBTC
BINANCE:XZCBTC
BINANCE:LSKBTC
BINANCE:TNTBTC
BINANCE:FUELBTC
BINANCE:MANABTC
BINANCE:BCDBTC
BINANCE:DGDBTC
BINANCE:ADXBTC
BINANCE:ADABTC
BINANCE:PPTBTC
BINANCE:CMTBTC
BINANCE:XLMBTC
BINANCE:CNDBTC
BINANCE:LENDBTC
BINANCE:WABIBTC
BINANCE:TNBBTC
BINANCE:WAVESBTC
BINANCE:GTOBTC
BINANCE:ICXBTC
BINANCE:OSTBTC
BINANCE:ELFBTC
BINANCE:AIONBTC
BINANCE:NEBLBTC
BINANCE:BRDBTC
BINANCE:EDOBTC
BINANCE:WINGSBTC
BINANCE:NAVBTC
BINANCE:LUNBTC
BINANCE:TRIGBTC
BINANCE:APPCBTC
BINANCE:VIBEBTC
BINANCE:RLCBTC
BINANCE:INSBTC
BINANCE:PIVXBTC
BINANCE:IOSTBTC
BINANCE:CHATBTC
BINANCE:STEEMBTC
BINANCE:NANOBTC
BINANCE:VIABTC
BINANCE:BLZBTC
BINANCE:AEBTC
BINANCE:RPXBTC
BINANCE:NCASHBTC
BINANCE:POABTC
BINANCE:ZILBTC
BINANCE:ONTBTC
BINANCE:STORMBTC
BINANCE:XEMBTC
BINANCE:WANBTC
BINANCE:WPRBTC
BINANCE:QLCBTC
BINANCE:SYSBTC
BINANCE:GRSBTC
BINANCE:CLOAKBTC
BINANCE:GNTBTC
BINANCE:LOOMBTC
BINANCE:BCNBTC
BINANCE:REPBTC
BINANCE:TUSDBTC
BINANCE:ZENBTC
BINANCE:SKYBTC
BINANCE:CVCBTC
BINANCE:THETABTC
BINANCE:IOTXBTC
BINANCE:QKCBTC
BINANCE:AGIBTC
BINANCE:NXSBTC
BINANCE:DATABTC
BINANCE:SCBTC
BINANCE:NPXSBTC
BINANCE:KEYBTC
BINANCE:NASBTC
BINANCE:MFTBTC
BINANCE:DENTBTC
import ccxt
def get_tickers(exchange, quote='BTC'):
markets = exchange.load_markets()
for ticker, details in markets.items():
if not details['active']:
continue
if details['quote'] == quote:
yield details['id']
def get_binance_coins():
binance = ccxt.binance()
for ticker in get_tickers(binance):
yield 'BINANCE:{}'.format(ticker)
def get_polo_coins():
polo = ccxt.poloniex()
for ticker in get_tickers(polo):
a, b = ticker.split('_')
yield 'POLONIEX:{}{}'.format(b, a)
if __name__ == '__main__':
coins = get_binance_coins()
print("\n".join(coins))
POLONIEX:BCNBTC
POLONIEX:BLKBTC
POLONIEX:BTCDBTC
POLONIEX:BTMBTC
POLONIEX:BTSBTC
POLONIEX:BURSTBTC
POLONIEX:CLAMBTC
POLONIEX:DASHBTC
POLONIEX:DGBBTC
POLONIEX:DOGEBTC
POLONIEX:EMC2BTC
POLONIEX:FLDCBTC
POLONIEX:FLOBTC
POLONIEX:GAMEBTC
POLONIEX:GRCBTC
POLONIEX:HUCBTC
POLONIEX:LTCBTC
POLONIEX:MAIDBTC
POLONIEX:OMNIBTC
POLONIEX:NAVBTC
POLONIEX:NEOSBTC
POLONIEX:NMCBTC
POLONIEX:NXTBTC
POLONIEX:PINKBTC
POLONIEX:POTBTC
POLONIEX:PPCBTC
POLONIEX:RICBTC
POLONIEX:STRBTC
POLONIEX:SYSBTC
POLONIEX:VIABTC
POLONIEX:XVCBTC
POLONIEX:VRCBTC
POLONIEX:VTCBTC
POLONIEX:XBCBTC
POLONIEX:XCPBTC
POLONIEX:XEMBTC
POLONIEX:XMRBTC
POLONIEX:XPMBTC
POLONIEX:XRPBTC
POLONIEX:ETHBTC
POLONIEX:SCBTC
POLONIEX:BCYBTC
POLONIEX:EXPBTC
POLONIEX:FCTBTC
POLONIEX:RADSBTC
POLONIEX:AMPBTC
POLONIEX:DCRBTC
POLONIEX:LSKBTC
POLONIEX:LBCBTC
POLONIEX:STEEMBTC
POLONIEX:SBDBTC
POLONIEX:ETCBTC
POLONIEX:REPBTC
POLONIEX:ARDRBTC
POLONIEX:ZECBTC
POLONIEX:STRATBTC
POLONIEX:NXCBTC
POLONIEX:PASCBTC
POLONIEX:GNTBTC
POLONIEX:GNOBTC
POLONIEX:BCHBTC
POLONIEX:ZRXBTC
POLONIEX:CVCBTC
POLONIEX:OMGBTC
POLONIEX:GASBTC
POLONIEX:STORJBTC
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment