TdxOAuth2AuthorizationAgent.RevokeAccessToken Method
Renders the account access and refresh tokens invalid and terminates the current authorization session.
Declaration
procedure RevokeAccessToken;
Remarks
An access token received from an OAuth 2.0 authorization server has a limited lifetime (in seconds) equal to the AccessTokenExpiresIn property value. You can call the RevokeAccessToken procedure to send an access token revocation request to the authorization server that issued the access and refresh tokens to render them invalid on demand. This procedure is particularly useful if you need to implement a safe “log out” feature in your application.
Calling the RevokeAccessToken procedure has no effect if the agent component is not authorized in an online account.
Note
Certain OAuth 2.0 authorization servers do not support access token revoke requests. Calling the RevokeAccessToken procedure results in the same effect as a FinishAuthorization call if the OAuth 2.0 endpoint that your application uses does not support the token revocation mechanism.