Can't set custom header in httpclient (ionic 3 app angular 5)

I am trying to use an api which requires an API key ‘Auth’, I am trying to send the key using httpHeaders using below code

getTest(){
let data = {'loginusertype':'12','loginuserid':'51','apitype':'1','start':'0','end':'20'};
let headers = new HttpHeaders({'Content-Type':'application/json; charset=utf-8','Auth':'593eb2c274d640a8798493bf340e08b6'});
this.http.post('http://www.mymediaxchange.com/api/serviceapi/v1/currentworks',data,{headers:headers})
.subscribe(
  (data) => console.log(data),
  (error) => console.log(error)
)  }

But I am not able to set headers the headers are set as below

Hi @kalpeshkkalekar :wave:

The screenshot you posted is showing the preflight request, sent from the browser to the API in order to check if CORS is supported. If the API responds allowing the real request to be made, then you will see the Auth header in the second request.

There is a new section in the docs about how CORS works and common errors and solutions: https://ionicframework.com/docs/faq/cors

Best,
Rodrigo