unix

JSON Timestamps

The unix-tz-json format

[1] A unix-tz-json value is a JSON object.

[9] A unix-tz-json value represents a timestamp and optional time-zone offset, or is invalid.

[4] A unix-tz-json value MUST have a pair whose name is unix and whose value is a JSON number. The value is the unix time representation of the timestamp of the unix-tz-json value.

[5] A unix-tz-json value MAY have a pair whose name is tzOffset and whose value is a JSON number or null. The value is the UTC offset representation of the time-zone offset of the unix-tz-json value. If there is no such pair, or if the value is null, the time-zone offset of the unix-tz-json is omitted.

[6] A unix-tz-json value MUST NOT have any other name/value pair.

[10] If a unix-tz-json value does not have a pair whose name is unix, the unix-tz-json value is invalid.

[11] If a unix-tz-json value have a pair whose name is unix and whose value is not a JSON number, the unix-tz-json value is invalid.

[12] If a unix-tz-json value have a pair whose name is unix and whose value is not a JSON number or null, the unix-tz-json value is invalid.

Definitions

[2] This specification depends on the Infra Standard.

[3] The terms number and object are defined by ECMA-404.

[7] Dates and times are to be interpreted per the time system defined by the HTML Standard.

[8] A unix time is the number of seconds since 00:00:00 UTC of January 1st, A.D. 1970. Note that the time system of HTML does not have leap seconds. Times before 1970 are represented as negative values. Fractional numbers can be used for subseconds.

[13] A UTC offset is the number of seconds between UTC and a local time. If the value is positive, the local time is ahead of UTC. If the value is negative, the local time is behind of UTC.

Notes