PHPackages                             kenod/isdoc-exporter - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Payment Processing](/categories/payments)
4. /
5. kenod/isdoc-exporter

ActiveLibrary[Payment Processing](/categories/payments)

kenod/isdoc-exporter
====================

PHP library for generating ISDOC/ISDOCX invoices according to the Czech ISDOC standard version 6.0.2

1.0.2(3mo ago)00MITPHPPHP ^8.3 || ^8.4 || ^8.5

Since Mar 31Pushed 3mo agoCompare

[ Source](https://github.com/kenod/ISDOCExporter)[ Packagist](https://packagist.org/packages/kenod/isdoc-exporter)[ RSS](/packages/kenod-isdoc-exporter/feed)WikiDiscussions main Synced 4w ago

READMEChangelogDependencies (4)Versions (2)Used By (0)

ISDOC Exporter
==============

[](#isdoc-exporter)

[![Packagist](https://camo.githubusercontent.com/fcb22c43e3aeb95dfa60de12c8002625eb26ac54949189f1b9894386a087ecab/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f6b656e6f642f6973646f632d6578706f72746572)](https://packagist.org/packages/kenod/isdoc-exporter)

PHP library for generating electronic invoices in the [ISDOC](https://isdoc.cz/) format (version 6.0.2) -- the Czech national standard for electronic invoicing.

**[Interactive Demo](https://fakturasnadno.cz/)** | [Packagist](https://packagist.org/packages/kenod/isdoc-exporter) | [Dokumentace v cestine](README.cs.md)

Features
--------

[](#features)

- ISDOC 6.0.2 compliant XML output
- All document types: invoice, credit note, debit note, proforma, advance invoice, simplified invoice
- VAT payer and non-VAT payer invoices
- Reverse charge support
- Multiple VAT rates
- Foreign currency support
- Czech bank database (names, BIC/SWIFT, IBAN generation)
- Automatic address parsing (street + building number)
- Country name to ISO code resolution
- Fluent API with method chaining
- Total rounding
- Save to file or download as HTTP response

Requirements
------------

[](#requirements)

- PHP 8.3+
- Extensions: `dom`, `bcmath`

Installation
------------

[](#installation)

```
composer require kenod/isdoc-exporter
```

Quick Start
-----------

[](#quick-start)

```
use Kenod\IsdocExporter\Invoice;

$invoice = new Invoice();
$invoice
    ->setNumber('2024001')
    ->setIssueDate('2024-01-15')
    ->setDueDate('2024-02-15');

$invoice->supplier
    ->setName('Supplier s.r.o.')
    ->setStreet('Main Street 10')
    ->setCity('Prague')
    ->setZip('110 00')
    ->setCompanyId('12345678');

$invoice->customer
    ->setName('Customer a.s.')
    ->setStreet('Side Street 20')
    ->setCity('Brno')
    ->setZip('602 00')
    ->setCompanyId('87654321');

$invoice->payment
    ->setAccountNumber('123456789')
    ->setBankCode('0100')
    ->setVariableSymbol('2024001');

$invoice
    ->addItem('Website development', 1.0, 'pcs', 15000.0, 15000.0, 0.0)
    ->addItem('Hosting for 1 year', 12.0, 'months', 200.0, 200.0, 0.0);

// Save to file
$invoice->export()->save('invoice.isdoc');

// Or get XML as string
$xml = $invoice->export()->toString();

// Or send as HTTP download
$invoice->export()->download('invoice.isdoc');
```

VAT Payer Invoice
-----------------

[](#vat-payer-invoice)

```
$invoice = new Invoice();
$invoice
    ->setNumber('FV-2024-042')
    ->setIssueDate('2024-03-01')
    ->setDueDate('2024-03-15')
    ->setVatPayer(true)
    ->setDeliveryDate('2024-02-29')
    ->setRoundTotal(true);

// Supplier and customer setup...

// Items with VAT (unitPrice without VAT, unitPriceWithVat with VAT, vatRate)
$invoice
    ->addItem('Development', 80.0, 'hrs', 1500.0, 1815.0, 21.0)
    ->addItem('Printed manual', 50.0, 'pcs', 350.0, 392.0, 12.0);

$invoice->export()->save('vat_invoice.isdoc');
```

Credit Note
-----------

[](#credit-note)

```
use Kenod\IsdocExporter\DocumentType;
use Kenod\IsdocExporter\Invoice;

$invoice = new Invoice();
$invoice
    ->setDocumentType(DocumentType::CreditNote)
    ->setNumber('DN-2024-001')
    ->setIssueDate('2024-04-01')
    ->setDueDate('2024-04-15')
    ->setVatPayer(true)
    ->setDeliveryDate('2024-04-01')
    ->setOriginalDocumentNumber('FV-2024-042')
    ->setOriginalDocumentDate('2024-03-01');

// ...
```

Reverse Charge
--------------

[](#reverse-charge)

```
$invoice = new Invoice();
$invoice
    ->setNumber('FV-2024-RC-001')
    ->setIssueDate('2024-06-30')
    ->setDueDate('2024-07-30')
    ->setVatPayer(true)
    ->setDeliveryDate('2024-06-30')
    ->setReverseCharge(true)
    ->setReverseChargeType('4'); // 4 = construction services

// ...
```

Foreign Currency
----------------

[](#foreign-currency)

```
$invoice = new Invoice();
$invoice
    ->setCurrencyCode('CZK')
    ->setForeignCurrencyCode('EUR')
    ->setCurrencyRate(25.35)
    ->setRefCurrencyRate(1.0);

// ...
```

Document Types
--------------

[](#document-types)

TypeEnum ValueDescription1`DocumentType::Invoice`Standard invoice (default)2`DocumentType::CreditNote`Credit note3`DocumentType::DebitNote`Debit note4`DocumentType::ProformaInvoice`Proforma invoice5`DocumentType::AdvanceInvoice`Advance invoice6`DocumentType::AdvanceCreditNote`Advance credit note7`DocumentType::SimplifiedInvoice`Simplified invoiceAPI Reference
-------------

[](#api-reference)

### Invoice

[](#invoice)

MethodDescription`setNumber(string)`Invoice number`setIssueDate(string)`Issue date (YYYY-MM-DD)`setDueDate(string)`Due date (YYYY-MM-DD)`setDeliveryDate(string)`Delivery / tax point date`setDocumentType(DocumentType)`Document type (default: Invoice)`setVatPayer(bool)`Whether the supplier is a VAT payer`setReverseCharge(bool)`Enable reverse charge`setReverseChargeType(string)`Reverse charge code (1=gold, 2=emission, 4=construction, 5=waste)`setFooterText(string)`Note / footer text`setOrderNumber(string)`Order reference number`setOriginalDocumentNumber(string)`Original document reference (for credit/debit notes)`setOriginalDocumentDate(string)`Original document issue date (YYYY-MM-DD)`setRoundTotal(bool)`Round the total to integer`setIssuingSystem(string)`Name of the issuing system`setCurrencyCode(string)`Local currency code (default: CZK)`setForeignCurrencyCode(string)`Foreign currency code`setCurrencyRate(float)`Exchange rate`setRefCurrencyRate(float)`Reference exchange rate`addItem(name, qty, unit, price, priceWithVat, vatRate, note?)`Add an invoice line item`export()`Returns `IsdocExporter` instance### Invoice Properties

[](#invoice-properties)

PropertyTypeDescription`$invoice->supplier``Party`Supplier party (fluent setters)`$invoice->customer``Party`Customer party (fluent setters)`$invoice->payment``PaymentInfo`Payment details (fluent setters)### Party

[](#party)

MethodDescription`setName(string)`Company or person name`setStreet(string)`Street with building number`setCity(string)`City`setZip(string)`Postal code`setCountry(string)`Country name (auto-resolved to ISO code)`setCompanyId(string)`Company registration number`setVatId(string)`VAT identification number`setRegisterInfo(string)`Commercial register info`setEmail(string)`Email address`setPhone(string)`Phone number`setWeb(string)`Website URL### PaymentInfo

[](#paymentinfo)

MethodDescription`setAccountNumber(string)`Bank account number (e.g. `19-2000145399`)`setBankCode(string)`Bank code (e.g. `0800`)`setVariableSymbol(string)`Variable symbol`setConstantSymbol(string)`Constant symbol`setSpecificSymbol(string)`Specific symbol### IsdocExporter

[](#isdocexporter)

MethodDescription`toString()`Returns the ISDOC XML as a string`save(string $filepath)`Saves the XML to a file`download(?string $filename)`Sends the XML as an HTTP downloadDevelopment
-----------

[](#development)

```
composer install
composer check    # runs phpcs + phpstan + phpunit
composer phpcs    # code style check
composer phpcbf   # auto-fix code style
composer phpstan  # static analysis (level 8)
composer test     # unit tests
```

License
-------

[](#license)

MIT

###  Health Score

37

—

LowBetter than 81% of packages

Maintenance82

Actively maintained with recent releases

Popularity0

Limited adoption so far

Community6

Small or concentrated contributor base

Maturity51

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Unknown

Total

1

Last Release

91d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/66b2b73d66cdce75b5fc18cf8d2e7fb4e144b834d0967b51fe18b391c15d94c9?d=identicon)[kenod](/maintainers/kenod)

---

Top Contributors

[![kenod](https://avatars.githubusercontent.com/u/88635?v=4)](https://github.com/kenod "kenod (3 commits)")

---

Tags

xmlinvoiceAccountingE-Invoiceczechfakturaisdocisdocx

###  Code Quality

TestsPHPUnit

Static AnalysisPHPStan

Code StylePHP\_CodeSniffer

Type Coverage Yes

### Embed Badge

![Health badge](/badges/kenod-isdoc-exporter/health.svg)

```
[![Health](https://phpackages.com/badges/kenod-isdoc-exporter/health.svg)](https://phpackages.com/packages/kenod-isdoc-exporter)
```

###  Alternatives

[num-num/ubl-invoice

A modern object-oriented PHP library to create and read valid UBL and EN 16931/Peppol BIS 3.0 files

136887.1k](/packages/num-num-ubl-invoice)[atgp/factur-x

PHP library to manage your Factur-X / ZUGFeRD 2.0 PDF invoices files

149883.7k4](/packages/atgp-factur-x)[saleh7/php-zatca-xml

An unofficial PHP library for generating ZATCA Fatoora e-invoices. This library facilitates the creation of compliant e-invoices, QR Codes, and certificates, as well as the submission of e-invoices to ZATCA's servers. It provides developers with an easy-to-use, customizable, and robust toolkit to integrate and automate ZATCA e-invoicing processes in PHP applications.

5616.0k](/packages/saleh7-php-zatca-xml)[cleverit/ubl_invoice

A PHP wrapper for UBL invoices

36286.3k](/packages/cleverit-ubl-invoice)[sevaske/php-zatca-xml

An unofficial PHP library for generating ZATCA Fatoora e-invoices. This library facilitates the creation of compliant e-invoices, QR Codes, and certificates, as well as the submission of e-invoices to ZATCA's servers. It provides developers with an easy-to-use, customizable, and robust toolkit to integrate and automate ZATCA e-invoicing processes in PHP applications.

218.1k1](/packages/sevaske-php-zatca-xml)[akaunting/module-offline-payments

Offline Payments app for Akaunting

11244.4k](/packages/akaunting-module-offline-payments)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
