cancel
Showing results for 
Search instead for 
Did you mean: 

SAP CAP metadata restriction

rcaziraghi
Participant

Hello experts,

Does anyone have any successful implementation of the unrestricted metadata endpoint configuration? I tried to follow the instructions in the CAP Cookbook (https://cap.cloud.sap/docs/guides/authorization#requires) to remove the metadata restriction but without success. Can anyone help?

Thank you.

cds.env.runtime.protectMetadata = false

protectmetadata.png

unauthorized.png

Accepted Solutions (1)

Accepted Solutions (1)

gregorw
Active Contributor

I've just tried and simply added:

cds.env.odata.protectMetadata = false;

to a custom server.js. That works for me.

johannesvogel
Advisor
Advisor

Thanks for answering, gregorw!

672cbd118d064be98c30c44331ab059e We'll fix the documentation. Sorry for the inconvenience!

rcaziraghi
Participant
0 Kudos

That worked for me Gregor, thank you!

Thank you Johannes!

Answers (0)