aeat.application.live._filed_data module

Filed-declaration register listing helpers for live AEAT workflows.

This module is the read-only selector boundary between the authenticated Sede declaration register and the heavier capture pipeline. It works only with Declaracion register rows: listing reports expose which AEAT artefact links are available, and selector helpers narrow one in-memory register result by period, expediente id, and caller limit before any artefact is downloaded.

The helpers do not authenticate, open browser sessions, persist observations, or stamp filing records. Those effects belong to aeat.application.live._filed_data_capture and aeat.application.live._filed_observation_persistence after the live-read gate and registry checks have run.

class FiledDataListingRow(**data)[source]

Bases: BaseModel

One filed declaration row listed from AEAT without downloading artefacts.

Parameters:
modelo: str
year: int
period: Period
expediente_id: str
status: str
presented_at: datetime
has_submitted_file: bool
has_declaration_copy: bool
has_justificante: bool
class FiledDataListingReport(**data)[source]

Bases: BaseModel

Read-only filed-declaration listing report.

Parameters:
modelo: str
year_from: int
year_to: int
row_count: int
rows: tuple[FiledDataListingRow, ...]
class BulkFiledDataListingReport(**data)[source]

Bases: BaseModel

Read-only filed-declaration listing report across multiple modelos.

Parameters:
modelos: tuple[str, ...]
year_from: int
year_to: int
row_count: int
failed_count: int
rows: tuple[FiledDataListingRow, ...]
failures: tuple[FiledDataCaptureFailureRow, ...]
select_declarations_for_capture(declarations, *, period=None, expediente_id=None, limit=None)[source]

Select register Declaracion rows.

Selection is an in-memory filter over one already-read register result. It does not fetch AEAT artefacts or persist local evidence; the capture service performs those steps after the live-read gate.

Return type:

tuple[Declaracion, ...]

Parameters:
filed_data_listing_row(declaration)[source]

Return link-availability metadata for one AEAT declaration register item.

Return type:

FiledDataListingRow

Returns:

A FiledDataListingRow with archive, declaration-copy, and justificante link-availability flags for the declaration.

Parameters:

declaration (Declaracion)