TF Fiscal

RPA Receipts

POST/api/rpa/estornar

Reverse RPA

Logical reversal — there is no cancellation, because the RPA is not transmitted anywhere. The receipt stays in the listing flagged as reversed, drops out of every closing total, and the number does not return to the sequence. Later receipts in the same period are not recalculated.

Required headers

tokenstringstringIssuing company token
signstringstringMD5 signature: MD5(token + path + body + timestamp)
timestampstringstringUnix timestamp in seconds

Body

id*stringstringReceipt ID
motivo*stringstringReversal reason (minimum 5 characters)

 * Required field.

Common errors

MessageCause
id inválido / id无效id is not a valid ObjectId
motivo deve ter pelo menos 5 caracteres / motivo至少需5个字符motivo has fewer than 5 characters after trimming
RPA não encontrado / 未找到该RPAThe receipt does not exist or does not belong to the company
RPA já está estornado / 该RPA已冲销The receipt is already reversed

Examples

# sign = md5(token + path + body + timestamp)
# Template generated from the endpoint path; replace the placeholders
curl -X POST "https://api.tffiscal.com/api/rpa/estornar" \
  -H "Content-Type: application/json" \
  -H "token: $TOKEN" \
  -H "timestamp: $TIMESTAMP" \
  -H "sign: $SIGN" \
  -d @body.json