When a supplier sends a Costa Rican electronic invoice, the email may contain an XML, a PDF, a Hacienda response and sometimes a ZIP holding all of them. The files look related because they describe the same purchase, but they are not interchangeable. XML carries the structured electronic document. PDF provides a readable representation. Hacienda's response reports what happened during validation.
Knowing the difference changes the accounting workflow. When someone reads a PDF and retypes supplier, line and tax data, the structured XML is being ignored. When the XML is stored but the response is lost, confirming the validation state becomes harder. When every file remains in email, the purchase stays outside accounts payable and the monthly close.
XML is the structured source
Costa Rican electronic documents are generated and transmitted in XML. Depending on the document type, the file includes identifiers, issuer, receiver, date, currency, sale terms, lines, quantities, prices, discounts, codes, taxes and totals. It also includes the numeric key used to connect the document with other parts of its record. XML is the appropriate source for importing information without copying every field.
That does not mean every incoming XML should create an approved bill. The receiver ID must be checked, the purchase must be confirmed, calculations need review, and the business must determine IVA treatment. Useful automation prepares a draft from source data and presents it to a person. Risky automation treats successful reading as approval.
PDF is for reading and sharing
The PDF lays out an invoice on a page that customers and teams can read easily. It works well for visual review, sending a copy or attaching evidence to an internal process. It is a poor primary source for data capture. Text may be embedded as an image, columns vary by supplier, and extraction can confuse decimal values, lines or taxes.
Think of XML as a record with named fields and PDF as a printout designed for people. Both matter. The mistake is asking the visual file to perform the structured file's job. If only a PDF arrives, request the XML rather than turning an exception into the standard process.
Hacienda's response reports the result
Hacienda's response is another XML file. It records the validation result and should be retained with the document it addresses. It does not replace the supplier document or state the buyer's decision about the purchase. It has a separate purpose: showing whether Hacienda accepted or rejected the submitted file and providing the related validation detail.
- Document XML: contains the structured sale or purchase data.
- PDF: displays a graphical representation for human readers.
- Hacienda response: reports the validation outcome for a submitted file.
- Receiver Message: records the buyer's decision when that process applies.
- ZIP: is only a container, so its documents still need to be identified and matched to the correct key.
Organizing files without trusting their names
Filenames vary across suppliers. Some add words, some use the document key, and others send a compressed bundle. Reliable matching reads the content and uses document identifiers instead of assuming that the third attachment is always the response. A multi-company inbox also needs to separate purchases for different legal entities based on receiver data.
A useful record keeps the bill, source XML, PDF, response, Receiver Message and additional support together. It also records how the files arrived and who reviewed them. A search by supplier, date or balance then leads to the correct evidence. Storing attachments creates an archive. Connecting them to the purchase creates traceability.
What Tario does with a supplier email
Tario can receive XML, PDF and ZIP files by email, upload or integration. It reads the XML, resolves the company through the receiver ID, prepares a bill with lines and taxes, and keeps support files close to the document. The team reviews before approval and can handle IVA and the Receiver Message from an organized inbox.
The practical result is not simply a tidier folder. It is avoiding duplicate entry and reaching the close with documents that can still be explained. If the current process depends on opening PDFs, copying totals and hunting through email for responses, separating the job of each file is already a meaningful improvement.