---
title: "QuittioFake – API-Referenz"
description: "Calculates invoices and chooses formats and profiles like a real run (requested formats, defaults.format, the automatic choice, profile keys and objects, defaults.profile), but skips validation, XML, template and PDF. Records every render call and every queued render, and dispatches the events of a real run (InvoiceRendering, InvoiceValidated with an empty result unless validation is off, InvoiceRendered)."
canonical_url: "https://quittio.dev/docs/api/Quittio/Laravel/Testing/QuittioFake"
locale: de
meta:
  "og:description": "Calculates invoices and chooses formats and profiles like a real run (requested formats, defaults.format, the automatic choice, profile keys and objects, defaults.profile), but skips validation, XML, template and PDF. Records every render call and every queued render, and dispatches the events of a real run (InvoiceRendering, InvoiceValidated with an empty result unless validation is off, InvoiceRendered)."
  "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": "QuittioFake – API-Referenz"
  "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) \\ [Laravel](https://quittio.dev/docs/api/Quittio/Laravel) \\ [Testing](https://quittio.dev/docs/api/Quittio/Laravel/Testing)

# QuittioFake

final class in quittio/laravel · extends [`QuittioManager`](https://quittio.dev/docs/api/Quittio/Laravel/QuittioManager)

`Quittio\Laravel\Testing\QuittioFake` · [Source](https://github.com/Quittio/quittio/blob/v0.7.1/packages/laravel/src/Laravel/Testing/QuittioFake.php#L30)

Calculates invoices and chooses formats and profiles like a real run (requested formats, defaults.format, the automatic choice, profile keys and objects, defaults.profile), but skips validation, XML, template and PDF. Records every render call and every queued render, and dispatches the events of a real run (InvoiceRendering, InvoiceValidated with an empty result unless validation is off, InvoiceRendered).

## Constants \#

| Constant | Value | Description |
| --- | --- | --- |
| `EXTENSION_TYPES` | `\Quittio\Laravel\Support\DriverRegistry::TYPES` | from [`QuittioManager`](https://quittio.dev/docs/api/Quittio/Laravel/QuittioManager) |

## Properties \#

| Property | Type | Description |
| --- | --- | --- |
| `$app` protected readonly | `Illuminate\Contracts\Container\Container` | from [`QuittioManager`](https://quittio.dev/docs/api/Quittio/Laravel/QuittioManager) |

## Methods \#

| Method | Description |
| --- | --- |
| `->__construct()` | |
| `->accountStatement()` | A new account statement with the seller and its defaults. |
| `->assertDocumentQueued()` | |
| `->assertDocumentRendered()` | |
| `->assertNothingQueued()` | Asserts that neither an invoice nor a document was queued. |
| `->assertNothingRendered()` | |
| `->assertQueued()` | |
| `->assertRendered()` | |
| `->assertRenderedCount()` | |
| `->bonusStatement()` | A new bonus statement (Bonusabrechnung, section 17 (4) UStG) with the seller and its defaults. |
| `->build()` | |
| `->cancellation()` | Builder for the cancellation of an issued invoice; render it like any invoice: Quittio::make(Quittio::cancellation($original, 'ST-2026-0001', 'Doppelt berechnet'))->render(). |
| `->check()` | Validates like a render run, without template and PDF, and returns the result; see Quittio\\Core\\Quittio::check(). |
| `->container()` | The application the manager works in. Under Laravel Octane that is the application of the current request (Container::getInstance()), not the one that created the singleton, so that configuration set for the request applies. |
| `->core()` | The core built from the current configuration; it is kept until the quittio configuration changes (config()->set(), another tenant), flush(), extend() or registerCountry(). |
| `->coreWithLevels()` | A new core (not the cached one) that validates with the configured levels plus $levels, every driver with its settings of validation.drivers.\* exactly as in a render run; e.g. quittio:validate --kosit --verapdf. |
| `->correction()` | Builder for a corrected invoice (384) that replaces an issued invoice, see \\Quittio\\Core\\Quittio::correction(); render it like any invoice. |
| `->countries()` | The country packs of the core. |
| `->defaultVat()` | VAT of invoice lines without VAT treatment (InvoiceBuilder::useDefaultVat()): the preset of quittio.defaults.vat, otherwise the standard preset of the seller's country pack; invoices of small businesses use the small business preset of the pack. |
| `->deliveryNote()` | A new delivery note with the seller and its defaults. |
| `->document()` | Starts the render call of a document; a builder is built at once. |
| `->documents()` | The recorded document results (quotes, reminders, …), in order. |
| `->edit()` | Builder that continues existing invoice data (a draft, an invoice read from XML); the declared amounts are compared with the configured calculator (calculation.\*). |
| `->extend()` | Registers a driver: renderer, validator, serializer or format\_resolver, or a rule that replaces the PHP rule with the code $name. The factory receives the container and the driver's configuration. |
| `->flush()` | Forgets the built core. Not needed after configuration changes: core() builds a new one when the quittio configuration differs from the one the core was built from. |
| `->formats()` | The output formats of the core. |
| `->invoice()` | A new invoice with the seller and its defaults (config/quittio.php, or the current issuer of quittio/managed); ends with ->render() or ->build(). |
| `->make()` | Starts a render call: format(), profile(), locale() … and render() or queue(). A builder is built and a model converted (ProvidesInvoiceData) at once. |
| `->orderConfirmation()` | A new order confirmation with the seller and its defaults. |
| `->paymentReminder()` | |
| `->prepare()` | Calculates and validates without rendering, whatever the validation mode; see Quittio\\Core\\Quittio::prepare(). |
| `->priceReduction()` | Builder for a document on the reduction of the consideration of an issued invoice (e.g. a cash discount taken), see \\Quittio\\Core\\Quittio::priceReduction(); render it like any invoice. |
| `->profiles()` | The profiles of the core, those of the country packs included. |
| `->proforma()` | A new proforma invoice with the seller and its defaults. |
| `->queued()` | The recorded queued render jobs, in order. |
| `->queuedDocuments()` | The recorded queued render jobs of documents, in order. |
| `->queueDocument()` | Records the document job and dispatches it like the real manager. |
| `->queueInvoice()` | Records the job and dispatches it like the real manager, so Queue::fake() sees it and a sync queue renders it with the fake. |
| `->quote()` | A new quote with the seller and its defaults (config/quittio.php or the current issuer). |
| `->read()` | Reads an incoming XML or PDF e-invoice from its content (bytes), never from a path. |
| `->readFile()` | Reads an incoming XML or PDF e-invoice from a file. |
| `->registerCountry()` | Registers a country pack; it wins over discovered and configured packs with the same code. The next call builds the core again (the default country depends on the packs). |
| `->renderDocument()` | The render run behind PendingDocument::render(), with the events DocumentRendering and DocumentRendered. |
| `->rendered()` | The recorded invoice results, in order (the main format of each call). |
| `->renderInvoice()` | The render run behind PendingInvoice::render(), with the events InvoiceRendering, InvoiceValidated (not in the mode "off") or InvoiceValidationFailed, and InvoiceRendered. |
| `->run()` | |
| `->runDocument()` | |
| `->settings()` | Typed read access to config('quittio'). |
| `->validateFile()` | Reads and validates an incoming e-invoice (content, never a path) with all configured levels. |
| `->validatePath()` | Reads and validates an incoming e-invoice from a file with all configured levels. |

### `__construct()`#

```
public function __construct(Container $app)
```

inherited from [`QuittioManager`](https://quittio.dev/docs/api/Quittio/Laravel/QuittioManager)

| Parameter | Type | Description |
| --- | --- | --- |
| `$app` | `Illuminate\Contracts\Container\Container` | |

### `accountStatement()`#

```
public function accountStatement(): RenderableDocumentBuilder
```

inherited from [`QuittioManager`](https://quittio.dev/docs/api/Quittio/Laravel/QuittioManager)

A new account statement with the seller and its defaults.

<dl><dt>Returns</dt>
<dd><code><a href="https://quittio.dev/docs/api/Quittio/Laravel/Builder/RenderableDocumentBuilder">RenderableDocumentBuilder</a></code></dd>
</dl>

### `assertDocumentQueued()`#

```
public function assertDocumentQueued(
    (callable(RenderDocument): bool)|null $callback = null,
): void
```

| Parameter | Type | Description |
| --- | --- | --- |
| `$callback` | `(callable([RenderDocument](https://quittio.dev/docs/api/Quittio/Laravel/Jobs/RenderDocument)): bool)\|null` = `null` | e.g. fn ($job) => $job->data()->number === 'AN-1' |

### `assertDocumentRendered()`#

```
public function assertDocumentRendered(
    (callable(RenderedDocument): bool)|null $callback = null,
): void
```

| Parameter | Type | Description |
| --- | --- | --- |
| `$callback` | `(callable([RenderedDocument](https://quittio.dev/docs/api/Quittio/Laravel/Rendering/RenderedDocument)): bool)\|null` = `null` | |

### `assertNothingQueued()`#

```
public function assertNothingQueued(): void
```

Asserts that neither an invoice nor a document was queued.

### `assertNothingRendered()`#

```
public function assertNothingRendered(): void
```

### `assertQueued()`#

```
public function assertQueued((callable(RenderInvoice): bool)|null $callback = null): void
```

| Parameter | Type | Description |
| --- | --- | --- |
| `$callback` | `(callable([RenderInvoice](https://quittio.dev/docs/api/Quittio/Laravel/Jobs/RenderInvoice)): bool)\|null` = `null` | e.g. fn ($job) => $job->data()->number === 'RE-1' |

### `assertRendered()`#

```
public function assertRendered(
    (callable(RenderedInvoice): bool)|null $callback = null,
): void
```

| Parameter | Type | Description |
| --- | --- | --- |
| `$callback` | `(callable([RenderedInvoice](https://quittio.dev/docs/api/Quittio/Laravel/Rendering/RenderedInvoice)): bool)\|null` = `null` | |

### `assertRenderedCount()`#

```
public function assertRenderedCount(int $count): void
```

| Parameter | Type | Description |
| --- | --- | --- |
| `$count` | `int` | |

### `bonusStatement()`#

```
public function bonusStatement(): RenderableDocumentBuilder
```

inherited from [`QuittioManager`](https://quittio.dev/docs/api/Quittio/Laravel/QuittioManager)

A new bonus statement (Bonusabrechnung, section 17 (4) UStG) with the seller and its defaults.

<dl><dt>Returns</dt>
<dd><code><a href="https://quittio.dev/docs/api/Quittio/Laravel/Builder/RenderableDocumentBuilder">RenderableDocumentBuilder</a></code></dd>
</dl>

### `build()`#

```
protected function build(list<string>|null $levels = null): Quittio
```

protected inherited from [`QuittioManager`](https://quittio.dev/docs/api/Quittio/Laravel/QuittioManager)

| Parameter | Type | Description |
| --- | --- | --- |
| `$levels` | `list<string>\|null` = `null` | validation levels instead of quittio.validation.levels |

<dl><dt>Returns</dt>
<dd><code><a href="https://quittio.dev/docs/api/Quittio/Core/Quittio">Quittio</a></code></dd>
</dl>

### `cancellation()`#

```
public function cancellation(
    InvoiceData $original,
    string $number,
    ?string $reason = null,
    ?string $strategy = null,
    ?Date $issueDate = null,
    list<array{line: string, quantity?: BigDecimal|int|string, amount?: string}>|null $lines = null,
    CancellationHistory|null $history = null,
    string|null $title = null,
): InvoiceBuilder
```

inherited from [`QuittioManager`](https://quittio.dev/docs/api/Quittio/Laravel/QuittioManager)

Builder for the cancellation of an issued invoice; render it like any invoice: Quittio::make(Quittio::cancellation($original, 'ST-2026-0001', 'Doppelt berechnet'))->render().

| Parameter | Type | Description |
| --- | --- | --- |
| `$original` | `[InvoiceData](https://quittio.dev/docs/api/Quittio/Core/Data/InvoiceData)` | |
| `$number` | `string` | |
| `$reason` | `?string` = `null` | |
| `$strategy` | `?string` = `null` | |
| `$issueDate` | `? [Date](https://quittio.dev/docs/api/Quittio/Core/Support/Date)` = `null` | |
| `$lines` | `list<array{line: string, Quittio\Laravel\quantity?: Brick\Math\BigDecimal\|int\|string, Quittio\Laravel\amount?: string}>\|null` = `null` | partial cancellation; null = full |
| `$history` | `[CancellationHistory](https://quittio.dev/docs/api/Quittio/Core/Corrections/CancellationHistory)\|null` = `null` | earlier partial cancellations, for the cumulative rounding of the VAT |
| `$title` | `string\|null` = `null` | document title in the PDF, e.g. "Stornorechnung"; null = the title of the country pack's correction policy |

<dl><dt>Returns</dt>
<dd><code><a href="https://quittio.dev/docs/api/Quittio/Core/Builder/InvoiceBuilder">InvoiceBuilder</a></code></dd>
</dl>

### `check()`#

```
public function check(InvoiceData $invoice, RenderOptions $options): ValidationResult
```

inherited from [`QuittioManager`](https://quittio.dev/docs/api/Quittio/Laravel/QuittioManager)

Validates like a render run, without template and PDF, and returns the result; see Quittio\\Core\\Quittio::check().

| Parameter | Type | Description |
| --- | --- | --- |
| `$invoice` | `[InvoiceData](https://quittio.dev/docs/api/Quittio/Core/Data/InvoiceData)` | |
| `$options` | `[RenderOptions](https://quittio.dev/docs/api/Quittio/Core/Rendering/RenderOptions)` | |

<dl><dt>Returns</dt>
<dd><code><a href="https://quittio.dev/docs/api/Quittio/Core/Validation/ValidationResult">ValidationResult</a></code></dd>
<dt>Throws</dt>
<dd><code><a href="https://quittio.dev/docs/api/Quittio/Core/Exceptions/ConfigurationException">ConfigurationException</a></code> – for an unknown format or an unsupported profile</dd></dl>

### `container()`#

```
protected function container(): Container
```

protected inherited from [`QuittioManager`](https://quittio.dev/docs/api/Quittio/Laravel/QuittioManager)

The application the manager works in. Under Laravel Octane that is the application of the current request (Container::getInstance()), not the one that created the singleton, so that configuration set for the request applies.

<dl><dt>Returns</dt>
<dd><code>Illuminate\Contracts\Container\Container</code></dd>
</dl>

### `core()`#

```
public function core(): Quittio
```

inherited from [`QuittioManager`](https://quittio.dev/docs/api/Quittio/Laravel/QuittioManager)

The core built from the current configuration; it is kept until the quittio configuration changes (config()->set(), another tenant), flush(), extend() or registerCountry().

<dl><dt>Returns</dt>
<dd><code><a href="https://quittio.dev/docs/api/Quittio/Core/Quittio">Quittio</a></code></dd>
</dl>

### `coreWithLevels()`#

```
public function coreWithLevels(list<string> $levels): Quittio
```

inherited from [`QuittioManager`](https://quittio.dev/docs/api/Quittio/Laravel/QuittioManager)

A new core (not the cached one) that validates with the configured levels plus $levels, every driver with its settings of validation.drivers.\* exactly as in a render run; e.g. quittio:validate --kosit --verapdf.

| Parameter | Type | Description |
| --- | --- | --- |
| `$levels` | `list<string>` | names as in quittio.validation.levels, e.g. kosit, verapdf |

<dl><dt>Returns</dt>
<dd><code><a href="https://quittio.dev/docs/api/Quittio/Core/Quittio">Quittio</a></code></dd>
</dl>

### `correction()`#

```
public function correction(
    InvoiceData $original,
    string $number,
    ?string $reason = null,
    ?Date $issueDate = null,
    ?string $title = null,
): InvoiceBuilder
```

inherited from [`QuittioManager`](https://quittio.dev/docs/api/Quittio/Laravel/QuittioManager)

Builder for a corrected invoice (384) that replaces an issued invoice, see \\Quittio\\Core\\Quittio::correction(); render it like any invoice.

| Parameter | Type | Description |
| --- | --- | --- |
| `$original` | `[InvoiceData](https://quittio.dev/docs/api/Quittio/Core/Data/InvoiceData)` | |
| `$number` | `string` | |
| `$reason` | `?string` = `null` | |
| `$issueDate` | `? [Date](https://quittio.dev/docs/api/Quittio/Core/Support/Date)` = `null` | |
| `$title` | `?string` = `null` | |

<dl><dt>Returns</dt>
<dd><code><a href="https://quittio.dev/docs/api/Quittio/Core/Builder/InvoiceBuilder">InvoiceBuilder</a></code></dd>
</dl>

### `countries()`#

```
public function countries(): CountryRegistry
```

inherited from [`QuittioManager`](https://quittio.dev/docs/api/Quittio/Laravel/QuittioManager)

The country packs of the core.

<dl><dt>Returns</dt>
<dd><code><a href="https://quittio.dev/docs/api/Quittio/Core/Countries/CountryRegistry">CountryRegistry</a></code></dd>
</dl>

### `defaultVat()`#

```
public function defaultVat(?string $sellerCountry, bool $smallBusiness): ?TaxPreset
```

inherited from [`QuittioManager`](https://quittio.dev/docs/api/Quittio/Laravel/QuittioManager)

VAT of invoice lines without VAT treatment (InvoiceBuilder::useDefaultVat()): the preset of quittio.defaults.vat, otherwise the standard preset of the seller's country pack; invoices of small businesses use the small business preset of the pack.

| Parameter | Type | Description |
| --- | --- | --- |
| `$sellerCountry` | `?string` | |
| `$smallBusiness` | `bool` | |

<dl><dt>Returns</dt>
<dd><code>?<a href="https://quittio.dev/docs/api/Quittio/Core/Tax/TaxPreset">TaxPreset</a></code></dd>
</dl>

### `deliveryNote()`#

```
public function deliveryNote(): RenderableDocumentBuilder
```

inherited from [`QuittioManager`](https://quittio.dev/docs/api/Quittio/Laravel/QuittioManager)

A new delivery note with the seller and its defaults.

<dl><dt>Returns</dt>
<dd><code><a href="https://quittio.dev/docs/api/Quittio/Laravel/Builder/RenderableDocumentBuilder">RenderableDocumentBuilder</a></code></dd>
</dl>

### `document()`#

```
public function document(DocumentData|DocumentBuilder $document): PendingDocument
```

inherited from [`QuittioManager`](https://quittio.dev/docs/api/Quittio/Laravel/QuittioManager)

Starts the render call of a document; a builder is built at once.

| Parameter | Type | Description |
| --- | --- | --- |
| `$document` | `[DocumentData](https://quittio.dev/docs/api/Quittio/Core/Documents/DocumentData)\| [DocumentBuilder](https://quittio.dev/docs/api/Quittio/Core/Documents/DocumentBuilder)` | |

<dl><dt>Returns</dt>
<dd><code><a href="https://quittio.dev/docs/api/Quittio/Laravel/Rendering/PendingDocument">PendingDocument</a></code></dd>
<dt>Throws</dt>
<dd><code><a href="https://quittio.dev/docs/api/Quittio/Core/Exceptions/InvalidInvoiceData">InvalidInvoiceData</a></code> – when a builder misses the seller, the buyer or a line's essentials</dd></dl>

### `documents()`#

```
public function documents(): list<RenderedDocument>
```

The recorded document results (quotes, reminders, …), in order.

<dl><dt>Returns</dt>
<dd><code>list&lt;<a href="https://quittio.dev/docs/api/Quittio/Laravel/Rendering/RenderedDocument">RenderedDocument</a>&gt;</code></dd>
</dl>

### `edit()`#

```
public function edit(InvoiceData $data): RenderableInvoiceBuilder
```

inherited from [`QuittioManager`](https://quittio.dev/docs/api/Quittio/Laravel/QuittioManager)

Builder that continues existing invoice data (a draft, an invoice read from XML); the declared amounts are compared with the configured calculator (calculation.\*).

| Parameter | Type | Description |
| --- | --- | --- |
| `$data` | `[InvoiceData](https://quittio.dev/docs/api/Quittio/Core/Data/InvoiceData)` | |

<dl><dt>Returns</dt>
<dd><code><a href="https://quittio.dev/docs/api/Quittio/Laravel/Builder/RenderableInvoiceBuilder">RenderableInvoiceBuilder</a></code></dd>
</dl>

### `extend()`#

```
public function extend(string $type, string $name, Closure $factory): static
```

inherited from [`QuittioManager`](https://quittio.dev/docs/api/Quittio/Laravel/QuittioManager)

Registers a driver: renderer, validator, serializer or format\_resolver, or a rule that replaces the PHP rule with the code $name. The factory receives the container and the driver's configuration.

| Parameter | Type | Description |
| --- | --- | --- |
| `$type` | `string` | |
| `$name` | `string` | |
| `$factory` | `Closure` | |

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

### `flush()`#

```
public function flush(): static
```

inherited from [`QuittioManager`](https://quittio.dev/docs/api/Quittio/Laravel/QuittioManager)

Forgets the built core. Not needed after configuration changes: core() builds a new one when the quittio configuration differs from the one the core was built from.

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

### `formats()`#

```
public function formats(): FormatRegistry
```

inherited from [`QuittioManager`](https://quittio.dev/docs/api/Quittio/Laravel/QuittioManager)

The output formats of the core.

<dl><dt>Returns</dt>
<dd><code><a href="https://quittio.dev/docs/api/Quittio/Core/Formats/FormatRegistry">FormatRegistry</a></code></dd>
</dl>

### `invoice()`#

```
public function invoice(): RenderableInvoiceBuilder
```

inherited from [`QuittioManager`](https://quittio.dev/docs/api/Quittio/Laravel/QuittioManager)

A new invoice with the seller and its defaults (config/quittio.php, or the current issuer of quittio/managed); ends with ->render() or ->build().

<dl><dt>Returns</dt>
<dd><code><a href="https://quittio.dev/docs/api/Quittio/Laravel/Builder/RenderableInvoiceBuilder">RenderableInvoiceBuilder</a></code></dd>
</dl>

### `make()`#

```
public function make(InvoiceData|ProvidesInvoiceData|InvoiceBuilder $data): PendingInvoice
```

inherited from [`QuittioManager`](https://quittio.dev/docs/api/Quittio/Laravel/QuittioManager)

Starts a render call: format(), profile(), locale() … and render() or queue(). A builder is built and a model converted (ProvidesInvoiceData) at once.

| Parameter | Type | Description |
| --- | --- | --- |
| `$data` | `[InvoiceData](https://quittio.dev/docs/api/Quittio/Core/Data/InvoiceData)\| [ProvidesInvoiceData](https://quittio.dev/docs/api/Quittio/Core/Contracts/ProvidesInvoiceData)\| [InvoiceBuilder](https://quittio.dev/docs/api/Quittio/Core/Builder/InvoiceBuilder)` | |

<dl><dt>Returns</dt>
<dd><code><a href="https://quittio.dev/docs/api/Quittio/Laravel/Rendering/PendingInvoice">PendingInvoice</a></code></dd>
<dt>Throws</dt>
<dd><code><a href="https://quittio.dev/docs/api/Quittio/Core/Exceptions/InvalidInvoiceData">InvalidInvoiceData</a></code> – when a builder misses an essential part (see InvoiceBuilder::build())</dd></dl>

### `orderConfirmation()`#

```
public function orderConfirmation(): RenderableDocumentBuilder
```

inherited from [`QuittioManager`](https://quittio.dev/docs/api/Quittio/Laravel/QuittioManager)

A new order confirmation with the seller and its defaults.

<dl><dt>Returns</dt>
<dd><code><a href="https://quittio.dev/docs/api/Quittio/Laravel/Builder/RenderableDocumentBuilder">RenderableDocumentBuilder</a></code></dd>
</dl>

### `paymentReminder()`#

```
public function paymentReminder(int $level = 0): RenderableDocumentBuilder
```

inherited from [`QuittioManager`](https://quittio.dev/docs/api/Quittio/Laravel/QuittioManager)

| Parameter | Type | Description |
| --- | --- | --- |
| `$level` | `int` = `0` | 0 = payment reminder, 1 = first reminder, 2 = second reminder … |

<dl><dt>Returns</dt>
<dd><code><a href="https://quittio.dev/docs/api/Quittio/Laravel/Builder/RenderableDocumentBuilder">RenderableDocumentBuilder</a></code></dd>
</dl>

### `prepare()`#

```
public function prepare(InvoiceData $invoice, RenderOptions $options): PreparedInvoice
```

inherited from [`QuittioManager`](https://quittio.dev/docs/api/Quittio/Laravel/QuittioManager)

Calculates and validates without rendering, whatever the validation mode; see Quittio\\Core\\Quittio::prepare().

| Parameter | Type | Description |
| --- | --- | --- |
| `$invoice` | `[InvoiceData](https://quittio.dev/docs/api/Quittio/Core/Data/InvoiceData)` | |
| `$options` | `[RenderOptions](https://quittio.dev/docs/api/Quittio/Core/Rendering/RenderOptions)` | |

<dl><dt>Returns</dt>
<dd><code><a href="https://quittio.dev/docs/api/Quittio/Core/Rendering/PreparedInvoice">PreparedInvoice</a></code></dd>
<dt>Throws</dt>
<dd><code><a href="https://quittio.dev/docs/api/Quittio/Core/Exceptions/ConfigurationException">ConfigurationException</a></code> – for an unknown format or an unsupported profile</dd></dl>

### `priceReduction()`#

```
public function priceReduction(
    InvoiceData $original,
    string $number,
    PriceReductionReason $reason,
    BigDecimal|int|string|null $percent = null,
    BigDecimal|int|string|null $amount = null,
    array<string, BigDecimal|int|string>|null $amounts = null,
    ?Date $issueDate = null,
    ?string $title = null,
): InvoiceBuilder
```

inherited from [`QuittioManager`](https://quittio.dev/docs/api/Quittio/Laravel/QuittioManager)

Builder for a document on the reduction of the consideration of an issued invoice (e.g. a cash discount taken), see \\Quittio\\Core\\Quittio::priceReduction(); render it like any invoice.

| Parameter | Type | Description |
| --- | --- | --- |
| `$original` | `[InvoiceData](https://quittio.dev/docs/api/Quittio/Core/Data/InvoiceData)` | |
| `$number` | `string` | |
| `$reason` | `[PriceReductionReason](https://quittio.dev/docs/api/Quittio/Core/Corrections/PriceReductionReason)` | |
| `$percent` | `Brick\Math\BigDecimal\|int\|string\|null` = `null` | |
| `$amount` | `Brick\Math\BigDecimal\|int\|string\|null` = `null` | |
| `$amounts` | `array<string, Brick\Math\BigDecimal\|int\|string>\|null` = `null` | net amount per VAT group ("S:19" => '50.00') |
| `$issueDate` | `? [Date](https://quittio.dev/docs/api/Quittio/Core/Support/Date)` = `null` | |
| `$title` | `?string` = `null` | |

<dl><dt>Returns</dt>
<dd><code><a href="https://quittio.dev/docs/api/Quittio/Core/Builder/InvoiceBuilder">InvoiceBuilder</a></code></dd>
</dl>

### `profiles()`#

```
public function profiles(): ProfileRegistry
```

inherited from [`QuittioManager`](https://quittio.dev/docs/api/Quittio/Laravel/QuittioManager)

The profiles of the core, those of the country packs included.

<dl><dt>Returns</dt>
<dd><code><a href="https://quittio.dev/docs/api/Quittio/Core/Profiles/ProfileRegistry">ProfileRegistry</a></code></dd>
</dl>

### `proforma()`#

```
public function proforma(): RenderableDocumentBuilder
```

inherited from [`QuittioManager`](https://quittio.dev/docs/api/Quittio/Laravel/QuittioManager)

A new proforma invoice with the seller and its defaults.

<dl><dt>Returns</dt>
<dd><code><a href="https://quittio.dev/docs/api/Quittio/Laravel/Builder/RenderableDocumentBuilder">RenderableDocumentBuilder</a></code></dd>
</dl>

### `queued()`#

```
public function queued(): list<RenderInvoice>
```

The recorded queued render jobs, in order.

<dl><dt>Returns</dt>
<dd><code>list&lt;<a href="https://quittio.dev/docs/api/Quittio/Laravel/Jobs/RenderInvoice">RenderInvoice</a>&gt;</code></dd>
</dl>

### `queuedDocuments()`#

```
public function queuedDocuments(): list<RenderDocument>
```

The recorded queued render jobs of documents, in order.

<dl><dt>Returns</dt>
<dd><code>list&lt;<a href="https://quittio.dev/docs/api/Quittio/Laravel/Jobs/RenderDocument">RenderDocument</a>&gt;</code></dd>
</dl>

### `queueDocument()`#

```
public function queueDocument(RenderDocument $job): RenderDocument
```

Records the document job and dispatches it like the real manager.

| Parameter | Type | Description |
| --- | --- | --- |
| `$job` | `[RenderDocument](https://quittio.dev/docs/api/Quittio/Laravel/Jobs/RenderDocument)` | |

<dl><dt>Returns</dt>
<dd><code><a href="https://quittio.dev/docs/api/Quittio/Laravel/Jobs/RenderDocument">RenderDocument</a></code></dd>
</dl>

### `queueInvoice()`#

```
public function queueInvoice(RenderInvoice $job): RenderInvoice
```

Records the job and dispatches it like the real manager, so Queue::fake() sees it and a sync queue renders it with the fake.

| Parameter | Type | Description |
| --- | --- | --- |
| `$job` | `[RenderInvoice](https://quittio.dev/docs/api/Quittio/Laravel/Jobs/RenderInvoice)` | |

<dl><dt>Returns</dt>
<dd><code><a href="https://quittio.dev/docs/api/Quittio/Laravel/Jobs/RenderInvoice">RenderInvoice</a></code></dd>
</dl>

### `quote()`#

```
public function quote(): RenderableDocumentBuilder
```

inherited from [`QuittioManager`](https://quittio.dev/docs/api/Quittio/Laravel/QuittioManager)

A new quote with the seller and its defaults (config/quittio.php or the current issuer).

<dl><dt>Returns</dt>
<dd><code><a href="https://quittio.dev/docs/api/Quittio/Laravel/Builder/RenderableDocumentBuilder">RenderableDocumentBuilder</a></code></dd>
</dl>

### `read()`#

```
public function read(string $content): ReadResult
```

inherited from [`QuittioManager`](https://quittio.dev/docs/api/Quittio/Laravel/QuittioManager)

Reads an incoming XML or PDF e-invoice from its content (bytes), never from a path.

| Parameter | Type | Description |
| --- | --- | --- |
| `$content` | `string` | |

<dl><dt>Returns</dt>
<dd><code><a href="https://quittio.dev/docs/api/Quittio/Core/Reading/ReadResult">ReadResult</a></code></dd>
<dt>Throws</dt>
<dd><code><a href="https://quittio.dev/docs/api/Quittio/Core/Xml/UnsafeXmlException">UnsafeXmlException</a></code> – when the XML is too large, not well-formed or not allowed</dd>
<dt>Throws</dt>
<dd><code><a href="https://quittio.dev/docs/api/Quittio/Core/Pdf/PdfException">PdfException</a></code> – when the PDF is too large, encrypted, malformed or exceeds a limit</dd>
<dt>Throws</dt>
<dd><code><a href="https://quittio.dev/docs/api/Quittio/Core/Reading/UnreadableInvoiceException">UnreadableInvoiceException</a></code> – for an unknown format, ZUGFeRD 1.0 or a PDF without an embedded invoice</dd></dl>

### `readFile()`#

```
public function readFile(string $path): ReadResult
```

inherited from [`QuittioManager`](https://quittio.dev/docs/api/Quittio/Laravel/QuittioManager)

Reads an incoming XML or PDF e-invoice from a file.

| Parameter | Type | Description |
| --- | --- | --- |
| `$path` | `string` | |

<dl><dt>Returns</dt>
<dd><code><a href="https://quittio.dev/docs/api/Quittio/Core/Reading/ReadResult">ReadResult</a></code></dd>
<dt>Throws</dt>
<dd><code><a href="https://quittio.dev/docs/api/Quittio/Core/Xml/UnsafeXmlException">UnsafeXmlException</a></code> – when the XML is too large, not well-formed or not allowed</dd>
<dt>Throws</dt>
<dd><code><a href="https://quittio.dev/docs/api/Quittio/Core/Pdf/PdfException">PdfException</a></code> – when the PDF is too large, encrypted, malformed or exceeds a limit</dd>
<dt>Throws</dt>
<dd><code><a href="https://quittio.dev/docs/api/Quittio/Core/Reading/UnreadableInvoiceException">UnreadableInvoiceException</a></code> – for an unknown format, ZUGFeRD 1.0 or a PDF without an embedded invoice (or a file that cannot be read)</dd></dl>

### `registerCountry()`#

```
public function registerCountry(CountryPack $pack): static
```

inherited from [`QuittioManager`](https://quittio.dev/docs/api/Quittio/Laravel/QuittioManager)

Registers a country pack; it wins over discovered and configured packs with the same code. The next call builds the core again (the default country depends on the packs).

| Parameter | Type | Description |
| --- | --- | --- |
| `$pack` | `[CountryPack](https://quittio.dev/docs/api/Quittio/Core/Countries/CountryPack)` | |

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

### `renderDocument()`#

```
public function renderDocument(
    DocumentData $document,
    RenderOptions $options,
): RenderedDocument
```

inherited from [`QuittioManager`](https://quittio.dev/docs/api/Quittio/Laravel/QuittioManager)

The render run behind PendingDocument::render(), with the events DocumentRendering and DocumentRendered.

| Parameter | Type | Description |
| --- | --- | --- |
| `$document` | `[DocumentData](https://quittio.dev/docs/api/Quittio/Core/Documents/DocumentData)` | |
| `$options` | `[RenderOptions](https://quittio.dev/docs/api/Quittio/Core/Rendering/RenderOptions)` | |

<dl><dt>Returns</dt>
<dd><code><a href="https://quittio.dev/docs/api/Quittio/Laravel/Rendering/RenderedDocument">RenderedDocument</a></code></dd>
</dl>

### `rendered()`#

```
public function rendered(): list<RenderedInvoice>
```

The recorded invoice results, in order (the main format of each call).

<dl><dt>Returns</dt>
<dd><code>list&lt;<a href="https://quittio.dev/docs/api/Quittio/Laravel/Rendering/RenderedInvoice">RenderedInvoice</a>&gt;</code></dd>
</dl>

### `renderInvoice()`#

```
public function renderInvoice(
    InvoiceData $invoice,
    RenderOptions $options,
): RenderedInvoice
```

inherited from [`QuittioManager`](https://quittio.dev/docs/api/Quittio/Laravel/QuittioManager)

The render run behind PendingInvoice::render(), with the events InvoiceRendering, InvoiceValidated (not in the mode "off") or InvoiceValidationFailed, and InvoiceRendered.

| Parameter | Type | Description |
| --- | --- | --- |
| `$invoice` | `[InvoiceData](https://quittio.dev/docs/api/Quittio/Core/Data/InvoiceData)` | |
| `$options` | `[RenderOptions](https://quittio.dev/docs/api/Quittio/Core/Rendering/RenderOptions)` | |

<dl><dt>Returns</dt>
<dd><code><a href="https://quittio.dev/docs/api/Quittio/Laravel/Rendering/RenderedInvoice">RenderedInvoice</a></code></dd>
<dt>Throws</dt>
<dd><code><a href="https://quittio.dev/docs/api/Quittio/Core/Validation/ValidationException">ValidationException</a></code> – when validation finds errors in the mode "error"</dd>
<dt>Throws</dt>
<dd><code><a href="https://quittio.dev/docs/api/Quittio/Core/Exceptions/ConfigurationException">ConfigurationException</a></code> – for an unknown format or an unsupported profile; see Quittio\Core\Quittio::render() for the other exceptions of a run</dd></dl>

### `run()`#

```
protected function run(InvoiceData $invoice, RenderOptions $options): RenderedInvoice
```

protected

| Parameter | Type | Description |
| --- | --- | --- |
| `$invoice` | `[InvoiceData](https://quittio.dev/docs/api/Quittio/Core/Data/InvoiceData)` | |
| `$options` | `[RenderOptions](https://quittio.dev/docs/api/Quittio/Core/Rendering/RenderOptions)` | |

<dl><dt>Returns</dt>
<dd><code><a href="https://quittio.dev/docs/api/Quittio/Laravel/Rendering/RenderedInvoice">RenderedInvoice</a></code></dd>
</dl>

### `runDocument()`#

```
protected function runDocument(
    DocumentData $document,
    RenderOptions $options,
): RenderedDocument
```

protected

| Parameter | Type | Description |
| --- | --- | --- |
| `$document` | `[DocumentData](https://quittio.dev/docs/api/Quittio/Core/Documents/DocumentData)` | |
| `$options` | `[RenderOptions](https://quittio.dev/docs/api/Quittio/Core/Rendering/RenderOptions)` | |

<dl><dt>Returns</dt>
<dd><code><a href="https://quittio.dev/docs/api/Quittio/Laravel/Rendering/RenderedDocument">RenderedDocument</a></code></dd>
</dl>

### `settings()`#

```
public function settings(): Settings
```

inherited from [`QuittioManager`](https://quittio.dev/docs/api/Quittio/Laravel/QuittioManager)

Typed read access to config('quittio').

<dl><dt>Returns</dt>
<dd><code><a href="https://quittio.dev/docs/api/Quittio/Laravel/Support/Settings">Settings</a></code></dd>
</dl>

### `validateFile()`#

```
public function validateFile(string $content): ValidationResult
```

inherited from [`QuittioManager`](https://quittio.dev/docs/api/Quittio/Laravel/QuittioManager)

Reads and validates an incoming e-invoice (content, never a path) with all configured levels.

| Parameter | Type | Description |
| --- | --- | --- |
| `$content` | `string` | |

<dl><dt>Returns</dt>
<dd><code><a href="https://quittio.dev/docs/api/Quittio/Core/Validation/ValidationResult">ValidationResult</a></code></dd>
<dt>Throws</dt>
<dd><code><a href="https://quittio.dev/docs/api/Quittio/Core/Xml/UnsafeXmlException">UnsafeXmlException</a></code> – when the XML is too large, not well-formed or not allowed</dd>
<dt>Throws</dt>
<dd><code><a href="https://quittio.dev/docs/api/Quittio/Core/Pdf/PdfException">PdfException</a></code> – when the PDF is too large, encrypted, malformed or exceeds a limit</dd>
<dt>Throws</dt>
<dd><code><a href="https://quittio.dev/docs/api/Quittio/Core/Reading/UnreadableInvoiceException">UnreadableInvoiceException</a></code> – for an unknown format, ZUGFeRD 1.0 or a PDF without an embedded invoice</dd></dl>

### `validatePath()`#

```
public function validatePath(string $path): ValidationResult
```

inherited from [`QuittioManager`](https://quittio.dev/docs/api/Quittio/Laravel/QuittioManager)

Reads and validates an incoming e-invoice from a file with all configured levels.

| Parameter | Type | Description |
| --- | --- | --- |
| `$path` | `string` | |

<dl><dt>Returns</dt>
<dd><code><a href="https://quittio.dev/docs/api/Quittio/Core/Validation/ValidationResult">ValidationResult</a></code></dd>
<dt>Throws</dt>
<dd><code><a href="https://quittio.dev/docs/api/Quittio/Core/Xml/UnsafeXmlException">UnsafeXmlException</a></code> – when the XML is too large, not well-formed or not allowed</dd>
<dt>Throws</dt>
<dd><code><a href="https://quittio.dev/docs/api/Quittio/Core/Pdf/PdfException">PdfException</a></code> – when the PDF is too large, encrypted, malformed or exceeds a limit</dd>
<dt>Throws</dt>
<dd><code><a href="https://quittio.dev/docs/api/Quittio/Core/Reading/UnreadableInvoiceException">UnreadableInvoiceException</a></code> – for an unknown format, ZUGFeRD 1.0 or a PDF without an embedded invoice (or a file that cannot be read)</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/Laravel/Testing/QuittioFake#webpage","@type":"WebPage","description":"Calculates invoices and chooses formats and profiles like a real run (requested formats, defaults.format, the automatic choice, profile keys and objects, defaults.profile), but skips validation, XML, template and PDF. Records every render call and every queued render, and dispatches the events of a real run (InvoiceRendering, InvoiceValidated with an empty result unless validation is off, InvoiceRendered).","name":"QuittioFake – API-Referenz","url":"https://quittio.dev/docs/api/Quittio/Laravel/Testing/QuittioFake","isPartOf":{"@id":"https://quittio.dev/#website"},"potentialAction":[{"@type":"ReadAction","target":["https://quittio.dev/docs/api/Quittio/Laravel/Testing/QuittioFake"]}],"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"}]}
```