GCM Chrome:空数据响应 [英] GCM Chrome: Empty Data Response
问题描述
我目前正在将gcm整合到我的web应用程序,订阅和registration_id保存工作中,当我触发邮递员邮件时,我也收到客户的回复。所以现在我需要转移标题和消息。
i用这个参数触发gcm api: http://i.imgur.com/MkrIAzF。 png ,这是从客户端收到的: http://i.imgur.com/gSZtEiY。 png
字段data每次都是空的,
它支持使用 Web推送加密标准。另请参阅developers.google.com网站上的博文。。
您可以自己实现它,也可以使用库网络推送或为Python推送 pywebpush 或PHP的网络推送。
i am currently integrating gcm in my web application, the subscription and the registration_id saving working, i get on the client also the response, when i trigger a message from Postman. So now i need to transfer the title and the message. i am triggering the gcm api with this parameter: http://i.imgur.com/MkrIAzF.png and thats the received from the client: http://i.imgur.com/gSZtEiY.png
The Field "data" is everytime empty,
Despite using GCM as its push service, Chrome doesn't support payloads using the GCM method.
It supports payloads encrypted using the Web Push encryption standard. See also the blog post on the developers.google.com website.
You can either implement it yourself, or use a library such as web-push for Node.js or pywebpush for Python or web-push for PHP.
这篇关于GCM Chrome:空数据响应的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!