事件分组事件标识
refundsrefunds/create
当订单上创建新退款时就会发生,与资金流动无关
请求头
  • 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
    店铺id
    Example: 1610418123456
  • X-Shopline-Merchant-Id string required
    商户ID
    Example: 2000001234
  • X-Shopline-API-Version string required
    版本号
    Example: v20210901
  • X-Shopline-Webhook-Id string required
    消息ID
    Example: b54557e48a5fbf7d70bcd043
请求体
  • created_at string
    退款单创建时间 (格式见IOS8601)
    Example: 2022-10-03T12:44:45-04:00
  • id string
    退款id
    Example: 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
    退款调整单id
    Example: 2309123221222208434
  • kind string
    调整单类型
    Example: shipping_refund
  • order_id string
    订单号
    Example: 21057168152571061289431726
  • reason string
    调整原因
    Example: reason msg
  • refund_id string
    退款单id
    Example: 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
    商品属性:名称 - 属性值 多个以逗号", "分割 如:颜色 - 红色, 尺寸 - X
    Example: 尺寸 - 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
    商品售价,精度2
    Example: 100
  • price_setobject
    多币种售价
  • presentment_moneyobject
    买家侧币种
  • amount string
    金额
  • currency_code string
    币种
  • shop_moneyobject
    卖家侧金额信息
  • amount string
    金额
  • currency_code string
    币种
  • product_id string
    spu序列号
    Example: 18054488231146952151833534
  • quantity integer
    商品数量
    Example: 1
  • requires_shipping boolean
    是否需要发货
    Example: true
  • sku string
    商品码,barCode
    Example: SKU1234
  • tax_linesobject[]
    税费信息
  • price string
    税费,精度2
    Example: 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
    退款金额合计,精度2
    Example: 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
    退款商品的税额,精度2
    Example: 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
    退款金额,精度2
    Example: 100
  • created_at string
    创建时间
    Example: 2022-10-03T12:44:45-04:00
  • currency string
    币种
    Example: USD
  • id string
    退款id
    Example: 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 error
    Example: success
  • user_id string
    买家id
    Example: 4323434
  • user_id string
    用户id
    Example: 16576456
响应
收到 SHOPLINE 发送的 Webhook 通知后,你需要按照如下 SHOPLINE 要求的格式进行响应。
HTTP/1.1 200 OK
关于如何订阅 Webhooks 及更多 Webhook 响应规则说明,请参考 Webhook 概述
这篇文章对你有帮助吗?