<iframe src="https://www.googletagmanager.com/ns.html?id=GTM-M74D8PB" height="0" width="0" style="display:none;visibility:hidden">
Loading
Skip to NavigationSkip to Main Content
0D54z000099OhnzCACOkta Classic EngineAPI Access ManagementAnswered2024-05-27T09:06:16.000Z2023-05-01T16:16:52.000Z2023-05-02T15:35:39.000Z

8g5nf (8g5nf) asked a question.

How to get specific attributes of user via api call from the application

Hi!

Can you please help me to resolve this issue? When I use the oauth2/v1/userinfo endpoint to locate profile data for the authenticated user, I receive user attributes like locale or zoneinfo. However, when I later use the api/v1/users/{userId} endpoint on behalf of the application (using the SSWS token), I cannot find a way to obtain those specific attributes of the user. Is there any way I could do that?

Thanks!

 

 


  • Mihai N. (Okta, Inc.)

    Hi @8g5nf (8g5nf)​ , Thank you for reaching out to the Okta Community!

     

    From the look of things, it might be expected not to get those as the api/v1/users/{userID} endpoint would pull only attributes that are listed on the Okta User Profile and that are not null. 

    I think the exact opposite of what you are trying to achieve was discussed on an older post: 

    https://devforum.okta.com/t/attribute-mappings-and-custom-claims-in-userinfo/22412

     

    My advice would be to reach out to the dedicated Developer Forum devforum.okta.com to take advantage of their expertise.  

    While we'll do our best to answer all of your questions here, this medium is more inclined towards Okta core products and features (non-developer work). 

     

     

    If my answers helped, remember to mark it as best to increase its visibility for other members of the Okta Community who might have the same questions as you. 

     

    Hope my answer helps! 

    --------------------------------

    Community members help others by clicking Like or Select as Best on responses. Try it today.

    Expand Post
This question is closed.
Loading
How to get specific attributes of user via api call from the application