Skip to content

18.2 LOS calls and operations

This page enumerates every meaningful operation in the LOS with what it does, what it validates, what it depends on, what side effects it has. The goal: an engineer / auditor can trace any application’s lifecycle precisely.

  • Input: { mobile, pan?, gstin?, channel, utm }
  • Validations: mobile format; PAN format if present; channel exists.
  • Side effects:
    • Dedup check on mobile / PAN.
    • Velocity check (channel / device).
    • Internal blacklist check.
    • Creates lead row.
    • Attribution recorded.
  • Audit: lead.created event.
  • Returns: lead_id.
  • Input: { lead_id }
  • Internal: sales / DSA / CA action.
  • Side effects: lead.status = qualified.
  • Returns: void.
  • Input: { pan, mobile, gstin, loan_amount_sought, channel, consent }
  • Operations:
    • GSTIN status check (vendor call: Karza / Signzy / GSP).
    • NIC code lookup against negative list.
    • Geography check.
    • Internal blacklist + velocity check.
    • Soft bureau pull (vendor call) if consent + supported.
  • Returns: { verdict, indicative_offer? }.
  • Cost: ~₹10 – ₹25 per check.
  • Input: { borrower_id?, lead_id?, loan_product_id, loan_amount_sought, tenure_sought, purpose_code }
  • Validations: product exists; amount within product min/max; tenure within product range.
  • Side effects:
    • Creates application row in DRAFT.
    • Initialises BFF session.
  • Returns: application_id.
  • Input: { application_id, section_name, data_json }
  • Sections: business_profile, promoter_details, beneficial_owners, loan_requirement, existing_debt, bank_accounts, collateral, etc.
  • Side effects:
    • Saves application_section_data.
    • Per-section validation (per-section schema).
  • Returns: { saved_at, validation_errors? }.
  • Input: { application_id, promoter_data }
  • Validations: PAN format; mobile unique among promoters (typically).
  • Side effects: creates promoter row linked to business_entity.
  • Input: { application_id, bo_data, parent_bo_id? }
  • Validations: ownership_pct sum check (across BOs).
  • Side effects: creates beneficial_owner row; recurses for multi-tier.
  • Input: { borrower_id, purpose, data_categories, version_of_policy, vendor?, vendor_consent_ref? }
  • Validations: purpose in allowed list.
  • Side effects:
    • Creates consent row with timestamp, IP, device.
    • Audited.
  • Returns: consent_id.
  • Input: { application_id, type, file_multipart }
  • Validations: file type allowed; file size within limit.
  • Side effects:
    • Stores file in S3 with versioning.
    • Creates document row with hash + URI.
  • Returns: document_id.
  • Input: { application_id }
  • Validations:
    • All required sections complete.
    • All required documents uploaded.
    • All required consents captured.
    • Loan amount within sanctioned product range.
  • Side effects:
    • State → SUBMITTED.
    • Triggers KYC + ingestion orchestration.
  • Returns: { status, expected_decision_at }.
  • Input: { promoter_id, method } (method: vcip / aadhaar_offline / digilocker)
  • Operations:
    • Per method, invoke vendor adapter.
    • For V-CIP: schedule session, return session URL.
    • For Aadhaar offline: prompt borrower to upload zip + share-code.
  • Returns: { session_id? }.
  • Input: { pan, name, dob }
  • Vendor: NSDL / Karza / Signzy.
  • Returns: { status, name_match_score }.
  • Input: { promoter_id, zip_url, share_code }
  • Operations: verify signature; extract fields.
  • Returns: { status, masked_aadhaar, fields }.

Op 14: vcip.complete (webhook from vendor)

