Skip to main content
Version: 0.46.0

Customer Management

The Customer Management system is the identity foundation for all financial operations in Lana. Every deposit account, credit facility, and financial transaction ultimately links back to a customer record. The system covers the full customer lifecycle, from initial registration and KYC verification through ongoing relationship management and activity monitoring.

Customer Types

Customer type is assigned at creation and determines several downstream behaviors: which KYC verification level is used (individual vs. business), which ledger account sets the customer's deposit accounts belong to, and how accounting entries are categorized in financial reports.

TypeDescriptionKYC LevelAccounting Treatment
IndividualNatural personBasic KYC (identity verification)Individual accounts
Government EntityGovernment organizationBasic KYB (business verification)Government accounts
Private CompanyPrivate corporationBasic KYBBusiness accounts
BankBanking institutionBasic KYBInterbank accounts
Financial InstitutionFinancial services companyBasic KYBInstitutional accounts
Foreign Agency or SubsidiaryForeign agency/subsidiaryBasic KYBForeign accounts
Non-Domiciled CompanyNon-domiciled corporationBasic KYBNon-resident accounts

The distinction between KYC and KYB matters because Sumsub applies different verification workflows for each. Individual customers go through identity document verification (passport, selfie), while all other types go through business verification workflows (corporate documents, beneficial ownership).

Customer Lifecycle

A customer progresses through several states from creation to active operations:

  1. Creation: An operator creates the customer record in the admin panel with email, optional Telegram ID, and customer type. The customer starts in Inactive status with KYC verification Pending.
  2. KYC verification: The operator generates a Sumsub verification link. The customer completes identity verification through Sumsub's interface. Sumsub notifies the system via webhook when verification concludes.
  3. Provisioning: When KYC is approved, the system emits events that trigger downstream provisioning. A Keycloak user account is created so the customer can authenticate, a welcome email is sent with credentials, and a deposit account is created.
  4. Active operations: The customer can now access the customer portal, receive deposits, and apply for credit facilities.

Activity Status

Customer activity status is managed automatically by a periodic background job. The system tracks each customer's last activity date and applies configurable thresholds to determine whether the customer should be considered active, inactive, or suspended.

StatusConditionEffect
ActiveActivity within the last yearFull operational access
InactiveNo activity for 1-10 yearsAccount operations paused; deposit accounts become inactive
SuspendedNo activity for over 10 yearsAccount suspended pending escheatment review

When a customer's activity status changes, all of their deposit accounts are updated to match. An inactive customer's deposit accounts cannot process new deposits or withdrawals until the customer becomes active again. The activity date is updated whenever the customer performs any financial operation.

KYC Verification States

StatusDescriptionNext Action
Pending VerificationInitial state for all new customersGenerate Sumsub verification link
VerifiedIdentity confirmed by SumsubCustomer can access financial products
RejectedVerification failedReview rejection reasons in Sumsub

KYC verification is a one-way gate: once verified, a customer remains verified. If verification is rejected, the operator can review the rejection reasons in the Sumsub dashboard and potentially request a new verification attempt.

When KYC verification requirements are enabled in the system configuration, a customer must be verified before a deposit account can be created or a credit facility can be initiated. This is a configurable policy that the bank can enable or disable.

System Components

ComponentModulePurpose
Customer Managementcore-customerCustomer entity, profiles, KYC state, activity tracking
KYC Processingcore-customer (kyc)Sumsub API integration, webhook callback handling
Document Storagecore-document-storageFile upload, cloud storage, download link generation
User Onboardinglana-user-onboardingKeycloak user provisioning on customer creation events

Integration with Other Modules

The customer record is referenced by virtually every other module in the system:

  • Deposits: Each customer has a deposit account (created automatically after KYC approval). The customer type determines which ledger account set the deposit account belongs to.
  • Credit: Credit facility proposals are linked to a customer. KYC verification can be required before disbursals are permitted.
  • Accounting: Customer type drives the chart-of-accounts placement for both deposit liabilities and credit receivables.
  • Governance: Approval processes for withdrawals and credit operations reference the customer indirectly through the associated entities.