退款更新
事件分组 | 事件标识 |
---|---|
refunds | refunds/update |
当订单上创建新退款时就会发生,与资金流动无关
请求头
- X-Shopline-Topic string required事件操作标识Example:
orders/edited
- X-Shopline-Hmac-Sha256 string required签名Example:
XWmrwMey6OsLMeiZKwP4FppHH3cmAiiJJAweH5Jo4bM=
- X-Shopline-Shop-Domain string required店铺域名Example:
shophub.myshopline.com
- X-Shopline-Shop-Id string required店铺idExample:
1610418123456
- X-Shopline-Merchant-Id string required商户IDExample:
2000001234
- X-Shopline-API-Version string required版本号Example:
v20210901
- X-Shopline-Webhook-Id string required消息IDExample:
b54557e48a5fbf7d70bcd043
请求体
- created_at string退款单创建时间 (格式见IOS8601)Example:
2022-10-03T12:44:45-04:00
- id string退款idExample:
SL201AS4571669738589065294
- note string退款备注Example:
备注
order_adjustmentsobject[]
调整单信息amount string调整单金额Example:100
amount_setobject
调整单金额presentment_moneyobject
展示金额amount double金额Example:100
currency_code string币种Example:USD
shop_moneyobject
商铺金额amount double金额Example:100
currency_code string币种Example:USD
id string退款调整单idExample:2309123221222208434
kind string调整单类型Example:shipping_refund
order_id string订单号Example:21057168152571061289431726
reason string调整原因Example:reason msg
refund_id string退款单idExample:27057168152571061289431726
tax_amount string调整单税费金额Example:100
tax_amount_setobject
调整单税费金额presentment_moneyobject
展示金额amount double金额Example:100
currency_code string币种Example:USD
shop_moneyobject
商铺金额amount double金额Example:100
currency_code string币种Example:USD
- order_id string订单号Example:
21057168152571061289431726
- processed_at string更新时间 (格式见IOS8601)Example:
2022-10-03T12:44:45-04:00
refund_line_itemsobject[]
退款详细信息id string退款单号Example:27057168152571061289431726
line_itemobject
商品行attribute string商品属性:名称 - 属性值 多个以逗号", "分割 如:颜色 - 红色, 尺寸 - XExample:尺寸 - X
fulfillable_quantity integer可发货数量Example:1
fulfillment_quantity integer可发货数量Example:1
fulfillment_service string物流商名称Example:走四方
fulfillment_status string商品的发货状态, 发货状态, fulfilled-已发货; partial-部分发货; null-未发货;Example:partial
grams double重量(克)Example:1.2
id string商品快照表的id, 系统生成,与订单号唯一确认一个商品Example:2655436734527560
price string商品售价,精度2Example:100
price_setobject
多币种售价presentment_moneyobject
买家侧币种amount string金额Example:20
currency_code string币种Example:USD
shop_moneyobject
卖家侧金额信息amount string金额Example:20
currency_code string币种Example:USD
product_id stringspu序列号Example:18054488231146952151833534
quantity integer商品数量Example:1
requires_shipping boolean是否需要发货Example:true
sku string商品码,barCodeExample:SKU1234
tax_linesobject[]
税费信息price string税费,精度2Example:100
price_setobject
税费多币种信息presentment_moneyobject
买家侧币种amount string金额Example:100
currency_code string币种Example:USD
shop_moneyobject
卖家侧金额信息amount string金额Example:100
currency_code string币种Example:USD
rate double税率Example:1.2
title string标题Example:标题
type string税费类型,product_tax:商品税 ; shipping_tax:运费税Example:product_tax
taxable boolean是否收税Example:true
title string商品标题Example:T-short
variant_id string商品sku序列号Example:18054488231146952151833534
variant_title string商品属性值, 多个以" / "分割, 如: “155 / 红色 / 大"Example:155 / 红色 / 大
vendor string供应商Example:供应商
line_item_id string商品快照表的id, 系统生成,与订单号唯一确认一个商品Example:23312553324324
quantity integer数量,商品数量Example:1
restock_type string库存返还类型,no_restock-未返还,cancel-取消, return-返还 只有未返还Example:no_restock
subtotal double退款金额合计,精度2Example:100
subtotal_setobject
退款金额合计,多币种信息,卖家和买家侧相同presentment_moneyobject
买家侧币种amount string金额Example:100
currency_code string币种Example:USD
shop_moneyobject
卖家侧金额信息amount string金额Example:100
currency_code string币种Example:USD
total_tax double退款商品的税额,精度2Example:100
total_tax_setobject
总税额,多币种信息presentment_moneyobject
卖家侧币种amount string金额Example:100
currency_code string币种Example:USD
shop_moneyobject
买家侧币种amount string金额Example:100
currency_code string币种Example:USD
transactionsobject[]
退款交易信息amount string退款金额,精度2Example:100
created_at string创建时间Example:2022-10-03T12:44:45-04:00
currency string币种Example:USD
id string退款idExample:10100112220607455014540963840
kind string交易类型(authorization, capture, sale, void, refund)Example:refund
order_id string订单号Example:21056836827909126061559008
processed_at string创建时间Example:2022-10-03T12:44:45-04:00
status string处理状态, pending, failure, success, and errorExample:success
user_id string买家idExample:4323434
- user_id string用户idExample:
16576456
响应
收到 SHOPLINE 发送的 Webhook 通知后,你需要按照如下 SHOPLINE 要求的格式进行响应。
HTTP/1.1 200 OK
关于如何订阅 Webhooks 及更多 Webhook 响应规则说明,请参考 Webhook 概述。
这篇文章对你有帮助吗?