# BR-DEX-13 Third party payment amount allows at most two decimals

The maximum number of decimal places allowed for the Third party payment amount (BT-DEX-002) is two.

## Problem Description

The maximum number of decimal places allowed for the Third party payment amount (BT-DEX-002) is two.

> **ERROR**: XRechnung 3.0

## Context and Significance

This XRechnung Extension rule mirrors the core two-decimal amount discipline (like BR-DEC rules) for the Extension-only third party payment amount.

## Solution

Round cbc:PaidAmount in cac:PrepaidPayment to two decimal places (for example 20.00, not 20.005). If you do not model third party payments, the standard XRechnung CIUS profile avoids this rule.

- validate
- convert

## Valid Examples

- <cbc:PaidAmount currencyID="EUR">20.00</cbc:PaidAmount>

## Invalid Examples

- <cbc:PaidAmount currencyID="EUR">20.005</cbc:PaidAmount> — three decimals

## Code Examples

### Valid XML
```
<cac:PrepaidPayment>
  <cbc:PaidAmount currencyID="EUR">20.00</cbc:PaidAmount>
</cac:PrepaidPayment>
```

### Invalid XML
```
<cac:PrepaidPayment>
  <cbc:PaidAmount currencyID="EUR">20.005</cbc:PaidAmount>
</cac:PrepaidPayment>
```

## Affected Fields

- [BT-DEX-002 Third party payment amount](/resources/xrechnung)

## Related Rules

- [BR-DEX-11](/resources/kosit-validator-errors/br-dex-11-third-party-payment-amount-required)
- [BR-DEX-14](/resources/kosit-validator-errors/br-dex-14-third-party-payment-amount-currency)

## Validation Tools

- [Official KoSIT Validator](https://erechnungsvalidator.service-bw.de/): Validate your XRechnung files against all BR-DE rules.
- [Convert PDF to XRechnung](/pdf-to-xrechnung): Automatic validation error fixes when converting.

## Related Resources

- [Official Specification](https://xeinkauf.de/xrechnung/)
- [Test Suite](https://github.com/itplr-kosit/xrechnung-testsuite)
- [Complete Error List](/resources/kosit-validator-errors): Overview of all German XRechnung validation rules.
