Class: Honeymaker::Clients::KrakenFutures

Inherits:
Honeymaker::Client show all
Defined in:
lib/honeymaker/clients/kraken_futures.rb

Constant Summary collapse

URL =
"https://futures.kraken.com"
RATE_LIMITS =
{ default: 500, orders: 500 }.freeze

Constants inherited from Honeymaker::Client

Honeymaker::Client::OPTIONS

Instance Attribute Summary

Attributes inherited from Honeymaker::Client

#api_key, #api_secret

Instance Method Summary collapse

Methods inherited from Honeymaker::Client

#get_balances, #initialize, rate_limits, #validate

Constructor Details

This class inherits a constructor from Honeymaker::Client

Instance Method Details

#get_accountsObject



12
13
14
# File 'lib/honeymaker/clients/kraken_futures.rb', line 12

def get_accounts
  get_private("/derivatives/api/v3/accounts")
end

#get_fills(last_fill_time: nil) ⇒ Object



16
17
18
# File 'lib/honeymaker/clients/kraken_futures.rb', line 16

def get_fills(last_fill_time: nil)
  get_private("/derivatives/api/v3/fills", { lastFillTime: last_fill_time })
end

#get_open_positionsObject



20
21
22
# File 'lib/honeymaker/clients/kraken_futures.rb', line 20

def get_open_positions
  get_private("/derivatives/api/v3/openpositions")
end

#historical_funding_rates(symbol:) ⇒ Object



24
25
26
# File 'lib/honeymaker/clients/kraken_futures.rb', line 24

def historical_funding_rates(symbol:)
  get_public("/derivatives/api/v3/historicalfundingrates", { symbol: symbol })
end