public class GoogleAuthorizationCodeFlow : AuthorizationCodeFlow, IAuthorizationCodeFlow, IDisposable
Google specific authorization code flow which inherits from AuthorizationCodeFlow.
Namespace
Google.Apis.Auth.OAuth2.FlowsAssembly
Google.Apis.Auth.dll
Constructors
GoogleAuthorizationCodeFlow(GoogleAuthorizationCodeFlow.Initializer)
public GoogleAuthorizationCodeFlow(GoogleAuthorizationCodeFlow.Initializer initializer)
Constructs a new Google authorization code flow.
Parameter | |
---|---|
Name | Description |
initializer | GoogleAuthorizationCodeFlow.Initializer |
Fields
includeGrantedScopes
public readonly bool? includeGrantedScopes
Gets the include granted scopes indicator. Do not use, use IncludeGrantedScopes instead.
Field Value | |
---|---|
Type | Description |
Nullable<Boolean> |
Properties
IncludeGrantedScopes
public bool? IncludeGrantedScopes { get; }
Gets the include granted scopes indicator.
Property Value | |
---|---|
Type | Description |
Nullable<Boolean> |
LoginHint
public string LoginHint { get; }
Gets the login_hint.
Property Value | |
---|---|
Type | Description |
String |
Nonce
public string Nonce { get; }
Gets the nonce.
Property Value | |
---|---|
Type | Description |
String |
ProjectId
public string ProjectId { get; }
The project ID associated with the credential using this flow.
Property Value | |
---|---|
Type | Description |
String |
Prompt
public string Prompt { get; }
Gets the prompt for consent behaviour.
Value can be null
, "none"
, "consent"
, or "select_account"
.
See OpenIDConnect documentation
for details.
Property Value | |
---|---|
Type | Description |
String |
RevokeTokenUrl
public string RevokeTokenUrl { get; }
Gets the token revocation URL.
Property Value | |
---|---|
Type | Description |
String |
UserDefinedQueryParams
public IEnumerable<KeyValuePair<string, string>> UserDefinedQueryParams { get; }
Gets the user defined query parameters.
Property Value | |
---|---|
Type | Description |
IEnumerable<KeyValuePair<String, String>> |
Methods
CreateAuthorizationCodeRequest(String)
public override AuthorizationCodeRequestUrl CreateAuthorizationCodeRequest(string redirectUri)
Creates an authorization code request with the specified redirect URI.
Parameter | |
---|---|
Name | Description |
redirectUri | String |
Returns | |
---|---|
Type | Description |
AuthorizationCodeRequestUrl |
RevokeTokenAsync(String, String, CancellationToken)
public override Task RevokeTokenAsync(string userId, string token, CancellationToken taskCancellationToken)
Asynchronously revokes the specified token. This method disconnects the user's account from the OAuth 2.0 application. It should be called upon removing the user account from the site.
Parameters | |
---|---|
Name | Description |
userId | String User identifier. |
token | String Access token to be revoked. |
taskCancellationToken | CancellationToken Cancellation token to cancel operation. |
Returns | |
---|---|
Type | Description |
Task |
|
If revoking the token succeeds, the user's credential is removed from the data store and the user MUST authorize the application again before the application can access the user's private resources.
ShouldForceTokenRetrieval()
public override bool ShouldForceTokenRetrieval()
Indicates if a new token needs to be retrieved and stored regardless of normal circumstances.
Returns | |
---|---|
Type | Description |
Boolean |