Oten Tecnologia
Oten Fiscal
Documentation
POST/nfcom/{idOrChave}/cancelamento

Request invoice cancellation

Requests NFCom cancellation. This route is asynchronous. Check the cancellation status at GET /nfcom/{idOrChave}/cancelamento/status.

Production: https://api.otentecnologia.com.brSandbox: https://api.sandbox.otentecnologia.com.br

Parameters

This route has no path or query parameters.

Request

cURL
curl -X POST 'https://api.otentecnologia.com.br/nfcom/{idOrChave}/cancelamento' \
  -H 'x-api-key: $OTEN_API_KEY' \
  -H 'Content-Type: application/json'

Responses

200OK
JSON
{
  "message": "Cancelamento em processamento"
}
400Bad Request
JSON
{
  "error": {
    "message": "Evento de cancelamento é permitido apenas para notas com status CONCLUIDO",
    "data": {
      "id": "5f99e7f54283fe3c5a67b65c",
      "chave": "41201008187168000160558050010000081705343099",
      "status": "REJEITADO"
    }
  }
}
401Unauthorized
JSON
{
  "error": {
    "message": "Token inválido"
  }
}
404Not Found
JSON
{
  "error": {
    "message": "Não localizamos qualquer NFCom com os parâmetros informados",
    "data": {
      "idOrChave": "5f57da21e8bfcfbe1191"
    }
  }
}