Skip to main content

Account Provisioning (In a single-account setup)

This flow is applicable if you are using the "One SharedSavings account per End User" account setup, and do not have Performance Dreams enabled. See Account Setups for more information and options.

sequenceDiagram participant bfe as Bank App participant sdk as Impact Finance SDK + Web App Frontend participant des as DES Backend participant bbe as Bank Backend bfe ->> sdk: SDK.launch note over sdk: User enters Impact Finance UX<br/>and can explore freely<br/>until launching a savehack sdk ->>+ des: Create Dream des -->>- sdk: Dream Created sdk ->>+ des: Launch Savehack des -->>- sdk: Savehack Launched note over sdk,des: Unless the End User already has an account<br/>we need to provision it now.<br/>Put savehack launch in paused state<br/>and hand over to Bank App. sdk ->>+ bfe: callback: Account Provisioning Requested (user Id) note over bfe: Take over screen and take <br /> user through account provisioning bfe -->>+ bbe: Initiate (async) account provisioning bfe -->> sdk: return from callback (complete future) deactivate bfe note over sdk,des: Start paused savehack launches<br />and prepare transactions note over sdk,des: Celebration: <br /> Dream with active savehack launches <br/> and pending balances! note over bbe: Account Provisioning Complete bbe ->>+ des: POST /accounts deactivate bbe note over des: Automatically link all existing<br/>Dreams to the new account des -->>- bbe: 201: Created note over bbe: Start acting on transactions sdk ->>+ des: Create another Dream note over des: Automatically link new<br/>Dream to the account des -->>- sdk: Dream Created

Note that the account provisioning flow is asynchronous and flexible in terms of when in the user journey it is done. It's for example also possible to decide to provision the account before the End User even starts using the Impact Finance Web App.

sequenceDiagram participant bfe as Bank App participant sdk as Impact Finance SDK + Web App Frontend participant des as DES Backend participant bbe as Bank Backend note over bfe: Take End User through account provisioning bfe -->> bbe: Initiate (async) account provisioning activate bbe bbe ->>+ des: POST /users des -->>- bbe: 201 Created bbe -->>+ des: POST /accounts des ->>- bbe: 201 Created bbe -->> bfe: done deactivate bbe bfe ->> sdk: SDK.launch sdk ->>+ des: Create Dream note over des: Automatically link new<br/>Dream to the account des -->>- sdk: Dream Created

To avoid creating multiple accounts, make sure to populate the externalId field with the POST request to the Impact Finance API /accounts endpoint.

If you don’t want to provide actual externalId and don't care about its value, then just set it to some constant string for example "dreams". It’s unique on user-level so it can be shared with other users, while guaranteeing that each user can only have a single account with this value.

If you don’t want to provide actual externalId, but still want to separate different accounts, then put the userId in the field. That will prevent a user from getting more than one account, while still separating different user accounts.

When nothing is provided in externalId then multiple POST requests to the Impact Finance API /accounts endpoint will create multiple accounts, even if the "One SharedSavings account per End User" feature is enabled.