How to Get Your FBR Digital Invoicing Token (Sandbox & Production) in 2026
Every FBR digital invoice needs a security token. Here is how a Pakistani business gets its sandbox token, passes the test scenarios, and unlocks the production token — and how a ready platform removes the developer work entirely.
What the token is
FBR's Digital Invoicing API is reached with a security token — a Bearer token that must be included in the header of every request. There are two: a sandbox token for testing and a production token for live invoices. Each token is reported to be valid for five years, and the same token decides which environment your invoices go to, so sandbox and production tokens must be kept strictly separate.
You do not create the token in code; you request it from FBR/PRAL through the IRIS portal, then either wire it into your own integration or hand it to a ready platform that uses it for you.
Step 1 — Request the sandbox token
Log in to iris.fbr.gov.pk with your NTN/CNIC and password, open Digital Invoicing, choose API Integration and select 'Proceed with PRAL as Licensed Integrator' (PRAL provides licensed-integrator services, including sandbox testing, free of cost). Complete the technical details form and submit any IP addresses to be whitelisted.
PRAL reviews the request, provisions your sandbox token and whitelists your IP — reported to complete within about two working hours, with an email when it is ready. The token then appears in IRIS under the sandbox environment section.
How do I whitelist my IP address for PRAL digital invoicing?
You whitelist your IP address on IRIS during Digital Invoicing enrolment, on the PRAL route. You enter one to three IP addresses, or upload an Excel sheet of addresses up to 1 MB. PRAL's data centre accepts or rejects them, usually within 2 working hours. An IP address is the internet address your system sends invoices from. PRAL blocks invoices that come from any other address.
Step 1. Find the right address. It is the public IP (the address the internet sees) of the computer or server that will send invoices. A cloud server usually has a fixed, or static, public IP. Many shop and office broadband lines change their IP from time to time, so ask your internet provider for a static IP before you enrol.
Step 2. Log in to iris.fbr.gov.pk with your NTN or CNIC and password. Open Digital Invoicing, choose API Integration and select PRAL as your licensed integrator. Step 3. Fill the technical details form, then type your IP addresses or upload the Excel sheet. Step 4. Wait for PRAL's email. Once your request is approved, your sandbox token appears in IRIS under the sandbox section.
If PRAL rejects the address, do not keep sending the same request. Open a case on the PRAL CRM (PRAL's support portal) with the query type 'Integration', and attach the rejection screen as a PDF. 'PRAL Digital Invoicing Helpline & Support: CRM Portal, FBR Helpline Numbers and What to Use When' explains which problems go to the CRM and which go to the FBR helpline.
Plan ahead if you move servers or change your internet provider. A new public IP will not be on PRAL's list, so your invoices can stop posting until the new address is whitelisted. Add the new address before you switch. Need help with enrolment? Contact Digi Invoice on WhatsApp 0300 8680363.
Step 2 — Pass the sandbox test scenarios
With the sandbox token you post the FBR test scenarios (SN001–SN028) that match your business activity and sector. The scenarioId is required in every sandbox payload — and must be removed for production. FBR tracks which scenarios you have cleared.
This step is where most integration errors surface, so it is worth getting each required scenario to a clean 'Valid' response before moving on.
Step 3 — Unlock the production token and go live
Once every required sandbox scenario passes, FBR generates your production environment token. You switch to the production tab in IRIS, use the new token, drop the scenarioId from the payload, and start posting live invoices that return a real Invoice Reference Number (IRN) and QR code.
With Digi Invoice you skip the developer work at every step: you connect your FBR profile through a guided setup and the platform manages tokens, payloads, scenario testing and the sandbox-to-production switch for you.
The token is one part of a longer setup. The full order of steps is in FBR Digital Invoicing Integration (2026): A Step-by-Step Guide.