completeRegister method
Completes the registration by sending the solution to the challenge back.
Implementation
@override
Future<AuthResponse> completeRegister(
RegistrationCompleteRequest request,
) async {
try {
final signedChallenge = jsonEncode(
CorbadoRegisterSignedChallengeRequest.fromRegisterCompleteRequest(
request,
).toJson(),
);
final result = await UsersApi(_client).passKeyRegisterFinishWithHttpInfo(
PassKeyFinishReq(signedChallenge: signedChallenge),
);
return AuthResponse.fromHttpResponse(result);
} on ApiException catch (e) {
throw ExceptionFactory.fromBackendMessage(
'passKeyRegisterFinish',
e.message ?? '',
);
}
}