@@ -33,15 +33,15 @@ class GenerateSupportedCoinsJson {
3333 listOf (this ::ascendex, this ::bibox, this ::bigone, this ::binance, this ::binance_us, this ::bit2c,
3434 this ::bitbank, this ::bitcambio, this ::bitclude,
3535 this ::bitcoinde, this ::bitfinex, this ::bitflyer, this ::bithumb, this ::bitglobal, this ::bitmart,
36- this ::bitpanda, this ::bitpay, this ::bitso, this ::bitstamp, this ::bittrex, this ::bitrue, this ::bitvavo, this ::bleutrade,
36+ this ::bitpanda, this ::bitpay, this ::bitso, this ::bitstamp, this ::bittrex, this ::bitrue, this ::bitvavo,
3737 this ::btcbox, this ::btcmarkets, this ::btcturk, this ::bybit, this ::cexio,
3838 this ::chilebit, this ::coinbase, this ::coinbasepro, this ::coindesk, this ::coingecko,
3939 this ::coinjar, this ::coinmate, this ::coinone, this ::coinsbit, this ::coinsph, this ::cointree,
4040 this ::cryptocom, this ::deversifi, this ::digifinex, this ::exmo, this ::foxbit, this ::gateio, this ::gemini,
4141 this ::hitbtc, this ::huobi, this ::independent_reserve, this ::indodax, this ::itbit, this ::korbit, this ::kraken, this ::kucoin,
4242 this ::kuna, this ::lbank, this ::liquid, this ::luno, this ::mercado, this ::mexc, this ::ndax,
4343 this ::nexchange, this ::okcoin, this ::okx, this ::p2pb2b, this ::paribu, this ::paymium, this ::phemex,
44- this ::pocketbits, this ::poloniex, this ::probit, this ::therock, this :: tradeogre, this ::uphold,
44+ this ::pocketbits, this ::poloniex, this ::probit, this ::tradeogre, this ::uphold,
4545 this ::vbtc, this ::whitebit, this ::wyre, this ::xt, this ::yadio, this ::yobit, this ::zbg, this ::zonda
4646 ).zip(Exchange .values())
4747
@@ -320,8 +320,10 @@ class GenerateSupportedCoinsJson {
320320 }
321321
322322 private fun bitpay (): List <String > {
323- return parse(" https://bitpay.com/currencies" , " $.data[*].code" ).flatMap {
324- listOf (" BTC_$it " , " BCH_$it " )
323+ val coins = parse(" https://bitpay.com/currencies" , " $.data[?(@.chain)].code" ).filterNot { it == " PAX" }
324+ val currencies = parse(" https://bitpay.com/currencies" , " $.data[*].code" )
325+ return coins.flatMap { coin ->
326+ currencies.map { currency -> " ${coin} _$currency " }
325327 }
326328 }
327329
@@ -346,10 +348,6 @@ class GenerateSupportedCoinsJson {
346348 return parse(" https://api.bitvavo.com/v2/markets" , " $[*].market" )
347349 }
348350
349- private fun bleutrade (): List <String > {
350- return parse(" https://bleutrade.com/api/v3/public/getmarkets" , " $.result[*].MarketName" )
351- }
352-
353351 private fun btcbox (): List <String > {
354352 return parseKeys(" https://www.btcbox.co.jp/api/v1/tickers" , " $" )
355353 }
@@ -411,8 +409,10 @@ class GenerateSupportedCoinsJson {
411409 }
412410
413411 private fun coinone (): List <String > {
414- return parse(" https://tb.coinone.co.kr/api/v1/tradepair/" , " $.tradepairs[*].target_coin_symbol" ).map {
415- it + " _KRW"
412+ val currencies = listOf (" KRW" )
413+ return currencies.flatMap { currency ->
414+ val list = parse(" https://api.coinone.co.kr/public/v2/markets/$currency " , " $.markets[*].target_currency" )
415+ list.map { " ${it} _$currency " }
416416 }
417417 }
418418
@@ -572,10 +572,6 @@ class GenerateSupportedCoinsJson {
572572 return parse(" https://api.probit.com/api/exchange/v1/market" , " $.data[*].id" )
573573 }
574574
575- private fun therock (): List <String > {
576- return parse(" https://api.therocktrading.com/v1/funds/tickers" , " $.tickers[*].fund_id" )
577- }
578-
579575 private fun tradeogre (): List <String > {
580576 val list = JsonPath .read(get(" https://tradeogre.com/api/v1/markets" ), " $[*]" ) as List <Map <String , * >>
581577 return list.map { it.keys.first().split(" -" ).reversed().joinToString(" _" ) }
@@ -604,7 +600,7 @@ class GenerateSupportedCoinsJson {
604600 }
605601
606602 private fun xt (): List <String > {
607- return parseKeys (" https://api .xt.com/data/api/v1/getTickers " , " $" )
603+ return parse (" https://sapi .xt.com/v4/public/symbol " , " $.result.symbols[*].symbol " )
608604 }
609605
610606 private fun yadio (): List <String > {
0 commit comments