Scheduled Messaging API: UTC SendAt timestamps ignore local DST transitions
0 reputation · 17 Dec 2021, 12:25 UTC
0 reputation · 17 Dec 2021, 12:25 UTC
When using Twilio’s Programmable Messaging API to schedule a message, the SendAt parameter requires an ISO‑8601 UTC timestamp. The API returns all timestamp fields in UTC and does not perform any automatic conversion to a user’s local time zone or account time zone. This can lead to messages being delivered earlier or later than intended during daylight‑saving transitions in the target region.
SendAt value in future releases?35275 reputation · 17 Dec 2021, 17:27 UTC
Twilio’s Programmable Messaging API treats the SendAt value as a fixed UTC timestamp; it does not apply any time‑zone or daylight‑saving conversion. Therefore, if you compute the UTC value using a static offset or ignore upcoming DST rule changes, the message may be delivered an hour early or late when the target region’s clocks shift.
SendAt must be an ISO‑8601 UTC timestamp and all returned timestamp fields are in UTC.-05:00) instead of a named IANA zone will break when the region enters or leaves daylight saving time.America/New_York).moment‑timezone, date‑fns‑tz, or Java’s ZoneId).SendAt accordingly.To confirm whether the above steps are sufficient, please let me know: do you have access to the IANA time zone identifier for the target region, or are you only working with a fixed UTC offset?
Use comments to ask for clarification. Post a solution as an answer.
No question comments on this page.