Skip to main content
Key: pl-favat-v3

Correction Definitions

Auto-generation of corrective invoices or credit and debit notes is supported.

Invoice Types

The types of invoices that can be created with a preceding definition:
  • credit-note

Stamp Keys

Stamp keys from the previous invoice that need to be referenced:
  • favat-ksef-number

Extensions

Tax categories for KSeF

The pl-favat-tax-category extension specifies tax categories for Polish FA_VAT/KSeF invoices. Each category corresponds to a field in the FA_VAT XML schema (P_13_, P_14_, etc.). This extension is used at the line tax level (lines[].taxes[]) and is automatically normalized by GOBL based on the tax combo key and rate fields. The extension is required for all line items. Automatic mapping from GOBL tax combos:
GOBL Tax KeyGOBL RateFA_VAT CategoryVAT %
standardgeneral123%
standardreduced28%
standardsuper-reduced35%
zero-6.10%
intra-community-6.20%
export-6.30%
exempt-7-
outside-scope-8-
reverse-charge-9-
Example:
{
	"$schema": "https://gobl.org/draft-0/bill/invoice",
	// ...
	"lines": [
		{
			// ...
			"taxes": [
				{
					"cat": "VAT",
					"key": "standard",
					"rate": "general",
					"percent": "23.0%",
					// Extension automatically set to "1"
					"ext": {
						"pl-favat-tax-category": "1"
					}
				}
			]
		}
	]
}
The ones that are not automatically mapped can be set manually.
CodeName
1Base rate
2First reduced rate
3Second reduced rate
4Taxi Rate
5OSS (one stop shop)
6.10% VAT
6.20% VAT for intra-community supply of goods
6.30% VAT for export
7Exempt
8Foreign sales outside scope of Polish VAT
9EU Reverse Charge
10Domestic Reverse charge
11Margin scheme

Invoice type code for KSeF

The pl-favat-invoice-type extension specifies the type of invoice for Polish FA_VAT/KSeF. This extension is used in the invoice tax section (tax.ext) and is automatically normalized by GOBL based on the invoice type and tags during the scenarios normalization step. Automatic mapping from GOBL invoice structure:
TagsGOBL invoice typeCodeDescription
-standardVATRegular invoice
partialstandardZALAdvance invoice
settlementstandardROZSettlement invoice
simplifiedstandardUPRSimplified invoice
-credit-noteKORCredit note
partialcredit-noteKOR_ZALAdvance credit note
settlementcredit-noteKOR_ROZSettlement credit note
Example of an advance invoice:
{
	"$schema": "https://gobl.org/draft-0/bill/invoice",
	"$addons": ["pl-favat-v3"],
	"$tags": ["partial"],
	"type": "standard",
	// ...
	"tax": {
		// Extension automatically set to "ZAL"
		"ext": {
			"pl-favat-invoice-type": "ZAL"
		}
	}
}
CodeName
VATRegular Invoice
ZALAdvance Invoice
ROZSettlement Invoice
UPRSimplified Invoice
KORCredit note
KOR_ZALadvance credit note
KOR_ROZSettlement credit note

Cash accounting flag for KSeF

The pl-favat-cash-accounting extension indicates whether an invoice uses cash accounting for VAT purposes (kasowa metoda rozliczenia VAT). This extension is used in the invoice tax section (tax.ext). This extension is not normalized automatically and must be set manually by the user when the cash accounting method applies. According to Polish VAT law (Article 19a sec. 5 item 1 or Article 21 sec. 1), certain small businesses may account for VAT on a cash basis rather than accrual basis. Values:
  • “1”: Cash accounting applies
  • “2”: Normal accounting (accrual basis) - default
Example with cash accounting:
{
	"$schema": "https://gobl.org/draft-0/bill/invoice",
	"$addons": ["pl-favat-v3"],
	// ...
	"tax": {
		"ext": {
			"pl-favat-cash-accounting": "1"
		}
	}
}
CodeName
1Cash accounting
2No cash accounting

Self-invoicing flag for KSeF

The pl-favat-self-billing extension indicates whether an invoice is self-billed (samofakturowanie), where the buyer issues the invoice on behalf of the supplier. This extension is used in the invoice tax section (tax.ext). This extension is automatically normalized by GOBL:
  • When the invoice has the self-billed tag, the value is set to “1”
  • Otherwise, the value defaults to “2”
Self-billing is permitted under Article 106d sec. 1 of the Polish VAT Act when there is a prior agreement between the parties. Values:
  • “1”: Self-billed invoice
  • “2”: Regular invoice - default
Example of a self-billed invoice:
{
	"$schema": "https://gobl.org/draft-0/bill/invoice",
	"$addons": ["pl-favat-v3"],
	"$tags": ["self-billed"],
	// ...
	"tax": {
		// Extension automatically set to "1"
		"ext": {
			"pl-favat-self-billing": "1"
		}
	}
}
CodeName
1Self-invoicing
2Not self-invoicing

Reverse charge code for KSeF