Section titled “Op 14: vcip.complete (webhook from vendor)”
  • Input: vendor webhook payload.
  • Side effects:
    • Update vcip_session row.
    • Trigger downstream kyc.individual.completed event.
  • Returns: ack.
  • Input: { subject_type, subject_id, name, dob?, address? }
  • Vendor: AML Watcher / World-Check.
  • Returns: { screen_id, hits[] }.
  • Input: { gstin }
  • Vendor: Karza / Signzy / GSP.
  • Returns: { status, legal_name, address, registration_date, taxpayer_type }.
  • Input: { cin_or_llpin }
  • Vendor: Karza / Probe42.
  • Returns: { status, directors, last_filing_date, shareholding }.
  • Input: { pan?, aadhaar?, mobile? }
  • Vendor: Karza / Signzy CKYC connector.
  • Returns: { kin? }.
  • Input: standardised CKYC payload.
  • Side effects: uploads to CKYCR; updates kyc_record.
  • Returns: { kin }.
  • Input: { account_number, ifsc, claimed_name }
  • Vendor: Razorpay / Cashfree / Setu.
  • Returns: { verified, returned_name, name_match_score }.
  • Input: { borrower_id, purpose, fi_types, date_range, frequency, validity }
  • Vendor: AA TSP (Setu / FinBox).
  • Returns: { consent_handle, redirect_url }.
  • Input: { consent_handle }
  • Vendor: AA TSP.
  • Operations: async fetch; data returned via webhook.
  • Returns: { fetch_id, status: "in_progress" }.
  • Input: vendor webhook with encrypted data.
  • Operations: decrypt; normalise into bank_statement table.
  • Side effects: emit data.bank_statement.parsed event.
  • Input: PDF file + password.
  • Vendor: Perfios / FinBox.
  • Operations: async parse; emit event on completion.
  • Returns: { pull_id, status }.
  • Input: { gstin, periods }
  • Vendor: GSP (Cygnet / Webtel).
  • Operations: triggers OTP to borrower’s GST-registered mobile.
  • Returns: { session_id, otp_required: true }.
  • Input: { session_id, otp }
  • Vendor: GSP.
  • Operations: triggers actual fetch.
  • Returns: { fetch_id, status }.
  • Input: GSP returns parsed returns.
  • Side effects: store in gst_report; emit event.
  • Input: { subject_type, subject_id, cic, report_type }
  • Vendor: CIC direct or aggregator.
  • Returns: { bureau_report_id, score, parsed_uri }.
  • Input: { cin_or_llpin }
  • Vendor: Karza / Probe42.
  • Returns: parsed MCA snapshot.
  • Input: Tally backup file.
  • Vendor: Karza Tally connector.
  • Operations: async parse.
  • Returns: { pull_id, status }.
  • Input: { application_id, policy_id? } (policy auto-selected if omitted)
  • Operations:
    • Snapshot inputs (all ingested data).
    • Load policy version.
    • Execute rules in order.
    • Execute scorecards.
    • Apply segment overlay.
    • Compute recommendation.
  • Returns: { decision_run_id, decision, grade, recommended }.
  • Audit: full trace stored in decision_run.trace_uri.
  • Input: { decision_run_id, reasons }
  • Side effects: case routed to manual review queue.
  • Input: { case_id, analyst_id }
  • Side effects: case assigned; analyst’s queue updated.
  • Input: { case_id, query_text, addressed_to }
  • Side effects:
    • Query sent to borrower / DSA / RM via SMS / email.
    • Case marked awaiting_response.
  • Input: { case_id, recommendation, deviation_requested? }
  • Side effects: analyst’s recommendation captured; routed to checker or deviation approver.
  • Input: { decision_run_id, reason, requested_overrides }
  • Side effects: routes to approval queue per delegation matrix.
  • Input: { deviation_id, approver_id, conditions? }
  • Side effects: decision moves to APPROVED with deviation flag + conditions.
  • Input: { decision_run_id, amount, tenure, rate, fees, conditions }
  • Side effects: creates offer row with validity.
  • Returns: offer_id.
  • Input: { offer_id }
  • Validations: offer not expired.
  • Side effects: offer status updated; triggers documentation.
  • Input: { application_id, offer_id }
  • Side effects: creates sanction row; triggers document generation.
  • Returns: sanction_id.
  • Input: { sanction_id, doc_type, language, template_version? }
  • Operations: render template with sanction + borrower data; produce PDF.
  • Side effects: stores in S3; creates issued_document row.
  • Returns: { document_id, object_uri }.
  • Input: { kfs_document_id, evidence }
  • Side effects: KFS marked acknowledged with timestamp + IP + device.
  • Returns: { acknowledged_at }.
  • Input: { document_id, signers[] }
  • Vendor: Leegality / Digio.
  • Returns: { session_id, signing_urls[] }.
  • Input: vendor webhook.
  • Side effects: per signer status updated; on all-complete, document marked executed.
  • Input: { document_id, state, denomination }
  • Vendor: SHCIL via partner.
  • Returns: { estamp_session_id, certificate_uri }.
  • Input: { application_id, account_token, ifsc, type, max_debit, valid_from, valid_to }
  • Vendor: Digio / Razorpay / Cashfree / Setu.
  • Returns: { mandate_id, status: "pending" }.
  • Input: { mandate_id }
  • Operations: polls vendor / sponsor bank.
  • Returns: { status }.
  • Input: { sanction_id, amount, to_account_token, purpose, splits? }
  • Validations:
    • Sanction valid + within validity.
    • Amount <= sanctioned + remaining limit.
    • Bank account verified.
    • All pre-conditions on sanction met.
  • Side effects: creates disbursement_instruction row in PENDING_APPROVAL.
  • Returns: disbursement_id.
  • Input: { disbursement_id }
  • Operations: runs the pre-disbursement checklist:
    • KYC valid + not expired.
    • KYB complete.
    • Sanction within validity.
    • All borrower documents executed.
    • KFS acknowledged.
    • NACH mandate active.
    • Bank account verified (penny drop within tolerance).
    • Sanctions screen clean.
    • Decision still valid (no new data invalidates).
    • Exposure caps unbreached.
    • Co-lender approval (if applicable).
    • DLG instrument confirmed (if applicable).
    • Cooling-off opted-in (where applicable).
  • Returns: { all_pass: bool, failures[] }.
  • Input: { disbursement_id, approver_id }
  • Validations: approver has delegated authority for this amount.
  • Side effects: status → APPROVED.
  • Input: { disbursement_id } with X-Idempotency-Key
  • Operations:
    • For co-lending: trigger partner-funds-release into escrow.
    • Call payout adapter (sponsor bank API or RazorpayX / Cashfree).
    • Capture UTR.
  • Side effects: status → EXECUTINGCOMPLETED on success.
  • Returns: { status, utr? }.
  • Input: vendor webhook with UTR.
  • Side effects:
    • Status → COMPLETED.
    • Triggers borrower notification.
    • Triggers loan activation in LMS.
  • Input: returned-funds notification.
  • Side effects:
    • Reverses loan booking.
    • Notifies ops.
    • Re-attempt workflow.
  • Input: { sanction_id, disbursement_id, product_terms }
  • Side effects:
    • Creates loan_account row.
    • Generates schedule.
    • Starts daily accrual.
    • Triggers co-lending allocation if applicable.
    • Emits loan.activated event.
  • Returns: loan_account_id.
  • Input: { loan_id }
  • Operations: SMS + WhatsApp + email with loan number + UTR + first due date + statement link.
  • Input: { loan_id, partner_id }
  • Operations: API / webhook + daily MIS entry.
  • Input: { loan_id, channel_id }
  • Operations: compute DSA fee per channel agreement.
  • Side effects: creates dsa_payout row.
  • Input: { payout_id, approver_id }
  • Operations: execute payout to DSA.
  • Input: { application_id, reason }
  • Side effects: state → WITHDRAWN. Refund any received fees.
  • Trigger: scheduler for offer / sanction validity.
  • Side effects: state → EXPIRED.

Already covered in 5.13.

Vendor cost reference (per application, illustrative)

Section titled “Vendor cost reference (per application, illustrative)”
Operation categoryTypical cost per application
Pre-eligibility₹10 – ₹25
KYC suite₹50 – ₹200 (depends on vendor mix)
V-CIP₹40 – ₹150 per session
AA fetch₹15 – ₹50
BSA parse₹15 – ₹50
GST pull₹20 – ₹80
Bureau (4 CICs)₹100 – ₹500
MCA fetch₹5 – ₹20
eSign + eStamp₹30 – ₹150
Mandate activation₹15 – ₹50
Payout fee₹2 – ₹10
Total per disbursed loan₹300 – ₹1,500 (vendor cost)
  • Every operation idempotency-keyed.
  • Every operation audited.
  • Every operation rate-limited per vendor.
  • Every operation has clear failure path.
  • Every operation has SLA tracked.