TinkoffInvest.HistoricalData (tinkoff_invest v0.2.0) View Source

Module for getting historical data for a security.

Useful when testing your algo or just need some insight on past prices

Link to this section Summary

Functions

Get candle history for specified figi by from, to and interval

Link to this section Functions

Link to this function

candles(figi, from, to, interval)

View Source

Specs

Get candle history for specified figi by from, to and interval

Example:

from = DateTime.utc_now() |> DateTime.add(-86400, :second)
to = DateTime.utc_now()
TinkoffInvest.HistoricalData.candles("SOMEFIGI", from, to, "1min")

Possible intervals:

1min, 2min, 3min, 5min, 10min, 15min, 30min, hour, day, week, month