Problem statement
Design the Know-Your-Customer verification pipeline that decides whether a new applicant may open a financial account. An applicant submits identity documents and personal details; the pipeline orchestrates document checks, biometric/liveness matching, sanctions and watchlist screening, and risk scoring, then routes the case to auto-approve, auto-reject, or manual review. Because a wrong decision has legal and financial consequences, every verdict must be explainable and every input retained for audit.
Operating context. The pipeline calls several third-party verification providers that are slow, rate-limited, occasionally down, and priced per call. Applications arrive continuously with daily peaks. Documents contain sensitive PII that must be encrypted and access-controlled. Assume 500000 applications/day, provider calls that take seconds to minutes, and a regulatory duty to reproduce exactly why any past decision was made.
Out of scope. The applicant-facing onboarding UI, the internal implementation of third-party providers, ongoing transaction monitoring after approval, and the manual-review console beyond the queue it consumes. Assume separate teams own the app, the providers, and the review tool.
What to produce. A high-level architecture covering: the case orchestration across multiple async provider steps, handling slow/failing/rate-limited providers with retries and timeouts, the decisioning and routing to approve/reject/review, secure handling and retention of PII, idempotent re-runs and resumability of a case, an auditable record of every input and step, and scaling to peak load without exceeding provider quotas. Sketch the pipeline stages and dataflow; we will probe specifics in checkpoints.
Functional requirements
- Accept an application and orchestrate document verification, liveness/biometric match, watchlist screening, and risk scoring as ordered async steps.
- Route each completed case to auto-approve, auto-reject, or manual review based on the combined step results and policy.
- Retry, time out, or fall back per provider step without failing the whole case, and resume a case from its last completed step.
- Produce an immutable, explainable decision record capturing every input, provider response, and rule that fired.
- Feed cases needing human judgment into a review queue and record the reviewer's final verdict back onto the case.
Non-functional requirements
- Handle 500000 applications/day with peaks of 30 applications/sec without exceeding any provider's rate limit.
- End-to-end p95 decision time < 5 minutes for fully automated cases; queue depth visible to operations.
- 99.9% availability for case intake; a provider outage degrades gracefully rather than dropping applications.
- All PII is encrypted at rest and in transit with per-field access control and full access auditing.
- Retain every application input and decision record for 7 years, fully reproducible, ~30 TB.
- Exactly-once decisioning: a retried or resumed case never produces a second or conflicting verdict.
Topics
- System Design HLD
- Fintech Kyc
- Patterns Orchestration
- Reliability Retries
- Security Pii