title: get response status of 415 Unsupported Media Type REST client
body: <p>I want to make a POST request to REST API running on Azure and I want to pass a javascript object with the POST request. But response shows 415 error code Unsupported Media type. I did try changing 'Content Type' to 'Application/json', but I get the same response.</p>
  
  <p>componentDidMount() {</p>
  
  <pre><code>const  bodyFormData = new FormData();
  bodyFormData.set('id', 30958);
  axios({
    method: 'post',
    url: 'https://example./api/example/GetExamplData',
    data: bodyFormData,
    config: { headers: {
        'Content-Type': 'application/x-www-form-urlencoded',
      }}
    })
      .then((response) =&gt; {console.log(response)}) 
      .catch(error =&gt; {console.log( 'the error has occured: ' + error) })
  }
  </code></pre>