---
title: "CodeListGenerator – API-Referenz · Quittio"
description: "Generates the code list files (resources/codelists/*.json) from the official EN 16931 Schematron rules (BR-CL-*), as shipped with the KoSIT validator configuration, and the narrower Peppol lists from the Peppol BIS Schematron."
canonical_url: "https://quittio.dev/docs/api/Quittio/Core/Codes/CodeListGenerator"
locale: de
meta:
  "og:description": "Generates the code list files (resources/codelists/*.json) from the official EN 16931 Schematron rules (BR-CL-*), as shipped with the KoSIT validator configuration, and the narrower Peppol lists from the Peppol BIS Schematron."
  "og:image": "https://quittio.dev/og/quittio-de.jpg"
  "og:image:alt": "Quittio: E-Rechnungen für PHP und Laravel. Rechtssicher, validiert, archiviert, mit geprüfter Beispielrechnung."
  "og:image:height": "630"
  "og:image:type": image/jpeg
  "og:image:width": "1200"
  "og:title": "CodeListGenerator – API-Referenz · Quittio"
  "twitter:image": "https://quittio.dev/og/quittio-de.jpg"
  "twitter:image:alt": "Quittio: E-Rechnungen für PHP und Laravel. Rechtssicher, validiert, archiviert, mit geprüfter Beispielrechnung."
---

> Index of every page on this site: [llms.txt](https://quittio.dev/llms.txt)

[API reference](https://quittio.dev/docs/api) / [Quittio](https://quittio.dev/docs/api/Quittio) \\ [Core](https://quittio.dev/docs/api/Quittio/Core) \\ [Codes](https://quittio.dev/docs/api/Quittio/Core/Codes)

# CodeListGenerator

final class in quittio/core

`Quittio\Core\Codes\CodeListGenerator` · [Source](https://github.com/Quittio/quittio/blob/v0.7.1/packages/core/src/Codes/CodeListGenerator.php#L14)

Generates the code list files (resources/codelists/\*.json) from the official EN 16931 Schematron rules (BR-CL-\*), as shipped with the KoSIT validator configuration, and the narrower Peppol lists from the Peppol BIS Schematron.

## Constants \#

| Constant | Value | Description |
| --- | --- | --- |
| `LISTS` | `['BR-CL-01' => 'invoice-type-codes', 'BR-CL-03' => 'currency-codes', 'BR-CL-06' => 'tax-point-date-codes-cii', 'BR-CL-07' => 'object-identifier-schemes', 'BR-CL …` | Rule codes and the code list names used by the package. |
| `PEPPOL_LISTS` | `[\Quittio\Core\Codes\CodeList::PEPPOL_EAS => 'PEPPOL-EN16931-CL008', \Quittio\Core\Codes\CodeList::PEPPOL_CURRENCIES => 'PEPPOL-EN16931-CL007', \Quittio\Core\Co …` | Code list names and the Peppol rules they are generated from (generatePeppol()). |

## Methods \#

| Method | Description |
| --- | --- |
| `::defaultTarget()` | |
| `->generate()` | |
| `->generatePeppol()` | Generates the Peppol code lists (PEPPOL-EN16931-CL…, P01…) that are narrower than the EN 16931 lists, from the Peppol BIS Billing 3.0 Schematron (PEPPOL-EN16931-UBL.sch). The codes are read from the assertion of the rule: an inline tokenize('…') or the variable (\<let>) the assertion refers to. |

### `defaultTarget()`#

```
public static function defaultTarget(): string
```

static

<dl><dt>Returns</dt>
<dd><code>string</code></dd>
</dl>

### `generate()`#

```
public function generate(string $xslPath, ?string $target = null): array<string, int>
```

| Parameter | Type | Description |
| --- | --- | --- |
| `$xslPath` | `string` | |
| `$target` | `?string` = `null` | |

<dl><dt>Returns</dt>
<dd><code>array&lt;string, int&gt;</code> – code list name =&gt; number of codes</dd></dl>

### `generatePeppol()`#

```
public function generatePeppol(
    string $schematronPath,
    ?string $target = null,
): array<string, int>
```

Generates the Peppol code lists (PEPPOL-EN16931-CL…, P01…) that are narrower than the EN 16931 lists, from the Peppol BIS Billing 3.0 Schematron (PEPPOL-EN16931-UBL.sch). The codes are read from the assertion of the rule: an inline tokenize('…') or the variable (\<let>) the assertion refers to.

| Parameter | Type | Description |
| --- | --- | --- |
| `$schematronPath` | `string` | |
| `$target` | `?string` = `null` | |

<dl><dt>Returns</dt>
<dd><code>array&lt;string, int&gt;</code> – code list name =&gt; number of codes</dd></dl>

```json
{"@context":"https://schema.org","@graph":[{"@id":"https://quittio.dev/#website","@type":"WebSite","description":"E-Rechnungen für PHP und Laravel: ZUGFeRD, XRechnung und Peppol erstellen, prüfen, lesen und archivieren.","inLanguage":"de-DE","name":"Quittio","url":"https://quittio.dev/","publisher":{"@id":"https://quittio.dev/#identity"},"workTranslation":{"@id":"https://quittio.dev/en#website"}},{"@id":"https://quittio.dev/docs/api/Quittio/Core/Codes/CodeListGenerator#webpage","@type":"WebPage","description":"Generates the code list files (resources/codelists/*.json) from the official EN 16931 Schematron rules (BR-CL-*), as shipped with the KoSIT validator configuration, and the narrower Peppol lists from the Peppol BIS Schematron.","name":"CodeListGenerator – API-Referenz","url":"https://quittio.dev/docs/api/Quittio/Core/Codes/CodeListGenerator","isPartOf":{"@id":"https://quittio.dev/#website"},"potentialAction":[{"@type":"ReadAction","target":["https://quittio.dev/docs/api/Quittio/Core/Codes/CodeListGenerator"]}],"primaryImageOfPage":{"@id":"https://quittio.dev/#logo"}},{"@id":"https://quittio.dev/#identity","@type":"Organization","description":"Open-Source-Bibliothek für E-Rechnungen in PHP und Laravel (ZUGFeRD, XRechnung, Peppol) und Quittio Managed.","email":"kontakt@niklasforst.de","legalName":"Niklas Forst – Softwareentwicklung","name":"Quittio","url":"https://quittio.dev","founder":{"@type":"Person","name":"Niklas Forst","url":"https://quittio.dev/ueber"},"logo":{"@id":"https://quittio.dev/#logo"},"sameAs":["https://github.com/Quittio/quittio","https://packagist.org/packages/quittio/quittio"]},{"@id":"https://quittio.dev/#logo","@type":"ImageObject","caption":"Quittio","contentUrl":"https://quittio.dev/logo.png","inLanguage":"de-DE","url":"https://quittio.dev/logo.png"}]}
```