Table of Contents

Sending Documents to SPV

About

The e-Invoice module enables processing and synchronization of documents with the ANAF RO e-Invoice system, both for submitted sales documents and purchase documents issued on behalf of the supplier.

ANAF Synchronization Queue

ANAF Synchronization Queue Page

The main interface for managing documents being processed.

Available Actions:

  • Initialize ANAF Sync - loads eligible documents into the queue (status: None).
  • Process Queue - processes documents, advancing them through synchronization stages.
  • Process Errors - reprocesses documents with errors.
  • Delete - removes documents with None and Error status from the queue.

Document Types

The following document type codes can be submitted from Business Central:

Document Type Description
380 Sales Invoice
381 Credit Note
384 Corrected Invoice
389 Self-Invoice
751 Fiscal Receipt

The extension supports two types of self-invoicing:

Document Type Description
1. Invoice issued by beneficiary on behalf of supplier Purchase documents marked to be sent to SPV. Used in cases provided by fiscal legislation.
2. For VAT collection purposes Specific document for situations where the beneficiary collects VAT, according to ANAF requirements.

Processing States

Documents go through the following stages:

Status Description
None Document loaded, not processed
XML Created XML file has been generated
XML Sent to ANAF Document has been submitted to ANAF
ANAF Status Received ANAF response has been retrieved
Archived Document has been archived

Information Received from ANAF

  • ANAF Index - upload identifier received upon submission.
  • ANAF Download Index - identifier for downloading confirmations.
  • ANAF Status - document status in the e-Invoice system (OK/nOK).

ANAF Synchronization Archive

The ANAF Synchronization Archive Queue page stores processed and archived documents for later reference and audit.

Available Actions

  • Check - verifies consistency between Business Central values and XML.
  • Reset nOK - resets documents with nOK status to None for revalidation.
  • Force OK - forcefully marks documents as OK.
  • Download eInvoice - downloads the XML file.
  • Download PDF - downloads the PDF visualization.
  • Download Confirmations - downloads the package with XML and ANAF confirmations.
  • Navigate - opens the posted document in Business Central.

Synchronization Modes

Manual Synchronization

The user initiates and processes documents manually from the ANAF Synchronization Queue page, pressing Process Queue repeatedly until archiving.

Automatic Synchronization (with Job Queue)

Automatic processing through configuration of two jobs:

  1. Initialization Job - retrieves eligible documents into the queue.

    • Codeunit: 45010147
    • Parameter: InitializeLines
    • Recommendation: once daily
  2. Processing Job - advances documents through synchronization stages.

    • Codeunit: 45010147
    • Parameter: ProcessQueue
    • Recommendation: 4 times daily (or more frequently for high volumes)

Terms

  • RO e-Invoice: the national electronic invoice system.
  • SPV: Virtual Private Space (access/operation channel and web services).
  • ANAF: National Agency for Fiscal Administration.

See Also