---
title: "Preview a payments file"
description: "Other routes API"
---

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

# Preview a payments file

{/* Generated by apps/docs/scripts/generate.ts from contracts/api/openapi.yaml. Do not edit. */}
<div class="cvo-op">
<div class="cvo-op-main">

<div class="cvo-op-header">
<div class="cvo-op-path-row">
<span class="cvo-method" data-method="post">POST</span>
<code class="cvo-op-path-code">/v1/data-files/payments/previews</code>
</div>
</div>

Reads a payments file (CSV, Excel or JSON) and says what importing it would do, row by row. Nothing is written. A row names a sent invoice by its `invoiceNumber`: of several versions, the newest. A received invoice is never named. `paidDate` is a day as `2026-10-31` or `31.10.2026`. Each row is `new` (the invoice will be marked paid), `same` (it is paid already) or `invalid`: no sent invoice has the number, several do, the day is missing or no day, or the file names the invoice twice. A row marks the whole invoice paid; there are no part payments. `basedOn` is a fingerprint of the paid invoices; send it with the import.

## Request body

`application/json`, required

## Response

A `200` answer carries these fields.

## Status codes

| Status | Meaning |
|---|---|
| `200` | What the file would do. |
| `400` | The body was refused, or the file is no payments file (`invalid_data_file`, `invalid_json`). Nothing was read. |
| `401` | No usable credential was sent (`invalid_credentials`). |
| `501` |  |
| `502` | The engine could not run, so nothing was read (`engine_unavailable`). |

</div>
<div class="cvo-op-aside">

</div>
</div>

Source: https://docs.certinvo.com/reference/api/other/preview-a-payments-file/index.mdx
