cancel
Showing results for 
Search instead for 
Did you mean: 

Get userId from oAuth Token

0 Kudos

Hi colleagues! I hope everything is ok, and I would like to thank you in advanced for your expert advice. If you think that there is somebody else that can answer this question here below please forward this to him/her.

We are working in the Success Acceleration and Automation Team under Michael’s Rieder organization, we are a young team we are just starting working with SCPI middleware for the creation of services for Successfactors. We are creating an iFlow in SAP Cloud Platform Integration service where the call is authenticated using oAuth and first thing we would like to do is to check the user that is accessing (User ID) in order to know which customer this user belong to and then secure the access to the Backend.

Have you got an idea about how we could get this User ID? Have you got any JS or Groovy Script that we could use to do so? Is there something in SCPI to deal with this? I think the way to proceed would be to get the oauth token of the logged in user, and with that token make a call to the authorization server to identify the user. Ideally the script is the method we want to follow as seen in the picture:

iflow.png

Also, I saw that google has some APIs such as htttps://domain/userinfo?alt=json&access_token=youraccess_token that you can use to request the user’s information. I wonder if we have something similar? Here is the link were I read about it:

https://stackoverflow.com/questions/7130648/get-user-info-via-google-api

Any advice or idea that you can provide it is more than appreciated.

Thanks and best regards!

#hci #integrations #spci

Accepted Solutions (0)

Answers (0)