tax_id
property represented by a tax.Identity object.
The Tax Identity contains a single primary code defined by the local tax agency and has validation rules with check digits that ensure they are valid. Depending on the local tax system, a tax identity code is almost always required for the supplier and usually also for the customer.
GOBL contains tax identity code normalization and validation rules that help you ensure all tax IDs are stored correctly and can be easily indexed. For example, take a Spanish tax ID that you might receive via an email or note like "ES-B-986.026.42"
. GOBL will try to normalize the code so that it is presented as:
type
property. Other standards define many more, but these are the ones we think are key for most use cases:
standard
- a regular commercial invoice between a supplier and customer.proforma
- used to send a “preview” of the final invoice to a customer for their approval. If a customer approves a proforma invoice, they’re effectively entering into a contract with the supplier for the services or goods to be supplied, so while tax agencies don’t consider this an essential type for tax collection, they can have legal consequences.corrective
- indicates that this invoice performs corrections to a previous invoice identified in the preceding
property defined as a bill.Preceding.credit-note
- traditional and most frequently used type when a supplier needs to issue a refund or cancel part of a preceding invoice.debit-note
- indicates that the preceding invoice was incomplete and there are now some additional costs. Most companies will just issue a new invoice to complement the previous one as opposed to issuing a specific debit note."simplified"
:
"reverse-charge"
tax tag, and will automatically include a special note.
The Italian FatturaPA format for example defines some 22 different invoice type codes that cover multiple different scenarios, including self billing. To support these we’ve defined a set of scenarios with different tags defined in the Italian tax regime. Here’s an example for an “Advance or down payment on a freelance invoice” type:
TD03
. For more details, see the GOBL FatturaPA project.