API Reference
GoogleApisCredentialSource
Adapts credentials from Google.Apis.Auth to the dependency-light OfficeIMO credential contract.
Inheritance
- Object
- GoogleApisCredentialSource
Usage
Explore 1 API references to this type
This type appears in these public API surfaces even when no hand-authored example is attached directly to the page.
Returned or exposed by 1
Constructors
public GoogleApisCredentialSource(GoogleCredential credential, TimeSpan? fallbackTokenLifetime = null) #Creates an adapter around a Google credential, applying requested scopes when the credential requires scoping.
Parameters
- credential Google.Apis.Auth.OAuth2.GoogleCredential
- fallbackTokenLifetime System.TimeSpan? = null
public GoogleApisCredentialSource(GoogleCredential credential, TimeSpan? fallbackTokenLifetime, String? account) #Creates an adapter with an informational account label that is not credential evidence.
Parameters
- credential Google.Apis.Auth.OAuth2.GoogleCredential
- fallbackTokenLifetime System.TimeSpan?
- account System.String?
public GoogleApisCredentialSource(GoogleCredential credential, TimeSpan? fallbackTokenLifetime, String? account, GoogleWorkspaceCredentialBindingResolver? credentialBindingResolver) #Creates an adapter that verifies account and grants through a provider-evidence resolver.
Parameters
- credential Google.Apis.Auth.OAuth2.GoogleCredential
- fallbackTokenLifetime System.TimeSpan?
- account System.String?
- credentialBindingResolver OfficeIMO.GoogleWorkspace.GoogleWorkspaceCredentialBindingResolver?
public GoogleApisCredentialSource(ITokenAccess credential, TimeSpan? fallbackTokenLifetime = null) #Creates an adapter around any Google token source, including UserCredential.
Parameters
- credential Google.Apis.Auth.OAuth2.ITokenAccess
- fallbackTokenLifetime System.TimeSpan? = null
public GoogleApisCredentialSource(ITokenAccess credential, TimeSpan? fallbackTokenLifetime, String? account) #Creates an adapter with an informational account label that is not credential evidence.
Parameters
- credential Google.Apis.Auth.OAuth2.ITokenAccess
- fallbackTokenLifetime System.TimeSpan?
- account System.String?
public GoogleApisCredentialSource(ITokenAccess credential, TimeSpan? fallbackTokenLifetime, String? account, GoogleWorkspaceCredentialBindingResolver? credentialBindingResolver) #Creates an adapter that verifies account and grants through a provider-evidence resolver.
Parameters
- credential Google.Apis.Auth.OAuth2.ITokenAccess
- fallbackTokenLifetime System.TimeSpan?
- account System.String?
- credentialBindingResolver OfficeIMO.GoogleWorkspace.GoogleWorkspaceCredentialBindingResolver?
Methods
public async Task<GoogleWorkspaceAccessToken> AcquireAccessTokenAsync(IEnumerable<String> scopes, CancellationToken cancellationToken = default) #Task<GoogleWorkspaceAccessToken>Acquires an access token and its available scope evidence for the requested operation.
Parameters
- scopes System.Collections.Generic.IEnumerable<System.String>
- OAuth scopes required by the pending operation.
- cancellationToken System.Threading.CancellationToken = default
- Token used to cancel acquisition.
Returns
A task that produces the acquired token and its scope and identity evidence. Callers must verify that the evidence covers their required scopes.
Inherited Methods
public virtual Boolean Equals(Object? obj) #BooleanParameters
- obj Object?