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

# Verify with Recovery Code

> Verify MFA using a recovery code when the user's enrolled device is unavailable.

## Endpoint

`POST /oauth/token`

Verifies multi-factor authentication (MFA) using a recovery code. Some multi-factor authentication (MFA) providers (such as Guardian) support using a recovery code to login. Use this method to authenticate when the user's enrolled device is unavailable, or the user cannot receive the challenge or accept it due to connectivity issues.

To verify MFA using a recovery code your app must prompt the user for the recovery code, and then make a request to `/oauth/token` with `grant_type=http://auth0.com/oauth/grant-type/mfa-recovery-code`. Include the collected recovery code and the `mfa_token` from the `mfa_required` error. If the recovery code is accepted, the response will be the same as for `password` or `http://auth0.com/oauth/grant-type/password-realm` grant types. It might also include a `recovery_code` field, which the application must display to the end-user to be stored securely for future use.

## Headers

**DPoP** `string`

A DPoP proof for the request. This is optional and only required if your application uses Demonstrating Proof-of-Possession.

## Body Parameters

The request body is in `application/x-www-form-urlencoded` format.

**grant\_type** `string` *required*

Denotes the flow you are using. For recovery code use `http://auth0.com/oauth/grant-type/mfa-recovery-code`.

Allowed values: `http://auth0.com/oauth/grant-type/mfa-recovery-code`

**client\_id** `string` *required*

Your application's Client ID.

**client\_assertion** `string`

A JWT containing a signed assertion with your application credentials.

**client\_assertion\_type** `string`

The value is `urn:ietf:params:oauth:client-assertion-type:jwt-bearer`.

Allowed values: `urn:ietf:params:oauth:client-assertion-type:jwt-bearer`

**client\_secret** `string`

Your application's Client Secret.

**mfa\_token** `string` *required*

The `mfa_token` you received from `mfa_required` error.

**recovery\_code** `string` *required*

Recovery code provided by the end-user.

## Response Schema

\{}

application/json

**access\_token** `string`

The access token from a successful verification.

**token\_type** `string`

The type of token issued.

**expires\_in** `integer`

The access token lifetime in seconds.

**recovery\_code** `string`

A new recovery code to be stored securely for future use.

## Response Messages

| Status | Description |
| - | - |
| 200 | Successful response for recovery code verification. |
| 400 | Bad request due to missing or invalid parameters. |
| 401 | Unauthorized, invalid mfa\_token or recovery\_code. |
