updateAuthenticationMethod method
Updates an existing authentication method identified by id.
Pass a new name to rename the method, and/or a new
preferredAuthenticationMethod (SMS or voice) for phone authenticators.
Omitted parameters are left unchanged.
Returns the updated AuthenticationMethod.
Requires an access token with the update:me:authentication_methods
scope and audience https://{domain}/me/.
Usage example
final method = await myAccount.updateAuthenticationMethod(
id: 'auth_method_id',
name: 'My phone',
preferredAuthenticationMethod: PhoneType.voice,
);
Implementation
Future<AuthenticationMethod> updateAuthenticationMethod({
required String id,
String? name,
PhoneType? preferredAuthenticationMethod,
}) =>
Auth0FlutterWebPlatform.instance.updateAuthenticationMethod(
_accessToken, id, name, preferredAuthenticationMethod);