Plaid Link
Plaid Link allows users to quickly verify bank accounts through instant account verification (IAV). If Moov is managing your Plaid relationship, you can use Moov.js to link bank accounts with Plaid.
Please coordinate with Moov support to prepare your account for Plaid.
Initialize Moov.js
As with all Moov.js methods, you will need a Moov access token with the appropriate scopes.
The Moov.js Plaid functions require the following scopes:
/accounts/{accountID}/bank-accounts.write
|
|
Initialize Plaid Link
Initialize a connection to Plaid, allowing users to instantly verify and link bank accounts to an existing Moov account. Note: For Moov-managed Plaid integrations only.
Parameters
Name | Type | Description |
---|---|---|
accountID |
UUID string | ID for an existing, connected, Moov account |
env |
"sandbox" or undefined |
Plaid environment. Use "sandbox" for testing. Use undefined for production. |
elementID |
string | Optional. If provided, Plaid flow will open when the DOM element with this ID is clicked. |
redirectURL |
URL string | If Plaid forces the user to a bank’s website, they will eventually return to this url. Must be a webpage on your current domain. Contact Moov Support to register this url in the Plaid dashboard. |
onSuccess |
(moovBankAccount) => void | Optional. Callback function executed when Plaid successfully links a bank account to Moov. Moov bank account object is passed as a parameter. |
onExit |
(err, metadata) => void | Optional. Callback function executed when the user exits the Plaid flow. |
onEvent |
(eventName, metadata) => void | Optional. Callback function executed on each Plaid event. |
|
|
|
|
Reinitialize Plaid (Oauth redirects)
Some banks use an OAuth flow to connect to Plaid. In these situations, your user will be redirected to the bank’s website to authenticate, and then redirected back to your specified redirectURL
. This redirect landing page must run moov.plaid.reinitialize
to resume the Plaid flow.
Parameters
Name | Type | Description |
---|---|---|
receivedRedirectUri |
URL string | URL of the current page. Will be a combination of your redirectURL and query parameters set by Plaid. |
accountID |
UUID string | ID for an existing, connected, Moov account |
env |
"sandbox" or undefined |
Plaid environment. Use "sandbox" for testing. Use undefined for production. |
elementID |
string | Optional. If provided, Plaid flow will open when the DOM element with this ID is clicked. |
onSuccess |
(moovBankAccount) => void | Optional. Callback function executed when Plaid successfully links a bank account to Moov. Moov bank account object is passed as a parameter. |
onExit |
(err, metadata) => void | Optional. Callback function executed when the user exits the Plaid flow. |
onEvent |
(eventName, metadata) => void | Optional. Callback function executed on each Plaid event. |
|
|
Using Plaid Sandbox
For testing purposes, you can use the env: "sandbox"
setting in your Plaid configuration object.
In Plaid’s sandbox environment, you can find test bank accounts by searching for Platypus
.
For all Platypus
bank accounts, the username is user_good
and the password is pass_good
.
Platypus
banks may throw a duplicate account
error at the end of the Plaid Link flow. Unfortunately, this issue is outside of Moov’s control. This issue is limited to Plaid’s sandbox environment, and should not affect users in production.