cryptoexchange 0.3.4 → 0.4.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (110) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +2 -2
  3. data/lib/cryptoexchange/exchanges/anx/services/market.rb +1 -1
  4. data/lib/cryptoexchange/exchanges/anx/services/pairs.rb +1 -1
  5. data/lib/cryptoexchange/exchanges/bitcoin_indonesia/services/market.rb +1 -1
  6. data/lib/cryptoexchange/exchanges/bitcoin_indonesia/services/pairs.rb +1 -1
  7. data/lib/cryptoexchange/exchanges/bitfinex/market.rb +8 -0
  8. data/lib/cryptoexchange/exchanges/bitfinex/services/market.rb +38 -0
  9. data/lib/cryptoexchange/exchanges/bitfinex/services/pairs.rb +27 -0
  10. data/lib/cryptoexchange/exchanges/bitflyer/services/market.rb +1 -1
  11. data/lib/cryptoexchange/exchanges/bitflyer/services/pairs.rb +1 -1
  12. data/lib/cryptoexchange/exchanges/bithumb/services/market.rb +1 -1
  13. data/lib/cryptoexchange/exchanges/bithumb/services/pairs.rb +1 -1
  14. data/lib/cryptoexchange/exchanges/bitstamp/services/market.rb +1 -1
  15. data/lib/cryptoexchange/exchanges/bitstamp/services/pairs.rb +1 -1
  16. data/lib/cryptoexchange/exchanges/bittrex/services/market.rb +1 -1
  17. data/lib/cryptoexchange/exchanges/bittrex/services/pairs.rb +1 -1
  18. data/lib/cryptoexchange/exchanges/bleutrade/services/market.rb +2 -2
  19. data/lib/cryptoexchange/exchanges/bleutrade/services/pairs.rb +1 -1
  20. data/lib/cryptoexchange/exchanges/btcc/services/market.rb +1 -1
  21. data/lib/cryptoexchange/exchanges/btcc/services/pairs.rb +1 -1
  22. data/lib/cryptoexchange/exchanges/bter/services/market.rb +1 -1
  23. data/lib/cryptoexchange/exchanges/bter/services/pairs.rb +1 -1
  24. data/lib/cryptoexchange/exchanges/ccex/services/market.rb +1 -1
  25. data/lib/cryptoexchange/exchanges/ccex/services/pairs.rb +1 -1
  26. data/lib/cryptoexchange/exchanges/coin_exchange/services/market.rb +1 -1
  27. data/lib/cryptoexchange/exchanges/coin_exchange/services/pairs.rb +1 -1
  28. data/lib/cryptoexchange/exchanges/coincheck/services/market.rb +1 -1
  29. data/lib/cryptoexchange/exchanges/coincheck/services/pairs.rb +1 -1
  30. data/lib/cryptoexchange/exchanges/coinone/services/market.rb +1 -1
  31. data/lib/cryptoexchange/exchanges/coinone/services/pairs.rb +1 -1
  32. data/lib/cryptoexchange/exchanges/cryptopia/services/market.rb +1 -1
  33. data/lib/cryptoexchange/exchanges/cryptopia/services/pairs.rb +1 -1
  34. data/lib/cryptoexchange/exchanges/ether_delta/services/market.rb +1 -1
  35. data/lib/cryptoexchange/exchanges/ether_delta/services/pairs.rb +1 -1
  36. data/lib/cryptoexchange/exchanges/gatecoin/services/market.rb +2 -2
  37. data/lib/cryptoexchange/exchanges/gatecoin/services/pairs.rb +1 -1
  38. data/lib/cryptoexchange/exchanges/gemini/services/market.rb +1 -1
  39. data/lib/cryptoexchange/exchanges/gemini/services/pairs.rb +1 -1
  40. data/lib/cryptoexchange/exchanges/hitbtc/services/market.rb +1 -1
  41. data/lib/cryptoexchange/exchanges/hitbtc/services/pairs.rb +1 -1
  42. data/lib/cryptoexchange/exchanges/korbit/services/market.rb +1 -1
  43. data/lib/cryptoexchange/exchanges/korbit/services/pairs.rb +1 -1
  44. data/lib/cryptoexchange/exchanges/kraken/market.rb +8 -0
  45. data/lib/cryptoexchange/exchanges/kraken/services/market.rb +46 -0
  46. data/lib/cryptoexchange/exchanges/kraken/services/pairs.rb +27 -0
  47. data/lib/cryptoexchange/exchanges/lakebtc/services/market.rb +1 -1
  48. data/lib/cryptoexchange/exchanges/lakebtc/services/pairs.rb +2 -2
  49. data/lib/cryptoexchange/exchanges/liqui/services/market.rb +1 -1
  50. data/lib/cryptoexchange/exchanges/liqui/services/pairs.rb +1 -1
  51. data/lib/cryptoexchange/exchanges/livecoin/services/market.rb +2 -2
  52. data/lib/cryptoexchange/exchanges/livecoin/services/pairs.rb +1 -1
  53. data/lib/cryptoexchange/exchanges/novaexchange/services/market.rb +1 -1
  54. data/lib/cryptoexchange/exchanges/novaexchange/services/pairs.rb +1 -1
  55. data/lib/cryptoexchange/exchanges/okcoin/services/market.rb +1 -1
  56. data/lib/cryptoexchange/exchanges/okcoin/services/pairs.rb +1 -1
  57. data/lib/cryptoexchange/exchanges/quoine/services/market.rb +2 -2
  58. data/lib/cryptoexchange/exchanges/quoine/services/pairs.rb +1 -1
  59. data/lib/cryptoexchange/version.rb +1 -1
  60. metadata +8 -52
  61. data/lib/cryptoexchange/exchanges/anx/models/market_pair.rb +0 -8
  62. data/lib/cryptoexchange/exchanges/anx/models/ticker.rb +0 -8
  63. data/lib/cryptoexchange/exchanges/bitcoin_indonesia/models/market_pair.rb +0 -8
  64. data/lib/cryptoexchange/exchanges/bitcoin_indonesia/models/ticker.rb +0 -8
  65. data/lib/cryptoexchange/exchanges/bitflyer/models/market_pair.rb +0 -8
  66. data/lib/cryptoexchange/exchanges/bitflyer/models/ticker.rb +0 -8
  67. data/lib/cryptoexchange/exchanges/bithumb/models/market_pair.rb +0 -8
  68. data/lib/cryptoexchange/exchanges/bithumb/models/ticker.rb +0 -8
  69. data/lib/cryptoexchange/exchanges/bitstamp/models/market_pair.rb +0 -8
  70. data/lib/cryptoexchange/exchanges/bitstamp/models/ticker.rb +0 -8
  71. data/lib/cryptoexchange/exchanges/bittrex/models/market_pair.rb +0 -8
  72. data/lib/cryptoexchange/exchanges/bittrex/models/ticker.rb +0 -8
  73. data/lib/cryptoexchange/exchanges/bleutrade/models/market_pair.rb +0 -8
  74. data/lib/cryptoexchange/exchanges/bleutrade/models/ticker.rb +0 -8
  75. data/lib/cryptoexchange/exchanges/btcc/models/market_pair.rb +0 -8
  76. data/lib/cryptoexchange/exchanges/btcc/models/ticker.rb +0 -8
  77. data/lib/cryptoexchange/exchanges/bter/models/market_pair.rb +0 -8
  78. data/lib/cryptoexchange/exchanges/bter/models/ticker.rb +0 -8
  79. data/lib/cryptoexchange/exchanges/ccex/models/market_pair.rb +0 -8
  80. data/lib/cryptoexchange/exchanges/ccex/models/ticker.rb +0 -8
  81. data/lib/cryptoexchange/exchanges/coin_exchange/models/market_pair.rb +0 -8
  82. data/lib/cryptoexchange/exchanges/coin_exchange/models/ticker.rb +0 -8
  83. data/lib/cryptoexchange/exchanges/coincheck/models/market_pair.rb +0 -8
  84. data/lib/cryptoexchange/exchanges/coincheck/models/ticker.rb +0 -8
  85. data/lib/cryptoexchange/exchanges/coinone/models/market_pair.rb +0 -8
  86. data/lib/cryptoexchange/exchanges/coinone/models/ticker.rb +0 -8
  87. data/lib/cryptoexchange/exchanges/cryptopia/models/market_pair.rb +0 -8
  88. data/lib/cryptoexchange/exchanges/cryptopia/models/ticker.rb +0 -8
  89. data/lib/cryptoexchange/exchanges/ether_delta/models/market_pair.rb +0 -8
  90. data/lib/cryptoexchange/exchanges/ether_delta/models/ticker.rb +0 -8
  91. data/lib/cryptoexchange/exchanges/gatecoin/models/market_pair.rb +0 -8
  92. data/lib/cryptoexchange/exchanges/gatecoin/models/ticker.rb +0 -8
  93. data/lib/cryptoexchange/exchanges/gemini/models/market_pair.rb +0 -8
  94. data/lib/cryptoexchange/exchanges/gemini/models/ticker.rb +0 -8
  95. data/lib/cryptoexchange/exchanges/hitbtc/models/market_pair.rb +0 -8
  96. data/lib/cryptoexchange/exchanges/hitbtc/models/ticker.rb +0 -8
  97. data/lib/cryptoexchange/exchanges/korbit/models/market_pair.rb +0 -8
  98. data/lib/cryptoexchange/exchanges/korbit/models/ticker.rb +0 -8
  99. data/lib/cryptoexchange/exchanges/lakebtc/models/market_pair.rb +0 -8
  100. data/lib/cryptoexchange/exchanges/lakebtc/models/ticker.rb +0 -8
  101. data/lib/cryptoexchange/exchanges/liqui/models/market_pair.rb +0 -8
  102. data/lib/cryptoexchange/exchanges/liqui/models/ticker.rb +0 -8
  103. data/lib/cryptoexchange/exchanges/livecoin/models/market_pair.rb +0 -8
  104. data/lib/cryptoexchange/exchanges/livecoin/models/ticker.rb +0 -8
  105. data/lib/cryptoexchange/exchanges/novaexchange/models/market_pair.rb +0 -8
  106. data/lib/cryptoexchange/exchanges/novaexchange/models/ticker.rb +0 -8
  107. data/lib/cryptoexchange/exchanges/okcoin/models/market_pair.rb +0 -8
  108. data/lib/cryptoexchange/exchanges/okcoin/models/ticker.rb +0 -8
  109. data/lib/cryptoexchange/exchanges/quoine/models/market_pair.rb +0 -8
  110. data/lib/cryptoexchange/exchanges/quoine/models/ticker.rb +0 -8
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 22bdccda478343a7dd66ddaf26059f5801a20066
4
- data.tar.gz: 6cff0eefe5f32dd033b66a31cb0d88f67a487920
3
+ metadata.gz: b4d08d974d4145bf2068ed0056f31bfe9e2c8419
4
+ data.tar.gz: fc0e014ad4cbdb93d1f84f1b409f2e0279844538
5
5
  SHA512:
