Building across multiple Arabic & GCC document types? Explore our unified Arabic OCR API & Bilingual Document Hub (PDFs, ZATCA invoices, Emirates ID, Iqama, Istimara, Mulkiya & health cards).
Arabic OCR Hub

UAE VAT & 15-Digit TRN Invoice OCR API

Extract bilingual Arabic–English supplier invoices in AED, validate 15-digit UAE Federal Tax Authority TRNs (100...), and capture multi-page line items and 5% VAT breakdowns in one REST API call.

200 free credits = 66 Invoice scans, no credit card. Then from $5 for 500 credits, pay as you go. See pricing

Bilingual UAE Arabic-English tax invoice with 15-digit TRN and AED 5% VAT transforming into structured gcc_compliance JSON with validated uae_trn fields

Why Generic Invoice Parsers Fail on UAE Bilingual Tax Invoices

Finance and AP teams operating in Dubai, Abu Dhabi, and Sharjah receive a constant mix of English-only free-zone PDFs and bilingual Arabic–English mainland supplier invoices. Generic OCR tools frequently mangle right-to-left Arabic vendor names, misread Eastern Arabic-Indic numerals (٠١٢٣٤٥٦٧٨٩) on AED totals, and fail to check whether a supplier's printed Tax Registration Number actually conforms to the UAE Federal Tax Authority's 15-digit 100... TRN format before ERP ingestion.

Bilingual AED Line-Item Extraction + Deterministic UAE TRN Checks

StructOCR's Invoice OCR API (POST /v1/invoice) reads digital and scanned UAE supplier invoices up to 5 PDF pages in one call, normalizes Arabic-Indic digits to 0–9, extracts full line items and 5% VAT breakdowns, and automatically returns a deterministic gcc_compliance object validating 15-digit UAE TRNs (^100\d{12}$). Processing Saudi supplier invoices too? See our ZATCA Invoice Scanner & QR OCR API or explore the unified Arabic OCR API Hub.

Need more testing? Create a free account to get 200 free credits (equals 66 Invoice scans).

UAE Accounts Payable & Bookkeeping Automation Workflows

UAE FTA VAT Return Prep & TRN Validation

Automatically verify that every incoming AED supplier tax invoice carries a structurally valid 15-digit TRN starting with 100 before booking recoverable 5% input VAT in Zoho Books, Xero, Tally, or Odoo.

Free-Zone & Mainland Multi-Entity AP Intake

Ingest bilingual PDF invoices from DIFC, JAFZA, DMCC, and Abu Dhabi suppliers with consistent UTF-8 vendor names, AE IBANs, and ISO YYYY-MM-DD dates.

Real Estate, Contracting & Logistics Line-Item Matching

Extract multi-page itemized schedules (up to 5 pages per PDF) with per-line quantities, unit prices, and tax rates for automated PO three-way matching.

Cross-Border GCC AP Hubs (UAE + Saudi Arabia)

Route both UAE (AED / uae_trn) and Saudi (SAR / ksa_vat + ZATCA TLV QR) invoices through a single POST /v1/invoice endpoint with automatic jurisdiction detection.

Technical Specs

  • Endpoint: `POST https://api.structocr.com/v1/invoice`
  • Authentication: `x-api-key` header + `Content-Type: application/json`
  • Input: Base64 string or Data URI (`img` / `image`) up to 4.5 MB decoded — PDF (up to 5 pages), JPG, PNG, WebP, HEIC
  • UAE TRN Check: Auto-emits `gcc_compliance` with `jurisdiction: "ARE"`, `tax_id_type: "uae_trn"`, and format validation (`^100\d{12}$`)
  • Multi-Rate Tax Support: Extracts `subtotal`, `tax_amount`, `tax_inclusive`, and `tax_breakdown` (5% standard, 0% zero-rated / export)
  • Pricing: 3 credits per invoice request (200 free sign-up credits = 66 invoices; automatic refund on failed calls)

Key Features

  • Bilingual Arabic–English clarity: Preserves UTF-8 Arabic and English merchant names and descriptions without reversed RTL text.
  • Eastern numeral normalization: Converts Arabic-Indic numerals (`٠–٩`) in TRNs, dates, and AED amounts to standard `0–9` digits.
  • Bank & settlement extraction: Captures 23-character UAE `AE` IBANs and SWIFT/BIC codes alongside buyer/seller tax IDs.
  • Strict null fallback: Missing fields always return `null` instead of guessed values so accounting validation rules stay deterministic.

Extract UAE Tax Invoices & Validate TRNs via POST /v1/invoice

Submit a Base64-encoded PDF (up to 5 pages), JPG, PNG, WebP, or HEIC invoice up to 4.5 MB to POST /v1/invoice. Check data.gcc_compliance.tax_id_valid to catch invalid or truncated TRNs before posting to your ERP. Full contract in the Invoice OCR API Docs.

import base64
import os
import requests

with open("dubai_supplier_invoice.pdf", "rb") as f:
    encoded = base64.b64encode(f.read()).decode("utf-8")

