订单更新
事件分组 | 事件标识 |
---|---|
orders | orders/updated |
订单更新
请求头
- 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
请求体
- adjust_price string调整金额
adjust_price_setobject
调整金额presentment_moneyobject
买家侧的金额信息amount string金额,精度2currency_code string币种shop_moneyobject
卖家侧的金额信息amount string金额,精度2currency_code string币种billing_addressobject
账单地址address1 string详细地址1address2 string详细地址2city string城市company string公司名称country string国家/地区country_code string国家/地区编码first_name string名last_name string姓name string姓名phone string电话province string省/二级地址province_code string省/二级地址编码zip string邮编- browser_ip string浏览器ip
- buyer_note string买家备注
- cancel_reason string取消订单原因
- cancelled_at string取消时间
- cart_token string购物车token
- checkout_id string当前订单关联的弃单id
- checkout_token string结算页token
client_detailsobject
客户端信息browser_ip string浏览器IPsession_hash stringsessionIduser_agent string客户端代理uuid stringuuid- created_at string创建订单时间
- currency string结算币种
- current_subtotal_price string当前商品总和,商品总价*数量
current_subtotal_price_setobject
当前商品总和多币种信息, 买卖家币种和金额一致presentment_moneyobject
买家侧金额信息amount string金额,精度2currency_code string币种shop_moneyobject
卖家侧金额信息amount string金额,精度2currency_code string币种- current_total_discounts string折扣总和,精度2,营销优惠+人工折扣
current_total_discounts_setobject
折扣总和多币种信息,没有多币种,所以买卖家币种和金额一致presentment_moneyobject
买家侧金额信息amount string金额,精度2currency_code string币种shop_moneyobject
卖家侧金额信息amount string金额,精度2currency_code string币种- current_total_price string当前订单总额,取值逻辑:商品总额 - 优惠总额 + 运费 + 税费
current_total_price_setobject
当前订单总额多币种信息,买卖家币种和金额一致presentment_moneyobject
买家侧金额信息amount string金额,精度2currency_code string币种shop_moneyobject
卖家侧金额信息amount string金额,精度2currency_code string币种- current_total_tax string税费总和,商品税 + 运费税
current_total_tax_setobject
税费总和多币种信息, 买卖家币种和金额一致presentment_moneyobject
买家侧金额信息amount string金额,精度2currency_code string币种shop_moneyobject
卖家侧金额信息amount string金额,精度2currency_code string币种customerobject
买家信息addressesobject
地址address1 string详细地址1address2 string详细地址2,备选city string城市country string国家/地区country_code string国家/地区编码first_name string名last_name string姓name string全名phone string电话province string省province_code string省编码zip string邮编area_code string手机区号created_at string买家创建时间currency string币种email string用户邮箱first_name string名id string用户idlast_name string姓phone string用户手机号- customer_locale string买家国家 语种编码+国家名称缩写
- deduct_member_point_amount string当前订单会员积分抵扣金额
discount_applicationsobject[]
该订单应用的所有折扣信息allocation_method string活动的折扣应用范围 1)across(该值分布在所有授权行中) 2)each(该值应用于每个授权行)Example:across
code string活动的具体描述Example:1Q3UMQM8RBP5
description string活动的具体描述Example:活动的具体描述
target_selection string活动的折扣应用具体对象 1)explicit(折扣分配到明确选择的商品行或运费行) 2)all(折扣分配到所有商品行或运费行) 3)ENTITLED(折扣仅分配到其有权使用的商品行或运费行)Example:all
target_type string活动的折扣应用对象 1)line_item 2)shipping_lineExample:line_item
title string活动的具体描述Example:活动的具体描述
type string活动折扣类型 1)manual(自定义类型) 2)automatic(自动折扣类型) 3)discount_code(折扣码类型)Example:manual
value string活动的折扣值Example:20
value_type string活动的折扣值类型,包含百分比和固定金额两类Example:fixed_amount
discount_codesobject[]
优惠码信息amount string优惠金额,精度2code string优惠码type string优惠类型, 1-减金额;2-打折;3-免运费;8-固定售价;9-最低价商品免费;10-打包价;11-第N件打折;- email string买家邮箱
- financial_status string支付状态: unpaid - 未支付; authorized - 已授权;pending-支付中; partially_paid-部分支付; paid-已支付; partially_refunded-部分退款; refunded-已退款;
- fulfillment_status string发货状态, fulfilled-已发货; partial-部分发货; null-未发货; 注:返回的枚举值与入参的查询枚举值不一样
fulfillmentsobject[]
包裹信息created_at string创建时间(格式见IOS8601)id string包裹编号line_itemsobject[]
商品列表attribute string商品属性:名称 - 属性值 多个以逗号", "分割 如:颜色 - 红色, 尺寸 - Xfulfillable_quantity integer可发货数量fulfillment_service string物流商名称,如果一种商品有多个不同的发货服务商,则以逗号分隔fulfillment_status string商品的发货状态, 发货状态, fulfilled-已发货; partial-部分发货; null-未发货;grams double重量(克)id string商品快照表的id, 系统生成,与订单号唯一确认一个商品image_url string商品图片location_id string地点IDname stringsku标题price string商品售价,精度2product_id stringspu序列号quantity integer订单中的商品数量requires_shipping boolean是否需要发货sku string商品码tax_linesobject[]
税费信息price string价格price_setobject
税费多币种信息presentment_moneyobject
买家侧金额信息amount string金额,精度2currency_code string币种shop_moneyobject
卖家侧金额信息amount string金额,精度2currency_code string币种rate double税率title string税费名称taxable boolean是否收税title string商品标题variant_id string商品sku序列号variant_title string商品属性值, 多个以" / "分割, 如: “155 / 红色 / 大"vendor string供应商name string发货单短号Example:1032-F2
order_id string订单号shipment_status string包裹状态status string物流配送状态, success-已发货; cancelled-已取消;tracking_company string物流公司名称tracking_number string第三方物流单号tracking_url string物流公司urlupdated_at string更新时间(格式见IOS8601)- hidden_order boolean是否是归档订单, true=已归档订单, false=未归档订单
- id string系统订单号
line_itemsobject[]
订单商品快照信息attribute string商品属性:名称 - 属性值 多个以逗号", "分割 如:颜色 - 红色, 尺寸 - Xdiscount_allocationsobject[]
折扣明细金额多币种amount string折扣明细金额Example:8.00
amount_setobject
折扣明细金额多币种presentment_moneyobject
支付币种amount string金额,精度2Example:8.00
currency_code string币种Example:USD
shop_moneyobject
店铺币种amount string金额,精度2Example:8.00
currency_code string币种Example:USD
discount_application_index integer标明在折扣明细中的位置Example:1
fulfillable_quantity integer可发货数量fulfillment_service string物流商名称,如果一种商品有多个不同的发货服务商,则以逗号分隔fulfillment_status string商品的发货状态, 发货状态, fulfilled-已发货; partial-部分发货; null-未发货;gift_card boolean是否为礼品卡商品grams double重量(克)id string商品快照表的id, 系统生成,与订单号唯一确认一个商品image_url string商品图片location_id string地点IDname stringsku标题price string商品售价,精度2price_setobject
商品售价,多币种金额信息presentment_moneyobject
支付币种amount string金额,精度2Example:8.00
currency_code string币种Example:USD
shop_moneyobject
店铺币种amount string金额,精度2Example:8.00
currency_code string币种Example:USD
product_id stringspu序列号propertiesobject[]
商品定制信息additional string定制商品附加字段name string自定义属性名称type string属性类型, text-字符,展示格式为 name: value; picture-图片,展示类型为 name: 通过urls获取渲染出缩略图;link-超链,展示类型为 name: value,支持点击链接跳转 到urls第一个urls arrayurl资源列表Example: ``value string自定义属性值quantity integer订单中的商品数量requires_shipping boolean是否需要发货sku string商品码tags string商品标签(多个逗号隔开)tax_linesobject[]
税费信息price string价格price_setobject
税费多币种信息presentment_moneyobject
买家侧金额信息amount string金额,精度2currency_code string币种shop_moneyobject
卖家侧金额信息amount string金额,精度2currency_code string币种rate double税率title string税费名称type string税费用类型,用于区分是商品税还是运费税,枚举值如下 product_tax:商品税 shipping_tax:运费税Example:shipping_tax
taxable boolean是否收税title string商品标题variant_id string商品sku序列号variant_title string商品属性值, 多个以" / "分割, 如: “155 / 红色 / 大"vendor string供应商- name string自定义单号(会变化)
- note string商家备注内容, 多个以逗号分隔
note_attributesobject[]
商家备注日志,日期内容create_time string备注创建时间(格式见IOS8601)name string备注来源(卖家标识)value string备注内容- order_at string成单时间
- order_status_url string订单状态页url
payment_detailsobject[]
支付单信息create_time string支付单创建时间pay_amount double支付金额pay_channel_deal_id string支付流水号:支付渠道生成的支付号pay_seq string支付网支付单号, SL内部定义的支付单的唯一编号请求号pay_status string支付状态- payment_gateway_names array付款方式列表,该订单所用到的付款方式列表Example: ``
- phone string买家联系方式
- presentment_currency string买家侧币种
- processed_user_id string订单创建者Example:
4201057495
refundsobject[]
退款列表created_at string退款单创建时间 (格式见IOS8601)id string退款idnote string退款备注order_id string订单号processed_at string更新时间user_id string用户idshipping_addressobject
收货地址address1 string详细地址1address2 string详细地址2,备选city string城市company string公司名称country string国家country_code string国家码delivery_store_code string门店编码delivery_store_name string门店名称district string区district_code string区编码first_name string名last_name string姓latitude string地址纬度Example:23.35773
longitude string地址经度Example:116.4151
name string全名phone string电话province string省份province_code string省份码zip string邮编shipping_linesobject[]
shippingLinescode string物流编号discount_allocationsobject[]
折扣明细金额多币种展示amount string折扣金额,精度2Example:8.00
amount_setobject
折扣多币种金额presentment_moneyobject
买家侧金额信息amount string金额,精度2Example:8.00
currency_code string币种Example:USD
shop_moneyobject
店铺侧金额信息amount string金额,精度2Example:8.00
currency_code string币种Example:USD
discount_application_index integer在折扣明细中的位置Example:1
discounted_price string折扣金额,精度2discounted_price_setobject
折扣多币种金额presentment_moneyobject
买家侧金额信息amount string金额,精度2Example:8.00
currency_code string币种Example:USD
shop_moneyobject
店铺侧金额信息amount string金额,精度2Example:8.00
currency_code string币种Example:USD
phone string电话price string物流运费, double类型的字符串price_setobject
物流运费多资源信息presentment_moneyobject
买家侧币种金额amount string金额,精度2currency_code string币种shop_moneyobject
卖家侧币种金额amount string金额,精度2currency_code string币种shipping_price string原运费金额值(非折扣后金额)Example:8.00
source string物流类型tax_linesobject[]
物流名称price string价格price_setobject
税费多币种信息presentment_moneyobject
卖家侧币种金额amount string金额,精度2currency_code string币种shop_moneyobject
买家侧币种金额amount string金额,精度2currency_code string币种rate double税率title string税费名称title string物流名称- status string订单状态,open-处理中,cancelled-已取消
- store_id string店铺ID
- subtotal_price string商品折后价总和, 商品总价 - 营销优惠 - 人工折扣
subtotal_price_setobject
商品折后价总和多币种信息presentment_moneyobject
买家侧金额信息amount string金额,精度2currency_code string币种shop_moneyobject
卖家侧金额信息amount string金额,精度2currency_code string币种- tags string订单标签
tax_linesobject[]
税费price string价格price_setobject
多币种金额信息presentment_moneyobject
买家侧金额信息amount string金额,精度2currency_code string币种shop_moneyobject
卖家侧金额信息amount string金额,精度2currency_code string币种rate double税率title string税费名称- tax_number string税号
- tax_type string税号类型
- taxes_included boolean总计额是否包含税额
- total_discounts string折扣总额,营销优惠+人工折扣
total_discounts_setobject
折扣总额多币种信息presentment_moneyobject
买家侧金额信息amount string金额,精度2currency_code string币种shop_moneyobject
卖家侧金额信息amount string金额,精度2currency_code string币种- total_line_items_price string商品原价总和,精度2
total_line_items_price_setobject
商品原价总和,多币种信息presentment_moneyobject
买家侧金额信息amount string金额,精度2currency_code string币种shop_moneyobject
卖家侧金额信息amount string金额,精度2currency_code string币种- total_outstanding string未付款金额总和,精度2
total_shipping_price_setobject
订单运费总和,多币种信息presentment_moneyobject
买家侧金额信息amount string金额,精度2currency_code string币种shop_moneyobject
卖家侧金额信息amount string金额,精度2currency_code string币种- total_tax string税费总和,精度2, 商品税 + 运费税
total_tax_setobject
税费总和,多币种信息presentment_moneyobject
买家侧金额信息amount string金额,精度2currency_code string币种shop_moneyobject
卖家侧的金额信息amount string金额,精度2currency_code string币种- total_tip_received string小费,精度2
- total_weight double商品总重量(g)
- updated_at string订单更新时间,(格式见IOS8601)
- user_id string买家id
响应
收到 SHOPLINE 发送的 Webhook 通知后,你需要按照如下 SHOPLINE 要求的格式进行响应。
HTTP/1.1 200 OK
关于如何订阅 Webhooks 及更多 Webhook 响应规则说明,请参考 Webhook 概述。
这篇文章对你有帮助吗?
Error loading component.