---
title: "Oznacz fakturę VAT jako opłaconą asynchronicznie"
description: "Zakres: `api:invoices:write`. Dodaje do kolejki oznaczenie faktury VAT jako opłaconej."
---

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

Path: inFakt API › Faktury VAT

`POST /async/invoices/{uuid}/paid.json`

Zakres: `api:invoices:write`. Dodaje do kolejki oznaczenie faktury VAT jako opłaconej.

## Authentication

Requires one of the following:

- `ApiKey`, apiKey, in header, header `X-inFakt-ApiKey`
- `Token`, apiKey, in header, header `X-Token`

## Path parameters

- `uuid` (`Invoices_markPaidAsync.path.uuid`; string, required)
  - format `uuid`

## Query parameters

- `allow_correction` (`Invoices_markPaidAsync.query.allow_correction`; boolean, optional) — Potwierdź akcję, która skoryguje złożone deklaracje (zamknięty okres księgowy). Bez tego takie żądania zwracają `422` z `errors.allow_correction` albo `errors.locked_accounting`, gdy plan nie pozwala na korekty (wtedy ta flaga jest ignorowana). Można też podać w treści żądania.

## Request body

_Required._

- `paid_date` (`Invoices_markPaidAsync.paid_date`; string, optional) — Domyślnie dzisiejsza data.
  - format `date`
- `allow_correction` (`Invoices_markPaidAsync.allow_correction`; boolean, optional) — Działa jak parametr zapytania `allow_correction`.

## Example requests

### Zadanie przyjęte

```json
{
  "paid_date": "2026-10-10"
}
```

## Code samples

### cURL

```bash
curl --request POST \
  --url https://api.sandbox-infakt.pl/v3/async/invoices/9bdc76fd-7a02-42ec-a4a3-42bc867b9a9f/paid.json \
  --header 'Content-Type: application/json' \
  --header 'X-inFakt-ApiKey: <X-inFakt-ApiKey>' \
  --data '
{
  "paid_date": "2026-10-10"
}
'
```

### TypeScript

```typescript
const url = 'https://api.sandbox-infakt.pl/v3/async/invoices/9bdc76fd-7a02-42ec-a4a3-42bc867b9a9f/paid.json';
const options = {
  method: 'POST',
  headers: {'Content-Type': 'application/json', 'X-inFakt-ApiKey': '<X-inFakt-ApiKey>'},
  body: JSON.stringify({paid_date: '2026-10-10'})
};

fetch(url, options)
  .then(res => res.json())
  .then(json => console.log(json))
  .catch(err => console.error(err));
```

### Python

```python
import requests

url = "https://api.sandbox-infakt.pl/v3/async/invoices/9bdc76fd-7a02-42ec-a4a3-42bc867b9a9f/paid.json"

payload = { "paid_date": "2026-10-10" }
headers = {
    "Content-Type": "application/json",
    "X-inFakt-ApiKey": "<X-inFakt-ApiKey>"
}

response = requests.post(url, json=payload, headers=headers)

print(response.text)
```

## Responses

### 201

Utworzono

#### Example

```json
{
  "invoice_task_reference_number": "5a7b9d2f-3c4e-4f60-8b8c-9d0e1f2a3b4c",
  "processing_code": 100,
  "processing_description": "Zlecenie przyjęte",
  "action": "mark_as_paid",
  "invoice_kind": "invoice",
  "invoice_uuid": "9bdc76fd-7a02-42ec-a4a3-42bc867b9a9f",
  "timestamps": {
    "task_created_at": "2026-10-02 12:05:00 +0200"
  }
}
```

- `invoice_task_reference_number` (`Invoices_markPaidAsync.response.201.invoice_task_reference_number`; string, required) — Uuid zadania; użyj go w endpoincie statusu.
  - format `uuid`
- `processing_code` (`Invoices_markPaidAsync.response.201.processing_code`; integer, required) — `100` zainicjowane, `120` oczekuje, `140` w trakcie, `201` faktura utworzona, `200` akcja wykonana, `422` błąd (zobacz `invoice_errors`).
  - format `int32`
- `action` (`Invoices_markPaidAsync.response.201.action`; string, required) — `create_invoice` albo `mark_as_paid`.
  - one of `"create_invoice"`, `"mark_as_paid"`
