Sha256: d6aa3c26986fef0d964209f26a438c5f84ff65c6e7047fd816e69936b7ee0f1d

Contents?: true

Size: 312 Bytes

Versions: 3

Compression:

Stored size: 312 Bytes

Contents

module IEX
  module Endpoints
    module Crypto
      def crypto(symbol, options = {})
        IEX::Resources::Crypto.new(get("crypto/#{symbol}/quote", options))
      rescue Faraday::ResourceNotFound => e
        raise IEX::Errors::SymbolNotFoundError.new(symbol, e.response[:body])
      end
    end
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
iex-ruby-client-1.1.0 lib/iex/endpoints/crypto.rb
iex-ruby-client-1.0.1 lib/iex/endpoints/crypto.rb
iex-ruby-client-1.0.0 lib/iex/endpoints/crypto.rb