Leases

Generate rent receipts

Generate rent receipts (quittances/reçus de loyer) for all active tenants of a lease for a given period.

Art. 21 Loi 89-462: The landlord must provide a rent receipt free of charge upon tenant request. The receipt must separate rent and charges. If the full amount has been paid, a "quittance" is issued. If only partial payment was made, a "reçu" is issued instead.

Behavior:

  • One receipt is generated per active tenant (lessee) on the lease
  • Each tenant's rent_share percentage is applied to rent and charges
  • If a receipt already exists for the same tenant/period, it is skipped (no duplicates)
  • A PDF is automatically generated for each receipt using the Typst template
  • The PDF includes: landlord info, tenant info with rent share %, property details, itemized charges, totals, and legal text

Permissions required: leases:write

post/leases/{lease_id}/receipts/generate

Request

  • Base URL: https://api.faireplace.com/api
  • URL: https://api.faireplace.com/api/leases/{lease_id}/receipts/generate
  • Auth: HTTP bearer

Path parameters

lease_idstring uuid required

Lease ID

Request body

period_startstring date required

Start date of the rental period

period_endstring date required

End date of the rental period (must be after period_start)

payment_datestring date nullable

Date of payment (optional, shown on the PDF)

Example request

{
  "period_start": "2026-03-01",
  "period_end": "2026-03-31",
  "payments": [
    {
      "amount_paid": 537.5
    }
  ],
  "payment_date": "2026-03-15"
}

Response

Receipts generated successfully. Returns one receipt per active tenant.

idstring uuid required

Unique identifier of the rent receipt

lease_idstring uuid required

ID of the associated lease

lessee_idstring uuid required

ID of the tenant this receipt is for

lessee_namestring required

Full name of the tenant

period_startstring date required

Start date of the rental period

period_endstring date required

End date of the rental period

rent_amountnumber required

Rent amount for this tenant (adjusted by rent_share)

charges_totalnumber required

Total charges amount for this tenant (adjusted by rent_share)

total_duenumber required

Total amount due (rent + charges)

amount_paidnumber required

Amount actually paid by the tenant

document_typestring required

QUITTANCE (full payment) or RECU (partial payment)

has_pdfboolean required

Whether a PDF has been generated for this receipt

Example response

[
  {
    "lessee_name": "Marie Martin",
    "period_start": "2026-03-01",
    "period_end": "2026-03-31",
    "rent_amount": 450,
    "charges_total": 87.5,
    "charges_detail": [
      {
        "category_name": "Eau froide",
        "amount": 12.5,
        "calculation_method": "Provision"
      }
    ],
    "total_due": 537.5,
    "amount_paid": 537.5,
    "document_type": "QUITTANCE",
    "has_pdf": true
  }
]

Changes

No recorded changes to this operation across all 1 revision of this API.