Data types
Here is how various data types not native to JSON are encoded.
Datetime
Datetime is date and time passed as a single value.
Datetime values are passed around as strings in the ISO 8601 format.
Example: "2015-03-15T10:28:27+00:00"
is March 15, 2015, at 10:28:27 in UTC. Note T
separating date and time.
For certain fields datetime values can have higher precision by including milliseconds: "2015-03-15T10:28:27.673+00:00"
.
Timestamp
The rules are the same as for datetime but precision is up to microseconds: "2015-03-15T10:28:27.673531+00:00"
.
Date
As with datetime, ISO 8601 is used to represent dates.
Example: "2014-09-04"
is September 4, 2014.
Time
Time is precise up-to-minutes. Values use the 24-hour format.
Example: "15:23"
.
Time with seconds is not valid.