---
title: "Pobierz plik JPK V7"
description: "Zakres: `api:accounting:read`."
---

> 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 › JPK V7

`GET /saf_v7_files/{id}.json`

Zakres: `api:accounting:read`.

## Authentication

Requires one of the following:

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

## Path parameters

- `id` (`JpkV7Files_get.path.id`; integer, required)
  - format `int64`

## Query parameters

- `fields` (`JpkV7Files_get.query.fields`; string, optional) — Zawężenie pól: nazwy pól API rozdzielone przecinkami, np. `id,company_name`; `id` jest zwykle dodawane. Odpowiedź zawiera wtedy tylko te pola, więc nie odpowiada pełnemu schematowi. Pola wyliczane, a nie zapisywane, mogą kończyć się błędem `500`; operacja je wymienia.

## Header parameters

- `X-inFakt-ApiVersion` (`JpkV7Files_get.header.X-inFakt-ApiVersion`; string, optional) — `3.1` zwraca status deklaracji `sent` zamiast `printed`.
  - one of `"3.1"`

## Code samples

### cURL

```bash
curl --request GET \
  --url https://api.sandbox-infakt.pl/v3/saf_v7_files/12.json \
  --header 'X-inFakt-ApiKey: <X-inFakt-ApiKey>'
```

### TypeScript

```typescript
const url = 'https://api.sandbox-infakt.pl/v3/saf_v7_files/12.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/saf_v7_files/12.json"

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

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

print(response.text)
```

## Responses

### 200

Sukces

#### Example

```json
{
  "id": 12,
  "uuid": "4c3b2a1d-0e9f-4a8b-9c7d-6e5f4a3b2c1d",
  "symbol": "JPK-V7M",
  "period": "2026-09-01",
  "period_name": "Wrzesień 2026",
  "correction_counter": 0,
  "payment_date": "2026-10-25",
  "tax_to_pay_price": 184000,
  "real_pay": 184000,
  "status": "draft",
  "tax_office": {
    "info": "",
    "name": "Urząd Skarbowy",
    "bank_name": "Narodowy Bank Polski",
    "account_number": "36101010100000000000000000"
  },
  "extensions": {
    "payments": {
      "enabled": false,
      "reason": "Płatność w trakcie przetwarzania",
      "pragma_offer_details_link": null
    }
  }
}
```

- `id` (`JpkV7Files_get.response.200.id`; integer, required)
  - format `int64`
- `uuid` (`JpkV7Files_get.response.200.uuid`; any of, required)
  - any of: `Uuid`, `null`
- `symbol` (`JpkV7Files_get.response.200.symbol`; string, required) — `JPK-V7M` lub `JPK-V7K`.
- `period` (`JpkV7Files_get.response.200.period`; string, required)
  - format `date`
- `period_name` (`JpkV7Files_get.response.200.period_name`; string, required)
- `correction_counter` (`JpkV7Files_get.response.200.correction_counter`; integer, required)
  - format `int32`
- `payment_date` (`JpkV7Files_get.response.200.payment_date`; string, required)
  - format `date`
- `tax_to_pay_price` (`JpkV7Files_get.response.200.tax_to_pay_price`; any of, required) — `null`, gdy plik nie ma części deklaracyjnej VAT.
  - any of: `Money`, `null`
- `real_pay` (`JpkV7Files_get.response.200.real_pay`; any of, required)
  - any of: `Money`, `null`
- `status` (`JpkV7Files_get.response.200.status`; string, required) — Status deklaracji: `draft`, `printed`, `sent` lub `paid`. `sent` jest zwracany tylko z nagłówkiem `X-inFakt-ApiVersion: 3.1`, w przeciwnym razie jako `printed`.
- `extensions` (`JpkV7Files_get.response.200.extensions`; object, required)
  - `payments` (`JpkV7Files_get.response.200.extensions.payments`; object, required) — Płatność online podatku w aplikacji inFakt.
    - `enabled` (`JpkV7Files_get.response.200.extensions.payments.enabled`; boolean, required) — `true`, gdy podatek można teraz zapłacić online.
    - `pragma_offer_details_link` (`JpkV7Files_get.response.200.extensions.payments.pragma_offer_details_link`; null, required)
    - `reason` (`JpkV7Files_get.response.200.extensions.payments.reason`; string, optional) — Powód niedostępności płatności online, np. `Płatność w trakcie przetwarzania`; tylko przy `enabled: false`.
    - `webview` (`JpkV7Files_get.response.200.extensions.payments.webview`; object, optional) — Przy `enabled: true`.
      - `link` (`JpkV7Files_get.response.200.extensions.payments.webview.link`; string, required) — Strona płatności online.
      - `pid` (`JpkV7Files_get.response.200.extensions.payments.webview.pid`; string, required) — Identyfikator płatności bez znaczenia dla klienta API.
    - `link` (`JpkV7Files_get.response.200.extensions.payments.link`; string, optional) — Strona płatności online; przy `enabled: true`.
    - `pid` (`JpkV7Files_get.response.200.extensions.payments.pid`; string, optional) — Przy `enabled: true`.
    - `amount` (`JpkV7Files_get.response.200.extensions.payments.amount`; integer, optional) — Kwota do zapłaty; przy `enabled: true`.
      - format `int64`
    - `fee` (`JpkV7Files_get.response.200.extensions.payments.fee`; integer, optional) — Opłata za płatność; przy `enabled: true`.
      - format `int64`
- `tax_office` (`JpkV7Files_get.response.200.tax_office`; object, optional) — Obecne, gdy przypisano urząd skarbowy dla VAT.
  - `info` (`JpkV7Files_get.response.200.tax_office.info`; string, required) — Podpowiedź wyświetlana, gdy brakuje numeru rachunku podatkowego; w przeciwnym razie `""`.
  - `name` (`JpkV7Files_get.response.200.tax_office.name`; string, required)
  - `bank_name` (`JpkV7Files_get.response.200.tax_office.bank_name`; string, required)
  - `account_number` (`JpkV7Files_get.response.200.tax_office.account_number`; any of, required) — Indywidualny rachunek podatkowy (mikrorachunek).
    - any of: `string`, `null`
- `esaf_request` (`JpkV7Files_get.response.200.esaf_request`; object, optional) — Obecne po wysłaniu pliku elektronicznie.
  - `status` (`JpkV7Files_get.response.200.esaf_request.status`; string, required)
  - `shippment_date` (`JpkV7Files_get.response.200.esaf_request.shippment_date`; string, required)
    - format `date`
  - `description` (`JpkV7Files_get.response.200.esaf_request.description`; any of, required)
    - any of: `string`, `null`

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

### 403

Brak uprawnień, limit planu dla tej akcji (`limit`) albo zawieszone konto.

#### Example

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

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

### 404

Nie znaleziono zasobu.

#### Example

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

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


Source: https://docs.niebieskiorzel.pl/api/jpk-v7-files-get/index.md
