on 11-27-2020 5:32 AM
Hi All,
I want to instantiate a workflow instance from my CAPM based service for which I need to pass the authorization header token. I am able to pass it by passing the headers as below; however I want to replace this method by a dynamic one; for example a destination so that I do not to pass the authorization as below. Any suggestions; how can we do it?
jhodel18 - any suggestions?
Regards,
Karan
var options = {
'method': 'GET',
'url': 'https://scp/oauth/token?grant_type=client_credentials',
'headers': {
'Accept': 'application/json',
'Content-Type': 'application/json',
'Authorization': 'Basic ************************'
}
};
Please check the recent discussions on the workflow service with CAP topic.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Karan,
I haven't really tried SCP Workflow yet, but based on what you are doing -- you are manually getting the JWT token. If your CAP-based service is authenticated by the same UAA service then that means you already have the token within the CAP framework.
I have written a blog post about how the User Authentication works in CAP -- https://blogs.sap.com/2020/07/20/cap-demystify-user-authentication/
The security context is the decoded JWT Token. If you can get that from within CAP then it should be the answer to the dynamic way you are looking for.
I hope it helps!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
74 | |
9 | |
8 | |
7 | |
6 | |
6 | |
5 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.