Change “Response content type”
-
Thanks for updating your plugin, adding “produces” parameter gets reflected fine by swagger interface showing them in “Response content type”.
My doubt is how to distinguish 2 different formats in the request parameter as I can’t see any difference when inspecting WordPress “$request_data” parameter in register_rest_route callback function.
Right now I use a GET parameter adding the format manually to the URL request, but it should be possible through the interface. When changing the format using “Response content type” curl adds an -H parameter to express the expected format. But the request URL itself doesn’t change, it always is https://xrcb.cat/ca/wp-json/xrcb/v1/radios
The page I need help with: [log in to see the link]
- The topic ‘Change “Response content type”’ is closed to new replies.