Class: Cryptoexchange::Exchanges::Joyso::Services::IdFetcher
- Inherits:
-
Object
- Object
- Cryptoexchange::Exchanges::Joyso::Services::IdFetcher
- Defined in:
- lib/cryptoexchange/exchanges/joyso/services/id_fetcher.rb
Class Method Summary collapse
Class Method Details
.get_id(base) ⇒ Object
5 6 7 8 9 10 |
# File 'lib/cryptoexchange/exchanges/joyso/services/id_fetcher.rb', line 5 def self.get_id(base) tokens = HTTP.get("#{Cryptoexchange::Exchanges::Joyso::Market::API_URL}/system") pairs_result = tokens.parse(:json) base_token = pairs_result['tokens'].select { |s| s['symbol'] == base } base_token[0]['address'] end |