Keep privileged work on your backend
A browser or mobile app should collect the identifier and code, but your server should hold the privileged API credential. Create an application-specific key, keep it out of client bundles, and rotate it through your operational process. Avoid putting codes or keys in URLs, analytics events, screenshots, or support logs. Configuration errors can expose a verification flow before any code is guessed.
Bind the code to an explicit purpose
Store the request identifier with the intended account, destination, and action in your own session state. A code proving access to one inbox must not authorize an unrelated account change. Verify the response server-side and use it only for the intended step. For a recovery journey, do not grant a full authenticated session simply because a password-reset code is valid; complete the defined recovery process first.
Control guesses and repeated sends
Use server-enforced expiration and attempt limits. A disabled resend button helps a genuine user understand timing, but it does not limit an automated client. Apply controls on the backend and consider account, destination, and traffic patterns together. Keep responses consistent where account discovery would create a risk. Set limits around real user behavior, then observe false positives rather than treating the first configuration as permanent.
Create the session only after success
Treat a delivered message as delivery information, not authentication. Create or upgrade the application session only after the verify operation succeeds. Use secure cookie and session controls, and reassess the authentication method for privileged or high-value actions. OTPs can be phished. The checklist is an integration baseline, not a replacement for an application-specific security review.
Check the verification result on your server
For WhatsApp and email, OTP Wire’s successful verify response includes success: true, verified: true, and status: verified. Check that result in your backend before completing the action tied to your pending request. A successful send response or a delivery event cannot replace this check. When using request_id, the API checks that the request belongs to the authenticated application. Your product still needs to bind it to the intended user and purpose; application ownership alone does not choose which account may sign in. If the API times out or rejects the attempt, keep the pending action incomplete and offer a controlled next step.
Distinguish request lockout from account protection
OTP Wire rejects verification for a request that is already verified, expired, or locked. Incorrect codes increment that request’s attempt counter, and reaching its maximum locks that request. This is a request-level control, not a complete account lockout policy for your product. Review repeated sends and verification attempts across your own account journeys, including channel changes, without treating an IP address as the only signal. For password recovery, avoid locking the whole account merely because someone requested a reset. In a non-production test setup, cover expired codes, exhausted attempts, a request from another application, repeat use after success, and concurrent submissions. Confirm that your application completes the intended action only once and gives a useful recovery path without logging raw codes.
