authorize method

Future<String> authorize({
  1. required String redirectUri,
  2. List<Prompt>? prompts,
  3. String? loginHint,
  4. String? nonce,
  5. List<String>? channelPublicIds,
  6. List<String>? serviceTerms,
  7. String? codeVerifier,
})

KO: 카카오계정으로 로그인: 리다이렉트 방식
EN: Login with Kakao Account through redirection

Implementation

Future<String> authorize({
  required String redirectUri,
  List<Prompt>? prompts,
  String? loginHint,
  String? nonce,
  List<String>? channelPublicIds,
  List<String>? serviceTerms,
  String? codeVerifier,
}) async {
  SdkLog.d(
    '[AuthCodeClient.authorize] started | redirectUri=$redirectUri prompts=${prompts?.map((e) => e.name).join(',')} channelCount=${channelPublicIds?.length ?? 0} serviceTermsCount=${serviceTerms?.length ?? 0} loginHintProvided=${loginHint != null} nonceProvided=${nonce != null}',
  );
  final code = await _platform.authorize(
    redirectUri,
    prompts,
    loginHint,
    codeVerifier != null ? PKCE(codeVerifier) : null,
    nonce,
    channelPublicIds,
    serviceTerms,
  );
  SdkLog.i('[AuthCodeClient.authorize] completed');
  return code;
}