API Integration Developer Guide

The AECloud Integration API connects a merchant's POS, retail, ERP, accounting, or other downstream system to AECloud. AECloud acts as the intermediary and orchestration layer between that system and LHDN Malaysia's MyInvois services. It accepts business-oriented JSON, validates and stores the document, converts supported data into the required regulatory representation, schedules or starts submission, and provides endpoints for status checking, voiding, cancellation, TIN services, and reference codes.

The API covers eight document families:

  • sale invoice;
  • sale credit note;
  • sale debit note;
  • sale refund note;
  • self-billed invoice;
  • self-billed credit note;
  • self-billed debit note; and
  • self-billed refund note.

This guide documents the current API contract exported on 26 August 2026 and cross-checked against the live AECloud API catalogue. Environment hostnames and credentials are intentionally represented by placeholders. Obtain the correct sandbox and production values from AECloud.

In this guide

Integration flow

  1. Complete the merchant, LHDN, outlet, and subscription setup in AECloud.
  2. Obtain the merchant's OAuth2 client ID and client secret.
  3. Request an access token using the client-credentials grant.
  4. Build an AECloud JSON document using valid merchant, buyer or supplier, tax, and item data.
  5. POST the document to the matching submission endpoint.
  6. Store the returned AECloud sale GUID and any LHDN identifiers.
  7. Query status by sale GUID or by submission date range until a terminal result is recorded.
  8. Use a void endpoint before LHDN processing, or the cancellation endpoint for an eligible validated document.

The merchant credential in step 2 authenticates the downstream system to AECloud. AECloud separately authenticates to MyInvois as an intermediary acting on behalf of the authorized taxpayer.

For environment access or unresolved integration issues, email support@einvoicecloud.com.