Closed vvinh4 closed 5 months ago
The application has many different organizations, and I want to pass the above org like the way flutter_appauth is doing. Can you guys help with this? I am using the library for Flutter Windows App.
final request = AuthorizationTokenRequest( config.clientId, config.callbackSchema, scopes: config.scopes, clientSecret: config.clientSecret, promptValues: ['login'], serviceConfiguration: AuthorizationServiceConfiguration( authorizationEndpoint: config.authorizeUrl, tokenEndpoint: config.tokenUrl, endSessionEndpoint: config.endSessionUrl, ), additionalParameters: config.getLoginAdditionalParameters( deviceToken: deviceToken, culture: cultureArgs.join('-'), ), issuer: config.identityEndPoint, preferEphemeralSession: false, );
` Map<String, String> getLoginAdditionalParameters({ String? deviceToken, String? culture, }) { final parameters = { 'organization': organization, 'deviceToken': deviceToken ?? '', 'applicationCode': Platform.isAndroid ? 'Android' : '', };
if (culture?.isNotEmpty ?? false) { parameters.putIfAbsent('culture', () => culture ?? ''); } return parameters;
}`
Custom parameter appending feature is added. Please find new update.
Thanks, team!
The application has many different organizations, and I want to pass the above org like the way flutter_appauth is doing. Can you guys help with this? I am using the library for Flutter Windows App.
final request = AuthorizationTokenRequest( config.clientId, config.callbackSchema, scopes: config.scopes, clientSecret: config.clientSecret, promptValues: ['login'], serviceConfiguration: AuthorizationServiceConfiguration( authorizationEndpoint: config.authorizeUrl, tokenEndpoint: config.tokenUrl, endSessionEndpoint: config.endSessionUrl, ), additionalParameters: config.getLoginAdditionalParameters( deviceToken: deviceToken, culture: cultureArgs.join('-'), ), issuer: config.identityEndPoint, preferEphemeralSession: false, );
` Map<String, String> getLoginAdditionalParameters({ String? deviceToken, String? culture, }) { final parameters = { 'organization': organization, 'deviceToken': deviceToken ?? '', 'applicationCode': Platform.isAndroid ? 'Android' : '', };
}`