"time_utc" is local time

The Netatmo API is a set of webservices allowing developers and third parties to access Netatmo device's data.
Post Reply
Posts: 1
Joined: 02 Oct 2015, 12:33

"time_utc" is local time

Post by GreenRover » 02 Oct 2015, 12:51

Hello, i tryed this both api calls:

All contain a dashboard_data.time_utc field.
But this fields contain a unix timestamp of my local timezone (Europe/Zuerich).

Here a screen shot of the netatmo dashbaord:
netatmo_screen.png (12.21 KiB) Viewed 293 times
The dashboard timezone is: Europe/Zuerich

and here the api result:
Auswahl_031.jpg (80.58 KiB) Viewed 293 times
The timestamp in field dashboard_data.time_utc is not UTC but Europe/Zuerich.

Changing the dashboard time zone settings makes no different to me.

How can i get real UTC timestamps from API?

Posts: 233
Joined: 18 Sep 2012, 12:18

Re: "time_utc" is local time

Post by trosenblatt » 06 Oct 2015, 17:48

Hello GreenRover,

TImestamps are ALWAYS in UTC. That the definition of timestamp (number of seconds since 01 Jan 1970 UTC)
Thomas Rosenblatt, Netatmo Team.

Posts: 2
Joined: 01 Dec 2015, 17:50

Re: "time_utc" is local time

Post by manfredst » 01 Dec 2015, 21:56

Hi, I got the same behavior.
Timestamps are NOT utc.
They are in my local time (vienna = utc+1)
my httpget was at 12-01-2015 21:36
and in the result was :
"last_message":1449001623, <= 12-01-2015 21:27
"last_seen":1449001578, <= 12-01-2015 21:26
"time_utc":1449001578, <= 12-01-2015 21:26
"date_max_temp":1448967229, <= 12-01-2015 11:53
"date_min_temp":1448999169, <= 12-01-2015 20:46
all the timestamps fit with my localtime


Post Reply

Return to “Netatmo API”