- Is the whole receipt content sent, or only the total amount?
- The whole content, per line: name, code, quantity, unit of measure, price with VAT and tax rate for each line separately. The total is not sent, Tezga calculates it from the lines, so the sum and the lines can never disagree. One receipt carries up to 500 lines. If the code exists in Tezga's catalogue, the line is linked to that item, so the report by item works for web sales too.
- How do discounts and promo codes from the shop show on the fiscal receipt?
- As a discount, not as a hidden price. On /order you send popustProcenat or popustRsd per line, and popustProcenat or popustRsd on the whole receipt (only one field per level). Tezga spreads a whole-receipt discount across the lines in proportion to the base, just as in the app, so VAT by tax rate stays correct, and the remaining penny goes to the largest line. When a line carries a code from Tezga's catalogue, send cenaIzZahteva:true: then the price and discount from the request apply, and the name, unit of measure and rate come from the catalogue. Web shop connections (WooCommerce, Shopify, PrestaShop, OpenCart, Magento, BigCommerce) always fiscalize the price the customer paid. A discount larger than the amount, two fields at the same level, and a discount together with a catalogue code without cenaIzZahteva return 422.
- How are the 20 and 10 percent rates recorded when the cart is mixed?
- Each line carries its own rate, so a mixed cart is not a special case. Tezga works with the Tax Administration's three tax labels: Ђ for 20 percent, Е for 10 percent and А for exempt. In the API you send the rate as 20, 10, 0 or pdv20, pdv10, oslobodjeno; for the web shop connector you set up a mapping of the shop's tax class to one of those three. An empty rate is read as 20 percent, never as exempt, and an unknown value returns an error instead of a wrong receipt. A zero from the platform is not treated as exempt for a VAT payer.
- Does the system recognise whether the customer is a private individual or a company?
- By the tax ID (PIB). If a PIB arrives with the order, the customer is recorded as a company: the fiscal receipt carries the customer identification 10:PIB, and the customer is found or created in the register by their PIB. Without a PIB the receipt is retail. The connectors take the PIB from the platform's fields: Magento from customer_taxvat, PrestaShop from siret, WooCommerce from the meta field for PIB or VAT, Shopify from the order note in the form PIB: 123456789. From your own system you simply send it in the field kupac.pib.
- Does a B2B receipt from the web shop also go to SEF, or does the ERP do that?
- It can go from Tezga. For an order with a PIB, the fiskalni_i_sef flow issues a fiscal receipt and sends the same document to SEF as an e-invoice, with the fiscal PFR number as a reference on the invoice. The sef flow sends only the e-invoice, without fiscalization. The condition is that the company has its own SEF API key in Settings; without it the document gets the status not connected and waits. A public-sector buyer with a JBKJS cannot go into the fiscal flow, because they are issued exclusively an e-invoice.
- How does an advance invoice work when the customer pays by card up front?
- Through the dedicated address /api/integrations/advance: you send the advance amount, the payment date, the rate and the customer, and Tezga issues an advance invoice. When you deliver the goods, the same call with zatvori:true and the real lines issues a refund of the advance and then the final invoice, with a reference to the advance that the regulation requires. If the refund of the advance does not go through at the Tax Administration, the final invoice is not issued, so no duplicate turnover arises. A web order paid in advance can also go through /order with tok:"avans" (and an optional datumUplate): an advance invoice is created for the order total after the discount, and it is closed with the same /advance call with zatvori:true and the same externalId. That works for an order with a single tax rate; mixed rates return 422 with instructions for /advance. For an order that is paid and delivered at once no advance is needed: a single call to /order.
- Does a partial refund work, for example one of three items?
- It does. POST /api/integrations/refund with vrsta:refundacija and a list of lines with quantities returns only those lines, and the amount is calculated in proportion to the original and reduced by whatever was returned earlier. A cancellation (storno) is always the whole receipt. A refund carries the number and time of the original receipt in the PFR, so the link is visible to the Tax Administration too. The original is found by Tezga's documentId or by your order number.
- How is an order cancelled when the customer backs out, from the ERP or from the shop?
- From the ERP with a single call to /api/integrations/refund by order number. From Tezga with a button on the order: a fiscal cancellation or refund is issued, the order gets the status refunded, and a refund record and a note are written into WooCommerce, a note into Shopify. The money is not returned to the customer automatically, that stays with your payment provider. A cancellation and a refund issued through the API, once they go through at the Tax Administration, trigger a webhook with the order number; actions from the register do not send an event, so the ERP reads them through GET documents.