OAuth2PkceServerConfig constructor

const OAuth2PkceServerConfig({
  1. required Uri tokenEndpointUrl,
  2. required String clientId,
  3. required String clientSecret,
  4. required ParseTokenResponse parseTokenResponse,
  5. String clientIdKey = 'client_id',
  6. String clientSecretKey = 'client_secret',
  7. OAuth2CredentialsLocation credentialsLocation = OAuth2CredentialsLocation.header,
  8. Map<String, String> tokenRequestHeaders = const {'Accept' : 'application/json', 'Content-Type' : 'application/x-www-form-urlencoded'},
  9. Map<String, dynamic> tokenRequestParams = const {},
})

Create a new server config for OAuth2 PKCE.

Implementation

const OAuth2PkceServerConfig({
  required this.tokenEndpointUrl,
  required this.clientId,
  required this.clientSecret,
  required this.parseTokenResponse,
  this.clientIdKey = 'client_id',
  this.clientSecretKey = 'client_secret',
  this.credentialsLocation = OAuth2CredentialsLocation.header,
  this.tokenRequestHeaders = const {
    'Accept': 'application/json',
    'Content-Type': 'application/x-www-form-urlencoded',
  },
  this.tokenRequestParams = const {},
});