Where the obligation comes from
The ATCUD comes from article 35 of Decree-Law 28/2019 of 15 February: the AT assigns a code to every registered series, which must then be part of the unique document code. Portaria 195/2020 of 13 August sets out how (articles 3 and 4): the validation code has at least 8 characters, is joined to the sequential number with a "-" and is printed as "ATCUD:code-number". After 2021, when it was voluntary (Law 75-B/2020, article 404), and 2022, when Despacho 351/2021-XXII made it optional, the ATCUD has been mandatory on every invoice and tax-relevant document since 1 January 2023, the date Law 12/2022 (article 316) uses as its reference.
How the validation code is obtained
- Define the series before using it: the identifier (for example 2026A), the document type, the first number and the planned start date.
- Register it with the AT, on the Portal das Finanças or by webservice, before issuing the first document.
- The AT returns the series validation code, 8 or more characters long.
- Every document in that series carries the ATCUD: validation code, hyphen and sequential number.
The QR code, mandatory since 1 January 2022 on invoices and documents issued by certified programs (article 6 of the same Portaria; optional in 2021 under Law 75-B/2020), carries the ATCUD too, in field H.
In Odoo, without a module
Odoo 17, 18, 19 and 20 ship no ATCUD, no AT QR code and no SAF-T (PT): we searched the source code of the four versions and the term does not appear. Odoo's own numbering knows nothing about series registered with the AT.
In Odoo, with CIUS-PT & ATCUD
With the CIUS-PT & ATCUD module, each series has an "AT Validation Code" field, locked as soon as an invoice uses it. The ATCUD is built from the series code and the digits after the slash of the printed number. If the code is missing or the number does not end in "/digits", the invoice is not issued and the error says why.

You register the series with the AT on the Portal das Finanças and type the validation code the AT returns into the series in Odoo. The invoice QR code is generated in byte mode, as the AT technical specifications require.

The full price: €9 per Odoo version on Odoo Apps plus the FlexigoTech Cloud subscription, Standard at €29 a month or €290 a year, VAT excluded, with a 14-day trial and no card.
What it does not do yet
The module's AT certification is in progress. Until the AT gives its number, documents carry certificate 0, and a business that invoices under Portuguese rules with invoicing software cannot use it yet to issue its legal invoices. It invoices in a program that is already certified or in the AT's applications (what the law requires).
Does the ATCUD replace the invoice number?
No. The invoice keeps its number (FT 2026A/15); the ATCUD adds the series validation code to it.
Can I change the validation code of a series already in use?
Not in the module: the field locks when the first invoice carries it. For a new series, you register a new series.
Keep reading
Checked against the linked sources
Sources
- info.portaldasfinancas.gov.pt/pt/informacao_fiscal/legislacao/diplomas_legislativos/Docume
- files.diariodarepublica.pt/1s/2020/08/15700/0001300015.pdf
- info.portaldasfinancas.gov.pt/pt/informacao_fiscal/legislacao/diplomas_legislativos/Docume
- info.portaldasfinancas.gov.pt/pt/informacao_fiscal/legislacao/Despachos_SEAF/Documents/Des
- files.diariodarepublica.pt/gratuitos/1s/2022/06/12200.pdf
- info.portaldasfinancas.gov.pt/pt/apoio_ao_contribuinte/Negocios/Faturacao/Regras_mecanismo
- github.com/odoo/odoo/tree/20.0/addons/l10n_pt
- Module source code: CIUS-PT & ATCUD, models/eif_invoice_series.py, services/at_qr.py
- apps.odoo.com/apps/modules/20.0/flexigo_portugal_efatura_e_invoice_connector
- Module source code: CIUS-PT & ATCUD, __manifest__.py
