payload如下,提交后报400,但是后台可以用别名推消息


(Ahah) #1
{"platform":["android"],
"audience":{"alias":["15921768522","18723450022"]},
"message":{"title":"data","msg_content":"d_new_order","content_type":"text","extras":{"elongitude":"","p_cancel":"","order_time":"2018-04-10 12:55:59","d_account":"","type":"00+电召订单","sposition":"","p_account":"13800000001","call_duration":"12","duration":"","path":"","com_time":"","d_name":"","d_evaluation":"","p_score":"","tip":"","company":"","p_tel":"13800000001","eposition":"","d_want":"0","d_status":"","order":"1407620120180410000013","driver_position":"","mileage":"","voide":"/telaudio/2018/04/10/1407620120180410000013BVPHJVUF.mp3","cost":"0.00","coupon":"","receive_time":"","p_evaluation":"","bill":"0.00","d_cancel":"","e_time":"","d_tel":"","ordersource":"01+电召","t_id":"14076202","slongitude":"","deduction":"","p_name":"","slatitude":"","car_number":"","d_score":"","elatitude":"","status":"00+发单中"}},
"options":{"sendno":1685521109,"apns_production":false}}

#2

400 对应多种报错码,请捕获具体的报错码和Message描述 来排查问题
https://docs.jiguang.cn/jpush/server/push/rest_api_v3_push/#_19


(Ahah) #3

[INFO ] 2018-04-10 11:03:11,084 method:com.communication.function.MessagePush.PushMessagebyalias(MessagePush.java:254)
Error Message: cannot find user by this audience
[INFO ] 2018-04-10 11:03:11,090 method:com.communication.function.MessagePush.PushMessagebyalias(MessagePush.java:255)
Msg ID: 2829696571
[ERROR] 2018-04-10 11:03:11,101 method:com.communication.function.MessagePush.PushMessagebyalias(MessagePush.java:256)
Sendno: 992809689


#4

根据上述说明排查。

你说官网可以,那么对照推送历史-详情,对比 API 推送的和官网推送的内容的不同之处。


(Ahah) #5

代码是1011,没有满足条件的推送目标,但是我用极光平台推送就可以推送成功


(Ahah) #6

我就是对照过,没有找到区别,才在这里问的:sweat:
别名就是这个"audience":{“alias”:[“15921768522”,“18723450022”]},平台上也没上不一样啊


#7

检查 AppKey 对不对

提供 AppKey ,API 推送的消息的 msgid,和官网推送的消息的 msgid


(Ahah) #8

appkey:33681b13acd5737d2f144053
api msgid:2829696571
官网id:9007203646416805


#9

API 推送得到的 msgid 2829696571在 33681b13acd5737d2f144053 和 c18b1196ef79951ae8ef2c35下都查不到

官网推送使用的 AppKey 是 AppKey c18b1196ef79951ae8ef2c35 应用名是的哥家族,别名传的是"15921768522"

请你去仔细检查你调 API 时做调用验证时传的 AppKey 值!


(Ahah) #10

辛苦了,谢谢!