Register the cancellation of a toll voucher by submitting the required data for asynchronous processing. Once the request is received, the system starts processing and returns a GUID for tracking.
Endpoint
-
POST:
/valePedagio/cancelar/{enterpriseId} -
Route Parameters
-
enterpriseId: CNPJ associated with the operation (string)
-
Request Body
The request body must be a JSON containing the cancellation data:
Look the reference for full details.
{
"cnpj": "CNPJ associated with the operation",
"ndvp": "NDVP number or identifier of the toll voucher",
"codigoVerificador": "NDVP verification code",
"motivo": "Reason for cancellation"
}
Layout
cancelamento
Object that contains the toll voucher cancellation data.
|
Field |
Type |
Description |
|---|---|---|
|
cnpj |
string(14) |
CNPJ associated with the operation |
|
ndvp |
string |
NDVP number or identifier |
|
codigoVerificador |
string |
NDVP verification code |
|
motivo |
string |
Reason for cancellation |
Response
After submitting the cancellation request, the API returns a JSON with the request status and a GUID for tracking.
-
sucesso: indicates whether the request was accepted (true) or rejected (false) -
guid: unique identifier to track the cancellation processing -
codigoandmensagem: may contain additional information or messages depending on the implementation
Success Example
{
"sucesso": true,
"guid": "xxxxxxxxxxxxxxx",
"codigo": "000",
"mensagem": "Batch received for processing."
}
Error Example
{
"sucesso": false,
"guid": "",
"codigo": "400",
"mensagem": "Validation error in request parameters."
}