Config constructor

Config({
  1. required String azureTennantId,
  2. required String clientId,
  3. required String scope,
  4. required String redirectUri,
  5. required String responseType,
  6. String? clientSecret,
  7. String? resource,
  8. String contentType = "application/x-www-form-urlencoded",
  9. BuildContext? context,
  10. String nonce = "nonce_value",
})

ResponseType to mobile usually is "code", and web usually is "id_token+token"

Implementation

Config(
    {required this.azureTennantId,
    required this.clientId,
    required this.scope,
    required this.redirectUri,
    required this.responseType,
    this.clientSecret,
    this.resource,
    this.contentType = "application/x-www-form-urlencoded",
    this.context,
    this.nonce = "nonce_value"}) {
  this.authorizationUrl =
      "https://login.microsoftonline.com/$azureTennantId/oauth2/v2.0/authorize";
  this.tokenUrl =
      "https://login.microsoftonline.com/$azureTennantId/oauth2/v2.0/token";
}