TF Fiscal

RPA Receipts

POST/api/rpa/get_pdf

Get RPA PDF

Returns the receipt PDF URL. It is generated on the first call and reused afterwards. The PDF derives from stored data — including the frozen calculation memo — so regerar never changes any amount.

Required headers

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

Body

id*stringstringReceipt ID
regerarboolboolForce PDF rebuild instead of reusing

 * Required field.

Common errors

MessageCause
id inválido / id无效id is not a valid ObjectId
RPA não encontrado / 未找到该RPAThe receipt does not exist or does not belong to the company
Falha ao gerar o PDF do RPA / 生成RPA的PDF失败PDF generation failed
Falha ao enviar o PDF do RPA / 上传RPA的PDF失败Upload of the PDF to file storage failed

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/get_pdf" \
  -H "Content-Type: application/json" \
  -H "token: $TOKEN" \
  -H "timestamp: $TIMESTAMP" \
  -H "sign: $SIGN" \
  -d @body.json