e-Way Bill API
User Guide
 
×
Menu
Index
  • Generation of EWB
Generation of EWB
 
1. GENERATE EWB API is used to generate ewb.
 
2. Rules to generate ewb is given in NIC API INTIGRATION GUIDE https://help.taxprogsp.co.in/ewb/EWB_API_14May2018.docx
 
3. As per new changes on date 23 April
    i. The distance between two locations is automatically calculated based on fromPincode and toPincode, with a grace of 10% extra distance, otherwise  appropriate error is responded without generating the E-waybill. If the distance provided is less than the distance in the database then, E-waybill will be generated without any alert message.
 
    ii. If the distance between the two pin-codes provided is not available in our database, E-waybill will be generated with an alert message as     "The distance between the given pincodes are not available in the system ." and its a responsibility of the generator to provide correct    distance in such cases.
 
    iii. If fromPincode and toPincode are same then, maximum distance allowed is 100 km.
 
    iv. Generation of duplicate E-waybills for the same document by Consignee and Transporter is not allowed hence forth, hence now onwards neither Consignor nor Consignee nor Transporter can generate duplicate E-waybills for the same document.
 
For More Detail -
 
 
Enhancement To Get The Distance Between FromPinCode To ToPinCode
 
If the given distance between fromPinCode & toPinCode is high than the actual distance. Then you will get
following responce
 
=============================================================
Decrypted URL Users
 
{
    "status_cd": "0",
    "error": {
        "error_cd": "702,",
        "message": "{\"fromPinCode\":\"450001\",\"toPinCode\":\"450051\",\"distance\":36}"
    }
}
you can Deserialize  message to RespInfoPl class
RespInfoPl respInfoPl = JsonConvert.DeserializeObject<RespInfoPl>(message);
==============================================================================================
 
 
Library Users
 
Library user will get "{\"fromPinCode\":\"450001\",\"toPinCode\":\"450051\",\"distance\":36}" in TxnResp.RespObj.alert
& 702 error code in TxnResp.TxnOutcome
if (TxnResp.TxnOutcome.Contains("702"))
{
RespInfoPl respInfoPl = new RespInfoPl();
    respInfoPl = JsonConvert.DeserializeObject<RespInfoPl>(TxnResp.RespObj.alert);
    //You can retrive respInfoPl attributes here
    ewbGen.transDistance = respInfoPl.distance;
    //Call GenEWB API again
    TxnResp = await EWBAPI.GenEWBAsync(EwbSession, ewbGen);
    if (TxnResp.IsSuccess)
          rtbResponce.Text = JsonConvert.SerializeObject(TxnResp.RespObj);
    else
          rtbResponce.Text = TxnResp.TxnOutcome;
}
 
=============================================================================================
 
public class RespInfoPl
{
    public string fromPincode { get; set; }
    public string toPincode { get; set; }
    public string distance { get; set; }
}