Cancel E-Waybill

You can use this API to cancel the E-Waybills.

Request Method

POST

Request URL

{{HOST}}​/einv/v2/eInvoice/ewaybill/cancel

Request Headers

Parameter
Data Type
Field Validations
Description

X-Cleartax-Auth-Token

String

NA

Mandatory. The auth token generated from ClearTax user id and password.

Gstin

String

NA

Mandatory. GSTIN number for the user.

Request Path Params

There are no path parameters for this API.

Request Query Params

There are no query parameters for this API.

Request Body

Parameter
Data Type
Field Validations
Description

ewbNo

Body

Number

E-WayBill Number

cancelRsnCode

Body

String

Reason for cancellation Enum:

DUPLICATE

DATA_ENTRY_MISTAKE

ORDER_CANCELLED

OTHERS

cancelRmrk

Body

String

Remarks

Response Status Codes

HTTP Status Code
Description

200

For a successfully processed request (may be a success or validation error).

400

Bad Request. Invalid JSON Payload.

401

If the user is not authenticated for the operation.

403

If the user is not authorized for the operation.

500

If there are any unhandled exceptions on the Clear side.

Response Schema

Parameter
Data Type
Field Validations
Description

ownerId

String

NA

This field will always be null.

gstin

String

NA

Gstin Number

irn

String

64 Digits

Invoice Reference Number

ewbNumber

12 Digits

E-Way Bill number

ewbStatus

String

Enum: Cancelled, null

Status of the E-Way Bill

errorDetails

Object

NA

Error Details. If there is no error then the value of this field will be null.

Error Details Object

Parameter
Data Type
Field Validation
Description

error_code

Number

NA

Error code

error_message

String

NA

Error message

error_source

String

NA

Error source

Sample Request and Response

Request

{
    "ewbNo": 151256807504,
    "cancelRsnCode": "DUPLICATE",
    "cancelRmrk" : "Duplicate Entry"
}

Response - Success:

HTTP Status Code - 200 OK

{
    "ownerId": null,
    "gstin": "29AAFCD5862R000",
    "irn": "385b6129a2da705952496775e85811c3a5ff9cc4bfba53649d57162d3d4bd3c8",
    "ewbNumber": 171010278843,
    "ewbStatus": "CANCELLED",
    "errorDetails": null
}

Response - Failure:

HTTP Status Code - 200 OK

{
    "ownerId": null,
    "gstin": "29AAFCD5862R000",
    "irn": null,
    "ewbNumber": 151011726811,
    "ewbStatus": null,
    "errorDetails": {
        "error_code": "107",
        "error_message": "cancelRsnCode : Cancel Reason Code is mandatory. Please correct the Cancel Reason Code and try again.",
        "error_source": "CLEARTAX"
    }
}

API Validations

E-Waybill should be present in the ClearTax database under your dedicated workspace.

API Constraints

  1. E-way bills can be cancelled by the generator of the e-way bill only.

  2. E-way bills can be cancelled within 24 hours of generation of e-way bill

Last updated

Was this helpful?