What Is MyInvois and Why It Matters
Malaysia's Inland Revenue Board (LHDN) has mandated that all businesses switch to e-invoicing via the MyInvois platform. The rollout is phased by company turnover — large companies above RM100 million have already been live since August 2024, and the mandate will reach all taxpayers by 2027.
Unlike a simple format change, MyInvois introduces a clearance model: every invoice must be submitted to LHDN's platform and receive a cryptographic stamp before it can be considered legally valid. This is a fundamental change to how billing systems need to be architected.
The Two Submission Models
Direct API Integration
Larger businesses with technical teams will typically integrate directly with the MyInvois API. This involves authenticating with LHDN's OAuth 2.0 service, serialising your invoice data into the UBL 2.1 or PEPPOL BIS 3.0 JSON format, submitting to the submission endpoint, polling for validation status, and storing the returned UUID and validation hash.
The critical architectural requirement: your system must be designed to handle asynchronous validation. Submissions are not validated synchronously. You must implement a polling mechanism and handle the three possible outcomes: valid, invalid (with error codes), or pending (still processing).
MyInvois Portal (Manual)
Smaller businesses without technical capability can submit via the MyInvois web portal directly. This is not scalable for businesses processing more than a handful of invoices per day.
The UBL 2.1 Format Requirements
LHDN requires invoices in UBL 2.1 XML or the equivalent JSON representation. The key mandatory fields that many billing systems don't currently capture:
- MyKad / Business Registration Number: Both supplier and buyer identification numbers in a specific format.
- SST Registration Number: If applicable, must be included in a specific field.
- MSIC Code: Malaysia Standard Industrial Classification code for the line item activity.
- Classification Code: LHDN's own product/service classification (different from MSIC).
- Digital Signature: The submission must include a valid digital signature from a LHDN-approved Certificate Authority.
Common Integration Pitfalls
Certificate Management
The digital signing requirement trips up most initial integrations. You need a signing certificate from an approved CA, and it must be renewed before expiry — an expired cert means you cannot submit any invoices, which is a business-stopping failure. Build certificate expiry monitoring into your integration from day one.
Handling Rejections
LHDN's validation is strict. Common rejection reasons: buyer TIN not matching registered name, MSIC code not found, total tax amount not matching line-item sum to two decimal places. Your integration must parse the rejection error codes and feed them back to your finance team in human-readable form — otherwise every rejection becomes a support ticket.
Cancellation and Credit Notes
A MyInvois-validated invoice can only be cancelled within 72 hours of validation. After that, you must issue a credit note (also submitted to MyInvois). Most billing systems have basic credit note logic — but the MyInvois workflow requires the credit note to reference the original invoice's UUID, which means your system must store and link validated UUIDs.
Architecture Recommendations
We recommend treating the MyInvois integration as a separate microservice — an e-invoicing adapter — rather than embedding the logic in your existing billing or ERP system. This approach:
- Isolates the complexity of LHDN's evolving API from your core business logic
- Provides a single place to update when LHDN changes their format requirements (and they will)
- Makes it easier to add monitoring, alerting, and retry logic
- Allows multiple upstream systems (billing, POS, contracts) to share the same integration
"The businesses that are struggling with MyInvois are the ones that tried to embed the integration directly into their existing ERP. Treat it as a dedicated service."
We've helped several Malaysian businesses — from retail to professional services — integrate MyInvois into their billing workflows. If your deadline is approaching and your current system isn't ready, we can help you scope and execute the integration.

