question

Donald Zimmanck avatar image
Donald Zimmanck asked

AMAZON.DATE and Time Zones

Hi everyone, I am working on an solar monitor skill that uses the Enphase Energy API to retrieve data on a solar production. I have a small bug in my energy retrieval. When a user asks, "Alexa, ask Enlighten how much energy my solar array produced today." The date I get returned from AMAZON.DATE is in UTC, whereas the Enphase API wants local time. Usually this isn't an issue, but in the evening or morning UTC and Local time will be on different dates. I know that users have the option to configure their Echo with a location for time zone information. Does anyone know how to retrieve this information and then convert the date into local time?
alexa skills kitvoice-user interface
10 |5000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

1 Answer

Steve A avatar image
Steve A answered
Unfortunately, there's no way at present for developers to access that information, though it's been requested several times. So right now you have to get that information from the user and store it yourself. Steve
10 |5000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.