The pl-favat-reverse-charge extension indicates whether the reverse charge mechanism applies to an invoice. This extension is used in the invoice tax section (tax.ext). This extension is automatically normalized by GOBL:
  • When the invoice has the reverse-charge tag, the value is set to “1”
  • Otherwise, the value defaults to “2”
Under the reverse charge mechanism (odwrotne obciążenie), the buyer rather than the seller is responsible for accounting for the VAT. This applies to:
  • EU intra-community services (B2B cross-border services)
  • Domestic reverse charge for specific goods and services listed in Polish VAT law
  • Imports of services from outside the EU
When using reverse charge, the line items should use the reverse-charge tax key, which automatically sets the tax category to “9” (EU Reverse Charge) or “10” (Domestic Reverse Charge) depending on the scenario. Values:
  • “1”: Reverse charge applies
  • “2”: Normal charge - default
Example of an EU reverse charge invoice:
{
	"$schema": "https://gobl.org/draft-0/bill/invoice",
	"$addons": ["pl-favat-v3"],
	"$tags": ["reverse-charge"],
	// ...
	"lines": [
		{
			// ...
			"taxes": [
				{
					"cat": "VAT",
					"key": "reverse-charge"
				}
			]
		}
	],
	"tax": {
		// Extension automatically set to "1"
		"ext": {
			"pl-favat-reverse-charge": "1"
		}
	}
}
CodeName
1Reverse charge
2No reverse charge

Split payment mechanism flag for KSeF

The pl-favat-split-payment-mechanism extension indicates whether the mandatory split payment mechanism (mechanizm podzielonej płatności, MPP) applies to an invoice. This extension is used in the invoice tax section (tax.ext). This extension is not normalized automatically and must be set manually when the split payment mechanism applies. According to Polish VAT law, split payment is mandatory when ALL of the following conditions are met:
  • The invoice amount exceeds PLN 15,000 (or equivalent in foreign currency)
  • The invoice covers goods or services listed in Annex 15 to the VAT Act
  • The transaction is B2B (business to business)
  • The invoice bears the note “split payment mechanism”
Under split payment, the buyer pays the VAT portion to a separate VAT account rather than to the seller directly. Values:
  • “1”: Split payment mechanism applies
  • “2”: Normal payment - default
Example:
{
	"$schema": "https://gobl.org/draft-0/bill/invoice",
	"$addons": ["pl-favat-v3"],
	// ...
	"tax": {
		"ext": {
			"pl-favat-split-payment-mechanism": "1"
		}
	},
	"notes": [
		{
			"key": "general",
			"text": "Mechanizm podzielonej płatności"
		}
	]
}
CodeName
1Split payment mechanism
2No split payment mechanism

Tax exemption code for KSeF

Extension used to indicate the type of reason for tax exemption code for KSeF. When the exempt tag is used in the invoice, having ext map’s pl-favat-exemption property is required. Also, it is required to add descriptive text for the legal basis for exemption. To do this in GOBL, add a note to the invoice with the exemption reason, in the following format:
{
	"$schema": "https://gobl.org/draft-0/bill/invoice",
	// ...

	"tax": {
		"ext": {
			"pl-favat-exemption": "A"
			// ...
		}
	},
	"notes": [
		{
			"key": "legal",
			"code": "A",
			"src": "pl-favat-exemption",
			"text": "Art. 25a ust. 1 pkt 9 ustawy o VAT"
		}
	]
}
In notes, code must match the code from the extension.
CodeName
ALaw or act issued under the Polish law
BDirective 2006/112/EC
COther legal basis

Margin scheme code for KSeF

The pl-favat-margin-scheme extension specifies the type of margin scheme (procedura marży) applied to an invoice. This extension is used in the invoice tax section (tax.ext). This extension is not normalized automatically and must be set manually when a margin scheme applies. Under margin schemes, VAT is calculated only on the seller’s margin (profit) rather than on the full sale price. This applies to specific business sectors in Poland:
  • Travel agencies (tour operators)
  • Sales of second-hand goods
  • Sales of works of art
  • Sales of collector’s items and antiques
When using a margin scheme, the tax category should typically be set to “11” (Margin scheme) in line items. Example for a travel agency:
{
	"$schema": "https://gobl.org/draft-0/bill/invoice",
	"$addons": ["pl-favat-v3"],
	// ...
	"tax": {
		"ext": {
			"pl-favat-margin-scheme": "2"
		}
	}
}
CodeName
2Travel agency
3.1Second-hand goods
3.2Works of art
3.3Antiques and collectibles

Payment method code for KSeF

The pl-favat-payment-means extension specifies the payment method used in an invoice. This extension is used in payment instructions (payment.instructions.ext) or payment advances (payment.advances[].ext). This extension is automatically normalized by GOBL based on the payment means key. The following table shows the mapping:
CodeFA_VAT NameGOBL Payment Means Key
1Cashcash
2Cardcard
3Voucherother+voucher
4Chequecheque
5Credit/Loanother+credit
6Credit Transfercredit-transfer
7Mobileonline
Example with bank transfer payment:
{
	"$schema": "https://gobl.org/draft-0/bill/invoice",
	"$addons": ["pl-favat-v3"],
	// ...
	"payment": {
		"instructions": {
			"key": "credit-transfer",
			// Extension automatically set to "6"
			"ext": {
				"pl-favat-payment-means": "6"
			},
			"credit_transfer": [
				{
					"iban": "PL61109010140000071219812874",
					"name": "Company Name"
				}
			]
		}
	}
}
CodeName
1Cash
2Card
3Coupon
4Cheque
5Loan
6Wire Transfer
7Mobile

