Business DocumentationLease Agreement Generation

Lease Agreement Generation & Signing

Overview

The lease agreement process is the core workflow in LandlordX where landlords create rental agreements for their property units, share them with tenants, and complete Aadhaar-based eSigning. This is also the point where tenant onboarding typically occurs.

LandlordX uses Aadhaar-based eSign for legally binding digital signatures, ensuring identity verification and creating tamper-proof, legally valid documents recognized under the Information Technology Act, 2000.

Agreement Lifecycle

Agreement Creation Flow

Complete User Journey

Step 1: Select Property Unit

Landlord selects from their available property units.

Step 2: Enter Tenant Details

interface TenantDetails {
  first_name: string; // Tenant's first name
  last_name: string; // Tenant's last name
  phone: string; // Mobile number (for OTP & WhatsApp)
  email?: string; // Optional email
}

Note: Full tenant onboarding (KYC) happens during the signing phase, not here.

Step 3: Define Agreement Terms

CategoryFields
Financial TermsRent Amount, Security Deposit, Rent Due Day, Late Fee
DurationStart Date, Tenure in Months, Notice Period Days, Auto Renew Option
Terms & ConditionsPets Allowed, Non-Veg Allowed, Smoking Allowed, Bachelor Allowed, Additional Policies
Included AmenitiesParking, Water, Security, Electricity, Maintenance

Step 4: Generate Preview

The system generates a professional PDF document containing:

  • Header: Agreement title with LandlordX branding
  • Parties Section: Landlord and tenant details
  • Property Details: Full address and unit information
  • Financial Terms: Rent, deposit, due dates
  • Terms & Conditions: All agreed conditions
  • Signature Blocks: Spaces for landlord and tenant signatures
  • Footer: Generated date and LandlordX branding

Step 5: Save & Share

Agreement Data Model

interface Agreement {
  agreement_id: string; // UUID
  agreement_number?: string; // Human-readable ID (e.g., "AGR-2024-0001")
  document_url: string; // URL to generated PDF
  property_unit_id: number; // Linked property unit
 
  // Duration
  agreement_start_date: Date;
  tenure_in_months: number; // End date derived from this
  auto_renew: boolean; // Auto-renewal flag
  notice_period_days: number; // Default: 30
 
  // Financial
  rent_amount: number; // Monthly rent (must be > 0)
  deposit_amount?: number; // Security deposit (>= 0)
  rent_due_day: number; // 1-31
  late_fee?: number; // Penalty for late payment
  payment_terms?: string; // Additional payment terms
 
  // Status
  status: AgreementStatus; // draft | pending | active | completed | terminated
  signed_date?: Date; // When fully signed
  termination_date?: Date; // If terminated early
 
  // Conditions
  pets_allowed: boolean;
  non_veg_allowed: boolean;
  smoking_allowed: boolean;
  bachelor_allowed: boolean;
  amenities?: string[]; // Included amenities
  additional_policies?: string; // Custom terms
  improvements?: string; // Allowed improvements
}

Status Transitions

Current StatusActionNew StatusWho Can Act
-Create agreementdraftLandlord
draftEdit agreementdraftLandlord
draftPublish agreementpendingLandlord
pendingAll parties signactiveSystem
pendingRevoke before signingdraftLandlord
activeTenure completescompletedSystem
activeEarly terminationterminatedLandlord/Tenant

Tenant Onboarding During Signing

This is the critical junction where tenant onboarding occurs.

Tenant Onboarding Scenarios

ScenarioFlow
New tenantInvite → OTP → Profile → eKYC → eSign
Existing, no KYCInvite → OTP → eKYC → eSign
Fully verifiedInvite → OTP → eSign directly

eSign Architecture

Complete Signing Flow

eSign Session

FieldDescription
document_idAgreement ID
signer_nameFull name from profile
signer_phoneMobile number
document_urlPDF to be signed
callback_urlWebhook for completion
redirect_urlURL to redirect user
expirySession expiry time

Digital Signature Generation

RegulationCompliance
IT Act 2000Section 5 - Electronic signatures recognized
IT Amendment Act 2008Section 3A - Aadhaar eSign validity
Controller of Certifying AuthoritiesLicensed eSign provider
UIDAI GuidelinesOTP-based Aadhaar authentication

Post-Signing Actions

Tenancy Record

When an agreement becomes active, a Tenancy record is created linking the tenant to the agreement:

interface Tenancy {
  tenancy_id: string; // UUID
  tenant_id: number; // User ID of tenant
  agreement_id: number; // Linked agreement
}

This allows:

  • Multiple tenants per agreement (co-tenants)
  • Tenant history tracking
  • Easy lookup of tenant’s current and past agreements

Error Handling

ErrorCauseResolution
Invalid AadhaarWrong format or non-existentRe-enter correct number
OTP expiredExceeded 10-minute validityRequest new OTP
OTP mismatchWrong OTP enteredRetry (max 3 attempts)
Session timeoutSigning not completed in timeRestart signing process
Mobile not linkedAadhaar mobile differentContact UIDAI to update
Document modifiedHash mismatch detectedRe-generate agreement

Notifications Triggered

EventRecipientsChannels
Draft savedLandlordIn-app
Agreement publishedLandlord, TenantWhatsApp, Email
Signature reminderPending signerWhatsApp
Agreement activatedLandlord, TenantWhatsApp, Email, In-app
Agreement expiring (30 days)Landlord, TenantWhatsApp