Module: Bitfinex::RESTv1FundingBook

Included in:
RESTv1
Defined in:
lib/rest/v1/funding_book.rb

Instance Method Summary collapse

Instance Method Details

#funding_book(currency = "usd", params = {}) ⇒ Hash

Get the full margin funding book

@example:

client.funding_book

Parameters:

  • currency (string) (defaults to: "usd")

    (optional) Speficy the currency, default “USD”

  • params (defaults to: {})

    :limit_bids [int] (optional) Limit the number of funding bids returned. May be 0 in which case the array of bids is empty.

  • params (defaults to: {})

    :limit_asks [int] (optional) Limit the number of funding offers returned. May be 0 in which case the array of asks is empty.

Returns:

  • (Hash)

    of :bids and :asks arrays



11
12
13
14
# File 'lib/rest/v1/funding_book.rb', line 11

def funding_book(currency="usd", params = {})
  check_params(params, %i{limit_bids limit_asks})
  get("lendbook/#{currency}", params: params).body
end