disableMfa method

Future<void> disableMfa(
  1. String code
)

Disable MFA (Multi-Factor Authentication).

code is the one-time password generated by the user's password manager.

Throws an ApiException if disabling MFA fails.

https://docs.nhost.io/auth/api-reference#disable-mfa

Implementation

Future<void> disableMfa(String code) async {
  await _apiClient.post(
    '/mfa/disable',
    data: {
      'code': code,
    },
    headers: _session.authenticationHeaders,
  );
}