---
title: "Simulate debit"
method: POST
path: "/simulations/directdeposits/debit"
tags: ["Simulations 2.0 — Direct Deposits"]
---

# Simulate debit

`POST /simulations/directdeposits/debit`

## Request

- Base URL: `https://sandbox-api.marqeta.com/v3`
- URL: `https://sandbox-api.marqeta.com/v3/simulations/directdeposits/debit`
- Auth: none declared
- TypeScript: <https://skmtc.dev/marqeta/apis/simulations-2-0-api/docs/simulations/directdeposits/debit/post.ts> (a function with typed inputs; its response is checked against the schema)

Use this endpoint to simulate debiting funds from a deposit account.

Simulate a direct deposit of funds to a user account by including the deposit account number of the account to be debited.
You can find the account number in the `account_number` field of the response when you create a new deposit account.
Alternatively, you can retrieve it by sending a `GET` request to the `/depositaccounts/user/{user_token}` endpoint.
For more information, see [Direct Deposit](/core-api/direct-deposits).

## Request body

- DirectDepositSimulationRequest
  - `account_number` string, required: The account number of the user to debit or credit.
  - `amount` number, required: Amount of the transaction.
  - `company_discretionary_data` string: Company-specific data provided by the direct deposit originator.
  - `company_entry_description` string: Company-specific data provided by the direct deposit originator.
  - `company_identification` string: Alphanumeric code that identifies the direct deposit originator.
  - `company_name` string: Name of the direct deposit originator.
  - `earlyPayEligible` boolean: Indicates whether the transaction is eligible for early pay.
  - `individual_identification_number` string: Accounting number by which the recipient is known to the direct deposit originator.
  - `individual_name` string: Identity of the direct deposit recipient.
  - `settlement_date` string, date-time, required: Date when the credit or debit is applied.
  - `standard_entry_class_code` string: Three-letter code identifying the type of entry.
  - `token` string: Unique identifier of the direct deposit transaction. If you do not include a token, the system generates one automatically. This token is used in other API calls. Marqeta recommends that you enter a string that you can remember for the token, rather than having the system generate a token for you. This value cannot be updated.
  - `type` 'CREDIT' | 'DEBIT': Provides information about whether funds are being debited from or credited to the account.

## Response `201`

Created

- DirectDepositSimulationResponse
  - `type` 'CREDIT' | 'DEBIT': Whether funds are being debited from or credited to the account.
  - `state` 'PENDING' | 'APPLIED' | 'REVERSED' | 'REJECTED': Current status of the direct deposit record.
  - `state_reason` string: Explains the current state of the direct deposit record.
  - `state_reason_code` string: A standard code describing the reason for the current state.
  - `token` string: Unique identifier of the direct deposit record.
  - `user_token` string: Unique identifier of the user associated with the direct deposit record.
  - `amount` number: Amount being debited or credited.
  - `business_token` string: Unique identifier of the business associated with the direct deposit record.
  - `company_discretionary_data` string: Company-specific data provided by the direct deposit originator.
  - `company_entry_description` string: Description of the purpose of the direct deposit.
  - `company_identification` string: Alphanumeric code that identifies the direct deposit originator.
  - `company_name` string: Name of the direct deposit originator.
  - `created_time` string, date-time: Date and time when the deposit account was created, in UTC.
  - `direct_deposit_account_token` string: Unique identifier of the affected deposit account.
  - `individual_identification_number` string: Accounting number by which the recipient is known to the direct deposit originator.
  - `individual_name` string: Name of the direct deposit recipient.
  - `last_modified_time` string, date-time: Date and time when the direct deposit account was last modified, in UTC.
  - `settlement_date` string, date-time: Date and time when the credit or debit is applied, in UTC.
  - `standard_entry_class_code` string: Three-letter code identifying the type of entry.

## Other responses

- `404`: Bad Request

---

[API](https://skmtc.dev/marqeta/apis/simulations-2-0-api.md) - [All operations](https://skmtc.dev/marqeta/apis/simulations-2-0-api/llms.txt) - [OpenAPI document](https://skmtc.dev/marqeta/apis/simulations-2-0-api/revisions/0d6f0fe4dedb?raw)
