AI-generated Key Takeaways
-
Hotel Ads XML messages and feeds use specific formats for Date, YearlessDate, DateTime, and Time.
-
Dates are expressed as YYYY-MM-DD (e.g., 2017-12-31), while YearlessDates omit the year, using MM-DD (e.g., 12-31).
-
DateTime follows the RFC 3339 format, YYYY-MM-DDTHH:mm[:ss.SSS]+|-HH:mm[Z], including timezone offsets.
-
Time is represented as HH:MM[:SS] (e.g., 16:20:00 or 16:20) and is interpreted in the property's local time zone.
Use the following date/time formats in the Hotel Ads XML messages and feeds.
Date
Dates are expressed in the following format:
YYYY-MM-DD
YYYY
: Four-digit yearMM
: Two-digit monthDD
: Two-digit day
Example: 2017-12-31
for December 31st, 2017.
YearlessDate
Yearless dates express a date event that occurs every year, and are expressed in the following format:
MM-DD
MM
: Two-digit monthDD
: Two-digit day
Example: 12-31
for December 31st.
DateTime
DateTime uses the RFC 3339 format:
YYYY-MM-DDTHH:mm[:ss.SSS]+|-HH:mm[Z]
YYYY
: Four-digit yearMM
: Two-digit monthDD
: Two-digit dayT
: Separates the date from the timeHH
: Hoursmm
: Minutesss
: (Optional) SecondsSSS
: (Optional) Milliseconds+|-
: Separates the date and time from the timezone offsetHH:mm
: Hours and minutes in the timezone offsetZ
: (Optional) Zero offset
Example: 2017-12-31T16:20:00-04:00
.
You can also specify Z
for the timezone offset, which indicates zero offset.
Time
Time is expressed in the format:
HH:MM[:SS]
HH
: HoursMM
: MinutesSS
: (Optional) Seconds
Example: 16:20:00
or 16:20
.
Times are interpreted in the local time zone of the associated property.