Malaysia v2: Delete Receipt API

Delete an existing receipt by its receipt number in the Malaysia LHDN API v2 (legacy): endpoint, headers, parameters, responses and code examples.

The Delete Receipt API deletes an existing receipt. Use it to remove outdated or incorrect receipts created with the Create Receipt API.

Endpoint

EnvironmentHost
Sandboxhttps://malaysia-sandbox.complyance.io
Productionhttps://malaysia-prod.complyance.io
Delete a receipthttp
POST https://malaysia-sandbox.complyance.io/deleteReceipt?receiptNumber=
POST https://malaysia-prod.complyance.io/deleteReceipt?receiptNumber=

Headers

HeaderTypeDescriptionExampleConditionality
x-api-keystringYour API keyyour-api-keyMandatory
Content-TypestringSet as application/jsonapplication/jsonMandatory

Request parameters

ParameterDescriptionRequiredExample
receiptNumberReceipt identifierYesReceipt/002/PQRS

The code examples below send receiptNumber in the JSON request body, with an empty receiptNumber= query parameter in the URL.

Response

Success response

HTTP status 200 OK:

Responsejson
{
  "status": "success",
  "message": "Receipt deleted successfully."
}

Error responses

HTTP status codeError codeDescription
400BAD_REQUESTThe input is invalid or fields are missing.
401UNAUTHORIZEDThe API key is missing or invalid.
404NOT_FOUNDThe receipt does not exist.
500SERVER_ERRORAn internal server error occurred.
Error responsejson
{
  "status": "error",
  "message": "Receipt not found or already deleted."
}

Code examples

bash
curl --location 'https://malaysia-prod.complyance.io/deleteReceipt?receiptNumber=' \
--header 'Content-Type: application/json' \
--header 'x-api-key: your-api-key' \
--data '{
  "receiptNumber": "RCPT-2025-0001"
}'

Notes

  • The x-api-key header must contain a valid API key.
  • The receiptNumber parameter is required and must match an existing receipt.
  • Use the sandbox host for testing.
  • Format the request body and headers correctly to avoid errors.