diff --git a/snippets/verification/start_sms/Snippet.java b/snippets/verification/start_sms/Snippet.java index 7cd28ef..840ff41 100644 --- a/snippets/verification/start_sms/Snippet.java +++ b/snippets/verification/start_sms/Snippet.java @@ -1,9 +1,10 @@ package verification; -import com.sinch.sdk.domains.verification.*; -import com.sinch.sdk.domains.verification.models.*; -import com.sinch.sdk.domains.verification.models.requests.*; -import com.sinch.sdk.domains.verification.models.response.*; +import com.sinch.sdk.domains.verification.api.v1.VerificationService; +import com.sinch.sdk.domains.verification.api.v1.VerificationStartService; +import com.sinch.sdk.domains.verification.models.v1.NumberIdentity; +import com.sinch.sdk.domains.verification.models.v1.start.request.VerificationStartRequestSms; +import com.sinch.sdk.domains.verification.models.v1.start.response.VerificationStartResponseSms; import java.util.logging.Logger; public class Snippet { @@ -14,15 +15,15 @@ static void execute(VerificationService verificationService) { // REMINDER: verification Service require to have set application key/secret // onto Sinch Client init - VerificationsService verificationsService = verificationService.verifications(); + VerificationStartService startService = verificationService.verificationStart(); String phoneNumber = "YOUR_phone_number"; LOGGER.info(String.format("Sending a SMS verification to '%s'", phoneNumber)); - StartVerificationResponseSMS response = - verificationsService.startSms( - StartVerificationSMSRequestParameters.builder() + VerificationStartResponseSms response = + startService.startSms( + VerificationStartRequestSms.builder() .setIdentity(NumberIdentity.valueOf(phoneNumber)) .build());