How it works
Verification is a two-step flow:- Create a verification: Surge sends a six-digit code to the number
- Check the code: Surge validates the code the user entered
1. Send the code
2. Check the code
When the user submits the code in your UI, send it to Surge for verification:result field indicating whether the verification succeeded:
Limits
- Expiration: 10 minutes from creation. After that, the verification moves to
expiredstatus and all check attempts returnexpired. - Max attempts: 3 incorrect guesses per verification. After 3 incorrect attempts, the verification moves to
exhaustedstatus. Create a new verification and prompt the user to resend the code.
Result values
Look up a verification in the dashboard
To see what happened to a code, open Verifications in the account’s navigation in the dashboard at hq.surge.app. The list shows each verification for the account with its status: Pending, Verified, Expired, or Attempt limit (theexhausted status). Filter by status, or search by the full phone number including its country code or by the verification ID from the API response.
Select a verification to open its details:
- SMS delivery: when Surge sent the code, its delivery status, and the failure reason if delivery failed
- Code attempts: the outcome and time of each code check, out of the 3 allowed
- The carrier for US numbers, or the country for other numbers