-
Notifications
You must be signed in to change notification settings - Fork 7
New Account Process
This document details the ideas I've had for how a new account could be created.
When a user creates a new Account
after creating a Leather login, I've been imagining three paths for creating that account:
- Manual account
- Plaid-linked account with full transaction history
- Plaid-linked account with only future imported transactions
For (1) manual account, the user simply gives the account a name
, starting_balance
, and type
(checking, savings, etc -- though we should keep these the same as account types from Plaid).
For (2 and 3) Plaid-linked account with full/future-only transaction history, the user bypasses the name
, starting_balance
, and type
fields and clicks "Link with bank account" (or similar). Here's an example of what I had for leather-django:
When the user clicks "Link your bank account", they are go into the Plaid Link UI, where they complete the process. Once they've successfully connected, we get a token and reload the page, and at this point we need a UI for the user to make some selections. They need to choose which accounts from the Plaid.Account
they want to create-or-link Account
s for in Leather, and whether they want those accounts to be started "fresh" with no transaction data (only future imported transactions) or if they want a historical pull of transactions. I say "create-or-link" because I think if you connect to your bank account with Plaid and you've already created a manual Account
, you should be able to say "link this Plaid-connected checking account with this already-existing Account
".
For (3) where the user only wants future imported transactions, they'll also need to set a starting balance.
Separate from the new-account-setup, I'm imagining a "Linked Accounts" settings UI where users could link/unlink Plaid.Account
s to Account
s at any time, since the only actual "linkage" should be handling a webhook of imported transactions and turning them into Transaction
s for the linked Account
.
Note: from a data perspective, I believe we also want a Plaid.PlaidAccount
model, which stores the user's access_token
and public_token
, but maybe the new API changes that. For posterity, here's how I implemented that in leather-django: https://github.com/nicksergeant/leather-django/blob/master/leather/accounts/models.py#L8