updatePhone abstract method
Future<String>
updatePhone({
- required String phone,
- required DeliveryMethod method,
- required String loginId,
- required String refreshJwt,
- UpdateOptions? options,
Updates an existing user by adding a phone number.
The phone
number will be updated for the user identified by loginId
after it is verified via OTP. In order to do this, the user must
have an active DescopeSession whose refreshJwt
should be
passed as a parameter to this function.
You can optionally pass the options
parameter to add the new phone number
as a loginId
for the updated user, and to determine how to resolve conflicts
if another user already exists with the same loginId
. See the documentation
for UpdateOptions
for more details.
Important: Make sure delivery method
is appropriate for using a phone number.
Implementation
Future<String> updatePhone({required String phone, required DeliveryMethod method, required String loginId, required String refreshJwt, UpdateOptions? options});