CandleStack
← All problem types

Period out of range

The requested period reaches outside the candles the instrument has for this timeframe.

Details

  • Status422 Unprocessable Content
  • Typehttps://candlestack.tech/problems/period-out-of-range

When it happens

  • start is before the first candle of the instrument in this timeframe.
  • end is in the future.

What to do

  1. 1Move start to available_from or later, and end to available_to or earlier; detail says which side failed and the exact value to use.
  2. 2Get the available period in advance from the instrument detail (GET /api/v1/data/instruments/<id>).

In the response

  • instrumentThe instrument id of the request.
  • timeframeThe timeframe of the request, e.g. 1h.
  • available_fromOpen time of the first candle in epoch seconds, or null when it is not known.
  • available_toThe time of the request in epoch seconds; candles are available up to it.