事件分组事件标识
customers_marketing_consentcustomers_marketing_consent/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
    店铺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
请求体
  • accepts_marketing boolean
    是否订阅邮件
    Example: true
  • accepts_marketing_updated_at string
    邮箱订阅时间
    Example: 2022-12-16T11:06:11+08:00
  • accepts_mobile_marketing boolean
    是否接受电话营销
    Example: true
  • accepts_mobile_marketing_updated_at string
    电话订阅时间(格式见IOS8601)
    Example: 2022-12-16T11:06:11+08:00
  • addressesobject[]
    地址信息列表
  • address1 string
    地址1
    Example: 7720 Cherokee Road
  • address2 string
    地址2
    Example: 22 Street
  • city string
    城市
    Example: Hagerman
  • company string
    公司
    Example: Joyy
  • country string
    国家
    Example: United States
  • country_code string
    国家编码
    Example: US
  • customer_id string
    客户id
    Example: 2004324532
  • default boolean
    是否默认地址
    Example: true
  • first_name string
    名称
    Example: wude
  • id string
    地址id
    Example: SL201342344234525
  • last_name string
    Example: James
  • phone string
    手机号
    Example: 008615098695473
  • province string
    Example: Kentucky
  • province_code string
    省编码
    Example: KY
  • zip string
    邮政编码
    Example: 40202
  • asid string
    FB登录id
    Example: 456542342
  • birthday string
    客户生日 格式为:YYYYMMDD
    Example: 19930426
  • created_at string
    创建时间
    Example: 2022-12-16T11:06:11+08:00
  • currency string
    币种
    Example: CNY
  • default_addressobject
    默认地址
  • address1 string
    地址1
    Example: 7720 Cherokee Road
  • address2 string
    地址2
    Example: 22 Street
  • city string
    城市
    Example: Hagerman
  • company string
    公司
    Example: Joyy
  • country string
    国家
    Example: United States
  • country_code string
    国家编码
    Example: US
  • customer_id string
    客户id
    Example: 20024344
  • default boolean
    是否默认地址
    Example: true
  • first_name string
    名称
    Example: Bob
  • id string
    地址id
    Example: SL201UA5006511321220969539
  • last_name string
    Example: James
  • phone string
    手机号
    Example: 008613923874352
  • province string
    Example: Kentucky
  • province_code string
    省编码
    Example: KY
  • zip string
    邮政编码
    Example: 40202
  • email string
    邮箱
    Example: gungcherny@gamil.com
  • email_marketing_consentobject
    邮件营销订阅信息
  • consent_collected_from string
    订阅信息来源
    Example: consent_collected_from
  • consent_updated_at string
    订阅变更时间
    Example: 2022-12-16T11:06:11+08:00
  • opt_in_level integer
    订阅方式(0
    ;1
    ;2
    )
    Example: 1
  • state integer
    订阅状态(0:取消订阅;1:已订阅;2:未订阅;3:订阅确认中)
    Example: 1
  • email_subscribe_flag integer
    邮箱订阅状态 0:取消订阅,1:已订阅,2:未订阅
    Example: 1
  • first_name string
    名字
    Example: wude
  • gender string
    性别:male / female / others/secret
    Example: male
  • id string
    客户id
    Example: 2003242345
  • language string
    客户所用语言
    Example: en
  • last_name string
    姓氏
    Example: James
  • last_order_id string
    最近一笔订单号
    Example: 2007732692139103132
  • mobile_subscribe_flag integer
    手机订阅状态0:取消订阅,1:已订阅,2:未订阅
    Example: 1
  • multipass_identifier string
    multipass标识
    Example: multipass_identifier
  • nick_name string
    用户昵称
    Example: Bob James
  • note string
    备注
    Example: high spent customer
  • orders_count long
    订单数量
    Example: 4
  • phone string
    手机号
    Example: 008615087594362
  • sms_marketing_consentobject
    短信营销订阅信息
  • consent_collected_from string
    订阅信息来源
    Example: consent_collected_from
  • consent_updated_at string
    订阅变更时间
    Example: 2022-12-16T11:06:11+08:00
  • opt_in_level integer
    订阅方式(0
    ;1
    ;2
    )
    Example: 1
  • state integer
    订阅状态(0:取消订阅;1:已订阅;2:未订阅)
    Example: 1
  • social_customer string
    社媒用户id
    Example: 62384242394395
  • state string
    客户状态【0 : 已禁用账户,1:待启用账户,2:已邀请账户,3:有效账户】
    Example: 2
  • subscribeActionType integer
    订阅行为 1,邮箱订阅;2,短信订阅;3,取消邮箱订阅;4,取消短信订阅
    Example: 1
  • tags string
    客户标签
    Example: test
  • total_spent string
    总花费金额
    Example: 3243
  • updated_at string
    更新时间
    Example: 2022-12-16T11:06:11+08:00
  • verified_email boolean
    是否验证邮件
    Example: true
响应
收到 SHOPLINE 发送的 Webhook 通知后,你需要按照如下 SHOPLINE 要求的格式进行响应。
HTTP/1.1 200 OK
关于如何订阅 Webhooks 及更多 Webhook 响应规则说明,请参考 Webhook 概述
这篇文章对你有帮助吗?