TdxOAuth2AuthorizationAgent.OnReceiveAuthorizationCode Event
Occurs on an attempt to receive an OAuth 2.0 authorization code.
Declaration
property OnReceiveAuthorizationCode: TReceiveAuthorizationCodeEvent read; write;
Remarks
Handle OnReceiveAccessToken instead of the OnReceiveAuthorizationCode protected event to provide custom authentication and authorization routines for a TdxOAuth2AuthorizationAgent class descendant.
The OnReceiveAuthorizationCode event is raised immediately after the OnReceiveAccessToken event and provides an option to override only the standard authentication routine that invokes the modal authorization dialog. Refer to the TReceiveAuthorizationCodeEvent nested procedural type description for detailed information on parameters available within the OnReceiveAuthorizationCode event handler.
Note
The OnReceiveAuthorizationCode event does not fire if the OnReceiveAccessToken event’s handler has successfully obtained an access token.