> ## Documentation Index
> Fetch the complete documentation index at: https://docs.lerian.studio/llms.txt
> Use this file to discover all available pages before exploring further.

# Template formats

> Design Reporter templates for HTML, XML, CSV, PDF, or TXT outputs — practical examples to start building reports that fit your use case.

The **Reporter** product supports multiple output formats, so you can generate exactly the file type you need, whether it's HTML, XML, CSV, PDF or plain text.

In this section, you'll find practical examples of how to structure your `.tpl` files for each format. These examples are a great starting point to help you design templates that fit your use case, follow formatting rules, and get parsed correctly during generation.

<Danger>
  The file content **must** follow the output format you need (HTML, XML, CSV, PDF or TXT), but make sure to save it with a `.tpl` extension. **This is required for the template to work properly.**
</Danger>

## Available examples

***

<div className="space-y-6 w-full sm:max-w-4xl">
  <Columns cols={3}>
    <Card title="HTML template" icon="code" href="/en/reporter/reporter-html-template">
      Analytical financial report with account-level transaction analysis.
    </Card>

    <Card title="XML template" icon="file-code" href="/en/reporter/reporter-xml-template">
      Analytical financial report in XML with custom logic and summaries.
    </Card>

    <Card title="TXT template" icon="file-lines" href="/en/reporter/reporter-txt-template">
      Transaction receipt template in plain text format.
    </Card>
  </Columns>
</div>

Each page includes the full template code, field-by-field explanations, and sample outputs that you can generate through Reporter.

## Tip for rendering a transaction receipt

***

To generate a transaction receipt using Reporter, you can send a request like this to the [Create a Report](/en/reference/reporter/create-report) endpoint:

<CodeGroup>
  ```json JSON theme={null}
  {
    "templateId": "0196f99c-4d3e-73bc-b5d3-2a5bb1efbee4",
    "ledgerId": [
      "0196d97e-587e-76d8-a458-9d2517ed9aba"
    ],
    "filters": {
      "midaz_transaction": {
        "transaction": {
          "id": ["0196d983-a2c2-7d5a-a5b7-029fe0dcb710"]
        }
      }
    }
  }
  ```
</CodeGroup>

### What does this filter do?

The `filters` field lets you limit the data used when rendering the template. In this case, you're telling the system to use **only** the transaction with the ID `0196d983-a2c2-7d5a-a5b7-029fe0dcb710`.

That means your receipt will include just that one transaction — and the operations linked to it — keeping the output clean and focused.

### What happens next?

Once the request is sent:

* The API returns a `reportId`.
* You can use this ID to check the status of the report.
* When it's ready, the report will be available for download.

### Why it matters

This approach gives you clarity and control. Each receipt is generated in isolation, using the filters and templates you define.
