Skip to Content
1
Mar 10, 2021 at 02:45 PM

Accessing protected CAP service in HTML5 app of other MTA project.

126 Views Last edit Jun 22, 2021 at 02:46 PM 2 rev

I have 2 projects, one with protected CAP service using managed app router and another MTA project with HTML5 application which is also using managed app router. When I try to access protected service in HTML5 app of other MTA project I get 401 unauthorized error but when I try to access service without roles in HTML5 app of other MTA project it works fine.

Is there any specific steps need to be followed to access protected service in HTML5 app ?

I have tried xs-security.json and xs-app.json configuration as per below blog, but couldn't do server.js changes as my second project is MTA project with HTML5 app not CAP service.

https://blogs.sap.com/2020/06/02/how-to-call-protected-app-from-external-app-as-external-user-with-scope/

Kind Regards,

Sagar