verifyOTP
method takes in different verification types. If a phone number is used, the type can either be sms
or phone_change
. If an email address is used, the type can be one of the following: signup
, magiclink
, recovery
, invite
, email_change
, or email
.verifyOTP
to sign up / sign-in a user.One of `phone`, `email`, or `token_hash` must be provided.
One of `phone`, `email`, or `token_hash` must be provided.
The token hash from the user's email link. One of `phone`, `email`, or `token_hash` must be provided.
undefined
The OTP sent to the user. Required if using `phone` or `email`.
A URL to redirect the user to after they are confirmed. Must be in your configured redirect URLs.
Deprecated.
try await supabase.auth.verifyOTP(
phone: "+13334445555",
token: "123456",
type: .sms
)
try await supabase.auth.verifyOTP(
email: "example@example-email.com",
token: "123456",
type: .signup
)