Subordinate Local Government Unit flag

The pl-favat-jst extension indicates whether the customer is a Subordinate Local Government Unit (Jednostka Samorządu Terytorialnego - JST). This extension is used in the customer party section (customer.ext). This extension is not normalized automatically and must be set manually. When this extension is set to “1” (customer is JST), GOBL validates that the customer has an identity with role “8” (Local Government Unit - recipient) in the customer.identities array. This identity must include a code field with the JST identifier. Values:
  • “1”: Customer is a Subordinate Local Government Unit
  • “2”: Customer is not a JST - default
Example:
{
	"$schema": "https://gobl.org/draft-0/bill/invoice",
	"$addons": ["pl-favat-v3"],
	// ...
	"customer": {
		"name": "Gmina Warszawa",
		"tax_id": {
			"country": "PL",
			"code": "5252548806"
		},
		"ext": {
			"pl-favat-jst": "1"
		},
		"identities": [
			{
				"code": "146501",
				"ext": {
					"pl-favat-third-party-role": "8"
				}
			}
		]
	}
}
CodeName
1Customer is a Subordinate Local Government Unit
2Customer is not a Subordinate Local Government Unit

Group VAT member flag

The pl-favat-group-vat extension indicates whether the customer is a member of a VAT group (Grupa VAT - GV). This extension is used in the customer party section (customer.ext). This extension is not normalized automatically and must be set manually. VAT groups in Poland allow multiple legal entities to be treated as a single taxpayer for VAT purposes. When this extension is set to “1” (customer is a GV member), GOBL validates that the customer has an identity with role “10” (GV member - recipient) in the customer.identities array. This identity must include a code field with the VAT group member identifier. Values:
  • “1”: Customer is a VAT Group member
  • “2”: Customer is not a VAT Group member - default
Example:
{
	"$schema": "https://gobl.org/draft-0/bill/invoice",
	"$addons": ["pl-favat-v3"],
	// ...
	"customer": {
		"name": "Member Company Ltd.",
		"tax_id": {
			"country": "PL",
			"code": "1234567890"
		},
		"ext": {
			"pl-favat-group-vat": "1"
		},
		"identities": [
			{
				"code": "GV-12345",
				"ext": {
					"pl-favat-third-party-role": "10"
				}
			}
		]
	}
}
CodeName
1Customer is a Group VAT member
2Customer is not a Group VAT member

Third party role

The pl-favat-third-party-role extension specifies the role of a third party or additional entity in an invoice transaction. This extension is used in party identities (customer.identities[].ext, supplier.identities[].ext, or in additional parties). This extension is not normalized automatically and must be set manually based on the role of the entity in the transaction. Common use cases:
  • Role “8”: Required when customer has pl-favat-jst = “1” (Local Government Unit)
  • Role “10”: Required when customer has pl-favat-group-vat = “1” (VAT Group member)
  • Role “5”: When invoice is issued by an entity on behalf of the taxpayer
  • Other roles: For factoring, recipients, payers, etc.
Each identity with this extension should also include a code field with the identifier of the third party. Example with JST customer:
{
	"customer": {
		// ...
		"ext": {
			"pl-favat-jst": "1"
		},
		"identities": [
			{
				"code": "146501",
				"ext": {
					"pl-favat-third-party-role": "8"
				}
			}
		]
	}
}
CodeName
1Factor
2Recipient
3Original entity
4Additional Purchaser
5Invoice Issuer
6Payer
7Local Government Unit (LGU) - issuer
8Local Government Unit (LGU) - recipient
9GV member - issuer
10GV member - recipient
11Employee

Effective date code

The pl-favat-effective-date extension specifies when a correction invoice (credit note) becomes effective for VAT purposes. This extension is used in credit note tax section (tax.ext) when type is credit-note. This extension is not normalized automatically and it is not mandatory. It can be set manually for credit notes based on when the correction should take effect. According to Polish VAT regulations, a correction invoice can be effective:
  • On the date of the original invoice (code “1”)
  • On the date of the correction invoice itself (code “2”)
  • On another specific date, or different dates for different line items (code “3”)
Values:
  • “1”: Effective according to original invoice date
  • “2”: Effective according to correction date
  • “3”: Effective on another date (or multiple dates)
Example of a credit note effective on correction date:
{
	"$schema": "https://gobl.org/draft-0/bill/invoice",
	"$addons": ["pl-favat-v3"],
	"type": "credit-note",
	// ...
	"tax": {
		"ext": {
			"pl-favat-invoice-type": "KOR",
			"pl-favat-effective-date": "2"
		}
	},
	"preceding": [
		{
			"code": "INVOICE-001",
			"issue_date": "2025-01-15"
		}
	]
}
CodeName
1Original
2Correction
3Other