All Questions
Api Design easy

A client wants the response in XML instead of JSON. How should it indicate this?

  1. A Send the request to a format-specific endpoint like /api/xml/users.
  2. B Include the Accept: application/xml header in the request.
  3. C Include the Content-Type: application/xml header in the request.
  4. D Set a custom X-Response-Format: xml header.

One system design question a day, with spaced repetition so the ones you miss come back.

Get the app

Related questions