Enterprise Connection retrieve access token

Hello,

I am trying to follow Call an Identity Provider API to get an access token once the user has authenticated from an Enterprise Connection.

When I then try to exchange this using the API described:

GET https://dev-n3xasz4ih2vaiv5v.us.auth0.com/api/v2/users/oidc|conn1|username

with the Auth0 management API bearer token, I receive:

{

"created_at": "2025-07-17T14:37:27.318Z",

"identities": [

    {

        "user_id": "conn1|username",

        "provider": "oidc",

        "connection": "conn1",

        "isSocial": **false**

    }

 ],
  ......

}

where there is no access_token in the identity response.

How can I obtain the access token related to the user who authenticates via the Enteprise Connection?

Regards Stuart

Hi @stuart.mackintosh,

Welcome back to the Auth0 Community!

The above mentioned behavior is the expected one since unfortunately the OIDC Enterprise Connections do not yet include an access token in the identities array of the user profile. The workaround would be creating a custom social connection, as suggested in this article as well - No IdP Access Token in Identities Array for OIDC Enterprise Connections.

Thank you!
Best regards,
Remus