Data formats for Dates and DateTimes

Data formats used by this API for Dates and DateTimes.

Format Abbreviations

TypeFormat
YYYY4-digit year
MM2-digit month with leading zeros
DD2-digit day of month with leading zeros
TLiteral character "T" used to separate the date and time portions of a DateTime
HH2-digit hour in 24 hour format with leading zeros
MI2-digit minutes with leading zeros
SS2-digit minutes with leading zeros
ZLiteral character "Z" representing the timezone as UTC
+/-For Time Zone identification; "+" or "-" indicating the direction of offset from UTC

 

 

Dates and DateTimes in Responses

The responses from this API will always represented in UTC using the following formats

TypeFormatExample DateExample Format
dateYYYY-MM-DDSeptember 30, 20182018-09-30
datetimeYYYY-MM-DDDTHH:MI:SSZSeptember 30, 2018, 6:55:30 PM EDT (Eastern Daylight Time/UTC -4)2018-09-30T22:55:30Z

 

 

Dates and DateTimes in Requests

The preferred format for dates and datetimes being sent in to the API in the request body or URL parameters is the same as described above in the Response Formats. It is preferred as well that the datetimes be sent in UTC. However, you may send them using any timezone provided that the timezone is specified using the format +/-HH or +/-HH:MI. 

Any datetime sent as input to the the API which does not include properly formatted timezone information will be assumed to be UTC

 

Any combination of the following alternatives can be used

AlternativesExample DateExample Datetime
"/" may be used in place of "-" as separators in the date part of a date or datetimeYYYY/MM/DDYYYY/MM/DDTHH:MI:SSZ
Space " " may be used in place of "T" to separate the date and time portions of a datetimeN/AYYYY-MM-DD HH:MI:SSZ
Seconds may be omitted from the time portion of a datetimeN/AYYYY-MM-DDTHH:MIZ
"Z" may be omitted to indicate that time is in UTCN/AYYYY-MM-DDTHH:MI:SS
Alternate timezone may be specified using +/-HH or +/-HH:MI as the offset from UTCN/AYYYY-MM-DDTHH:MI:SS+/-HH:MI
"Z" may be replaced with "+00" or "+00:00" to indicate UTCN/AYYYY-MM-DDTHH:MI:SS+00:00