跳转到内容
返回官网

推送消息配置

开发者配置各平台的消息推送。注意:调用后会再按此次接口配置的消息列表覆盖所有以前的配置,请谨慎操作。

接口地址:

https://kf.fw199.com/gateway/partner/event/update

参数名类型说明示例
appidString开发者AppId开放平台提供
timestamplong当前时间戳,开发者的接口请求和开放平台的时间差在5分钟之内。
seller_nickstring开发者对应的seller_nick百鞋馆
opstring包括:taobao,taobao_daifa,jd,pdd,ks,1688,doudian_oms,doudian_erptaobao
topic_liststring需要开通消息类型的列表。tb_push_success_trade
signstring接口签名 ,对请求参数进行签名,签名算法可参考附件示例代码

请求示例

String op = "taobao";
//业务参数
Map<String, String> data = new HashMap<String, String>();
data.put("appid", Config.AppId);
Long timestamp = System.currentTimeMillis() / 1000;
data.put("timestamp", timestamp.toString());
data.put("seller_nick", Config.TBSellerNick);
data.put("op",op);
data.put("topic_list","[\"tb_push_success_trade\",\"tb_refund_refundsuccess\",\"tb_alibaba_invoice_apply\"]");
// 签名
data.put("sign", Utils.Sign(data,Config.AppSecret));
// 调用服务API
doHttpRequest(Config.EventListUpdate ,data);

返回示例

{"code":0,"message":"ok","data":"操作成功"}

其中,code为0表示成功,非0为失败,失败时,message中会有失败信息。