Disclaimer: While I have been working with RAML for almost a year now, and am familiar with the 0.8 spec, I’m new to this forum category. Also, I have not been involved in the ongoing efforts of defining RAML 1.0 yet. Please treat my incompetence with kindness.
As far as I can see, the
date type in RAML 0.8 is derived from the one used in the HTTP protocol. Of course, that is very useful when defining header parameters in RAML. But it may not be the best available date format for other data-processing scenarios. In particular, it is slightly redundant, contains cultural baggage, needs to be fully parsed for comparisons or sorting. Also, it would lead to additional URL encoding when used in uri-parameters or query-parameters, due to the spaces.
On the other hand, both schema languages in use with RAML employ more sane date formats:
- XML Schema makes use of ISO 8601
(and also defines some neat formats for durations)
- JSON-Schema makes use of RFC 3339
… which for most practical purposes are equal, as far as I know.
I’d like to suggest to introduce an additional date type to RAML, that would be more consistent with the schema languages. It would also lack most of the shortcomings that I mentioned above. How about calling it
isodate? While at it, you might also consider adding some of the duration types from XML schema?