Skip to content

Add response format middleware for JSON/XML output, updated README about this topic

Summary

In this PR a Response Format Middleware was created. It that allows API consumers to request responses in either JSON or XML format.

JSON format is the default format.

How to Test

Open Swagger UI and:

  1. Call any endpoint (/api/Book/list), expected format of the output is JSON.

  2. Now call the same endpoint but add to the URL (api/Book/list?format=xml), expected format of the ouput is XML.

Merge request reports

Loading