I want to receive XML from the stats management API. As per reference, it supports both JSON (by default) and text/xml.
Assuming, this needs to be sent in as Accept header, when I send text/xml, I receive the below "Not Acceptable" response. This seems to work with all the other management API calls.
GET https://api.enterprise.apigee.com/v1/o/{org}/environments/{env}/stats/apis HTTP/1.1 Host: api.enterprise.apigee.com Accept: text/xml Authorization: Basic {auth} HTTP/1.1 406 Not Acceptable Date: Mon, 08 May 2017 06:00:26 GMT Server: Apigee LB Content-Length: 0 Connection: keep-alive
Any thoughts?
@Girish Gajria , Thank you for highlighting same. I can able to reproduce above issue. @spadmanabhan Any help here ? ~~MGMT-4055~~
@Girish Gajria - as a workaround you could send the payload into an Apigee Edge loopback proxy to do the JSONToXML conversion.
FYI
accept:application/xml also causes a 406 "Not Acceptable"
@Dino, thanks for the suggestion. Doing the same for now (running a JSONtoXML conversion on the response). Luckily for me, my URL is configurable (so I can switch back and forth). But looking forward to the solution, nonetheless.
We will look into this and update.
User | Count |
---|---|
1 | |
1 | |
1 | |
1 | |
1 |