← Back to Documentation
Focus logo

Focus Integration with UAE FTA E-Invoicing via TrustBill

Connect Focus RT, Focus 9, Focus Cloud and Focus MRP to TrustBill for PINT-AE e-invoicing · REST · SData · CSV

Overview

This guide explains how to connect Focus — RT, 9, Cloud and MRP — to TrustBill, a UAE FTA-accredited service provider (ASP). Invoices posted in Focus are submitted as PINT-AE compliant e-invoices to the FTA without replacing your ERP.

Focus already manages UAE VAT, customer TRNs, item masters, inventory and financials. What it does not ship natively is PINT-AE XML generation and delivery through an FTA-accredited ASP over the Peppol network. TrustBill bridges that gap.

What this integration delivers

  • Submit sales invoices and credit notes from Focus to the FTA
  • Cloud path for Focus Cloud via REST API / SData
  • On-premise path for Focus RT and Focus 9 via SData, web services or the TrustBill Desktop Agent
  • PINT-AE XML generated, validated and delivered by TrustBill
  • FTA acknowledgement, UUID and QR written back to Focus custom fields
  • Bulk migration path for historical invoices via CSV

What is Focus?

Focus (Focus Softnet) is a UAE-headquartered ERP and business management suite. The product lines most used for e-invoicing are:

  • Focus RT — real-time ERP with a web layer and SData / REST endpoints
  • Focus 9 — desktop + web hybrid ERP with SData and web-service integration
  • Focus Cloud — SaaS ERP with a public REST API and webhooks
  • Focus MRP — manufacturing-focused ERP based on the Focus stack

Supported Versions

ProductSupported VersionsPrimary API
Focus RT2021, 2022, 2023, 2024 releasesSData / REST
Focus 99.0, 9.1, 9.2, 9.3SData / Web services
Focus Cloud2023, 2024 releasesREST API / Webhooks
Focus MRP2023, 2024 releasesSData / REST

Prerequisites

  • Focus company with UAE VAT, TRN and customer tax IDs configured
  • Customer records with 15-digit UAE TRN for B2B invoices
  • User / service account with permission to read posted invoices and customers
  • Active TrustBill SME account with API credentials
  • Network egress from the Focus host or middleware to TrustBill API endpoints
  • For on-premise editions: the SData servlet or web services endpoint must be enabled

Integration Architecture

Focus stays the source of record. A middleware agent or scheduled job reads invoices and pushes them to TrustBill.

  1. Invoice posted in Focus.
  2. Connector / agent reads the invoice via REST, SData or database.
  3. Payload normalised into TrustBill's PINT-AE JSON.
  4. POST to TrustBill /api/v1/invoices with API key authentication.
  5. TrustBill validates, renders PINT-AE XML and delivers over Peppol.
  6. Acknowledgement written back to Focus custom fields.

Connection Methods

1. Focus Cloud REST API (Recommended for cloud)

Use the Focus Cloud REST API to fetch invoices, contacts and products with OAuth 2.0 authentication.

2. Focus RT / 9 SData

Query SData feeds for sales invoices, customers and items. Transform to TrustBill JSON and POST.

3. TrustBill Desktop Agent

For on-premise Focus 9 or RT, install the Windows agent on the application server. It reads the invoice register and forwards to TrustBill.

4. CSV / Excel Export

Export invoice data from Focus reports and upload to TrustBill bulk import as a fallback.

Authentication

TrustBill API uses Bearer tokens. Focus-side authentication depends on the edition.

POST https://trustbill.ae/api/v1/invoices
Authorization: Bearer tb_your_api_key_here
Content-Type: application/json

Focus product auth:

  • Focus Cloud: OAuth 2.0 client credentials or authorization code from the Focus admin portal
  • Focus RT / 9: SData user credentials or Windows service account for the Desktop Agent
  • Focus MRP: Same SData / REST credentials as the core Focus application

Focus RT

Focus RT exposes SData and REST endpoints. The standard pattern is to query the sales invoice feed, transform the payload and post to TrustBill.

GET https://focusrtserver/sdata/FOCUS/{company}/salesInvoices
  ?startIndex=1&count=50
  &where=status%20eq%20'Posted'

For a deeper Focus RT guide, see the Focus RT integration page.

Focus 9

Focus 9 ships with SData and SOAP web services. Enable the web services layer in the Focus 9 application manager, then generate an invoice query service for TrustBill.

POST https://focus9server/Focus9WS/InvoiceService.asmx
Content-Type: text/xml; charset=utf-8
SOAPAction: "http://focussoftnet.com/GetPostedInvoices"

<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope ...>
  <soap:Body>
    <GetPostedInvoices xmlns="http://focussoftnet.com/">
      <CompanyCode>UAE01</CompanyCode>
      <FromDate>2026-09-01</FromDate>
      <ToDate>2026-09-08</ToDate>
    </GetPostedInvoices>
  </soap:Body>
</soap:Envelope>

Focus Cloud

Focus Cloud provides a JSON REST API. Register a developer app, obtain an OAuth token and poll the sales invoice endpoint.

GET https://api.focuscloud.ae/v1/sales_invoices
  ?status=posted&from=2026-09-01&to=2026-09-08
Authorization: Bearer {focus_cloud_token}

