Class: Flashboy::Exchange
Instance Method Summary
collapse
Methods inherited from Client
#docs, docs, #host, host, #key, key, #name, name, #order_book_path, order_book_path, quote_path, #quote_path
Instance Method Details
#order_book(pair) ⇒ Object
12
13
14
15
16
17
18
19
|
# File 'lib/flashboy/exchange.rb', line 12
def order_book(pair)
id = formatted_pair(pair)
data = request order_book_path(id)
OrderBook.new parse_order_book(data, id).merge(
pair: pair,
exchange: name
)
end
|
#quote(pair) ⇒ Object
3
4
5
6
7
8
9
10
|
# File 'lib/flashboy/exchange.rb', line 3
def quote(pair)
id = formatted_pair(pair)
data = request quote_path(id)
Quote.new parse_quote(data, id).merge(
pair: pair,
exchange: name
)
end
|