Technology & Architecture

Tech stack, API integrations, credit scoring, mobile money connectivity, security, and scalability considerations

1. Architecture Overview

The platform follows a multi-layered architecture with clear separation between the borrower-facing app, the bank/MFI integration layer, and the internal scoring/engine components.

Layer 1 — Borrower Interface📱 React Native Mobile App (Android primary, iOS secondary) + USSD Gateway
Layer 2 — API Gateway🔐 Authentication · Rate Limiting · Request Routing · API Versioning
Layer 3 — Core Servicesâš™ī¸ Loan Origination ¡ KYC Verification ¡ Credit Scoring ¡ Repayment Processing ¡ Notifications
Layer 4 — Bank/MFI IntegrationđŸĻ Partner Bank APIs ¡ Loan Disbursement ¡ Repayment Reconciliation ¡ Compliance Reporting
Layer 5 — Payment RailsđŸ’ŗ Telebirr ¡ M-Pesa ¡ Bank Transfer ¡ EthSwitch ¡ Mobile Money APIs
Layer 6 — Data & Intelligence🧠 Alternative Credit Scoring · Fraud Detection · Analytics · Reporting
Layer 7 — InfrastructuređŸ–Ĩī¸ In-Country Data Center ¡ PostgreSQL ¡ Redis ¡ Monitoring ¡ Backup/DR

2. Technology Stack

Frontend (Borrower App)

ComponentTechnologyRationale
Mobile FrameworkReact NativeSingle codebase for Android + iOS. Team already skilled (per original proposal). Large ecosystem.
UI LibraryReact Native Paper or NativeBaseMaterial Design components. Good accessibility. Amharic font support.
State ManagementRedux Toolkit or ZustandPredictable state for complex loan workflows.
Offline SupportWatermelonDB or AsyncStorageCritical for areas with intermittent connectivity. Queue KYC submissions for later sync.

Frontend (Admin/Bank Portal)

ComponentTechnologyRationale
Web FrameworkReact + Next.jsServer-side rendering for performance. Admin dashboards, reporting views.
UI LibraryTailwind CSS + shadcn/uiFast development, consistent design system, dark mode support.

Backend

ComponentTechnologyRationale
API FrameworkNode.js (Hono or Express) or Python (FastAPI)Hono for lightweight API gateway. FastAPI for credit scoring services (Python ML ecosystem).
Primary DatabasePostgreSQLACID compliance for financial data. JSON support for flexible KYC documents. Proven in Ethiopian context.
CacheRedisSession management, rate limiting, real-time credit score caching.
Message QueueBullMQ or Redis StreamsAsync processing for loan applications, disbursement triggers, notification dispatch.
SearchPostgreSQL FTS or MeilisearchLoan application search, applicant lookup. Meilisearch for Amharic text search.
Document StorageMinIO or PostgreSQL large objectsKYC documents (ID photos, trade licenses). In-country storage mandatory.

ML / Credit Scoring

ComponentTechnologyRationale
ML Frameworkscikit-learn + XGBoostProven for tabular credit scoring. Fast inference, good explainability.
Deep Learning (optional)PyTorchIf using image data for KYC or NLP for Amharic text analysis.
Model ServingFastAPI + ONNX RuntimeLow-latency inference. ONNX for production model portability.
Feature StorePostgreSQL + RedisReal-time features from transaction data, cached for fast scoring.

Infrastructure

ComponentTechnologyRationale
HostingEthio Telecom DC or local providerData localization mandate. Evaluate Ethio Telecom's cloud offerings.
ContainerizationDocker + Docker Compose (or K3s)Simple deployment. K3s for lightweight Kubernetes if scaling.
CI/CDGitHub Actions or GitLab CIAutomated testing and deployment. In-country runner for deployment.
MonitoringGrafana + PrometheusSystem health, API latency, error rates. Alerting for incidents.
LoggingLoki or ELK StackCentralized logging for audit trails and debugging.
Backuppg_dump + offsite within EthiopiaDaily backups with off-site storage. RTO < 24 hours.

3. API Integrations Required

Mobile Money Integration

â„šī¸ Critical integration. Disbursement and repayment MUST go through mobile money to reach the mass market. Direct bank transfers are too slow and require bank account ownership.
ServicePurposeIntegration Method
Telebirr APIDisbursement + repaymentThrough partner bank's Telebirr integration (e.g., CBO API). Direct API may require PII-level access.
M-Pesa APIAlternative disbursement channelSafaricom Developer Portal. Growing user base in Ethiopia.
EthSwitchInteroperability hubNational switch for bank-to-bank and bank-to-mobile transfers. Required for PII interoperability.
Telebirr USSDNon-smartphone accessUSSD gateway for loan applications and status checks without a smartphone.

Identity & KYC

ServicePurposeNotes
National ID verificationPrimary identity documentNational Digital ID system is in development. Current: OCR + AI verification of ID photos.
Trade License verificationBusiness existence proofOCR extraction + manual or API verification with trade office.
Liveness checkSelfie match to ID photoFace recognition API (e.g., FaceTec, or open-source alternatives).
Kebele IDSupplementary IDFor borrowers without National ID. Photo capture + OCR.

Payment & Banking

