curl --request POST \
--url https://api.sandbox.co.in/gst/compliance/e-invoice/tax-payer/invoice/{irn}/cancel \
--header 'Authorization: <authorization>' \
--header 'Content-Type: application/json' \
--header 'x-api-key: <x-api-key>' \
--data '
{
"Irn": "49a7c675b25f730d2353622e4767df203fed2495411953e0351737d47308d868",
"CnlRsn": "1",
"CnlRem": "Wrong entry"
}
'{
"code": 200,
"data": {
"Data": {
"CancelDate": "2023-03-30 17:11:00",
"Irn": "49a7c675b25f730d2353622e4767df203fed2495411953e0351737d47308d868"
},
"ErrorDetails": null,
"InfoDtls": null,
"Status": 1
},
"timestamp": 1763446641000,
"transaction_id": "4b8e067e-eb06-42bb-bd23-3fe49f89a2a3"
}Cancel an e-Invoice by passing the invoice registration number (IRN).
curl --request POST \
--url https://api.sandbox.co.in/gst/compliance/e-invoice/tax-payer/invoice/{irn}/cancel \
--header 'Authorization: <authorization>' \
--header 'Content-Type: application/json' \
--header 'x-api-key: <x-api-key>' \
--data '
{
"Irn": "49a7c675b25f730d2353622e4767df203fed2495411953e0351737d47308d868",
"CnlRsn": "1",
"CnlRem": "Wrong entry"
}
'{
"code": 200,
"data": {
"Data": {
"CancelDate": "2023-03-30 17:11:00",
"Irn": "49a7c675b25f730d2353622e4767df203fed2495411953e0351737d47308d868"
},
"ErrorDetails": null,
"InfoDtls": null,
"Status": 1
},
"timestamp": 1763446641000,
"transaction_id": "4b8e067e-eb06-42bb-bd23-3fe49f89a2a3"
}E-Invoice access token
Specifies the source to access, either primary (NIC 1) or secondary (NIC 2)
primary, secondary "primary"
Enables criss-cross operations by routing requests through the specified source (e.g., access primary via secondary if primary is unavailable)
primary, secondary "secondary"
API version
API key for identification
"c70892f2468fcab5d0827a04ea0f55fab64edd553dc36a365e38440df443c3ef"
200 IRN cancelled / 9999 IRN is not active / 2270 More than 24 hrs old / 2230 IRN cannot be cancelled as EWB is active / 2143 IRN doesn't belong to user
Was this page helpful?