Account Linking
Good to know: account linking is useful if you wish to use AIS (Account Information Service) or skip authentication steps when initiating payments via the in-app payments module.
For initialising the account linking flow, you will need to get state and pass it to the SDK - a description on how to get state can be found here.
Firstly, you will need to integrate kevin. API and fetch account linking state. Instructions on how to do it can be found here:
AccountSessionConfiguration has multiple settings to tackle:
accountLinkingType
- allows to choose if you want to link bank account or payment card. By default it will link bank accountpreselectedCountry
- preselects country in our prebuilt UIdisableCountrySelection
- uses only preselected country and does not allow to change itcountryFilter
- allows only certain countries to be supportedbankFilter
- allows to filter banks and show only selected ones to user. It accepts list of bank ids that should be show to user.preselectedBank
- preselects bank in our prebuilt UIskipBankSelection
- skips bank and country selection and redirects user to the bank SCA immediately
// initialize configuration with state fetched from the API
const config = KevinAccountSessionConfiguration(
state: 'state',
preselectedCountry: KevinCountry.lithuania,
countryFilter: [
KevinCountry.lithuania,
KevinCountry.estonia,
KevinCountry.latvia
],
preselectedBank: 'SOME_BANK_ID',
bankFilter: [
'SWEDBANK_LT',
'SEB_LT',
'LUMINOR_LT',
'REVOLUT_LT',
],
accountLinkingType: KevinAccountLinkingType.bank,
);
Call
startAccountLinking()
method and wait for the result.const config = KevinAccountSessionConfiguration(
state: 'state',
preselectedCountry: KevinCountry.lithuania,
);
final result = await KevinAccounts.startAccountLinking(config);
Last modified 1mo ago