OAuth2Helper constructor

OAuth2Helper(
  1. OAuth2Client client, {
  2. int grantType = AUTHORIZATION_CODE,
  3. required String clientId,
  4. String? clientSecret,
  5. List<String>? scopes,
  6. bool enablePKCE = true,
  7. bool enableState = true,
  8. dynamic tokenStorage,
  9. Function? afterAuthorizationCodeCb,
  10. Map<String, dynamic>? authCodeParams,
  11. Map<String, dynamic>? accessTokenParams,
  12. BaseWebAuth? webAuthClient,
  13. Map<String, dynamic>? webAuthOpts,
})

Implementation

OAuth2Helper(this.client,
    {this.grantType = AUTHORIZATION_CODE,
    required this.clientId,
    this.clientSecret,
    this.scopes,
    this.enablePKCE = true,
    this.enableState = true,
    tokenStorage,
    this.afterAuthorizationCodeCb,
    this.authCodeParams,
    this.accessTokenParams,
    this.webAuthClient,
    this.webAuthOpts}) {
  this.tokenStorage = tokenStorage ?? TokenStorage(client.tokenUrl);
}