iPhone中没有收到bluemix通知

时间:2015-07-31 02:32:51

标签: ios mobile apple-push-notifications ibm-cloud ibm-mobile-services

我一直在尝试使用Bluemix向IOS设备发送推送通知,在仪表板中,它提供了Notification发送的成功响应,但我在任何设备中都没有收到相同的响应。

Note: Getting an response "UserId not set". Please do the needful.

Response:
Device is already registered. Return the device Id - Response is: httpStatus: 200
responseHeaders: {
    "Cache-Control" = "no-cache=\"set-cookie, set-cookie2\"";
    Connection = "Keep-Alive";
    "Content-Type" = "application/json";
    Date = "Fri, 31 Jul 2015 02:23:43 GMT";
    Expires = "Thu, 01 Dec 1994 16:00:00 GMT";
    "Set-Cookie" = "LtpaToken2=OwuD5qhTnGA48q9L5dQ+U2niyL+3R52+0ckK09o1Q2dPfq6ZJeIqXtvlb3mdwCP68o+LrjLdHcZOIqTwnQrgM7E3GPOde80ENO5T73uNbi/nUx1G358YpBu/D7TXO/gN+TT6zv/ShGI+ECDQwQVjkk5o7e8PRNje7QwGTe6ls/KASQ3PnPrt5HaKmdhaCtGqDm/dfbhIdF04uXWsAfLUpBqzrzt3lHd1nxQkOfCHyKp7xl2Rp3lh4x6oIDNMHph04zgukwVOEHftKXN4TgAj8Xd0ug9cGxuKthfPCr2gsoKc0KrOABSODHUhcHjW010YnU0Eam60Yr+iR5axhzs1M8FY83VOXC+CcrQINBfCakvArP0PecwVTK2qfSQSnfPBD+wokCwMX78YMukIXs2fprsFwvNE/ZE9tKIfiz9C9ruVe0c6h79fbUx9C0yuugZMDaOheiEXfgAUL6QVu4cWQG1Ul1HV+8SVq9VKh1GjKd4=; Path=/; HttpOnly";
    "Transfer-Encoding" = Identity;
    "X-Backside-Transport" = "OK OK";
    "X-Cf-Requestid" = "bbb1720e-9d41-44d8-4151-871119ed5a68";
    "X-Client-IP" = "60.51.27.236";
    "X-Global-Transaction-ID" = 987171295;
    "X-Powered-By" = "Servlet/3.0";
}
responseJson: {
  createdTime = "2015-07-31T02:23:06Z";
  deviceId = "84278A9D-FB54-4E71-ASS1-F5F62113C813";
  lastUpdatedTime = "2015-07-31T02:23:06Z";
  token = 281e351bfa3350e9e2ca96ec95dbf635363e30c708a14903awew7c670eba06ac;
    userId = "UserId not set";
}
Response text: {"deviceId":"84278A9D-FB54-4E71-ASS1-F5F62113C813","token":"281e351bfa3350e9e2ca96ec95dbf635363e30c708a1490xxx7c670eba06ac","userId":"UserId not set","createdTime":"2015-07-31T02:23:06Z","lastUpdatedTime":"2015-07-31T02:23:06Z"}

1 个答案:

答案 0 :(得分:0)

  1. 您可以检查以确保您上传的推送证书未过期。您可以在Push-> Configuration

  2. 下的Push Dashboard中找到它
  3. 当您发送推送通知时,应用程序是在后台吗?除非您在收到推送通知时编写了专门处理的代码,并且应用程序位于前台,否则您将看不到推送通知。您可以在“didReceiveRemoteNotification”函数中编写一些代码,例如显示快速测试的警报。