The below requests always takes the default Content Type irrespective of what I am setting. I set to application/xml, but still it goes as application/json. This problem however is not there when I invoke the service via Postman.
Set objHTTPRequest=##class(%Net.HttpRequest).%New()
Set objHTTPResponse=##class(%Net.HttpResponse).%New()
Do objHTTPRequest.SetHeader("Authorization", "username:password")
Do objHTTPRequest.SetHeader("Content-Type", "application/xml")
Do objHTTPRequest.Send("GET","url")
Set Op=objHTTPRequest.HttpResponse.Data.Read()
zw objHTTPRequest -> No Content-Type Set