response = requests.post(
    "https://api.structocr.com/v1/invoice",
    headers={
        "x-api-key": os.environ["STRUCTOCR_API_KEY"],
        "Content-Type": "application/json",
    },
    json={"img": f"data:application/pdf;base64,{encoded}"},
    timeout=60,
)
response.raise_for_status()
data = response.json()["data"]

gcc = data.get("gcc_compliance") or {}
print("Jurisdiction:", gcc.get("jurisdiction"))          # ARE
print("TRN Normalized:", gcc.get("tax_id_normalized")) # 15-digit TRN
print("TRN Valid:", gcc.get("tax_id_valid"))           # True if ^100\d{12}$
print("Total AED:", data["financials"]["total_amount"])

Structured JSON Output with UAE TRN Validation (Synthetic Example)

Synthetic bilingual Dubai supplier invoice response matching the live POST /v1/invoice schema, including gcc_compliance UAE TRN verification and 5% VAT breakdown.

{
  "success": true,
  "data": {
    "type": "invoice",
    "invoice_number": "DXB-2026-4419",
    "date": "2026-11-20",
    "due_date": "2026-12-20",
    "currency": "AED",
    "language": "ar",
    "merchant": {
      "name": "Emirates Horizon Trading LLC / شركة أفق الإمارات للتجارة ذ.م.م",
      "address": "Business Bay, Bay Square Bldg 4, Dubai, UAE",
      "email": "[email protected]",
      "phone": "+971 4 555 0148",
      "tax_id": "100492817300003",
      "iban": "AE070331234567890123456",
      "swift_bic": "EBILAEAD"
    },
    "customer": {
      "name": "Al-Mina Facilities Management LLC",
      "address": "Jebel Ali Free Zone, Dubai, UAE",
      "email": "[email protected]",
      "tax_id": "100283746500003"
    },
    "financials": {
      "subtotal": 20000,
      "tax_amount": 1000,
      "discount_amount": null,
      "shipping_amount": null,
      "total_amount": 21000,
      "tax_inclusive": false,
      "tax_breakdown": [
        {
          "tax_rate": "5%",
          "tax_amount": 1000
        }
      ]
    },
    "line_items": [
      {
        "description": "HVAC Preventive Maintenance Contract / عقد صيانة تكييف",
        "quantity": 1,
        "unit_price": 14000,
        "tax_rate": "5%",
        "amount": 14000
      },
      {
        "description": "HEPA Replacement Filter Pack / مجموعة فلاتر بديلة",
        "quantity": 20,
        "unit_price": 300,
        "tax_rate": "5%",
        "amount": 6000
      }
    ],
    "gcc_compliance": {
      "jurisdiction": "ARE",
      "tax_id_type": "uae_trn",
      "tax_id_normalized": "100492817300003",
      "tax_id_valid": true,
      "zatca_qr": null
    }
  }
}

Frequently Asked Questions

How does StructOCR validate a UAE Tax Registration Number (TRN)?

StructOCR strips whitespace and hyphens, converts any Eastern Arabic-Indic numerals (٠–٩) to Western digits, and validates the normalized tax ID against the standard 15-digit UAE Federal Tax Authority TRN pattern beginning with 100 (^100\d{12}$). Note that this is a deterministic structural format check—not a live lookup against the FTA portal.

When does POST /v1/invoice include the gcc_compliance object for UAE invoices?

Whenever the extracted currency is AED—or when UAE/Arabic document context (such as Dubai/Abu Dhabi address, AE IBAN, or Arabic text) pairs with a valid 15-digit UAE TRN—POST /v1/invoice automatically attaches gcc_compliance with jurisdiction: "ARE" and tax_id_type: "uae_trn".

Does it support both 5% standard-rated and 0% zero-rated UAE VAT invoices?

Yes. StructOCR extracts document-level subtotal, tax_amount, total_amount, and the per-rate tax_breakdown array (for example, 5% and 0% lines on the same invoice) along with individual line_items[].tax_rate values without inventing missing figures.

Can I process both UAE and Saudi Arabia ZATCA supplier invoices through one endpoint?

Yes. POST /v1/invoice automatically detects Saudi (SAU / SAR) vs UAE (ARE / AED) context. On Saudi invoices it validates 15-digit KSA VAT numbers (3...3) and decodes readable ZATCA Phase 1/2 Base64 TLV QR payloads; on UAE invoices it validates 15-digit TRNs (100...).

How many pages and how much does UAE invoice OCR cost?

Each POST /v1/invoice call processes up to 5 PDF pages (4.5 MB max decoded) for 3 permanent credits ($0.0174/invoice on the Pro pack). New accounts receive 200 permanent free credits (66 invoices) with no credit card required, and failed calls refund automatically.

Explore More Invoice & Accounts Payable OCR Solutions

Core Infrastructure

Accounts Payable & Invoice OCR API

Automate vendor invoice ingestion across global and GCC tax formats with multi-page PDF line-item extraction, VAT/TRN checks, and ERP-ready JSON.

Technical Comparisons & Integrations

Explore platform integrations and competitive analysis

From tutorial to production in 5 minutes.

You've seen the code. Now get your API key, grab your 200 free credits, and see it work with your own images. No credit card required.

Instant Access Cancel Anytime No Credit Card