I have added a simple API to my Apigee account but on making a request via Apigee, a 301 response is being returned and the Apigee URL is being rewritten to the target API URL.
Testing the target API directly returns a 200 response and testing on two other competitor platforms doesn’t show this behaviour either which makes me think there is a setting somewhere that I need to change to have Apigee act as a reverse proxy instead of a redirect.
When setting up the API in Apigee I did specify Reverse Proxy.
Can you share Target Url if possible to try out same ? If target returns 301 & you test same in the browser then page will be redirected. I believe it’s a browser setting rather than Apigee. Did you get a chance to test same using tool like curl / postman ?
You can share target URL using secure comments option below the comment box submit button if it’s confidential.
Where do we see that being generated? Refer to trace picture below. Is it in ‘response from target’? If so, click on ‘request sent to target’ and click show curl and compare that to the curl you run directly. If not, it must be coming in the ‘response’ sent to client section. Do you have any policies that are being executed between response from target and response to client?