Skip to main content
Using various test values (aka, sentinel values), you may simulate some common scenarios you’ll encounter so you can effectively test your code. Every potential error payload returned by the API can also be simulated to demonstrate the life cycle of a microdeposit. Those sentinel values, and how to use them, will be described in each section below. These test scenarios only work in our integrations environment, not in production. Producing the scenario is just a matter of using the given inputs when start

Validation Errors

Validation errors prevent a microdeposit from being created. The following table explains the validation rules for every relevant field for testing.

Field-Level Validation

Field-level validations can be tested using any data that triggers validation rules to admit an error. This example shows a request with an invalid email address.

All Possible Validation Errors

Request with Invalid Email

Example When a Required Field is Empty, or When Required Values Aren’t Submitted:

Example When a Given Value is Present But Triggers a Data Validation Rule:

The following errors can occur when given values that trigger validation rules. Note that the given values aren’t special — any value provided which breaks the validation rules will trigger these errors: Here’s the updated table with code ticks in the first column:

Duplicate Microdeposit Errors

To produce a duplicate microdeposit error, use the following steps:
  1. Create a valid microdeposit, keeping track of the routing and account number. Attempt to create a microdeposit for the same user, using the same routing and account number.
  2. The result will be an error with the message A MicroDeposit (MIC-a1b2-c3d4) with the same combination of routing and account number already exists.
Create Valid Microdeposit
Attempt to Create Another with the Same Account/Routing
Expected Error Response

Throttling Errors

To produce a throttling error, use the following steps:
  1. For a single user, create three valid microdeposits.
  2. Attempt to create a fourth microdeposit no later than three days from when the first microdeposit was created. The expected response should be an error with the message “Create too many created within acceptable window.”
To test that new microdeposits can be made after the three-day window, you can either:
  • Wait three days
  • Delete one of the three microdeposits

Lifecycle Testing

ACH Errors

In a real-world scenario, a microdeposit won’t immediately return an ACH error. ACH errors occur only when deposits are attempted, and deposits can take several hours or several days to arrive. When producing ACH errors for testing purposes, microdeposits immediately change from a status of INITIATED to ERRORED. In the real world, a microdeposit will transition from INITIATED to REQUESTED and then to ERRORED. ACH errors R01 through R26 can be triggered by using special test values for the first_name field: testACHErrorA through testACHErrorZ. Create microdeposit with testACHError
Response
Check the Microdeposit Status
Response ERROED status
To test specific ACH error codes:
  1. Create a microdeposit using testACHError (or any other valid test name for a given error) as the first_name. The initial response will look like a normal, valid microdeposit.
  2. Check the status of the microdeposit. The ACH error_code and error_message can now be seen, and the status is now ERRORED. Note that specific ACH errors can be tested by adding a letter to the first_name value.

Invalid Verification Value Error

Note that “invalid” verification values aren’t the same as “incorrect” values. Using non-numeric or blank verification values will trigger validation errors. To test an invalid verification error:
  1. Create a valid microdeposit using a special account number. Account numbers that begin with 3333 will automatically transition from REQUESTED to DEPOSITED 2 minutes after creating the microdeposit.
  2. Once 2 minutes have passed, check the microdeposit to ensure that the status is now DEPOSITED.
  3. Attempt to verify the microdeposit using invalid deposit amounts. You should see an error message describing the invalid verification amounts.
Create Microdeposit with Special Account Number
Response
Check the Status
Response with DEPOSITED Status
Verify with Invalid Amounts
Error Response

Incorrect Verification Value Error

Note that “incorrect” verification values aren’t the same as “invalid” values. Incorrect verification values will trigger a microdeposit verification error. End users are allowed three attempts to enter the correct verification amounts. On the third failed attempt, the microdeposit will move to a PREVENTED status, and is considered complete. Note that PREVENTED indicates a legitimate failure for the end user to verify their account. A PREVENTED status doesn’t indicate a problem with the verification process. To test an incorrect verification value error:
  1. Create a valid microdeposit using a special account number. Account numbers that begin with 3333 will automatically transition from REQUESTED to DEPOSITED 2 minutes after creating the microdeposit.
  2. Wait at least 2 minutes, then check the status to ensure that the status is now DEPOSITED.
  3. Now that the microdeposit is ready to verify, use 0.02 for both values.
  4. Check the status of the microdeposit. It should now be DENIED.
Create Microdeposit with Special Account Number
Response
Check the Status after 2 Minutes
Response with DEPOSITED status
Verify with with Values 0.02
Check the Microdeposit Status
Response with DENIED Status

Early Verification Error

To test an early verification error:
  1. Create a valid microdeposit.
  2. Attempt to verify the microdeposit using any deposit amounts. An error indicating that it’s too early to verify should be present in the response.
Create a Microdeposit
Verify Using Any Amounts
Error Response

Verifying Multiple Times Error

To test a multiple verification error:
  1. Create a valid microdeposit using any special 3333xxx account number.
  2. Wait at least 2 minutes.
  3. Check the microdeposit status.
  4. Once the status shows as DEPOSITED:
    • Verify the microdeposit using 0.09 for both deposit amounts. This simulates a successful verification.
  5. Attempt to verify again.
    • The response should indicate that the microdeposit couldn’t be verified again.
Create Microdeposit with Special Account Number
Response
Check the Status after 2 Minutes
Response with DEPOSITED Status
Attempt to Verify Again with Amounts 0.09
Error Response