- `timestamps` (`Invoices_markPaidAsync.response.201.timestamps`; object, required)
  - `task_created_at` (`Invoices_markPaidAsync.response.201.timestamps.task_created_at`; string, required)
- `processing_description` (`Invoices_markPaidAsync.response.201.processing_description`; string, optional)
- `invoice_kind` (`Invoices_markPaidAsync.response.201.invoice_kind`; string, optional)
- `invoice_errors` (`Invoices_markPaidAsync.response.201.invoice_errors`; any of, optional) — Błędy, gdy `processing_code` to `422`: błędy pól według nazwy pola w API (lista albo pojedynczy komunikat, np. `{"status": "Faktura już została oznaczona jako zapłacona."}`) albo zwykły komunikat przy nieoczekiwanych błędach.
  - any of: `object`, `string`
- `invoice_uuid` (`Invoices_markPaidAsync.response.201.invoice_uuid`; string, optional) — Ustawiane, gdy faktura już istnieje.
  - format `uuid`

### 401

Brak klucza API, nieprawidłowy klucz albo klucz bez wymaganego zakresu uprawnień.

#### Example

```json
{
  "error": "Zasób którego szukasz nie został znaleziony."
}
```

- `error` (`Invoices_markPaidAsync.response.401.error`; any of, optional) — Komunikat po polsku (po angielsku dla `429`). Niektóre akcje zamiast jednego tekstu zwracają listę komunikatów albo błędy walidacji według pól.
  - any of: `string`, `array<string>`, `object`
- `errors` (`Invoices_markPaidAsync.response.401.errors`; any of, optional) — Błędy walidacji według nazw pól API; na niektórych endpointach zwykły komunikat.
  - any of: `object`, `string`
- `limit` (`Invoices_markPaidAsync.response.401.limit`; string, optional) — Kod limitu planu, np. `limit_exceeded`, `plan_upgrade_needed`, `cant_add_client`.
- `type` (`Invoices_markPaidAsync.response.401.type`; string, optional)
  - one of `"redirect"`, `"email_not_confirmed"`
- `url` (`Invoices_markPaidAsync.response.401.url`; string, optional)
- `action_url` (`Invoices_markPaidAsync.response.401.action_url`; string, optional)

### 402

API niedostępne w obecnym planie (`limit: plan_upgrade_needed`) albo osiągnięty limit dokumentów.

#### Example

```json
{
  "error": "Zasób którego szukasz nie został znaleziony."
}
```

- `error` (`Invoices_markPaidAsync.response.402.error`; any of, optional) — Komunikat po polsku (po angielsku dla `429`). Niektóre akcje zamiast jednego tekstu zwracają listę komunikatów albo błędy walidacji według pól.
  - any of: `string`, `array<string>`, `object`
- `errors` (`Invoices_markPaidAsync.response.402.errors`; any of, optional) — Błędy walidacji według nazw pól API; na niektórych endpointach zwykły komunikat.
  - any of: `object`, `string`
- `limit` (`Invoices_markPaidAsync.response.402.limit`; string, optional) — Kod limitu planu, np. `limit_exceeded`, `plan_upgrade_needed`, `cant_add_client`.
- `type` (`Invoices_markPaidAsync.response.402.type`; string, optional)
  - one of `"redirect"`, `"email_not_confirmed"`
- `url` (`Invoices_markPaidAsync.response.402.url`; string, optional)
- `action_url` (`Invoices_markPaidAsync.response.402.action_url`; string, optional)

### 404

Nie znaleziono zasobu.

#### Example

```json
{
  "error": "Zasób którego szukasz nie został znaleziony."
}
```

- `error` (`Invoices_markPaidAsync.response.404.error`; any of, optional) — Komunikat po polsku (po angielsku dla `429`). Niektóre akcje zamiast jednego tekstu zwracają listę komunikatów albo błędy walidacji według pól.
  - any of: `string`, `array<string>`, `object`
- `errors` (`Invoices_markPaidAsync.response.404.errors`; any of, optional) — Błędy walidacji według nazw pól API; na niektórych endpointach zwykły komunikat.
  - any of: `object`, `string`
- `limit` (`Invoices_markPaidAsync.response.404.limit`; string, optional) — Kod limitu planu, np. `limit_exceeded`, `plan_upgrade_needed`, `cant_add_client`.
- `type` (`Invoices_markPaidAsync.response.404.type`; string, optional)
  - one of `"redirect"`, `"email_not_confirmed"`