6
- metadata.gz: 29013a559084db947eeca02aa0e7bee42c9451fc00a0d47f5135f70f72f52de51a103f88f8793cc083f0318c4e6710e85e5c07a07b4b9d7365d97cd2ed67fc6e
7
- data.tar.gz: f412cbe653f408ba08b50c2be728ef4dbcd1a745c6be779c3170d300280ec3121bb6d42f85ddae75af0e30770997bb2ff07cadb894c49b8db2a27722a2978c04
6
+ metadata.gz: 5f6e9330b3c3d3acfc3afb9210e71d853e63d47663121baf2b61ffb7308f3cc2143c61aa3a51d40ab5d0ffc299f20007925f678f28a611c60720617ce53b22cc
7
+ data.tar.gz: 5d55cd4bf6cc41d3c969617b558db0bf3f1a84e23e0e0f76e89cd9737bd0a650279a6a3f74d54e6ea0cc7fe4afa51b9775dfb8d7e36bed58abf73d7b8813df7c
data/README.md CHANGED
@@ -37,7 +37,7 @@ Or install it yourself as:
37
37
  | Bittrex | Y | | | | Y |
38
38
  | GDAX | | | | | |
39
39
  | Gemini | Y | | | | Y |
40
- | Kraken | | | | | |
40
+ | Kraken | Y | | | | Y |
41
41
  | Poloniex | | | | | |
42
42
  | Coincheck | Y | | | | User-Defined|
43
43
  | Bitflyer | Y | | | | Y |
@@ -51,7 +51,7 @@ Or install it yourself as:
51
51
  | BTC-e | | | | | |
52
52
  | Bleutrade | Y | | | | Y |
53
53
  | Yobit | | | | | |
54
- | Bitfinex | | | | | |
54
+ | Bitfinex | Y | | | | Y |
55
55
  | BTER | Y | | | | Y |
56
56
  | Cryptopia | Y | | | | Y |
57
57
  | Livecoin | Y | | | | Y |
@@ -18,7 +18,7 @@ module Cryptoexchange::Exchanges
18
18
  end
19
19
 
20
20
  def adapt(output)
21
- ticker = Anx::Models::Ticker.new
21
+ ticker = Cryptoexchange::Models::Ticker.new
22
22
  base = output['data']['vol']['currency']
23
23
  target = output['data']['high']['currency']
24
24
 
@@ -11,7 +11,7 @@ module Cryptoexchange::Exchanges
11
11
  def adapt(output)
12
12
  market_pairs = []
13
13
  output.each do |pair|
14
- market_pairs << Anx::Models::MarketPair.new(
14
+ market_pairs << Cryptoexchange::Models::MarketPair.new(
15
15
  base: pair[:base],
16
16
  target: pair[:target],
17
17
  market: Anx::Market::NAME
@@ -21,7 +21,7 @@ module Cryptoexchange::Exchanges
21
21
 
22
22
  def adapt(output, market_pair)
23
23
  output = output['ticker']
24
- ticker = BitcoinIndonesia::Models::Ticker.new
24
+ ticker = Cryptoexchange::Models::Ticker.new
25
25
  ticker.base = market_pair.base
26
26
  ticker.target = market_pair.target
27
27
  ticker.market = BitcoinIndonesia::Market::NAME
@@ -11,7 +11,7 @@ module Cryptoexchange::Exchanges
11
11
  def adapt(output)
12
12
  market_pairs = []
13
13
  output.each do |pair|
14
- market_pairs << BitcoinIndonesia::Models::MarketPair.new(
14
+ market_pairs << Cryptoexchange::Models::MarketPair.new(
15
15
  base: pair[:base],
16
16
  target: pair[:target],
17
17
  market: BitcoinIndonesia::Market::NAME
@@ -0,0 +1,8 @@
1
+ module Cryptoexchange::Exchanges
2
+ module Bitfinex
3
+ class Market
4
+ NAME = 'bitfinex'
5
+ API_URL = 'https://api.bitfinex.com/v1'
6
+ end
7
+ end
8
+ end
@@ -0,0 +1,38 @@
1
+ module Cryptoexchange::Exchanges
2
+ module Bitfinex
3
+ module Services
4
+ class Market < Cryptoexchange::Services::Market
5
+ class << self
6
+ def supports_individual_ticker_query?
7
+ true
8
+ end
9
+ end
10
+
11
+ def fetch(market_pair)
12
+ output = super(ticker_url(market_pair))
13
+ adapt(output, market_pair)
14
+ end
15
+
16
+ def ticker_url(market_pair)
17
+ "#{Cryptoexchange::Exchanges::Bitfinex::Market::API_URL}/pubticker/#{market_pair.base}#{market_pair.target}"
18
+ end
19
+
20
+ def adapt(output, market_pair)
21
+ ticker = Cryptoexchange::Models::Ticker.new
22
+ ticker.base = market_pair.base
23
+ ticker.target = market_pair.target
24
+ ticker.market = Bitfinex::Market::NAME
25
+ ticker.ask = NumericHelper.to_d(output['ask'])
26
+ ticker.bid = NumericHelper.to_d(output['bid'])
27
+ ticker.last = NumericHelper.to_d(output['last_price'])
28
+ ticker.high = NumericHelper.to_d(output['high'])
29
+ ticker.low = NumericHelper.to_d(output['low'])
30
+ ticker.volume = NumericHelper.to_d(output['volume'])
31
+ ticker.timestamp = output['timestamp'].to_i
32
+ ticker.payload = output
33
+ ticker
34
+ end
35
+ end
36
+ end
37
+ end
38
+ end
@@ -0,0 +1,27 @@
1
+ module Cryptoexchange::Exchanges
2
+ module Bitfinex
3
+ module Services
4
+ class Pairs < Cryptoexchange::Services::Pairs
5
+ PAIRS_URL = "#{Cryptoexchange::Exchanges::Bitfinex::Market::API_URL}/symbols"
6
+
7
+
8
+ def fetch
9
+ output = super
10
+ adapt(output)
11
+ end
12
+
13
+ def adapt(output)
14
+ market_pairs = []
15
+ output.each do |pair|
16
+ market_pairs << Cryptoexchange::Models::MarketPair.new(
17
+ base: pair[0..2],
18
+ target: pair[3..-1],
19
+ market: Bitfinex::Market::NAME
20
+ )
21
+ end
22
+ market_pairs
23
+ end
24
+ end
25
+ end
26
+ end
27
+ end
@@ -18,7 +18,7 @@ module Cryptoexchange::Exchanges
18
18
  end
19
19
 
20
20
  def adapt(output)
21
- ticker = Bitflyer::Models::Ticker.new
21
+ ticker = Cryptoexchange::Models::Ticker.new
22
22
  base, target = output['product_code'].split('_')
23
23
  ticker.base = base
24
24
  ticker.target = target
@@ -17,7 +17,7 @@ module Cryptoexchange::Exchanges
17
17
 
18
18
  if product_code =~ /\A[A-Z]{3}_[A-Z]{3}\z/
19
19
  base, target = product_code.split('_')
20
- market_pairs << Bitflyer::Models::MarketPair.new(
20
+ market_pairs << Cryptoexchange::Models::MarketPair.new(
21
21
  base: base,
22
22
  target: target,
23
23
  market: Bitflyer::Market::NAME
@@ -19,7 +19,7 @@ module Cryptoexchange::Exchanges
19
19
 
20
20
  def adapt(output, market_pair)
21
21
  market = output['data']
22
- ticker = Bithumb::Models::Ticker.new
22
+ ticker = Cryptoexchange::Models::Ticker.new
23
23
  ticker.base = market_pair.base
24
24
  ticker.target = market_pair.target
25
25
  ticker.market = Bithumb::Market::NAME
@@ -11,7 +11,7 @@ module Cryptoexchange::Exchanges
11
11
  def adapt(output)
12
12
  market_pairs = []
13
13
  output.each do |pair|
14
- market_pairs << Bithumb::Models::MarketPair.new(
14
+ market_pairs << Cryptoexchange::Models::MarketPair.new(
15
15
  base: pair[:base],
16
16
  target: pair[:target],
17
17
  market: Bithumb::Market::NAME
@@ -20,7 +20,7 @@ module Cryptoexchange::Exchanges
20
20
  end
21
21
 
22
22
  def adapt(output, market_pair)
23
- ticker = Bitstamp::Models::Ticker.new
23
+ ticker = Cryptoexchange::Models::Ticker.new
24
24
  ticker.base = market_pair.base
25
25
  ticker.target = market_pair.target
26
26
  ticker.market = Bitstamp::Market::NAME
@@ -11,7 +11,7 @@ module Cryptoexchange::Exchanges
11
11
  def adapt(output)
12
12
  market_pairs = []
13
13
  output.each do |pair|
14
- market_pairs << Bitstamp::Models::MarketPair.new(
14
+ market_pairs << Cryptoexchange::Models::MarketPair.new(
15
15
  base: pair[:base],
16
16
  target: pair[:target],
17
17
  market: Bitstamp::Market::NAME
@@ -20,7 +20,7 @@ module Cryptoexchange::Exchanges
20
20
  end
21
21
 
22
22
  def adapt(output)
23
- ticker = Bittrex::Models::Ticker.new
23
+ ticker = Cryptoexchange::Models::Ticker.new
24
24
  market = output['result'][0]
25
25
 
26
26
  ticker.base = market['MarketName'].split("-")[0]
@@ -13,7 +13,7 @@ module Cryptoexchange::Exchanges
13
13
  pairs = output['result']
14
14
  market_pairs = []
15
15
  pairs.each do |pair|
16
- market_pairs << Bittrex::Models::MarketPair.new(
16
+ market_pairs << Cryptoexchange::Models::MarketPair.new(
17
17
  base: pair['BaseCurrency'],
18
18
  target: pair['MarketCurrency'],
19
19
  market: Bittrex::Market::NAME
@@ -20,7 +20,7 @@ module Cryptoexchange::Exchanges
20
20
  def adapt_all(output)
21
21
  output['result'].map do |ticker|
22
22
  currency_pair = ticker['MarketName'].split("_")
23
- market_pair = Cryptoexchange::Exchanges::Bleutrade::Models::MarketPair.new(
23
+ market_pair = Cryptoexchange::Models::MarketPair.new(
24
24
  base: currency_pair[1],
25
25
  target: currency_pair[0],
26
26
  market: Bleutrade::Market::NAME
@@ -30,7 +30,7 @@ module Cryptoexchange::Exchanges
30
30
  end
31
31
 
32
32
  def adapt(output, market_pair)
33
- ticker = Bleutrade::Models::Ticker.new
33
+ ticker = Cryptoexchange::Models::Ticker.new
34
34
  ticker.base = market_pair.base
35
35
  ticker.target = market_pair.target
36
36
  ticker.market = Bleutrade::Market::NAME
@@ -13,7 +13,7 @@ module Cryptoexchange::Exchanges
13
13
  def adapt(output)
14
14
  market_pairs = []
15
15
  output['result'].each do |pair|
16
- market_pairs << Bleutrade::Models::MarketPair.new(
16
+ market_pairs << Cryptoexchange::Models::MarketPair.new(
17
17
  base: pair['BaseCurrency'],
18
18
  target: pair['MarketCurrency'],
19
19
  market: Bleutrade::Market::NAME
@@ -22,7 +22,7 @@ module Cryptoexchange::Exchanges
22
22
  end
23
23
 
24
24
  def adapt(output, market_pair)
25
- ticker = Btcc::Models::Ticker.new
25
+ ticker = Cryptoexchange::Models::Ticker.new
26
26
  ticker.base = market_pair.base
27
27
  ticker.target = market_pair.target
28
28
  ticker.market = Btcc::Market::NAME
@@ -11,7 +11,7 @@ module Cryptoexchange::Exchanges
11
11
  def adapt(output)
12
12
  market_pairs = []
13
13
  output.each do |pair|
14
- market_pairs << Btcc::Models::MarketPair.new(
14
+ market_pairs << Cryptoexchange::Models::MarketPair.new(
15
15
  base: pair[:base],
16
16
  target: pair[:target],
17
17
  market: Btcc::Market::NAME
@@ -18,7 +18,7 @@ module Cryptoexchange::Exchanges
18
18
  end
19
19
 
20
20
  def adapt(output, market_pair)
21
- ticker = Bter::Models::Ticker.new
21
+ ticker = Cryptoexchange::Models::Ticker.new
22
22
  ticker.base = market_pair.base
23
23
  ticker.target = market_pair.target
24
24
  ticker.market = Bter::Market::NAME
@@ -13,7 +13,7 @@ module Cryptoexchange::Exchanges
13
13
  output.map do |pair|
14
14
  base, target = pair.upcase.split('_')
15
15
 
16
- Bter::Models::MarketPair.new({
16
+ Cryptoexchange::Models::MarketPair.new({
17
17
  base: base,
18
18
  target: target,
19
19
  market: Bter::Market::NAME
@@ -28,7 +28,7 @@ module Cryptoexchange::Exchanges
28
28
  market = ticker_output['ticker']
29
29
  volume = HashHelper.dig(volumes_output, 'ticker', market_pair.base.downcase, 'vol')
30
30
 
31
- ticker = Ccex::Models::Ticker.new
31
+ ticker = Cryptoexchange::Models::Ticker.new
32
32
  ticker.base = market_pair.base
33
33
  ticker.target = market_pair.target
34
34
  ticker.market = Ccex::Market::NAME
@@ -13,7 +13,7 @@ module Cryptoexchange::Exchanges
13
13
  output['pairs'].map do |pair|
14
14
  base, target = pair.upcase.split('-')
15
15
 
16
- Ccex::Models::MarketPair.new({
16
+ Cryptoexchange::Models::MarketPair.new({
17
17
  base: base,
18
18
  target: target,
19
19
  market: Ccex::Market::NAME
@@ -32,7 +32,7 @@ module Cryptoexchange::Exchanges
32
32
  def adapt(output, market_pair)
33
33
  market = output['result']
34
34
 
35
- ticker = CoinExchange::Models::Ticker.new
35
+ ticker = Cryptoexchange::Models::Ticker.new
36
36
  ticker.base = market_pair.base
37
37
  ticker.target = market_pair.target
38
38
  ticker.market = CoinExchange::Market::NAME
@@ -11,7 +11,7 @@ module Cryptoexchange::Exchanges
11
11
 
12
12
  def adapt(output)
13
13
  output['result'].map do |market|
14
- CoinExchange::Models::MarketPair.new({
14
+ Cryptoexchange::Models::MarketPair.new({
15
15
  base: market['MarketAssetCode'],
16
16
  target: market['BaseCurrencyCode'],
17
17
  market: CoinExchange::Market::NAME
@@ -18,7 +18,7 @@ module Cryptoexchange::Exchanges
18
18
  end
19
19
 
20
20
  def adapt(output)
21
- ticker = Coincheck::Models::Ticker.new
21
+ ticker = Cryptoexchange::Models::Ticker.new
22
22
  ticker.base = 'BTC'
23
23
  ticker.target = 'JPY'
24
24
  ticker.market = Coincheck::Market::NAME
@@ -11,7 +11,7 @@ module Cryptoexchange::Exchanges
11
11
  def adapt(output)
12
12
  market_pairs = []
13
13
  output.each do |pair|
14
- market_pairs << Coincheck::Models::MarketPair.new(
14
+ market_pairs << Cryptoexchange::Models::MarketPair.new(
15
15
  base: pair[:base],
16
16
  target: pair[:target],
17
17
  market: Coincheck::Market::NAME
@@ -19,7 +19,7 @@ module Cryptoexchange::Exchanges
19
19
  end
20
20
 
21
21
  def adapt(output)
22
- ticker = Coinone::Models::Ticker.new
22
+ ticker = Cryptoexchange::Models::Ticker.new
23
23
  ticker.base = output['currency']
24
24
  ticker.target = 'KRW'
25
25
  ticker.market = Coinone::Market::NAME
@@ -13,7 +13,7 @@ module Cryptoexchange::Exchanges
13
13
  market_pairs = []
14
14
  output.each do |_, value|
15
15
  next unless value.is_a? Hash
16
- market_pair = Coinone::Models::MarketPair.new
16
+ market_pair = Cryptoexchange::Models::MarketPair.new
17
17
  market_pair.base = value['currency']
18
18
  market_pair.target = 'krw'
19
19
  market_pair.market = Coinone::Market::NAME
@@ -23,7 +23,7 @@ module Cryptoexchange::Exchanges
23
23
  data = output['Data']
24
24
  base, target = data['Label'].split('/')
25
25
 
26
- ticker = Cryptopia::Models::Ticker.new
26
+ ticker = Cryptoexchange::Models::Ticker.new
27
27
  ticker.base = base
28
28
  ticker.target = target
29
29
  ticker.market = Cryptopia::Market::NAME
@@ -14,7 +14,7 @@ module Cryptoexchange::Exchanges
14
14
  market_pairs = []
15
15
  pairs.each do |pair|
16
16
  base, target = pair['Label'].split('/')
17
- market_pair = Cryptopia::Models::MarketPair.new
17
+ market_pair = Cryptoexchange::Models::MarketPair.new
18
18
  market_pair.base = base
19
19
  market_pair.target = target
20
20
  market_pair.market = Cryptopia::Market::NAME
@@ -23,7 +23,7 @@ module Cryptoexchange::Exchanges
23
23
  name = "#{market_pair.base}_#{market_pair.target}"
24
24
  market = output[name]
25
25
 
26
- ticker = EtherDelta::Models::Ticker.new
26
+ ticker = Cryptoexchange::Models::Ticker.new
27
27
  ticker.base = market_pair.base
28
28
  ticker.target = market_pair.target
29
29
  ticker.market = EtherDelta::Market::NAME
@@ -13,7 +13,7 @@ module Cryptoexchange::Exchanges
13
13
  output.keys.map do |pair|
14
14
  base, target = pair.split('_')
15
15
 
16
- EtherDelta::Models::MarketPair.new({
16
+ Cryptoexchange::Models::MarketPair.new({
17
17
  base: base,
18
18
  target: target,
19
19
  market: EtherDelta::Market::NAME
@@ -20,7 +20,7 @@ module Cryptoexchange::Exchanges
20
20
  def adapt_all(output)
21
21
  output['tickers'].map do |ticker|
22
22
  currency_pair = ticker['currencyPair']
23
- market_pair = Cryptoexchange::Exchanges::Gatecoin::Models::MarketPair.new(
23
+ market_pair = Cryptoexchange::Models::MarketPair.new(
24
24
  base: currency_pair[0..2],
25
25
  target: currency_pair[3..-1],
26
26
  market: Gatecoin::Market::NAME
@@ -30,7 +30,7 @@ module Cryptoexchange::Exchanges
30
30
  end
31
31
 
32
32
  def adapt(output, market_pair)
33
- ticker = Gatecoin::Models::Ticker.new
33
+ ticker = Cryptoexchange::Models::Ticker.new
34
34
  ticker.base = market_pair.base
35
35
  ticker.target = market_pair.target
36
36
  ticker.market = Gatecoin::Market::NAME
@@ -17,7 +17,7 @@ module Cryptoexchange::Exchanges
17
17
  base = currency_pair[0..2]
18
18
  target = currency_pair[3..-1]
19
19
 
20
- market_pair = Gatecoin::Models::MarketPair.new
20
+ market_pair = Cryptoexchange::Models::MarketPair.new
21
21
  market_pair.base = base
22
22
  market_pair.target = target
23
23
  market_pair.market = Gatecoin::Market::NAME
@@ -18,7 +18,7 @@ module Cryptoexchange::Exchanges
18
18
  end
19
19
 
20
20
  def adapt(output, market_pair)
21
- ticker = Gemini::Models::Ticker.new
21
+ ticker = Cryptoexchange::Models::Ticker.new
22
22
 
23
23
  #this api just have bid and ask like below:
24
24
  # {