Global Documentation
Overview Workspace Sign In
Docs Invoices & Billing FBR Pakistan Fiscal Invoicing & POS Tier-1 Integration
Available on: Standard, Growth, Enterprise

FBR Pakistan Fiscal Invoicing & POS Tier-1 Integration

12 min read 29 views Updated Nov 27, 2026
✨
Have questions about this article?

Ask WIE Brain to explain step-by-step or walk you through configuration.

1. Executive Summary & Regulatory Framework

The Federal Board of Revenue (FBR) of Pakistan mandates real-time integration of electronic fiscal invoicing for all Tier-1 Retailers, prescribed corporate entities, and sales-tax-registered businesses under Sales Tax Rules, 2006 (Chapter XIV-AA, Rule 150ZEG), SRO 1006(I)/2021, and SRO 1005(I)/2021. ITSTHS Workspace includes native, zero-dependency compliance engineering that directly connects billing workflows to the official FBR Fiscal Data Gateway.

Compliance Mandate Regulatory Standard System Implementation in Workspace
Tier-1 POS Integration SRO 1006(I)/2021 & Rule 150ZEB Automated real-time transmission of sales receipts via FBR IMS API endpoint with verified FBR Invoice Number stamp.
B2B Digital E-Billing SRO 1525(I)/2023 & SRO 56(I)/2024 Structured electronic document exchange with buyer NTN/STRN validation and digital tax clearance.
Tax Asaan QR Code Rule 150ZEG(2) Instant cryptographic 2D barcode embedded on printed PDF and web invoices, verifiable by consumers via FBR Tax Asaan app.
Credit / Debit Notes Rule 150ZEF & Sales Tax Act Sec 9 Automated RefUSIN parent tracking with InvoiceType = 3 transmission ensuring audit reconciliation.

2. Official Portals & Integration Resources

When provisioning API credentials or verifying fiscal logs with tax authorities, refer to the official portals below:

3. Configuration & Credential Setup

To enable and configure FBR Pakistan integration in your workspace:

  1. Navigate to Settings → Invoices → FBR Pakistan (POS / Digital Invoicing).
  2. Toggle Enable FBR Fiscal Integration to Active.
  3. Select the appropriate API Integration Mode:
    • POS Tier-1 (Point of Sale Integration): Standard retail and client counter invoicing (IMS Gateway).
    • B2B Digital Invoicing (E-Billing): Corporate e-invoicing for business-to-business transactions.
  4. Input your regulatory tax credentials:
    • POS Machine ID (POS ID): The 6-to-7 digit numeric terminal identifier issued in your FBR Iris / IMS dashboard.
    • Seller NTN: Your 7-digit National Tax Number followed by check-digit (e.g., 1234567-8).
    • Seller STRN: Your Sales Tax Registration Number (e.g., 07-01-9999-999-99).
    • API Bearer Token: The cryptographic bearer auth token generated by FBR for your registered POS ID.
  5. Use the Test FBR Connection button to perform an automated handshake test to verify connectivity.

4. Unique Sales Invoice Number (USIN) Architecture

Every invoice generated within the workspace is assigned an immutable, sequentially unique USIN according to FBR technical specifications:

USIN Format: {POSID}_{YYYYMMDD}_{InvoiceID}
Example:     101001_20261012_1042

The system enforces absolute uniqueness across calendar days and invoice revisions, preventing duplicate sequence rejections by the FBR gateway.

5. Buyer Identification & CNIC / NTN Resolution

Under Pakistan Sales Tax law, invoices must accurately reflect the buyer's tax classification:

  • Registered Corporate Buyers: The system automatically extracts the buyer's 7-digit NTN or STRN from their CRM client profile.
  • Unregistered Individuals (Above Threshold): Invoices exceeding statutory thresholds capture the buyer's 13-digit Computerized National Identity Card (CNIC) number.
  • Retail / Unidentified Consumers: Transactions where individual identification is legally exempt automatically default to the official consumer identifier 9999999.

6. Credit Notes, Debit Notes & RefUSIN Compliance

When issuing invoice cancellations, returns, or partial adjustments, FBR regulations require explicit linking to the original fiscalized sales invoice:

  • The workspace sets the document InvoiceType to 3 (Credit Note).
  • The parent invoice's original fiscal USIN is automatically populated in both the header RefUSIN field and on each returned line item.
  • The gateway validates that the tax reversal does not exceed the originally declared sales tax.

7. Real-Time Fiscal Verification & Tax Asaan QR Code

Upon invoice issuance or payment receipt:

  1. The system compiles a 17-parameter JSON payload conforming to FBR Schema v1.4.
  2. Transmits the payload over HTTPS TLS 1.3 with Bearer authorization to the gateway.
  3. Receives the official 16-to-19 digit FBR Invoice Number.
  4. Generates a cryptographic Tax Asaan QR Code encoded with:
    FBR:{FBR_INVOICE_NUMBER}|USIN:{USIN}|POS:{POS_ID}|TOTAL:{TOTAL_AMOUNT}|TAX:{TOTAL_TAX}|DATE:{DATE}
  5. Renders the QR code directly on both the web view and the PDF invoice download with the official POS Integrated Fiscal Invoice regulatory stamp.

8. Offline Fiscal Sandbox Simulator

For development environments, user training, and staging servers, ITSTHS Workspace includes an embedded Offline Fiscal Sandbox Simulator. When Sandbox mode is enabled:

  • Invoices can be safely tested without incurring statutory tax liabilities or connecting to live government production servers.
  • The simulator generates fully compliant mock FBR Invoice Numbers and scannable Tax Asaan QR codes with complete audit log entries.
  • Transitioning to live production requires only disabling the Sandbox toggle in Settings.

9. Security, Idempotency & Audit Logs

All fiscal transmissions are protected by a comprehensive security and auditing layer:

  • Self-Healing Schema: Database columns and audit tables auto-heal without requiring manual SQL migrations during upgrades.
  • Idempotency: Invoices with existing verified FBR stamps are protected against duplicate accidental transmissions.
  • Tamper-Resistant Audit Trail: Every request and gateway response is recorded in crm_fbr_audit_logs with response timestamps, HTTP status codes, latency, and operator IDs.
← Previous Guide Managing Sales Quotes & Proposals