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

# About Account Name Inquiry

> Learn about the Account Name Inquiry (ANI) feature and how it helps approve or decline transactions on the Marqeta platform.

Account Name Inquiry (ANI) is an account verification feature that is supported by both the Mastercard and Visa card networks. This is an anti-fraud feature intended to prevent the delivery of account takeover fraud and authorized push-payment scams to fraudulent recipients. ANI allows originating institutions to verify that the name users are providing during their card registration process matches the name associated with the card on file by the card issuer.

ANI works independently of a financial transaction. It is a \$0 authorization, non-financial, and inquiry-type request made by merchants when the user is introducing their card account as a form of payment. This request can be conducted on an ad hoc or a periodic basis.

At the end of this guide, you should understand:

* How ANI matching works, including the requirements to participate in the ANI decision-making process.

* How to receive name-matching results via webhook notifications.

* How ANI affects transactions using Just-in-Time (JIT) Funding.

<h2 id="_how_ani_matching_works">
  How ANI matching works
</h2>

Marqeta supports the ANI feature to ensure compliance, and it is optional for you to participate in the ANI decisioning process. The ANI feature follows these steps to determine name-matching results:

<Steps>
  <Step>
    During ANI, Visa or Mastercard sends an ANI request to Marqeta with the cardholder’s first name, middle name, and/or last name.
  </Step>

  <Step>
    Marqeta compares the name from the card network against the cardholder name on file at Marqeta.
  </Step>

  <Step>
    Marqeta performs the name match and returns the results to the card network.
  </Step>
</Steps>

The name-matching results consist of Match, Partial Match, or No Match for each name element (first/middle/last), as well as an overall match result for the complete name set.

<h2 id="_participating_in_the_ani_decision_making_process">
  Participating in the ANI decision-making process
</h2>

When ANI makes a match determination, the results are included in the `account_name_verification` object within the [transaction message](/core-api/transactions/). When [configuring a webhook](/core-api/webhooks/) to subscribe to ANI match results, set the `type` value to `transaction.account_name_verification`.

The `account_name_verification` object contains the following ANI data:

* Name data sent by the merchant in the transaction message.

* Name data held by the Marqeta platform.

* A standardized response code and memo that describe the ANI match determination.

The following is a sample `account_name_verification` object as it would appear in a transaction notification sent to your webhook endpoint.

```json JSON lines wrap theme={null}
"account_name_verification": {
  "request": {
    "first_name": "John",
    "middle_name": "A",
    "last_name": "Smith"
    "card_name": "JOHN A SMITH"
  },
  "on_file": {
    "first_name": "John",
    "middle_name": "A",
    "last_name": "Smith"
    "card_name": "JOHN A SMITH"
  },
  "response": {
    "code": "####",
    "memo": "Match"
  }
}
```

<h3 id="_ani_response_codes">
  ANI response codes
</h3>

When you participate in the ANI decision-making process to make a match determination, the results follow a standardized, four-digit response code with a memo that provides more details.

The four digits correspond to the cardholder’s name as follows:

| Digit Position | Element(s) of Name |
| -------------- | ------------------ |
| First digit    | First name         |
| Second digit   | Middle name        |
| Third digit    | Last name          |
| Fourth digit   | Full name          |

Each digit can include a value of `0`, `1`, `2`, or `3`. The values describe the following results:

| Value | Description                       |
| ----- | --------------------------------- |
| `0`   | Name validation was not performed |
| `1`   | No match                          |
| `2`   | Partial match                     |
| `3`   | Full match                        |

The following table lists possible response codes based on the ANI feature:

| Code   | First Name    | Middle Name   | Last Name     | Full Name     |
| ------ | ------------- | ------------- | ------------- | ------------- |
| `0000` | Not validated | Not validated | Not validated | Not validated |
| `1111` | Not matched   | Not matched   | Not matched   | Not matched   |
| `3333` | Exact match   | Exact match   | Exact match   | Exact match   |
| `1232` | Not matched   | Partial match | Exact match   | Partial match |

<h2 id="_overwriting_ani_match_results">
  Overwriting ANI match results
</h2>

If you fund accounts using the Gateway JIT Funding feature, your system can overwrite the ANI match determination by including updated name data in your JIT ANI response. This is useful if your system’s on-file name data is more up to date than what is held by the Marqeta platform.

For more information on overwriting ANI match determinations, see [Using ANI with JIT Funding](/developer-guides/using-ani-with-jit-funding/).
