-2

I'm trying to make a POST request to edit the configuration of ocelot.json file.

I'm using the https://ocelot.readthedocs.io/en/latest/features/administration.html API

POST {adminPath}/configuration

This overrwrites the existing configuration (should probably be a put!). I reccomend getting your config from the GET endpoint, making any changes and posting it back…simples.

But when I try to make a POST request with the JSON as body it gives me this response: Response code: 415 Unsupported Media type

I tried searching on the internet but couldnt find anything that would solve this

Alex
  • 1

1 Answers1

-1

The problem was in postman using 2 Content-type headers, so as soon as I removed wrong one it worked..

Alex
  • 1
  • provide code and prints to prove your possible solution. I'm facing this issue but the postman don't have 2 content-type and this actually don't make much sense – Joao Victor Aug 31 '23 at 19:42