Hello i hawing problems to get data from thingspeek, it always shows blank in first 2 hours
How to fix it?
Hello i hawing problems to get data from thingspeek, it always shows blank in first 2 hours
Welcome to forum @aigarsinserts
Is the date data coming from thingspeek UTC?
the date looks like this https://api.thingspeak.com/channels/2299167/feeds.json
im using https://api.thingspeak.com/channels/2299167/feeds.json?start=${__from:date:YYYY-MM-DD}%20${__from:date:HH}:${__from:date:mm}:${__from:date:ss}&end=${__to:date:YYYY-MM-DD}%20${__to:date:HH}:${__to:date:mm}:${__to:date:ss} to get custom timeframe data
Try to set dashboard timezone to UTC
Whatâs your browser timezone? UTC+/-2?
I did use -2, +2 and utc it did not change at all.
It is +2
So you still have not answered if the time coming from that api is utc.
So which plugin are you using to fetch the data?
You can use jsonata to convert that date time to utc
Im not sure data comes from esp8266 then it goes to thingspeek and only then to grafana my local time is +2 utc, in thingspeek it is working fine. Only in grafana first 2 hours are missing
Im using âyesoreyeram-infinity-datasourceâ
Im already cheeasing the time by using " https://api.thingspeak.com/channels/2299167/feeds.json?start=${__from:date:YYYY-MM-DD}%20${__from:date:HH}:${__from:date:mm}:${__from:date:ss}&end=${__to:date:YYYY-MM-DD}%20${__to:date:HH}:${__to:date:mm}:${__to:date:ss}" it is used to tell thingspeek what timeframe to use
I bet ${__to:date:YYYY-MM-DD}%20${__to:date:HH}:${__to:date:mm}:${__to:date:ss}
formats in your browser local time zone.
So just change your browser (computer) timezone to UTC and it should be fine.
See if this doc helps which explain the time range problem with thingspeak.
Having the same problem.
Iâm at UTC+01 :00
Querying Thingspeaks give also the âcreated_atâ with +1 ( when removing the format in Grafana), example : Fri Mar 15 2024 08:56:30 GMT+0100 (Central European Standard Time)
Iâm missing the 1 (left) hour when using â3 hourâ interval (but I receive data from the query)
Iâm receiving âno dataâ when using â1 hourâ or âLast 5 minâ interval.
(Itâs no option for me to change the PC Windows time to UTC )
Tried JSON and CSV with the same result/problem.
Also using ${__to:date:YYYY-MM-DD}%20${__to:date:HH}:${__to:date:mm}:${__to:date:ss} in the query.
Searched and read already a lot of related community pages but still didnât find the solution.
THIS IS THE SOLUTION
I found solution, i hope you will check it and tell if it works for you.
you need to add ?timezone=Europe%2FRiga before start, here is for differed timezones Time Zones Reference - MATLAB & Simulink - MathWorks Switzerland
or if you use âofsetâ (feeds.json?ofset?start=$) works just fine
My boy ye did it, we fixed grafana.
Please Someone send my apology letter to admin
**