API date-time response is...
API date-time response is not compliant with RFC3339
- Accueil
- Espace Client
- Community Forum
- General Discussion
- Product Suggestions
- API date-time response is not compliant with RFC3339
- Community Forum
- API date-time response is not compliant with RFC3339
Topic: API date-time response is not compliant with RFC3339
According to OpenAPI data type "date-time" should be in RFC3339 format (https://swagger.io/docs/specification/data-models/data-types/). Example: 2018-05-08T14:52:11.52Z (Note the "Z" in the end)The current API response truncates the timezone information, meaning the "Z" and everything that should come after it is missing.Example:curl -X GET "https://api.dynu.com/v2/dns" -H "accept: application/json" -H "API-Key: verysecurekey" | jq... "createdOn": "2022-06-16T06:13:42", "updatedOn": "2023-01-27T10:30:01.77"Note the missing "Z".This causes issues when clients try to parse response according to standard. For example an openapi go client generated from your API spec will fail to parse any time field and will throw error on every response that contains such field.Please fix the response implementation.
Reply with quote | Report
Author | Topic: API date-time response is not compliant with RFC3339 |
---|---|
krenakzs Joined: 15/06/2022 |
API date-time response is not compliant with RFC3339 vendredi 27 janvier 2023 07:49
According to OpenAPI data type "date-time" should be in RFC3339 format (https://swagger.io/docs/specification/data-models/data-types/). Example: 2018-05-08T14:52:11.52Z (Note the "Z" in the end)The current API response truncates the timezone information, meaning the "Z" and everything that should come after it is missing.Example:curl -X GET "https://api.dynu.com/v2/dns" -H "accept: application/json" -H "API-Key: verysecurekey" | jq... "createdOn": "2022-06-16T06:13:42", "updatedOn": "2023-01-27T10:30:01.77"Note the missing "Z".This causes issues when clients try to parse response according to standard. For example an openapi go client generated from your API spec will fail to parse any time field and will throw error on every response that contains such field.Please fix the response implementation.
|
It is currently vendredi 15 novembre 2024 03:25 US Mountain Standard Time
vendredi 15 novembre 2024 03:25