> ## 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.

# Simulate ATM withdrawal

> Simulate a pindebit.atm.withdrawal type transaction by including the cardtoken and amount in your request.

POST/simulate/financial/withdrawal

Simulate a `pindebit.atm.withdrawal` type transaction by including the `card_token` and `amount` in your request.

## Body field details

| Fields | Description |
| - | - |
| mid string  Required | Merchant Identification number. **Allowable Values:**  50 char max |
| card\_token string  Required | The unique identifier of the card used in the transaction. **Allowable Values:**  Existing card token. |
| pin string  Optional | The PIN number for the associated card, if required. **Allowable Values:**  4 char max |
| account\_type string  Required | The type of account – checking, savings, credit card. **Allowable Values:**  checking, savings, credit |
| amount decimal  Required | The amount of money to withdraw. **Allowable Values:**  Format: 0.00 |
| card\_acceptor object  Optional | Contains attributes that describe the merchant. **Allowable Values:**  A valid `card_acceptor` object. |
| webhook object  Optional | Allows information to be posted asynchronously to endpoints hosted in your environment. **Allowable Values:**  A valid `webhook` object. |

## The card\_acceptor object

| Fields | Description |
| - | - |
| mcc string  Optional | Merchant category code. **Allowable Values:**  5 char max |
| partial\_approval\_capable boolean  Optional | Whether the response can approve an amount less than or equal to the requested amount. **Allowable Values:**  `true`, `false` **Default value:** `false` |
| name string  Optional | Merchant name. **Allowable Values:**  255 char max |
| address string  Optional | Merchant address. **Allowable Values:**  255 char max |
| city string  Optional | Merchant city. **Allowable Values:**  255 char max |
| state string  Optional | Merchant state. **Allowable Values:**  2 char max |
| zip string  Optional | Merchant ZIP or postal code. **Allowable Values:**  10 char max |
| country string  Optional | Merchant country. **Allowable Values:**  40 char max |
| ecommerce\_security\_level\_indicator string  Optional | Contains the fields representing the security protocol and cardholder authentication type associated with the transaction. **Allowable Values:**  0-9 |

## The webhook object

| Fields | Description |
| - | - |
| endpoint string  Optional | Endpoint to which a copy of the response is sent. **Allowable Values:**  - HTTPS URL  - 250 char max  - Empty string not allowed |
| username string  Optional | Username for accessing the endpoint. **Allowable Values:**  50 char max |
| password string  Optional | Password for accessing the endpoint. **Allowable Values:**  No restrictions |

## Sample request body

```json JSON lines wrap theme={null}
{
  "mid": "11111",
  "account_type": "savings",
  "card_token": "f9c00b07-be2d-4240-ad89-98a0595fc3a2",
  "amount": "1.00"
}
```

## Sample response body

```json JSON expandable lines wrap theme={null}
{
  "type": "pindebit.atm.withdrawal",
  "state": "COMPLETION",
  "token": "d566329d-4886-4170-a42a-337deb1acaa2",
  "user_token": "b2d2c739-a9fe-4af0-9f34-964aae4c3e31",
  "acting_user_token": "b2d2c739-a9fe-4af0-9f34-964aae4c3e31",
  "card_token": "f9c00b07-be2d-4240-ad89-98a0595fc3a2",
  "gpa": {
    "currency_code": "USD",
    "ledger_balance": 10,
    "available_balance": 0,
    "credit_balance": 0,
    "pending_credits": 0,
    "impacted_amount": -1,
    "balances": {
      "USD": {
        "currency_code": "USD",
        "ledger_balance": 10,
        "available_balance": 0,
        "credit_balance": 0,
        "pending_credits": 0,
        "impacted_amount": -1
      }
    }
  },
  "gpa_order": {
    "token": "d5f0486a-e831-4926-9e59-47427948d68d",
    "amount": 1,
    "created_time": "2024-07-11T19:45:22Z",
    "last_modified_time": "2024-07-11T19:45:22Z",
    "transaction_token": "a870af0e-f98e-40d3-a8d2-350d015d69f9",
    "state": "COMPLETION",
    "response": {
      "code": "0000",
      "memo": "Approved or completed successfully"
    },
    "funding": {
      "amount": 1,
      "source": {
        "type": "program",
        "token": "**********b4c2",
        "active": true,
        "name": "PFS for simulating transactions",
        "is_default_account": false,
        "created_time": "2024-07-10T00:09:35Z",
        "last_modified_time": "2024-07-10T00:09:35Z"
      }
    },
    "funding_source_token": "**********b4c2",
    "user_token": "b2d2c739-a9fe-4af0-9f34-964aae4c3e31",
    "currency_code": "USD"
  },
  "duration": 129,
  "created_time": "2024-07-11T19:45:22Z",
  "user_transaction_time": "2024-07-11T19:45:22Z",
  "request_amount": 1,
  "amount": 1,
  "issuer_interchange_amount": 0,
  "currency_code": "USD",
  "approval_code": "693945",
  "response": {
    "code": "0000",
    "memo": "Approved or completed successfully"
  },
  "network": "VISA",
  "subnetwork": "VISANET",
  "acquirer_fee_amount": 0,
  "acquirer": {
    "institution_id_code": "59103660914",
    "retrieval_reference_number": "492752528413",
    "system_trace_audit_number": "977404"
  },
  "user": {
    "metadata": {}
  },
  "card": {
    "metadata": {}
  },
  "card_acceptor": {
    "mid": "11111",
    "mcc": "6411",
    "name": "Marqeta Storefront",
    "street_address": "330 Central Ave.",
    "city": "St. Petersburg",
    "state": "FL",
    "zip": "33705",
    "country_code": "USA"
  },
  "pos": {
    "terminal_id": "TR100000",
    "partial_approval_capable": false,
    "purchase_amount_only": false,
    "is_recurring": false
  }
}
```


## Related topics

- [Simulate ATM withdrawal authorization](https://www.marqeta.com/docs/core-api/simulations-card-transactions/atm-withdrawals/simulate-atm-withdrawal-authorization.md)
- [Simulate ATM withdrawal authorization clearing](https://www.marqeta.com/docs/core-api/simulations-card-transactions/atm-withdrawals/simulate-atm-withdrawal-authorization-clearing.md)
- [ATM Withdrawal Simulations Overview](https://www.marqeta.com/docs/core-api/simulations-card-transactions/atm-withdrawals.md)
- [Simulations 2.0 — Card Transactions Overview](https://www.marqeta.com/docs/core-api/simulations-card-transactions.md)
- [Simulating Transactions Overview](https://www.marqeta.com/docs/core-api/simulating-transactions.md)