Webhooks are also available: configure Focus Cloud to call your middleware when a new invoice is posted, and the middleware pushes to TrustBill.

Focus → TrustBill Field Mapping

Focus FieldTrustBill JSONNotes
Invoice NoinvoiceNumberUnique per seller
Invoice DateissueDateISO-8601
Company TRNseller.trn15-digit UAE TRN
Customer TRNbuyer.trnRequired for B2B
Item Descriptionitems[].nameEnglish + Arabic if available
Quantityitems[].quantityPositive numeric
Unit Priceitems[].unitPriceAfter line discount
Total with VATtotals.grossAmountVAT inclusive

UAE VAT / Tax Mapping

Map Focus tax codes to FTA tax category codes.

Focus Tax CodeTrustBill taxCategoryRate
VAT 5%STANDARD5%
VAT 0%ZERO_RATE0%
ExemptEXEMPT
Reverse ChargeREVERSE_CHARGE5%
Out of ScopeOUT_OF_SCOPE

Credit Notes

Focus credit notes are mapped to the TrustBill credit-note endpoint. Include the original invoice number.

POST https://trustbill.ae/api/v1/credit-notes
{
  "originalInvoiceNumber": "SI-001",
  "issueDate": "2026-09-08",
  "creditNoteNumber": "CN-001",
  "reason": "Product return",
  "totals": {
    "grossAmount": -1050.00
  }
}

Status Tracking

TrustBill posts status updates to a webhook URL. The middleware writes the values back to Focus custom fields or a status table.

POST https://your-middleware.example.com/webhook/trustbill
Content-Type: application/json

{
  "invoiceNumber": "SI-001",
  "status": "Acknowledged",
  "ackRef": "FDA-ACK-123456789",
  "uuid": "a1b2c3d4-...",
  "reason": null
}

Bulk Migration

Export historical invoices from Focus reports or SData with the columns from the field mapping table, then upload to TrustBill.

POST https://trustbill.ae/api/v1/invoices/bulk
Authorization: Bearer tb_your_api_key
Content-Type: multipart/form-data

file: focus_invoices.csv
options: {"mode":"sandbox","skipErrors":true}

Sandbox & Live Modes

Test the full flow without touching the FTA. Switch to live once FTA registration and ASP assignment are complete.

ModeEndpoint / OptionWhat it does
Sandbox?mode=sandbox or bulk import sandboxValidates PINT-AE, no FTA delivery
Live?mode=liveSubmits to FTA via ASP over Peppol

Multi-Company & Multi-Currency

Focus RT, Focus 9 and Focus Cloud all support multiple companies under one install or subscription — common for UAE groups running a mainland trading entity alongside a free-zone entity. TrustBill treats each Focus company as an independent seller with its own TRN.

Company → TrustBill profile mapping

Maintain a lookup table that maps each Focus company code to a TrustBill API key and TRN in the Desktop Agent config or middleware. Never route two companies' invoices through one shared TrustBill profile.

Multi-currency invoices

When a Focus invoice is raised in a foreign currency, include both the trade currency amount and the AED-converted total (using the exchange rate recorded on the invoice) in the TrustBill payload — PINT-AE always requires an AED figure for FTA reporting.

Multiple branches

Where Focus branches represent different Emirates or outlets, tag the branch code in your internal reconciliation log alongside the TrustBill invoice ID — useful during an FTA audit even though PINT-AE itself has no branch field.

Error Handling & API Errors

Handle every non-2xx TrustBill response deterministically in the Desktop Agent or middleware — separate retryable errors from permanent validation errors.

HTTP StatusMeaningAction
400Malformed JSON or missing required fieldFix the payload mapping; do not retry unchanged
401Invalid or expired API keyRotate the key in the Desktop Agent / Focus Cloud app config
403TRN on invoice does not match the API key's registered TRNFix company → TRN mapping
409Duplicate invoice number for this sellerCheck idempotency key / Focus invoice number reuse
422PINT-AE validation failure (tax, TRN format, totals mismatch)Inspect errors[] array; fix mapping
429 / 5xxRate limited or TrustBill/FTA temporarily unavailableRetry with exponential backoff (max ~5 attempts)

Setup Checklist

  • UAE TRN configured for every Focus company
  • Customer records populated with TRNs for B2B customers
  • SData / REST / Desktop Agent access enabled and credentials secured
  • Company → TrustBill API key mapping table created
  • Tax code → PINT-AE tax category mapping reviewed with finance
  • Credit note flow mapped to TrustBill credit notes
  • Webhook or polling job configured for status write-back
  • Sandbox invoices tested for standard, zero-rated, exempt and reverse-charge cases
  • Bulk migration CSV template validated against historical invoice data
  • Go-live date agreed and live mode switched only after sandbox sign-off

Troubleshooting

  • 422 validation error: Confirm customer TRN is 15 digits and seller TRN is set.
  • SData 401: Check the SData user credentials and that the company is enabled for web access.
  • Focus Cloud token expired: Refresh the OAuth token before the one-hour expiry.
  • Desktop agent not seeing invoices: Verify the agent is running under a user with Focus company access and that the DSN is correct.
  • Missing Arabic names: Use a custom field for the Arabic legal name and include it in the mapping.

Support

Need help with the Focus integration? Our team can review your SData setup, Focus Cloud app, Desktop Agent configuration or CSV mapping.