> ## Documentation Index
> Fetch the complete documentation index at: https://translations.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# MfaWebauthnError

> Décrit tous les hooks et toutes les méthodes disponibles pour personnaliser l’écran `mfa-webauthn-error` d’Universal Login.

L’écran `mfa-webauthn-error` affiche une erreur survenue lors d’une tentative d’authentification WebAuthn et propose à l’utilisateur des options pour récupérer ou essayer une autre méthode.

<Frame>
  <img style={{maxHeight:"400px"}} src="https://mintcdn.com/translations/uTJewtgJuMVcjLxB/docs/images/ja-jp/cdy7uua7fh8z/4YEVrKX7HVo2LYWyZGxajt/865744113a4dbf5beff6bbce6587d8dc/Screenshot_2025-05-27_at_20.15.31.png?fit=max&auto=format&n=uTJewtgJuMVcjLxB&q=85&s=9440574e557645c74effed6e0d27629a" alt="MFAWebauthnError" width="363" height="487" data-path="docs/images/ja-jp/cdy7uua7fh8z/4YEVrKX7HVo2LYWyZGxajt/865744113a4dbf5beff6bbce6587d8dc/Screenshot_2025-05-27_at_20.15.31.png" />
</Frame>

<div id="import">
  ## Importation
</div>

Chaque écran a son propre ensemble de hooks et de méthodes. Le SDK prend en charge l’**importation partielle** et l’**importation racine** pour chaque écran.

* L’**importation partielle** vous permet d’inclure uniquement le code nécessaire à votre cas d’utilisation.
* L’**importation racine** vous permet de charger tous les écrans à partir d’un seul lot, ce qui est utile si vous voulez une version unifiée capable de gérer tous les écrans possibles.

```jsx Import Example theme={null}
// importation racine
import { useMfaWebAuthnError } from '@auth0/auth0-acul-react';

// importation partielle
import {
  useMfaWebAuthnError,
  // Hooks de contexte
  useUser,
  useTenant,
  useBranding,
  useClient,
  useOrganization,
  usePrompt,
  useScreen,
  useTransaction,
  useUntrustedData,
  // Hooks communs
  useCurrentScreen,
  useAuth0Themes,
  useErrors,
  // Hooks utilitaires
  useChangeLanguage,
  // Méthodes
  noThanks,
  tryAgain,
  tryAnotherMethod,
  usePassword,
} from "@auth0/auth0-acul-react/mfa-webauthn-error";

function MfaWebAuthnErrorScreen() {
  const { tryAgain } = useMfaWebAuthnError();
  return (
    <button onClick={() => tryAgain()}>
      Try Again
    </button>
  );
}
```

<div id="context-hooks">
  ## Context Hooks
</div>

Hooks associés à l’écran qui fournissent un accès en lecture seule aux données de contexte Auth0 sur l’écran `mfa-webauthn-error`. Importez-les depuis `@auth0/auth0-acul-react/mfa-webauthn-error`.

<ParamField body="useBranding" type={<span>() =&gt; <a href="/docs/fr-ca/libraries/acul/react-sdk/API-Reference/Types/interfaces/BrandingMembers">BrandingMembers</a></span>}>
  Ce hook fournit des configurations de l’image de marque, comme le logo, les couleurs et les paramètres de thème affichés sur l’écran `mfa-webauthn-error`.

  ```jsx Example theme={null}
  import { useBranding } from '@auth0/auth0-acul-react/mfa-webauthn-error';
  function CustomTheme() {
    const branding = useBranding();
  }
  ```
</ParamField>

<ParamField body="useClient" type={<span>() =&gt; <a href="/docs/fr-ca/libraries/acul/react-sdk/API-Reference/Types/interfaces/ClientMembers">ClientMembers</a></span>}>
  Ce hook fournit des configurations liées au client, comme `id`, `name` et `logoUrl`, pour l’écran `mfa-webauthn-error`.

  ```jsx Example theme={null}
  import { useClient } from '@auth0/auth0-acul-react/mfa-webauthn-error';
  function AppInfo() {
    const client = useClient();
  }
  ```
