cancel
Showing results for 
Search instead for 
Did you mean: 

SAP BTP services getting unauthorized error

subhm779
Explorer
0 Kudos

We've having issues in different regions of BTP.

For example CAP OData is giving unauthorized error 401 , Region used is us10.

Hopefully this gets resolved ASAP because this is affecting our production services.

Accepted Solutions (0)

Answers (1)

Answers (1)

Willem_Pardaens
Product and Topic Expert
Product and Topic Expert
0 Kudos

Hi Shubham,

Kindly elaborate on your issue?

CAP is a development framework with which you can create applications. If the CAP-developed endpoints give you HTTP Error 401 this means that you did not properly authenticate before calling the endpoint. You have to authenticate first, but how to do this depends on the chosen security settings in the CAP application.

For example, for XSUAA based authentication, you need to first generate an OAuth access token and use that as Bearer token in the Authorization header when calling your endpoint. The access token can be generated by calling the /oauth/token endpoint using the client_id and client_secret mentioned in the XSUAA binding or Service Key.

subhm779
Explorer
0 Kudos

Thanks Willem for the information , its now resolved the issue was on authentication method on xs-app JSON file.