Open Lan2u opened 4 years ago
I would lean towards using the Headers option as it is more natural via HTTP and ensures that the api endpoints are kept as clean as possible
I would lean towards using the Headers option as it is more natural via HTTP and ensures that the api endpoints are kept as clean as possible
Agree
Is your feature request related to a problem? Please describe. The API will currently always return JSON, we should allow for the ability to return multiple formats.
Describe the solution you'd like The return format could either be specified directly in the path like {API_URL}/{FORMAT} e.g. /events/{id}/json, /events/{id}/xml or the formats that the client accepts could be included using an AcceptsHeader and then the server chooses the 'best' one.
Describe alternatives you've considered See above
Additional context https://docs.microsoft.com/en-us/azure/architecture/best-practices/api-implementation#support-content-negotiation