ServicePurposeNotes
Partner Bank APILoan disbursement, balance check, repayment reconciliationEach partner bank will have different API capabilities. Build adapter pattern.
SMS GatewayOTP, notifications, repayment remindersIntegrate with local SMS providers (e.g., Africa's Talking, Ethio Telecom SMS).
Push NotificationsReal-time app notificationsFirebase Cloud Messaging (Android), APNs (iOS).

4. Credit Scoring Engine

This is the core IP and competitive differentiator. With CRB inaccessible, the scoring engine must rely entirely on alternative data.

Data Sources for Scoring

Data SourceWhat It Tells YouAvailability
Mobile money transactionsIncome patterns, cash flow stability, spending behaviorHigh — with borrower consent via Telebirr/M-Pesa APIs
POS / merchant dataBusiness revenue, transaction volume, seasonalityMedium — via payment processor partnerships
Trade licenseBusiness existence, registration type, years activeHigh — collected during KYC
National ID dataAge, location, identity verificationHigh — collected during KYC
Phone metadataDevice age, usage patterns (NOT contacts — avoid Kenya mistake)Medium — with explicit consent
App behaviorEngagement, consistency, feature usageHigh — first-party data
Employer dataIncome stability, employment tenureMedium — for salaried borrowers
Geographic dataUrban vs. rural, regional risk factorsHigh — from device GPS (with consent)

Scoring Model Architecture

  1. Feature engineering: Transform raw transaction data into behavioral features (avg monthly income, income volatility, expense-to-income ratio, transaction frequency, cash flow trends)
  2. Model training: XGBoost ensemble for primary scoring. Logistic regression as interpretable baseline.
  3. Score bands: Map scores to credit tiers — determines maximum loan amount and interest rate
  4. Explainability: SHAP values for each decision — required for transparency and regulatory compliance
  5. Feedback loop: Repayment outcomes feed back into model retraining. Model improves over time.
  6. Fraud detection: Separate model for application fraud (identity mismatch, synthetic identities, document forgery)
âš ī¸ Model risk: Alternative data scoring is less established than traditional credit bureau scoring. Initial models will have higher uncertainty. Plan for: conservative initial limits, manual review queue for edge cases, and gradual model expansion as data accumulates.

5. Security Requirements

RequirementImplementationPriority
Encryption at restAES-256 for all stored data (PostgreSQL TDE, document encryption)Critical
Encryption in transitTLS 1.3 for all API communications. Certificate pinning in mobile app.Critical
AuthenticationJWT + refresh tokens. Biometric auth (fingerprint/face) for sensitive operations.Critical
AuthorizationRole-based access control (RBAC). Admin portal: loan officer, compliance officer, admin.Critical
Rate limitingAPI rate limiting to prevent abuse. Stricter limits on loan application endpoints.High
Intrusion detectionIDS/IPS on network perimeter. Log anomaly detection.High
Penetration testingAnnual third-party pentest. Quarterly internal security review.High
Audit trailsImmutable logs for all financial transactions and admin actions. 5+ year retention.High
Incident responseDocumented IR plan. 72-hour breach notification to ECA (PDPP requirement).High
KYC document securityEncrypted storage with access logging. Auto-expiry for expired documents.Medium

6. Scalability Considerations

7. Development Timeline Estimate

PhaseDurationDeliverables
Discovery & Design3-4 weeksRequirements finalization, UX research (Amharic), architecture design, bank/MFI partner selection
Core Platform MVP8-10 weeksKYC flow, loan application, credit scoring engine v1, admin dashboard, bank API integration
Payment Integration3-4 weeksTelebirr disbursement/repayment, mobile money reconciliation, EthSwitch integration
Testing & QA3-4 weeksUAT with partner bank, security audit, performance testing, compliance review
Pilot Launch2-3 weeksLimited release to selected MSMEs, monitoring, feedback collection, iteration
Full LaunchOngoingPublic release, marketing, partner bank onboarding, model improvement
Total to MVP~16-20 weeksUp from 14 weeks in original proposal — additional time for compliance and banking integrations

8. Cost Implications (vs. Original Estimate)

The original proposal estimated ETB 292,500 for a driver-focused microcredit app. The expanded scope significantly increases requirements:

ItemOriginal (Driver App)Expanded (Full Platform)Delta
Design & PlanningETB 30,000ETB 80,000-120,0003-4× (UX research, multi-language, bank portal)
DevelopmentETB 206,250ETB 600,000-900,0003-4× (scoring engine, bank APIs, admin portal)
TestingETB 56,250ETB 150,000-200,0003× (security audit, compliance testing, UAT)
Compliance & LegalNot includedETB 100,000-200,000New (ECA registration, legal counsel, AML setup)
InfrastructureNot includedETB 200,000-400,000/yrNew (in-country data center, monitoring, backup)
Total (Year 1)ETB 292,500ETB 1,130,000-1,820,000~4-6×
â„šī¸ Note: These are rough estimates. Actual costs depend on team size, partner bank API complexity, and compliance requirements. The expanded platform is a significantly larger undertaking than the original proposal. Consider phased delivery to manage cash flow.

9. Key Technical Decisions to Make

  1. Node.js vs. Python for core API? — Node.js for speed/real-time, Python for ML integration. Consider Hono (Node) for API gateway + FastAPI for scoring services.
  2. Single bank or multi-bank from MVP? — Start with 1 bank partner for MVP, add more in phase 2. Multi-bank adds significant integration complexity.
  3. USSD from day one? — Critical for non-smartphone users but adds development cost. Consider phase 2.
  4. Amharic-only or multi-language from launch? — Amharic-first with Oromo support as priority phase 2 addition.
  5. Build vs. buy credit scoring? — Build (Kifiya-style) vs. partner with existing scoring provider. Build is higher upfront but owns the IP.
  6. Hosting provider? — Evaluate Ethio Telecom DC, local private DCs, and emerging Ethiopian cloud providers.