BinanceFutures.USDM.MarketData.funding_rate

You're seeing just the function funding_rate, go back to BinanceFutures.USDM.MarketData module for more information.
Link to this function

funding_rate(symbol \\ nil, start_time \\ nil, end_time \\ nil, limit \\ 500)

View Source

Specs

funding_rate(
  nil | binary(),
  nil | pos_integer(),
  nil | pos_integer(),
  pos_integer()
) :: {:ok, map()} | {:ok, [map()]} | BinanceFutures.HTTPClient.error()

Gets Funding Rate History.

Additional API details:

  • If startTime and endTime are not sent, the most recent limit datas are returned.
  • If the number of data between startTime and endTime is larger than limit, return as startTime + limit.
  • In ascending order.

If symbol will be omitted rates for all symbols will be returned.

Example

iex(3)> BinanceFutures.USDM.MarketData.funding_rate("BNBUSDT")
{:ok,
[
  %{
    "fundingRate" => "-0.00149526",
    "fundingTime" => 1601971200005,
    "symbol" => "BNBUSDT"
  },
  %{
    "fundingRate" => "-0.00081215",
    "fundingTime" => 1602000000000,
    "symbol" => "BNBUSDT"
  },
  %{"fundingRate" => "0.00000000", "fundingTime" => 1603267200004, ...},
  %{"fundingRate" => "0.00000000", ...},
  %{...},
  ...
]}