Lista avansnih slučajeva
get/v1/advance-cases
Scope fiscal:read
Lanci avansa po vremenu poslednje promene, sa filterom stanja (OPEN, CLOSED, FAILED) i pretragom po referenci.
Beleške iz ugovora (OpenAPI, engleski)
Returns tenant-scoped advance chains in most-recently-updated order so an operator can continue a chain without handling an internal identifier. Filters narrow by state, reference text and last change.
Parametri
| Polje | Gde | Tip | Opis |
|---|---|---|---|
taxpayerIdopciono | query | uuid | |
businessPremiseIdopciono | query | uuid | |
stateopciono | query | string | OPEN is every chain still in progress (including unknown-outcome states the operator must resolve); CLOSED and FAILED are terminal.
|
searchopciono | query | string | Case-insensitive substring of the client reference. max 200 |
updatedFromopciono | query | date-time | Only chains changed at or after this instant. Any RFC 3339 offset is accepted and compared as an instant. |
pageSizeopciono | query | integer | >= 1<= 50default 25 |
Primer
curl -X GET "https://api.bokapos.rs/v1/advance-cases?businessPremiseId=b7d4e2c1-9a3f-4c8e-8f21-6e5a0c9d3b22&state=OPEN&search=ORDER-5001" \
-H "Authorization: Bearer $BOKAPOS_TOKEN"Odgovori
| 200 OK | Recent advance chainsAdvanceCasePage |
|---|---|
| 422 Unprocessable Content | The command violates a Boka or fiscal ruleErrorCode |
{
"items": [
{
"id": "c4d5e6f7-a8b9-4c0d-9e1f-2a3b4c5d6e7f",
"taxpayerId": "3f9c2a8e-6b1d-4e5a-9c47-1d2b8e6f0a11",
"businessPremiseId": "b7d4e2c1-9a3f-4c8e-8f21-6e5a0c9d3b22",
"clientReference": "ORDER-5001",
"externalAdvance": null,
"state": "OPEN",
"advanceSales": [],
"cancellations": [],
"cancelledAdvanceSaleIds": [],
"advanceRefund": null,
"finalSale": null,
"failureCode": null,
"createdAt": "2026-09-03T09:00:00.000Z",
"updatedAt": "2026-09-03T09:01:00.700Z"
}
]
}Odgovor: AdvanceCasePage
Opisi polja su preuzeti iz OpenAPI ugovora i na engleskom su; nazivi polja i vrednosti su isti u oba jezika.
| Polje | Tip | Opis |
|---|---|---|
itemsobavezno | array<AdvanceCase> | |
idobavezno | uuid | |
taxpayerIdobavezno | uuid | |
businessPremiseIdobavezno | uuid | |
clientReferenceobavezno | string | |
externalAdvanceopciono | ExternalAdvance| null (može biti null) | |
amountobavezno | number | Sum of every advance collected before eFiscalization; at most two decimals. > 0step 0.01 |
taxLabelobavezno | string | Tax label of the future supply; must be a prescribed advance label. |
paymentTypeobavezno | PaymentType |
|
lastDocumentNumberobavezno | string | Number of the last pre-fiscal advance document, digits only (1 to 20). It is sent as the
`<number>` part of the reference `XXXXXXXX-XXXXXXXX-<number>`; the official examples are
`17`, `121` and `159`, and the V-PFR rejects any other form. Anything but digits returns
422 with the `ExternalAdvance.LastDocumentNumber` validation key.
min 1max 20pattern ^[0-9]{1,20}$ |
lastDocumentTimeobavezno | date-time | Issue date of that document; must precede the request. |
stateobavezno | string |
|
advanceSalesobavezno | array<FiscalDocument> | |
idobavezno | uuid | |
taxpayerIdobavezno | uuid | |
businessPremiseIdobavezno | uuid | |
idempotencyKeyobavezno | string | |
clientReferenceobavezno | string | |
invoiceTypeobavezno | InvoiceType |
|
transactionTypeobavezno | TransactionType |
|
cashierIdobavezno | string | |
buyerIdopciono | string| null (može biti null) | |
buyerDetailsopciono | FiscalBuyerDetails| null (može biti null) | The buyer's company-registry facts stored with the document at reservation and printed under the buyer identification. Null when the buyer is not a domestic company (prefixes 10, 12, 14 with a valid PIB) or the register could not answer at issuance. |
legalNameobavezno | string | max 350 |
taxIdentifierobavezno | string | pattern ^[0-9]{9}$ |
registrationNumberopciono | string| null (može biti null) | pattern ^[0-9]{8}$ |
addressopciono | string| null (može biti null) | max 300 |
cityopciono | string| null (može biti null) | max 100 |
sourceobavezno | string |
|
resolvedAtobavezno | date-time | |
statusobavezno | FiscalDocumentStatus |
|
fiscalizedobavezno | boolean | |
failureCodeopciono | string| null (može biti null) | |
pfrRejectionopciono | object| null (može biti null) | Present only on a single-document read of a REJECTED operation. The V-PFR's own validation result, bounded to the property path of the caller's request and the supplier's numeric codes (2310 invalid tax label; 2800 to 2808 required, length, range, value, format and list-size validation). Lists never carry it. |
itemsobavezno | array<object> | max 10 items |
retryableobavezno | boolean | |
pfropciono | PfrResult| null (može biti null) | |
invoiceNumberobavezno | string | |
sdcTimeobavezno | date-time | |
requestedByobavezno | string | |
signedByobavezno | string | |
transactionTypeCounteropciono | integer| null (može biti null) | V-PFR transaction-type counter (the left half of the printed counter). Null when the stored receipt does not carry it; the printed counter is always in the journal text. |
totalCounteropciono | integer| null (može biti null) | V-PFR total counter (the right half of the printed counter and the last segment of invoiceNumber). Null under the same condition as transactionTypeCounter. |
invoiceCounterExtensionopciono | string| null (može biti null) | Official Cyrillic invoice/transaction type pair printed after the counter (ПП, ПР, АП, АР, КП, КР, ОП, ОР, РП, РР). Null under the same condition as transactionTypeCounter. |
totalAmountobavezno | number | |
totalTaxopciono | number| null (može biti null) | Sum of the V-PFR signed tax amounts of the document (the printed "Укупан износ пореза" before its two-decimal display rounding). Null under the same condition as transactionTypeCounter. |
verificationUrlobavezno | uri | |
journalobavezno | string | |
receiptopciono | ReceiptRepresentations| null (može biti null) | |
textUrlobavezno | uri-reference | |
jsonUrlobavezno | uri-reference | |
pdfA4Urlobavezno | uri-reference | |
pdf80mmUrlobavezno | uri-reference | |
pdf58mmUrlobavezno | uri-reference | |
previewImageUrlobavezno | uri-reference | |
qrImageUrlobavezno | uri-reference | |
verificationUrlobavezno | uri | |
preferredPaperFormatobavezno | string | Immutable preferred print/PDF format captured when this fiscal operation was reserved.
|
referenceopciono | ResolvedReference | |
fiscalDocumentIdopciono | uuid | |
pfrNumberobavezno | string | |
pfrTimeobavezno | date-time | |
createdAtobavezno | date-time | |
updatedAtobavezno | date-time | |
cancellationsobavezno | array<FiscalDocument> | Standalone Advance Refunds that cancelled an erroneous Advance Sale of this case, in issue order. |
idobavezno | uuid | |
taxpayerIdobavezno | uuid | |
businessPremiseIdobavezno | uuid | |
idempotencyKeyobavezno | string | |
clientReferenceobavezno | string | |
invoiceTypeobavezno | InvoiceType |
|
transactionTypeobavezno | TransactionType |
|
cashierIdobavezno | string | |
buyerIdopciono | string| null (može biti null) | |
buyerDetailsopciono | FiscalBuyerDetails| null (može biti null) | The buyer's company-registry facts stored with the document at reservation and printed under the buyer identification. Null when the buyer is not a domestic company (prefixes 10, 12, 14 with a valid PIB) or the register could not answer at issuance. |
legalNameobavezno | string | max 350 |
taxIdentifierobavezno | string | pattern ^[0-9]{9}$ |
registrationNumberopciono | string| null (može biti null) | pattern ^[0-9]{8}$ |
addressopciono | string| null (može biti null) | max 300 |
cityopciono | string| null (može biti null) | max 100 |
sourceobavezno | string |
|
resolvedAtobavezno | date-time | |
statusobavezno | FiscalDocumentStatus |
|
fiscalizedobavezno | boolean | |
failureCodeopciono | string| null (može biti null) | |
pfrRejectionopciono | object| null (može biti null) | Present only on a single-document read of a REJECTED operation. The V-PFR's own validation result, bounded to the property path of the caller's request and the supplier's numeric codes (2310 invalid tax label; 2800 to 2808 required, length, range, value, format and list-size validation). Lists never carry it. |
itemsobavezno | array<object> | max 10 items |
retryableobavezno | boolean | |
pfropciono | PfrResult| null (može biti null) | |
invoiceNumberobavezno | string | |
sdcTimeobavezno | date-time | |
requestedByobavezno | string | |
signedByobavezno | string | |
transactionTypeCounteropciono | integer| null (može biti null) | V-PFR transaction-type counter (the left half of the printed counter). Null when the stored receipt does not carry it; the printed counter is always in the journal text. |
totalCounteropciono | integer| null (može biti null) | V-PFR total counter (the right half of the printed counter and the last segment of invoiceNumber). Null under the same condition as transactionTypeCounter. |
invoiceCounterExtensionopciono | string| null (može biti null) | Official Cyrillic invoice/transaction type pair printed after the counter (ПП, ПР, АП, АР, КП, КР, ОП, ОР, РП, РР). Null under the same condition as transactionTypeCounter. |
totalAmountobavezno | number | |
totalTaxopciono | number| null (može biti null) | Sum of the V-PFR signed tax amounts of the document (the printed "Укупан износ пореза" before its two-decimal display rounding). Null under the same condition as transactionTypeCounter. |
verificationUrlobavezno | uri | |
journalobavezno | string | |
receiptopciono | ReceiptRepresentations| null (može biti null) | |
textUrlobavezno | uri-reference | |
jsonUrlobavezno | uri-reference | |
pdfA4Urlobavezno | uri-reference | |
pdf80mmUrlobavezno | uri-reference | |
pdf58mmUrlobavezno | uri-reference | |
previewImageUrlobavezno | uri-reference | |
qrImageUrlobavezno | uri-reference | |
verificationUrlobavezno | uri | |
preferredPaperFormatobavezno | string | Immutable preferred print/PDF format captured when this fiscal operation was reserved.
|
referenceopciono | ResolvedReference | |
fiscalDocumentIdopciono | uuid | |
pfrNumberobavezno | string | |
pfrTimeobavezno | date-time | |
createdAtobavezno | date-time | |
updatedAtobavezno | date-time | |
cancelledAdvanceSaleIdsobavezno | array<uuid> | Ids of the Advance Sales in `advanceSales` that a fiscalized cancellation removed from the chain. The remaining fiscalized Advance Sales are the effective chain: they are what the next Advance Sale references, what a closure refunds, and what the next cancellation targets. |
advanceRefundopciono | FiscalDocument| null (može biti null) | |
idobavezno | uuid | |
taxpayerIdobavezno | uuid | |
businessPremiseIdobavezno | uuid | |
idempotencyKeyobavezno | string | |
clientReferenceobavezno | string | |
invoiceTypeobavezno | InvoiceType |
|
transactionTypeobavezno | TransactionType |
|
cashierIdobavezno | string | |
buyerIdopciono | string| null (može biti null) | |
buyerDetailsopciono | FiscalBuyerDetails| null (može biti null) | The buyer's company-registry facts stored with the document at reservation and printed under the buyer identification. Null when the buyer is not a domestic company (prefixes 10, 12, 14 with a valid PIB) or the register could not answer at issuance. |
legalNameobavezno | string | max 350 |
taxIdentifierobavezno | string | pattern ^[0-9]{9}$ |
registrationNumberopciono | string| null (može biti null) | pattern ^[0-9]{8}$ |
addressopciono | string| null (može biti null) | max 300 |
cityopciono | string| null (može biti null) | max 100 |
sourceobavezno | string |
|
resolvedAtobavezno | date-time | |
statusobavezno | FiscalDocumentStatus |
|
fiscalizedobavezno | boolean | |
failureCodeopciono | string| null (može biti null) | |
pfrRejectionopciono | object| null (može biti null) | Present only on a single-document read of a REJECTED operation. The V-PFR's own validation result, bounded to the property path of the caller's request and the supplier's numeric codes (2310 invalid tax label; 2800 to 2808 required, length, range, value, format and list-size validation). Lists never carry it. |
itemsobavezno | array<object> | max 10 items |
retryableobavezno | boolean | |
pfropciono | PfrResult| null (može biti null) | |
invoiceNumberobavezno | string | |
sdcTimeobavezno | date-time | |
requestedByobavezno | string | |
signedByobavezno | string | |
transactionTypeCounteropciono | integer| null (može biti null) | V-PFR transaction-type counter (the left half of the printed counter). Null when the stored receipt does not carry it; the printed counter is always in the journal text. |
totalCounteropciono | integer| null (može biti null) | V-PFR total counter (the right half of the printed counter and the last segment of invoiceNumber). Null under the same condition as transactionTypeCounter. |
invoiceCounterExtensionopciono | string| null (može biti null) | Official Cyrillic invoice/transaction type pair printed after the counter (ПП, ПР, АП, АР, КП, КР, ОП, ОР, РП, РР). Null under the same condition as transactionTypeCounter. |
totalAmountobavezno | number | |
totalTaxopciono | number| null (može biti null) | Sum of the V-PFR signed tax amounts of the document (the printed "Укупан износ пореза" before its two-decimal display rounding). Null under the same condition as transactionTypeCounter. |
verificationUrlobavezno | uri | |
journalobavezno | string | |
receiptopciono | ReceiptRepresentations| null (može biti null) | |
textUrlobavezno | uri-reference | |
jsonUrlobavezno | uri-reference | |
pdfA4Urlobavezno | uri-reference | |
pdf80mmUrlobavezno | uri-reference | |
pdf58mmUrlobavezno | uri-reference | |
previewImageUrlobavezno | uri-reference | |
qrImageUrlobavezno | uri-reference | |
verificationUrlobavezno | uri | |
preferredPaperFormatobavezno | string | Immutable preferred print/PDF format captured when this fiscal operation was reserved.
|
referenceopciono | ResolvedReference | |
fiscalDocumentIdopciono | uuid | |
pfrNumberobavezno | string | |
pfrTimeobavezno | date-time | |
createdAtobavezno | date-time | |
updatedAtobavezno | date-time | |
finalSaleopciono | FiscalDocument| null (može biti null) | |
idobavezno | uuid | |
taxpayerIdobavezno | uuid | |
businessPremiseIdobavezno | uuid | |
idempotencyKeyobavezno | string | |
clientReferenceobavezno | string | |
invoiceTypeobavezno | InvoiceType |
|
transactionTypeobavezno | TransactionType |
|
cashierIdobavezno | string | |
buyerIdopciono | string| null (može biti null) | |
buyerDetailsopciono | FiscalBuyerDetails| null (može biti null) | The buyer's company-registry facts stored with the document at reservation and printed under the buyer identification. Null when the buyer is not a domestic company (prefixes 10, 12, 14 with a valid PIB) or the register could not answer at issuance. |
legalNameobavezno | string | max 350 |
taxIdentifierobavezno | string | pattern ^[0-9]{9}$ |
registrationNumberopciono | string| null (može biti null) | pattern ^[0-9]{8}$ |
addressopciono | string| null (može biti null) | max 300 |
cityopciono | string| null (može biti null) | max 100 |
sourceobavezno | string |
|
resolvedAtobavezno | date-time | |
statusobavezno | FiscalDocumentStatus |
|
fiscalizedobavezno | boolean | |
failureCodeopciono | string| null (može biti null) | |
pfrRejectionopciono | object| null (može biti null) | Present only on a single-document read of a REJECTED operation. The V-PFR's own validation result, bounded to the property path of the caller's request and the supplier's numeric codes (2310 invalid tax label; 2800 to 2808 required, length, range, value, format and list-size validation). Lists never carry it. |
itemsobavezno | array<object> | max 10 items |
retryableobavezno | boolean | |
pfropciono | PfrResult| null (može biti null) | |
invoiceNumberobavezno | string | |
sdcTimeobavezno | date-time | |
requestedByobavezno | string | |
signedByobavezno | string | |
transactionTypeCounteropciono | integer| null (može biti null) | V-PFR transaction-type counter (the left half of the printed counter). Null when the stored receipt does not carry it; the printed counter is always in the journal text. |
totalCounteropciono | integer| null (može biti null) | V-PFR total counter (the right half of the printed counter and the last segment of invoiceNumber). Null under the same condition as transactionTypeCounter. |
invoiceCounterExtensionopciono | string| null (može biti null) | Official Cyrillic invoice/transaction type pair printed after the counter (ПП, ПР, АП, АР, КП, КР, ОП, ОР, РП, РР). Null under the same condition as transactionTypeCounter. |
totalAmountobavezno | number | |
totalTaxopciono | number| null (može biti null) | Sum of the V-PFR signed tax amounts of the document (the printed "Укупан износ пореза" before its two-decimal display rounding). Null under the same condition as transactionTypeCounter. |
verificationUrlobavezno | uri | |
journalobavezno | string | |
receiptopciono | ReceiptRepresentations| null (može biti null) | |
textUrlobavezno | uri-reference | |
jsonUrlobavezno | uri-reference | |
pdfA4Urlobavezno | uri-reference | |
pdf80mmUrlobavezno | uri-reference | |
pdf58mmUrlobavezno | uri-reference | |
previewImageUrlobavezno | uri-reference | |
qrImageUrlobavezno | uri-reference | |
verificationUrlobavezno | uri | |
preferredPaperFormatobavezno | string | Immutable preferred print/PDF format captured when this fiscal operation was reserved.
|
referenceopciono | ResolvedReference | |
fiscalDocumentIdopciono | uuid | |
pfrNumberobavezno | string | |
pfrTimeobavezno | date-time | |
createdAtobavezno | date-time | |
updatedAtobavezno | date-time | |
failureCodeopciono | string| null (može biti null) | |
createdAtobavezno | date-time | |
updatedAtobavezno | date-time |