What to store in your ERP once FBR answers
Sending an invoice to FBR is half the job. The other half is saving FBR’s answer with the invoice it belongs to. That answer is your proof of filing, your guard against filing twice, and your record for the next six years.

Answer first. The sure test for “filed” is simple: FBR returned an invoice number that isn’t blank, and no line came back with an error. Save that number with the invoice in your own system. Save the line-by-line results, a status and the time with it. Save the exact invoice data you sent, and FBR’s reply exactly as it arrived. From then on, treat the invoice as locked. FBR’s API cannot edit or cancel a filed invoice, so changing it in your system changes nothing at FBR. And if an invoice’s reply never arrived, find out whether FBR has it before you send it again. FBR will happily accept the same invoice twice.
When an invoice is actually filed
FBR’s rejections don’t look like failures at first glance. FBR sends a success reply (HTTP 200) whether it accepted the invoice or not. The real answer sits inside the reply. It can be trickier still: FBR’s own documents show an invoice marked as accepted overall while one line underneath is rejected. If you only check that the call worked, rejected invoices will quietly be marked as done.
So build around one rule: a non-blank FBR invoice number plus a clean result on every line. Treat everything else as a failure that needs fixing. Show it in a status field that your finance team really looks at.
What to store, field by field
| Store | Why it matters |
|---|---|
| FBR invoice number | The proof of filing, the value behind the QR code, and what a buyer or auditor will ask for |
| Line-by-line results | FBR returns a number or an error for every line; without these, a rejected line is easy to miss |
| Status | Validated, waiting to send, filed, failed, so finance sees at a glance what still needs attention |
| Failure reason | FBR’s error code and message, so the fix goes to the right person: customer and product lists, tax code matching, or the invoice itself |
| Invoice data sent | Exactly what went to FBR, byte for byte, not rebuilt later from today’s customer and product lists |
| FBR’s reply | Exactly what came back, including anything your code didn’t understand at the time |
| Submission time | The FBR number records when FBR accepted the invoice; your own time stamp shows when you sent it |
| Test (sandbox) or live | A test invoice must never be mistaken for a live one |
| Your unique key | If you resend after a network timeout, it shows this is the same invoice, not a new one |
With eInvoicePro, the invoice data sent and FBR’s raw reply are kept for every invoice, and you can fetch them back. A failed invoice can be resent on its own, without resending the rest of its batch. Keep a copy in your own system too, so the record lives where your finance team already works.
Reading the FBR number
The FBR invoice number has a structure worth knowing. It starts with the seller’s registration number, then the letters DI, then a 13-digit time stamp counted in milliseconds. Take FBR’s published example, 7000007DI1747119701593. Its tail works out to 12:01:41 Pakistan time on 13 May 2025, which is when FBR accepted the invoice. That can be later than when you created it. Keep the number as text, exactly as FBR sent it. It is a reference, not a quantity, and it is longer for a seller registered on a CNIC than on an NTN.
The QR code on the printed invoice holds that number and nothing more: no amounts, no buyer. Scanning it only tells you which record to look up at FBR. That is why your system needs to hold the number, not the image.
The invoice that got no answer
A rejection is easy to deal with. The riskier case is an invoice that got no answer at all, because of a timeout or a dropped connection. Sometimes FBR records the invoice but the reply is lost on its way back to you. FBR doesn’t turn away a repeat of an invoice it already holds. So sending it again creates a second live invoice, and cancelling that one uses up part of a limited monthly cancellation allowance.
Two safeguards work together here. First, put a unique key on each invoice you send (an idempotency key; eInvoicePro’s API accepts one). Then, if you resend after a network timeout on your side, it is recognised as the same invoice, not a new one. But that only protects your side of the connection. It cannot make FBR itself turn away duplicates. So for any invoice in an unknown state, the rule is: find out whether FBR has it before sending it again.
Locking the invoice afterwards
From the moment FBR issues its number, FBR’s copy is the one that matters. Its API offers no way to cancel, delete or edit an invoice. Instead, since Sales Tax General Order 01 of 2026 took effect on 30 March 2026, there is a manual route. A valid e-invoice raised by genuine mistake can be cancelled, deleted or edited inside FBR’s own system within 72 hours of being generated. After that, it needs the Commissioner Inland Revenue’s prior approval. None of this can be done from your ERP. There is nothing to automate, line up or batch.
So the invoice in your system should behave the same way. Lock it for editing once it is filed. Send any correction to someone who can make it in FBR’s portal, then record what was done on the invoice. A debit note for a later adjustment is a new document that refers to the original FBR number. It is not an edit to the original. Our guide to correcting or cancelling an FBR invoice covers the rules in detail. It includes one trap: editing a single line means you can never cancel that invoice.
Six years of records
You must keep records for six years, and the rules expect them to show exactly what was sent, as it stood at the time. Printed PDFs struggle to prove that. A copy of the invoice data you sent and FBR’s reply proves it directly, so keep both with the number.
Daily checking is the other half. Your sales tax return’s Annexure-C is filled from the e-invoices FBR has on record. So compare your own sales register with FBR-accepted invoices every day. That catches a missing or duplicated invoice while there is still time to act, not when the return and your books disagree.
Where it goes in your system
Most accounting systems don’t have a field for an FBR invoice number, so you add one. How you add it depends on the system:
- SAP, NetSuite and Business Central support custom fields on the invoice header (a transaction body field in NetSuite, a table extension in Business Central). That is the natural home for the number and status.
- Odoo can hold extra fields on the invoice through a small module, where your hosting allows one.
- QuickBooks Online and Zoho Books offer custom fields on invoices, enough for the number and a status.
- Tally is best left untouched. Keep the FBR record in the service that sends your invoices to FBR, linked to the voucher it belongs to. Don’t save it back into the company file.
Wherever the number lives, print it on the invoice with the QR code. And make sure your team can search for an invoice by your number or by FBR’s.
FAQs
Is the QR code enough on its own? No. The QR code only holds the FBR invoice number. On its own it proves nothing until someone checks that number against FBR’s records. Save the number itself with the invoice.
Can we fix a filed invoice by editing it in our ERP? No. Editing it in your ERP changes nothing at FBR. A genuine mistake is corrected in FBR’s own system within 72 hours of the invoice being generated, and with the Commissioner’s approval after that.
Why keep the invoice data sent if we have the FBR number? Because the rules ask for a record that can re-create the information as it was when sent. Your customer and product lists change. A copy of exactly what you sent, and exactly what FBR returned, does not.
What should happen when FBR rejects one line of a multi-line invoice? The invoice is not filed. Fix the cause, such as an HS code, unit or sale type on that item, and resend the whole invoice. Treat it as failed until every line comes back clean.
Does a unique key on each invoice stop FBR filing an invoice twice? It stops your own resends after a network timeout from creating a duplicate on your side. It cannot make FBR itself reject duplicates. So check before resending any invoice whose outcome is unknown.
Related reading: how FBR digital invoicing works, correcting an FBR invoice and the eInvoicePro API.
Ready to simplify your FBR digital invoicing?
Join 2000+ businesses that use eInvoicePro to make invoices and send them to FBR.