</ParamField>

<ParamField body="useOrganization" type={<span>() =&gt; <a href="/docs/fr-ca/libraries/acul/react-sdk/API-Reference/Types/interfaces/OrganizationMembers">OrganizationMembers</a></span>}>
  Ce hook fournit des renseignements sur l’Organization de l’utilisateur si le flux d’AMF est limité à l’Organization. Retourne `null` lorsqu’aucun contexte d’Organization n’est présent.

  ```jsx Example theme={null}
  import { useOrganization } from '@auth0/auth0-acul-react/mfa-webauthn-error';
  function OrgSelector() {
    const organization = useOrganization();
    if (!organization) {
      return <p>Aucun contexte d’organisation</p>;
    }
  }
  ```
</ParamField>

<ParamField body="usePrompt" type={<span>() =&gt; <a href="/docs/fr-ca/libraries/acul/react-sdk/API-Reference/Types/interfaces/PromptMembers">PromptMembers</a></span>}>
  Ce hook contient des données sur le prompt actuel dans le flux d’authentification.

  ```jsx Example theme={null}
  import { usePrompt } from '@auth0/auth0-acul-react/mfa-webauthn-error';
  function FlowInfo() {
    const prompt = usePrompt();
  }
  ```
</ParamField>

<ParamField body="useScreen" type={<span>() =&gt; <a href="/docs/fr-ca/libraries/acul/react-sdk/API-Reference/Types/interfaces/ScreenMembersOnMfaWebAuthnError">ScreenMembersOnMfaWebAuthnError</a></span>}>
  Ce hook contient des détails propres à l’écran `mfa-webauthn-error`, y compris sa configuration et son contexte.

  ```jsx Example theme={null}
  import { useScreen } from '@auth0/auth0-acul-react/mfa-webauthn-error';
  function ScreenDebug() {
    const screen = useScreen();
  }
  ```
</ParamField>

<ParamField body="useTenant" type={<span>() =&gt; <a href="/docs/fr-ca/libraries/acul/react-sdk/API-Reference/Types/interfaces/TenantMembers">TenantMembers</a></span>}>
  Ce hook contient des données liées au tenant, comme `id` et les métadonnées associées.

  ```jsx Example theme={null}
  import { useTenant } from '@auth0/auth0-acul-react/mfa-webauthn-error';
  function TenantInfo() {
    const tenant = useTenant();
  }
  ```
</ParamField>

<ParamField body="useTransaction" type={<span>() =&gt; <a href="/docs/fr-ca/libraries/acul/react-sdk/API-Reference/Types/interfaces/TransactionMembers">TransactionMembers</a></span>}>
  Ce hook fournit des données propres à la transaction pour l’écran `mfa-webauthn-error`, comme l’état actuel du flux d’AMF.

  ```jsx Example theme={null}
  import { useTransaction } from '@auth0/auth0-acul-react/mfa-webauthn-error';
  function TransactionInfo() {
    const transaction = useTransaction();
  }
  ```
</ParamField>

<ParamField body="useUntrustedData" type={<span>() =&gt; <a href="/docs/fr-ca/libraries/acul/react-sdk/API-Reference/Types/interfaces/UntrustedDataMembers">UntrustedDataMembers</a></span>}>
  Ce hook fournit les données non fiables transmises à l’écran, comme les valeurs préremplies provenant des paramètres d’URL.

  ```jsx Example theme={null}
  import { useUntrustedData } from '@auth0/auth0-acul-react/mfa-webauthn-error';
  function PrefilledForm() {
    const untrustedData = useUntrustedData();
  }
  ```
</ParamField>

<ParamField body="useUser" type={<span>() =&gt; <a href="/docs/fr-ca/libraries/acul/react-sdk/API-Reference/Types/interfaces/UserMembers">UserMembers</a></span>}>
  Ce hook fournit des détails sur l’utilisateur actif, notamment le `username`, l’`email` et les méthodes d’authentification disponibles.

  ```jsx Example theme={null}
  import { useUser } from '@auth0/auth0-acul-react/mfa-webauthn-error';
  function UserProfile() {
    const user = useUser();
  }
  ```
