Skip to content

[P1] GRE modal 01 (transporte público) + Transportista doc 31 #11

@Railly

Description

@Railly

Context

PR #7 shipped GRE Remitente (tipoDoc=09) with modTraslado=02 (transporte privado, emisor mueve los bienes). When the customer hires a third-party carrier (modTraslado=01) or when the carrier itself emits the guía (tipoDoc=31), the schema diverges.

Scope

  1. Modal 01 (transporte público)

    • Add `cac:CarrierParty` block to `src/cpe/ubl/gre.ts`
    • Validate transportista RUC + nroMtc (registro MTC)
    • Make chofer optional (carrier provides their own)
  2. GRE Transportista (tipoDoc 31)

    • New UBL builder `src/cpe/ubl/gre-transportista.ts` (different schema entirely)
    • New emit path in REST client (same endpoint, different content)
  3. Multiple choferes — schema accepts loop, currently 1-only

Success criteria

  • Modal 01 verified against SUNAT beta
  • Transportista (31) verified against SUNAT beta
  • Unit tests for each new schema variant
  • LIMITATIONS.md: 4 sub-bullets in GRE section move from 🚧 to 🔬 or ⚠️

References

  • LIMITATIONS.md → "Guía de Remisión Electrónica (GRE)" sub-limitations
  • Greenter despatch2022.xml.twig has the full modal 01 + carrier blocks

Metadata

Metadata

Assignees

No one assigned

    Labels

    area:restREST OAuth APIs (consulta, padron, GRE)enhancementNew feature or requestpriority:p1High value, next quarter

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions