class Cryptoexchange::Exchanges::Rightbtc::Services::Pairs

Constants

PAIRS_URL

Public Instance Methods

adapt(output) click to toggle source
# File lib/cryptoexchange/exchanges/rightbtc/services/pairs.rb, line 11
def adapt(output)
  markets = output['status']['message']
  markets.map do |pair|
    Cryptoexchange::Models::MarketPair.new(
      base: pair[1]['bid_asset_symbol'],
      target: pair[1]['ask_asset_symbol'],
      market: Rightbtc::Market::NAME
    )
  end
end
fetch() click to toggle source
Calls superclass method Cryptoexchange::Services::Pairs#fetch
# File lib/cryptoexchange/exchanges/rightbtc/services/pairs.rb, line 6
def fetch
  output = super
  adapt(output)
end