跳到主要内容

不当款项 Webhook

提示

我们 webhook 的响应超时时间为 5 秒。

注意!

QI Tech 的 webhooks 不应以严格方式进行映射。 API 返回的 webhook payload 中可能会添加额外字段。

Webhook 重发

您可以按照文档中的详细说明查询并重发 webhooks:Webhook 重发

简介

当 QI Tech 识别并处理不当款项退款时,此 webhook 会自动触发。验证完成后,系统将使用系统中注册的发放账户,通过 PIX 向借款人进行转账。此事件仅在退款成功完成时发送。

不当款项退款 Webhook

Response Body
{
"callback": {
"event_datetime": "2024-01-15T14:30:00.000Z",
"key": "fb34e0ac-2c98-47e7-9040-406b8c3d80e7",
"status": "refunded",
"webhook_type": "laas.devolution.refund_receipt",
"data": {
"devolution_key": "fb34e0ac-2c98-47e7-9040-406b8c3d80e7",
"devolution_amount": 150.75,
"devolution_status": "refunded",
"devolution_reason_description": "The payment arrived earlier than expected. The difference between the paid amount and the present value should be refund",
"receipt_url": "https://storage.googleapis.com/receipts/devolution_receipt_12345.pdf",
"document_key": "cd27a0c3-630d-4682-81b2-71b5b325bcde",
"transacted_at": "2024-01-15T14:25:30.000Z"
}
}
}

字段定义

callback 对象

字段类型描述必填
event_datetimestringISO 8601 UTC 格式的事件日期和时间
keystring退款的唯一 key
statusstring退款状态
webhook_typestringwebhook 类型
dataobject退款的具体数据

data 对象

字段类型描述必填
devolution_keystring退款的唯一 key
devolution_amountnumber退款金额(巴西雷亚尔)
devolution_statusstring退款当前状态
devolution_reason_descriptionstring退款原因描述
receipt_urlstring退款凭证 URL
document_keystring相关文件的 key
transacted_atstringISO 8601 UTC 格式的交易日期和时间

可能的状态

状态描述
refunded退款已成功处理

使用示例

当您收到此 webhook 时,表示已成功处理了一笔 PIX 退款。您可以:

  1. 通过 devolution_status 字段验证退款状态
  2. 通过 receipt_url 提供的 URL 访问凭证
  3. 通过 devolution_amount 字段确认退款金额
  4. 通过 devolution_reason_description 字段了解退款原因