Sha256: 591f62df66854b25484b75df571cdb80633214924c2250cabc7b311552419fce
Contents?: true
Size: 446 Bytes
Versions: 4
Compression:
Stored size: 446 Bytes
Contents
module IEX module Endpoints module KeyStat def key_stat(symbol, stat, options = {}) result = get("stock/#{symbol}/stats/#{stat}", { token: publishable_token }.merge(options)) raise IEX::Errors::StatNotFoundError.new(stat, result) if result.is_a?(Hash) result rescue Faraday::ResourceNotFound => e raise IEX::Errors::SymbolNotFoundError.new(symbol, e.response[:body]) end end end end
Version data entries
4 entries across 4 versions & 1 rubygems