on 05-14-2018 4:22 PM
Hello,
I created an API that consumes an oData service created in SAP Gateway, and the response always looks like this :
I've read that in oData 2.0 the metadata isn't optional, but is there any way to hide this from the response ? Mostly because it contains a direct URL to our Backend, and I don't want the API consumers to have access to this data.
I tried looking up for the methods in DPC_EXT class but I couldn't find any.
Please help!
The URLs in __metadata should be the URLs used by your API consumers to access the API, which they need to know anyway.
If your API is "hidden" behind a proxy and __metadata does not contain the "external" proxy URLs but instead shows the "internal" backend URLs, then the proxy isn't forwarding its external URL information to Gateway. See https://wiki.scn.sap.com/wiki/display/BSP/Using%20Proxies for information on how proxies and ABAP backends can be configured to produce correct "external" URLs.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
this is not possible.
You could use a reverse proxy and put it in between your backend system and the API consumers to shield the hostname of your system from the consumers.
BR
Andre
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
86 | |
10 | |
10 | |
9 | |
6 | |
6 | |
6 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.