---
title: "Sprawdź status zadania asynchronicznego"
description: "Zakres: `api:invoices:read`. Status zadania utworzonego przez dowolny endpoint `POST /async/{kind}`."
---

> 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 › Zadania asynchroniczne

`GET /async/{kind}/status/{invoice_task_reference_number}.json`

Zakres: `api:invoices:read`. Status zadania utworzonego przez dowolny endpoint `POST /async/{kind}`.

## Authentication

Requires one of the following:

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

## Path parameters

- `kind` (`AsyncTasks_getStatus.path.kind`; string, required)
  - one of `"invoices"`, `"margin_invoices"`, `"advance_invoices"`, `"final_invoices"`, `"internal_evidences"`, `"internal_invoices"`, `"fiscal_reports"`, `"corrective_invoices"`, `"oss_invoices"`, `"corrective_oss_invoices"`, `"daily_revenues"`, `"corrective_margin_invoices"`
- `invoice_task_reference_number` (`AsyncTasks_getStatus.path.invoice_task_reference_number`; string, required)
  - format `uuid`

## Code samples

### cURL

```bash
curl --request GET \
  --url https://api.sandbox-infakt.pl/v3/async/invoices/status/4f6a8c1e-2b3d-4e5f-9a7b-8c9d0e1f2a3b.json \
  --header 'X-inFakt-ApiKey: <X-inFakt-ApiKey>'
```

### TypeScript

```typescript
const url = 'https://api.sandbox-infakt.pl/v3/async/invoices/status/4f6a8c1e-2b3d-4e5f-9a7b-8c9d0e1f2a3b.json';
const options = {method: 'GET', headers: {'X-inFakt-ApiKey': '<X-inFakt-ApiKey>'}};

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/status/4f6a8c1e-2b3d-4e5f-9a7b-8c9d0e1f2a3b.json"

headers = {"X-inFakt-ApiKey": "<X-inFakt-ApiKey>"}

response = requests.get(url, headers=headers)

print(response.text)
```

## Responses

### 200

Sukces

#### Example

```json
{
  "invoice_task_reference_number": "4f6a8c1e-2b3d-4e5f-9a7b-8c9d0e1f2a3b",
  "processing_code": 201,
  "processing_description": "Faktura stworzona",
  "action": "create_invoice",
  "invoice_kind": "invoice",
  "invoice_uuid": "9bdc76fd-7a02-42ec-a4a3-42bc867b9a9f",
  "timestamps": {
    "task_created_at": "2026-10-02 12:00:00 +0200"
  }
}
```

- `invoice_task_reference_number` (`AsyncTasks_getStatus.response.200.invoice_task_reference_number`; string, required) — Uuid zadania; użyj go w endpoincie statusu.
  - format `uuid`
- `processing_code` (`AsyncTasks_getStatus.response.200.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` (`AsyncTasks_getStatus.response.200.action`; string, required) — `create_invoice` albo `mark_as_paid`.
  - one of `"create_invoice"`, `"mark_as_paid"`
- `timestamps` (`AsyncTasks_getStatus.response.200.timestamps`; object, required)
  - `task_created_at` (`AsyncTasks_getStatus.response.200.timestamps.task_created_at`; string, required)
- `processing_description` (`AsyncTasks_getStatus.response.200.processing_description`; string, optional)
- `invoice_kind` (`AsyncTasks_getStatus.response.200.invoice_kind`; string, optional)
- `invoice_errors` (`AsyncTasks_getStatus.response.200.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` (`AsyncTasks_getStatus.response.200.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` (`AsyncTasks_getStatus.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` (`AsyncTasks_getStatus.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` (`AsyncTasks_getStatus.response.401.limit`; string, optional) — Kod limitu planu, np. `limit_exceeded`, `plan_upgrade_needed`, `cant_add_client`.
- `type` (`AsyncTasks_getStatus.response.401.type`; string, optional)
  - one of `"redirect"`, `"email_not_confirmed"`
- `url` (`AsyncTasks_getStatus.response.401.url`; string, optional)
- `action_url` (`AsyncTasks_getStatus.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` (`AsyncTasks_getStatus.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` (`AsyncTasks_getStatus.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` (`AsyncTasks_getStatus.response.402.limit`; string, optional) — Kod limitu planu, np. `limit_exceeded`, `plan_upgrade_needed`, `cant_add_client`.
- `type` (`AsyncTasks_getStatus.response.402.type`; string, optional)
  - one of `"redirect"`, `"email_not_confirmed"`
- `url` (`AsyncTasks_getStatus.response.402.url`; string, optional)
- `action_url` (`AsyncTasks_getStatus.response.402.action_url`; string, optional)

### 404

Nie znaleziono zasobu.

#### Example

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

- `error` (`AsyncTasks_getStatus.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` (`AsyncTasks_getStatus.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` (`AsyncTasks_getStatus.response.404.limit`; string, optional) — Kod limitu planu, np. `limit_exceeded`, `plan_upgrade_needed`, `cant_add_client`.
- `type` (`AsyncTasks_getStatus.response.404.type`; string, optional)
  - one of `"redirect"`, `"email_not_confirmed"`
- `url` (`AsyncTasks_getStatus.response.404.url`; string, optional)
- `action_url` (`AsyncTasks_getStatus.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` (`AsyncTasks_getStatus.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` (`AsyncTasks_getStatus.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` (`AsyncTasks_getStatus.response.406.limit`; string, optional) — Kod limitu planu, np. `limit_exceeded`, `plan_upgrade_needed`, `cant_add_client`.
- `type` (`AsyncTasks_getStatus.response.406.type`; string, optional)
  - one of `"redirect"`, `"email_not_confirmed"`
- `url` (`AsyncTasks_getStatus.response.406.url`; string, optional)
- `action_url` (`AsyncTasks_getStatus.response.406.action_url`; string, optional)

### 423

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

#### Example

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

- `error` (`AsyncTasks_getStatus.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` (`AsyncTasks_getStatus.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` (`AsyncTasks_getStatus.response.423.limit`; string, optional) — Kod limitu planu, np. `limit_exceeded`, `plan_upgrade_needed`, `cant_add_client`.
- `type` (`AsyncTasks_getStatus.response.423.type`; string, optional)
  - one of `"redirect"`, `"email_not_confirmed"`
- `url` (`AsyncTasks_getStatus.response.423.url`; string, optional)
- `action_url` (`AsyncTasks_getStatus.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` (`AsyncTasks_getStatus.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` (`AsyncTasks_getStatus.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` (`AsyncTasks_getStatus.response.429.limit`; string, optional) — Kod limitu planu, np. `limit_exceeded`, `plan_upgrade_needed`, `cant_add_client`.
- `type` (`AsyncTasks_getStatus.response.429.type`; string, optional)
  - one of `"redirect"`, `"email_not_confirmed"`
- `url` (`AsyncTasks_getStatus.response.429.url`; string, optional)
- `action_url` (`AsyncTasks_getStatus.response.429.action_url`; string, optional)


Source: https://docs.niebieskiorzel.pl/api/async-tasks-get-status/index.md
