---
title: "YAML to XLIFF CLI"
manual: "Klaro! Consent Manager"
version: "main"
permalink: "https://docs.typo3.org/permalink/erhaweb/klaro-consent-manager:howto-yaml-to-xliff@main"
source: "Integrator/HowTo/YamlToXliff/Index.rst"
rendered: "2026-09-24T10:59:30+00:00"
---

# YAML to XLIFF CLI {#howto-yaml-to-xliff}

The extension provides the Symfony command `klaro:yaml-to-xliff`. It converts
top-level Klaro translation YAML files into TYPO3-compatible XLIFF 1.2 files.
After conversion, reference the generated or adjusted file as a
[custom XLIFF file](https://docs.typo3.org/permalink/erhaweb/klaro-consent-manager:howto-reference-xliff@main) when it should override
project-specific labels.

## Usage {#usage}

```bash
vendor/bin/typo3 klaro:yaml-to-xliff src/translations Resources/Private/Language --base=en
```

With DDEV:

```bash
ddev typo3 klaro:yaml-to-xliff src/translations Resources/Private/Language --base=en
```

## Arguments and options {#arguments-and-options}

-   **input**

    -   *type:* directory

    Directory containing `*.yml` or `*.yaml` files. File names are interpreted
    as locale identifiers, for example `en.yml` or `de.yaml`.

-   **output**

    -   *type:* directory

    Target directory for generated XLIFF files. The command creates the
    directory if it does not exist.

-   **--base**

    -   *type:* string

    Base language. If the base language is `en`, the command writes
    `locallang.xlf` for the base language and `<iso>.locallang.xlf` for target
    languages.

-   **--product-name**

    -   *type:* string
    -   *Default:* `klaro_consent_manager`

    Optional `product-name` attribute for the generated XLIFF `<file>` tag.

-   **--original**

    -   *type:* string
    -   *Default:* `EXT:klaro_consent_manager/Resources/Private/Language/locallang.xlf`

    Optional `original` attribute for the generated XLIFF `<file>` tag.
