Skip to content

[P2] F.1683 — Declaración mensual 1ra categoría (alquileres / arrendamiento) #30

@moshe-exe

Description

@moshe-exe

Context

F.1683 ("Arrendamiento - Persona Natural") is the monthly 5%-IR declaration that any natural person renting out property to a tercero must file via SUNAT SOL. It's high-frequency (monthly, per-property, per-arrendatario) and currently forces SOL-clave + browser steps every period:

  1. SOL login → Mis declaraciones y pagos → F.1683
  2. Form: RUC/DNI arrendatario, tipo bien, ubicación, monto en moneda original
  3. If USD: lookup TC SBS for fecha-pago → SUNAT applies it server-side
  4. "Agregar a bandeja" → "Pagar" → bank popup (BCP/BBVA/Interbank/etc.)
  5. Constancia PDF (número operación + fecha)

Today this is fully manual or driven via UI automation (Chrome DevTools MCP). sunat-cli already covers RHE/F616 via agent-browser; F.1683 is the natural next surface for the same pattern.

Use case driving this request: MONKEY IN HEAVEN E.I.R.L. owner files F.1683 monthly for personal rental income; would adopt sunat-cli end-to-end if this lands.

Scope

  1. src/dj-mensual/f1683/ — new module

    • Schema for declare input: { ruc_arrendador, periodo, predio: {...}, arrendatario: {tipoDoc, nroDoc, nombre}, monto: {valor, moneda}, fecha_pago }
    • Auto-resolve TC SBS when moneda=USD (reuse existing tipo-cambio)
    • Compute base imponible + IR 5% (server-side validation, but preview locally for T0)
  2. f1683 declare command (agent-browser driver)

    • T0: print computed base, IR, TC used, número de orden simulado
    • T2 (--yes): submit "Agregar a bandeja"
    • T3 (--pay): trigger bank popup — gated by intent token like cpe void
  3. f1683 list — query bandeja + constancias por periodo (read-only)

  4. f1683 constancia — download PDF by número de orden

Success criteria

  • T0 preview matches SOL's calculated IR for both PEN and USD cases
  • T2 verified end-to-end against SUNAT beta (bandeja populated)
  • TC USD case uses SBS rate from fecha_pago (not fecha_emision)
  • Idempotency: re-running same (ruc, periodo, predio, arrendatario) detects existing bandeja entry instead of duplicating
  • LIMITATIONS.md: new "Declaraciones juradas mensuales" section

Open questions

  • Is there a non-UI endpoint? F.1683 has no public API as of 2026-05; agent-browser is likely required. Confirm before scoping.
  • Multi-predio: one declare call per (predio, arrendatario) pair, or batch?
  • Should this live under a new area:dj-mensual label (would also house future F.1665 4ta-cat retención, F.621 IGV-Renta, etc.)?

References

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions