validateOtp method
Implementation
Future<http.Response> validateOtp(
String id, String otp, String apiKey) async {
final requestBody = {"otp_code": otp};
return await http.post(
Uri.parse(ApiConstants.baseUrl +
ApiConstants.initiateVerification +
id +
ApiConstants.verifyOtp),
headers: {"API-KEY": apiKey, "Content-Type": "application/json"},
body: jsonEncode(requestBody),
);
}