Open hypo-thesis opened 4 years ago
What's your question exactly ?
It should be noted that between April 5th and April 12th there were only four market days. The market is closed on the weekend and it was closed for Good Friday as well. count
would be the number of candles rather than using to
. So https://finnhub.io/api/v1/forex/candle?symbol=OANDA:EUR_USD&resolution=D&from=1572651390&count=5&token=mytoken
would (if I'm doing that correctly) give you the five candles after April 5th, which again would skip Good Friday and would give you April 14th instead.
count [optional] Shortcut to set to=Unix.Now and from=Unix.Now - count * resolution_second.
So as the example suggests
request('https://finnhub.io/api/v1/forex/candle?symbol=OANDA:EUR_USD&resolution=D&from=1572651390&to=1575243390&token=mytoken', { json: true }, (err, res, body) => { if (err) { return console.log(err); } console.log(body.url); console.log(body.explanation); });
Returns the results. upon changing the Unix time stamps I receive
NULL
the above code was executed with
1586103635
representing 5th of April and1586709080
representing today 12th of April. which resulted into[1.08538, 1.09283, 1.0935700000000002]
so basically a query of 7 days came back as an array of 3. The day before 4th of April with time stamp of1586017880
comes back as an array of 5.Can you elaborate a little more on how this time frame works and what
count
is ? I do not see count in the sample as well.