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

# Card simulator

> Use the card simulator to test card payment integrations in sandbox environments.

The card simulator is a sandbox-only connector that simulates card payment responses. Use it to test your integration, validate failover scenarios between connectors, and verify your handling of AVS and CVV responses.

The simulator supports all standard card features including delayed capture, partial capture, refunds, void, 3-D Secure pass-through, digital wallets, network tokens, and over capture.

## Credentials

When setting up the card simulator in the dashboard, the following credential is available:

* **Merchant ID** (optional) - An optional merchant ID for testing purposes.

## Error codes

The `amount` field is used to simulate error codes. See the [error codes](/guides/api/error-codes)
documentation for all the possible error codes and each of the amounts to trigger them.

## AVS responses

A buyer's `postal_code` simulates different `avs_response_code` values
for a transaction.

| `avs_response_code`      | Description                          | `postal_code`                 |
| :----------------------- | :----------------------------------- | :---------------------------- |
| `match`                  | The post code and address match      | any other                     |
| `no_match`               | Neither post code or address matched | any post code containing `77` |
| `partial_match_postcode` | Only the post code matched           | any post code containing `88` |
| `partial_match_address`  | Only the address matched             | any post code containing `99` |

## CVV responses

The CVV (`security_code`) simulates different `cvv_response_code` values.

| `cvv_response_code` | Description                                        | `security_code` |
| :------------------ | :------------------------------------------------- | :-------------- |
| `match`             | The `CVV` matched                                  | any other       |
| `not_provided`      | The `CVV` was not provided or unable to be checked | `222`           |
| `no_match`          | The `CVV` did not match                            | `333`           |

## Integration

To accept card payments with the card simulator, use one of Gr4vy's client-side integration methods to securely collect card details.

You can integrate using:

* **[Embed](/guides/payments/embed/quick-start)** - A pre-built, customizable payment form that handles the complete payment flow
* **[Secure Fields](/guides/payments/secure-fields/quick-start)** - Embed card input fields for building custom payment forms while maintaining PCI compliance
* **[Mobile SDKs](/guides/get-started#client-side-and-mobile-sdks)** - Native SDKs for iOS, Android, React Native, and other platforms
