<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
0D54z00009TR7MsCALOkta Classic EngineAPI Access ManagementAnswered2023-07-17T16:41:04.000Z2023-07-15T02:07:22.000Z2023-07-17T16:41:04.000Z

RayL.08683 (Customer) asked a question.

access_token from oauth2/v1/token is not able to call api/v1/users/{userId}/groups

I implement okta login in my web app.

When okta redirect to my app, I send another request to oauth2/v1/token to exchange token.

Then I take the access_token from the response

And use the access_token to call api/v1/users/{userId}/groups

However, I got 403 forbidden

 

I have go throw my okta application setting and didn't see any setting related with it.


  • RayL.08683 (Customer)

    I have added scope=openid+profile+email+groups in the token exchange api but the response still shows scp: [ 'openid', 'email' ],

  • Paul S. (Okta, Inc.)

    Hello @RayL.08683 (Customer)​ Thank you for reacting out to our Community!

     

    Please see this documentation below that should provide the information you are looking for:

    https://developer.okta.com/docs/guides/customize-tokens-groups-claim/main/

     

    Additionally if you need further assistance we recommend to leverage the Okta Developer forums for this type of questions and take advantage of their expertise.

    https://devforum.okta.com/

     

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

    Expand Post
This question is closed.
Loading
access_token from oauth2/v1/token is not able to call api/v1/users/{userId}/groups