- `url` (`Invoices_markPaidAsync.response.404.url`; string, optional)
- `action_url` (`Invoices_markPaidAsync.response.404.action_url`; string, optional)

### 406

Ścieżka nie kończy się na `.json`.

#### Example

```json
{
  "error": "Zasób którego szukasz nie został znaleziony."
}
```

- `error` (`Invoices_markPaidAsync.response.406.error`; any of, optional) — Komunikat po polsku (po angielsku dla `429`). Niektóre akcje zamiast jednego tekstu zwracają listę komunikatów albo błędy walidacji według pól.
  - any of: `string`, `array<string>`, `object`
- `errors` (`Invoices_markPaidAsync.response.406.errors`; any of, optional) — Błędy walidacji według nazw pól API; na niektórych endpointach zwykły komunikat.
  - any of: `object`, `string`
- `limit` (`Invoices_markPaidAsync.response.406.limit`; string, optional) — Kod limitu planu, np. `limit_exceeded`, `plan_upgrade_needed`, `cant_add_client`.
- `type` (`Invoices_markPaidAsync.response.406.type`; string, optional)
  - one of `"redirect"`, `"email_not_confirmed"`
- `url` (`Invoices_markPaidAsync.response.406.url`; string, optional)
- `action_url` (`Invoices_markPaidAsync.response.406.action_url`; string, optional)

### 422

Nie utworzono zadania; szczegóły w `errors`.

#### Example

```json
{
  "errors": {}
}
```

- `errors` (`Invoices_markPaidAsync.response.422.errors`; object, required)

### 423

Niepotwierdzony adres e-mail albo wymagana weryfikacja tożsamości.

#### Example

```json
{
  "error": "Zasób którego szukasz nie został znaleziony."
}
```

- `error` (`Invoices_markPaidAsync.response.423.error`; any of, optional) — Komunikat po polsku (po angielsku dla `429`). Niektóre akcje zamiast jednego tekstu zwracają listę komunikatów albo błędy walidacji według pól.
  - any of: `string`, `array<string>`, `object`
- `errors` (`Invoices_markPaidAsync.response.423.errors`; any of, optional) — Błędy walidacji według nazw pól API; na niektórych endpointach zwykły komunikat.
  - any of: `object`, `string`
- `limit` (`Invoices_markPaidAsync.response.423.limit`; string, optional) — Kod limitu planu, np. `limit_exceeded`, `plan_upgrade_needed`, `cant_add_client`.
- `type` (`Invoices_markPaidAsync.response.423.type`; string, optional)
  - one of `"redirect"`, `"email_not_confirmed"`
- `url` (`Invoices_markPaidAsync.response.423.url`; string, optional)
- `action_url` (`Invoices_markPaidAsync.response.423.action_url`; string, optional)

### 429

Przekroczony limit zapytań. Komunikat jest po angielsku, np. `API rate limit exceeded. Try again in 60 seconds.`

#### Example

```json
{
  "error": "Zasób którego szukasz nie został znaleziony."
}
```

- `error` (`Invoices_markPaidAsync.response.429.error`; any of, optional) — Komunikat po polsku (po angielsku dla `429`). Niektóre akcje zamiast jednego tekstu zwracają listę komunikatów albo błędy walidacji według pól.
  - any of: `string`, `array<string>`, `object`
- `errors` (`Invoices_markPaidAsync.response.429.errors`; any of, optional) — Błędy walidacji według nazw pól API; na niektórych endpointach zwykły komunikat.
  - any of: `object`, `string`
- `limit` (`Invoices_markPaidAsync.response.429.limit`; string, optional) — Kod limitu planu, np. `limit_exceeded`, `plan_upgrade_needed`, `cant_add_client`.
- `type` (`Invoices_markPaidAsync.response.429.type`; string, optional)
  - one of `"redirect"`, `"email_not_confirmed"`
- `url` (`Invoices_markPaidAsync.response.429.url`; string, optional)
- `action_url` (`Invoices_markPaidAsync.response.429.action_url`; string, optional)


Source: https://docs.niebieskiorzel.pl/api/invoices-mark-paid-async/index.md
