PRAL Digital Invoicing guide, in simple words
A short summary of what the official PRAL documents say, so you do not have to read more than 100 pages. Read it in Urdu or English with the language button.
This page is our own plain-language summary. It is not an official PRAL or FBR document and may become old. When in doubt, check the official PRAL documents or ask PRAL support (dicrm.pral.com.pk).
Based on these PRAL documents
- Digital Invoicing User Manual v1.6 · 16 Apr 2026
Registration, sandbox, production, fixing invoices, support portal - Technical Specification for DI API v1.12 · 24 Jul 2025
Web addresses, JSON fields, replies, reference lists, QR code, scenarios - Error Message Guide (Sales) Sale module
Cause and action for every sale error code - Digital Invoicing FAQs FAQ
Who must join, costs, IP, tokens, common problems - DI Scenarios for Sandbox Testing v1.11
A sample invoice for each scenario SN001 to SN028
Get the original PDFs from the PRAL support site: user manual, technical specification, error guide, FAQs and scenarios. They are the official source and may be newer than this summary.
1. What is Digital Invoicing?
- It is an FBR system. Your invoice goes to FBR in real time through PRAL's platform.
- It is mandatory for registered taxpayers under SRO 709(I)/2025. This includes exporters and businesses that file nil returns (a null submission is still needed).
- Small shops are not excused. If you have no invoicing system, write to your tax office.
- Benefits listed: real-time checking, automatic tax calculation, fewer mistakes, and invoices that fill Annexure C and the sales tax return by themselves.
- It replaces the old monthly IMS upload once you are integrated. The manual invoice tab in the portal is switched off for now; shops with no system keep using IMS until FBR says otherwise.
- Late posting because of a fault in your own system can still be penalised. Send the invoice again when your system is back.
2. Steps to register and go live
This is the order given in the PRAL user manual when you choose PRAL as your Licensed Integrator.
- Log in to the IRIS portal with your NTN/CNIC and password, then open Digital Invoicing on the dashboard.
- Choose API Integration (for shops with software or ERP). Manual Invoice Generation is for those without a system.
- Choose the Licensed Integrator. PRAL is free and includes sandbox testing. Other integrators may charge.
- Technical details: contact person, mobile, email, ERP/system provider, cloud or on-premises, version, and a CRM email and password for support.
- Pick your Business Nature (you can pick many) and one Sector. This decides which test scenarios you must pass.
- IP whitelisting is a must: hosting company name, country, and 1 to 3 IP addresses (or an .xls file up to 1 MB for many). It must be a static public IP; mobile data or changing IPs are not accepted. PRAL normally answers within 2 working hours.
- Sandbox opens after approval. Copy the sandbox web address, token and sample JSON from the Sandbox tab.
- Send test invoices for every scenario shown for your business. At least 1 invoice per scenario must succeed. The tab shows eligible, successful, pending and failed scenarios, and you can click Failed to see the error.
- When all scenarios pass, a Production Token is made automatically. Open the Production tab, copy the production address and token, switch your software to them, and start sending live invoices.
- If you pick another integrator, they review your application and handle IP whitelisting and sandbox. PRAL does not whitelist IPs for other integrators' customers.
- Changing software later means doing the integration again with the same credentials.
3. Costs and who can charge
- PRAL integration and sandbox are free of cost.
- Another licensed integrator may not charge more than Rs. 10 per invoice. The FAQ also gives caps of Rs. 100,000 per taxpayer or Rs. 1,000,000 a year for the alternative option. Check the exact terms with the integrator.
- PRAL does not sell its own invoicing software yet.
- PRAL and FBR only receive the invoice data you send. They cannot reach into your own system.
4. How sending works (the API)
- Two main calls: validate (check without saving) and post (send for real). Sandbox and production have separate web addresses ending in _sb for sandbox.
- Sandbox post: gw.fbr.gov.pk/di_data/v1/di/postinvoicedata_sb. Production post: gw.fbr.gov.pk/di_data/v1/di/postinvoicedata. Validate uses validateinvoicedata_sb or validateinvoicedata.
- Every request carries your token in the header as: Authorization: Bearer <token>. Use the sandbox token for sandbox and the production token for production. The token is valid for 5 years.
- The invoice is one JSON: header once (invoiceType, invoiceDate, seller and buyer details, buyerRegistrationType, invoiceRefNo) and an items list. Sandbox also needs scenarioId.
- Each item needs: hsCode, productDescription, rate, uoM, quantity, totalValues, valueSalesExcludingST, fixedNotifiedValueOrRetailPrice, salesTaxApplicable, salesTaxWithheldAtSource, saleType. Optional: extraTax, furtherTax, sroScheduleNo, fedPayable, discount, sroItemSerialNo.
- The buyer NTN/CNIC may be left out only when the buyer is Unregistered.
- A good reply has statusCode 00 and an invoiceNumber made by FBR. A bad reply has 01 with an error code. Always also look inside invoiceStatuses: each item line can have its own error.
- HTTP replies: 200 OK, 401 Unauthorized (bad or wrong-environment token), 500 server problem.
- There is no daily limit on invoices. Bulk upload is not allowed: each invoice must be sent in real time when it is made.
- If sending fails because of internet or a technical fault, nothing retries by itself. You must send the invoice again.
5. Writing the fields correctly
- Date: YYYY-MM-DD, for example 2025-05-25. A date in the future is rejected.
- NTN/CNIC: digits only, no dashes. CNIC is 13 digits and NTN is 7 digits.
- HS code: 4 digits, a dot, 4 digits, for example 0101.2100.
- Province: use the official province name (Punjab, Sindh), not a city name like Karachi or Lahore.
- Buyer registration type: exactly Registered or Unregistered, and it must match the buyer's FBR profile.
- Unit of measure (UoM) is case-sensitive. Write KG, not kg. Use the unit that FBR allows for that HS code.
- Numbers: not negative, not empty, not text. Up to 2 decimal places, and up to 4 for quantity.
- Tax amount must equal sale value × rate. For quantity-based rates use quantity × rate.
- 3rd Schedule goods: calculate tax on the Fixed/Notified Value or Retail Price, not on the sale value. Example: fixed value 1000 at 18% gives tax 180.
- If the rate is not 18%, you must give the SRO/Schedule number, and then the SRO item serial number.
- Sale type and rate must fit each other. Check valid pairs with the SaleTypeToRate reference list.
- Seller and buyer cannot have the same registration number.
6. Reference lists from FBR
These lists give the exact valid values. They need your token. Sample paths (all begin with gw.fbr.gov.pk):
- /pdi/v1/provinces: provinces
- /pdi/v1/doctypecode: document types
- /pdi/v1/itemdesccode: HS codes
- /pdi/v1/sroitemcode and /pdi/v2/SROItem: SRO items
- /pdi/v1/transtypecode: sale (transaction) types
- /pdi/v1/uom and /pdi/v2/HS_UOM: units, and units allowed for an HS code
- /pdi/v1/SroSchedule and /pdi/v2/SaleTypeToRate: SRO schedules and the rates allowed per sale type
- /dist/v1/statl: is a registration number active on a date. /dist/v1/Get_Reg_Type: is a number Registered or Unregistered.
7. What must be printed on the bill
- The FBR Digital Invoicing logo and the QR code must be printed on every invoice.
- QR code: version 2.0 (25×25 modules), size 1.0 × 1.0 inch.
- The FBR invoice number comes back in the reply after a successful post.
8. After sending: fixing, cancelling and debit notes
- There is no edit or delete in your own software after sending. Changes are made in the IRIS portal (Invoice Dashboard, Search Invoice) or by a debit note.
- Portal corrections only work for invoices sent through DI integration, and only within 72 hours of the insertion date.
- You can edit or cancel one item at a time, or cancel the whole invoice. Header details and the invoice number cannot change. Each item can be edited only once.
- Once an item is edited it cannot be cancelled, so "Cancel all" is off for that invoice.
- The invoice date cannot be moved to earlier than 3 days before today.
- Not allowed: invoices linked with Annexure C, or already counted in a submitted return. Invoices move to the return after 72 hours or at month end, whichever is first.
- Limit: changes are allowed only up to 10% of last month's sales, in total across all invoices and items.
- After a change, a revised invoice is made with the same number and date. You can still view the old item details. On the PDF, E means edited and C means cancelled.
- Debit note: needs the reference invoice number (it must exist), a reason (if Others, add remarks), and a date on or after the original invoice date and within 180 days of it. Quantity, value and taxes cannot be more than the original.
- Partial payment or instalments: still issue one invoice for the full value at the start.
9. Getting help from PRAL
- Support portal (CRM): dicrm.pral.com.pk. Email: digital.invoicing@pral.com.pk.
- Taxpayer: log in with IRIS (your own NTN and password) or DI-Support (the email and password you gave in technical details). After 5 wrong tries the ID is blocked.
- Click + New Case. Fill priority (High, Normal, Low), query type (Integration or Post Integration), title and description, then Save. Then add PDF attachments.
- Attachment size: the user manual says up to 5 MB and the FAQ says 20 MB. Keep files under 5 MB to be safe.
- Track cases in Case List, search by case number or title, and click View to read replies or add correspondence.
Sandbox test scenarios
- SN001Goods at standard rate to registered buyers
- SN002Goods at standard rate to unregistered buyers
- SN003Sale of steel (melted and re-rolled)
- SN004Sale by ship breakers
- SN005Reduced rate sale
- SN006Exempt goods sale
- SN007Zero rated sale
- SN008Sale of 3rd Schedule goods
- SN009Cotton spinners buying from cotton ginners (textile)
- SN010Telecom services
- SN011Toll manufacturing sale by steel sector
- SN012Petroleum products
- SN013Electricity supply to retailers
- SN014Gas to CNG stations
- SN015Mobile phones
- SN016Processing / conversion of goods
- SN017Goods where FED is charged in ST mode
- SN018Services where FED is charged in ST mode
- SN019Services
- SN020Electric vehicles
- SN021Cement / concrete block
- SN022Potassium chlorate
- SN023CNG sales
- SN024Goods listed in SRO 297(1)/2023
- SN025Drugs at fixed ST rate (Eighth Schedule, serial 81)
- SN026Standard rate sale to end consumers by retailers
- SN0273rd Schedule goods to end consumers by retailers
- SN028Reduced rate sale to end consumers by retailers
SN026, SN027 and SN028 apply only if you are registered as a retailer in your sales tax profile. Which scenarios you must pass depends on your Business Nature and Sector. For example, a retailer in Wholesale/Retail needs SN026, SN027, SN028 and SN008. The full table is in section 10 of the Technical Specification.
Sale error codes in the PRAL guide
Type a code or a word to search.
0002Buyer registration no. not in proper format
Fix: Digits only. CNIC 13 digits, NTN 7 digits. No dashes or special characters.
0003Invoice type not valid
Fix: Use Sale Invoice or Debit Note.
0007Sale type not valid
Fix: Use a sale type from the FBR sale type list (transtypecode).
0008 / 0050Sales tax withheld wrong for cotton ginner sale
Fix: For cotton ginners, tax withheld at source must be zero or equal to the sales tax.
0010Buyer name is required
Fix: Write the buyer's name.
0012Buyer registration type not valid
Fix: Use Registered or Unregistered.
0013Sale type not provided
Fix: Fill the sale type from the FBR list.
0018 / 0023Sales tax is empty
Fix: Fill the sales tax amount (0 if none).
0019 / 0044HS code missing or invalid
Fix: Use a valid code like 0101.2100 from the FBR HS list.
0020Rate is empty
Fix: Fill the rate from the FBR rate list for the sale type.
0021Value of sales excluding ST is empty
Fix: Fill valueSalesExcludingST.
0022Tax withheld at source is empty (cotton ginners)
Fix: Fill salesTaxWithheldAtSource.
0026Reference invoice no. needed for debit note
Fix: Give the original FBR invoice number.
0027Reason needed for debit note
Fix: Pick a valid reason.
0028Reason is Others but no remarks
Fix: Write the remarks for the reason.
0029 / 0035Debit note date earlier than original invoice
Fix: Debit note date must be the same as or after the original invoice date.
0034Debit note after 180 days
Fix: A debit note can be added only within 180 days of the original invoice.
0042Invoice date is empty
Fix: Fill the invoice date.
0043Invoice date is in the future
Fix: Use today or an earlier date.
0046Rate not correct for the sale type
Fix: Take the rate from the SaleTypeToRate list for your sale type.
0052HS code does not match the sale type
Fix: Use an HS code that is valid for that sale type.
0053Registration type does not match buyer's profile
Fix: Check the buyer with FBR (Get_Reg_Type) and use the right type.
0056Toll manufacturing: buyer must be steel sector
Fix: Give the registration no. of a steel sector buyer.
0057Reference invoice for debit note does not exist
Fix: Give a correct invoice reference number.
0058Buyer and seller number are the same
Fix: Self invoicing is not allowed. Use the real buyer's number.
0059Price is below the minimum notified price
Fix: Raise the declared price to the minimum shown in the message.
0060Services at 50/SqY or 100/SqY need UoM SqY
Fix: Set UoM to SqY.
0061Services (FED in ST mode) at 200/bill need Bill of lading
Fix: Set UoM to Bill of lading.
0062Steel melting and re-rolling needs UoM MT
Fix: Set UoM to MT.
0067Debit note is bigger than the original invoice
Fix: Quantity, value and taxes must be equal to or less than the original.
0071Buyer NTN is invalid
Fix: Check the buyer's NTN and enter it again.
0073Seller province missing or invalid
Fix: Use the official province name from the provinces list.
0074Buyer province missing or invalid
Fix: Use the official province name from the provinces list.
0077SRO/Schedule no. needed when rate is not 18%
Fix: Pick the SRO/Schedule that matches the rate from the FBR list.
0078SRO item serial no. needed
Fix: Pick the item serial no. for the SRO you gave.
0079Above 20,000 per unit, 5% is not allowed
Fix: For Electricity Supply to Retailers, choose a valid rate from the list.
0082Seller number does not belong to a registered person
Fix: Give your valid NTN/CNIC.
0086Not an EFS holder who imported compressor scrap
Fix: Only EFS licence holders who imported it in the last 12 months are allowed.
0090Fixed/notified value or retail price needed
Fix: For 3rd Schedule goods fill fixedNotifiedValueOrRetailPrice.
0091Extra tax on reduced rate goods
Fix: Check the sale type is really for reduced rate goods, or remove the extra tax.
0093Manufacturers cannot add non-adjustable supplies
Fix: Not allowed for Eighth Schedule Table I, item 81.
0097Potassium chlorate needs UoM KG
Fix: Use the right HS code and UoM KG.
0098Quantity is empty
Fix: Quantity is required when selling goods at standard rate.
0099UoM not allowed for this HS code
Fix: Take the unit from the HS_UOM list. Check capital letters.
0100Buyer must be registered for Cotton Ginner
Fix: Add a registered buyer.
0101Toll manufacturing cannot be a service
Fix: HS code 8805.2100 cannot go with a services sale type. Change the HS code or sale type.
0102Tax does not match (3rd Schedule goods)
Fix: Work out tax from the fixed/notified value or retail price.
0103Tax does not match (potassium chlorate)
Fix: Use the valid rate for this sale type.
0104Tax does not match sale value × rate
Fix: Calculate tax from the sale value you sent.
0105Tax does not match quantity × rate
Fix: Calculate tax from the quantity you sent.
0108Seller registration no. not in proper format
Fix: Digits only. CNIC 13 digits, NTN 7 digits.
0113Invoice date not in proper format
Fix: Use YYYY-MM-DD, for example 2025-05-25.
0300Numeric values invalid
Fix: No negative, empty, null or text numbers.
0302Too many decimal places
Fix: Up to 2 decimals, 4 for quantity.