Step 4: Handle JavaScript Callback #

The Customer will complete the IAV flow by authenticating with their online banking credentials. You’ll know their bank account was successfully added and verified if you receive a JSON response in your callback that includes a link to the newly created funding source.

IAV select account screen

Example success callback #

json
{
  "_links": {
    "funding-source": {
      "href": "https://api-sandbox.dwolla.com/funding-sources/80275e83-1f9d-4bf7-8816-2ddcd5ffc197"
    }
  }
}

Handling IAV errors #

IAV related errors are returned either as user-facing messages within the IAV flow, or triggered through the dwolla.js callback. User-facing messages are displayed in red text at the top of the bank login screen informing the user there was an issue with connecting the associated bank account. Error callbacks will trigger letting your app know of errors that can't be fixed by the user within the flow.

Error callbacks will contain a similar JSON error response body as common errors in the API, which includes a top-level error code and a message. Reference the following list of error callbacks:

CodeMessageDescription
UnexpectedPageIAV navigated to an unexpected page and was cancelled.A Dwolla related error occurred.
InvalidIavTokenInvalid IAV token.An IAV token has already been used or has exceeded its expiration time of 1 hour.
UnsupportedBankSorry, that financial institution is not supported. If possible, please choose a different one or an alternative method for connecting your financial institution.The customer's bank is not supported by the IAV flow.
RateLimitReachedSorry, we’re having trouble logging into your account. Please try a different account.The customer exceeded the max number of two IAV attempts with the same bank. The customer must wait 30 minutes in order to re-authenticate.

Example error callback

json
{
  "code": "RateLimitReached",
  "message": "Sorry, we’re having trouble logging into your account. Please try a different account."
}

Test in the Sandbox for free today.

Use sandbox environment to test API requests.

Get API Keys
2022 All Rights Reserved
Financial institutions play an important role in our network.

All funds transfers made using the Dwolla Platform are performed by a financial institution partner, and any funds held in a Dwolla Balance are held by a financial institution partner. Learn more about our financial institution partners.