</ParamField>

<ParamField body="useMfaWebAuthnError" type={<a href="/docs/fr-ca/libraries/acul/react-sdk/API-Reference/Types/interfaces/MfaWebAuthnErrorMembers">MfaWebAuthnErrorMembers</a>}>
  Ce hook renvoie toutes les méthodes et tout le contexte disponibles sur l’écran `mfa-webauthn-error`.
</ParamField>

<div id="methods">
  ## Méthodes
</div>

<ParamField body="noThanks" type="Promise<void>">
  Cette méthode supprime l’erreur WebAuthn et annule le flux d’AMF en cours.

  ```jsx Example theme={null}
  import { useMfaWebAuthnError } from '@auth0/auth0-acul-react/mfa-webauthn-error';

  function NoThanksButton() {
    const { noThanks } = useMfaWebAuthnError();
    return (
      <button onClick={() => noThanks()}>
        Non merci
      </button>
    );
  }
  ```
</ParamField>

<ParamField body="tryAgain" type="Promise<void>">
  Cette méthode relance l’authentification WebAuthn après une erreur.

  ```jsx Example theme={null}
  import { useMfaWebAuthnError } from '@auth0/auth0-acul-react/mfa-webauthn-error';

  function TryAgainButton() {
    const { tryAgain } = useMfaWebAuthnError();
    return (
      <button onClick={() => tryAgain()}>
        Réessayer
      </button>
    );
  }
  ```
</ParamField>

<ParamField body="tryAnotherMethod" type="Promise<void>">
  Cette méthode redirige vers l’écran de sélection de la méthode d’AMF afin que l’utilisateur puisse choisir un autre facteur d’authentification.

  ```jsx Example theme={null}
  import { useMfaWebAuthnError } from '@auth0/auth0-acul-react/mfa-webauthn-error';

  function TryAnotherMethodButton() {
    const { tryAnotherMethod } = useMfaWebAuthnError();
    return (
      <button onClick={() => tryAnotherMethod()}>
        Essayer une autre méthode
      </button>
    );
  }
  ```
</ParamField>

<ParamField body="usePassword" type="Promise<void>">
  Cette méthode modifie le flux d’authentification pour utiliser un mot de passe au lieu de WebAuthn.

  ```jsx Example theme={null}
  import { useMfaWebAuthnError } from '@auth0/auth0-acul-react/mfa-webauthn-error';

  function UsePasswordButton() {
    const { usePassword } = useMfaWebAuthnError();
    return (
      <button onClick={() => usePassword()}>
        Utiliser plutôt le mot de passe
      </button>
    );
  }
  ```
</ParamField>

<div id="commonutility-hooks">
  ## Hooks communs et utilitaires
</div>

<ParamField body={<a href="/docs/fr-ca/libraries/acul/react-sdk/API-Reference/Hooks/useAuth0Themes">useAuth0Themes</a>} type="Hooks">
  Ce hook permet d’obtenir les options du thème actuel avec une configuration à plat à partir du contexte d’image de marque.
</ParamField>

<ParamField body={<a href="/docs/fr-ca/libraries/acul/react-sdk/API-Reference/Hooks/useChangeLanguage">useChangeLanguage</a>} type="Hooks">
  Ce hook renvoie une fonction qui permet de changer la langue d’affichage sur l’écran ACUL actuel.
</ParamField>

<ParamField body={<a href="/docs/fr-ca/libraries/acul/react-sdk/API-Reference/Hooks/useCurrentScreen">useCurrentScreen</a>} type="Hooks">
  Ce hook permet d’obtenir le contexte de l’écran actuel et son état.
</ParamField>

<ParamField body={<a href="/docs/fr-ca/libraries/acul/react-sdk/API-Reference/Hooks/useErrors">useErrors</a>} type="Hooks">
  Ce hook lit et gère les erreurs serveur, client et développeur affichées à l’écran.
</ParamField>
