POST
/api/nf3e/cancelCancel NF3e
Cancels an authorized NF3e (event 110111). Only NF3e documents issued through this platform can be cancelled: the access key is looked up in this account's records, and NF3e não encontrada is returned when it is not found. An NF3e already recorded as cancelled on the platform is rejected with an error without being submitted; the cancellation event is sent to the environment (production or test) in which the NF3e was issued.
Required headers
tokenstring | string | Token of the issuing company |
signstring | string | MD5 signature |
timestampstring | string | Unix timestamp in seconds |
Body
chNF3e*string | string | Access key of the NF3e (44 digits) |
xJust*string | string | Cancellation justification (minimum 15 characters as required by the tax authority) |
nProtstring | string | NF3e authorization protocol (16 digits). Optional — when omitted, the authorization protocol recorded on the platform is used; an error is returned when the record has no protocol (not authorized) |
* Required field.
Examples
# sign = md5(token + path + body + timestamp) # Template generated from the endpoint path; replace the placeholders curl -X POST "https://api.tffiscal.com/api/nf3e/cancel" \ -H "Content-Type: application/json" \ -H "token: $TOKEN" \ -H "timestamp: $TIMESTAMP" \ -H "sign: $SIGN" \ -d @body.json
{
"chNF3e": "35260712345678000199660010000000011012345675",
"xJust": "Cancelamento por erro no faturamento da unidade consumidora",
"nProt": "3532600001234567"
}
{
"success": true,
"message": "NF3e cancelada",
"cStat": "135",
"xMotivo": "Evento registrado e vinculado a NF3e",
"nProt": "3532600001234568"
}