/userinfo endpoint is a standard API specification that the issuer implements and makes available to RPs, as an alternative method for those RPs to obtain updated subject claim data (that is, updated user information). An RP can use its OAuth access token with a special HTTP GET request to the issuer’s /userinfo endpoint. The response includes the latest claim values authorized for the RP according to the scopes in the access token. It can also include claim data that may have been excluded from the ID token due to size concerns, like an embedded profile image.
The /userinfo endpoint’s response body is a JSON object where each claim is a field/vale pair:
/userinfo endpoint whenever it needs the latest copy of a subject’s claim data. However, as a best practice, we recommend you rely on the ID token, and to refresh it as needed.
Parent topic:OAuth 2.0 and OpenID Connect
