web-push

Web push service worker registration error - Registration failed - could not retrieve the public key ?

半城伤御伤魂 提交于 2019-12-11 04:44:13
问题 When trying to install a service worker (Chrome 55), I'm getting this error in the browser console. Registration failed - could not retrieve the public key But this is happening only in the browser in one of the devices. In other devices in chrome 55, it's working fine. I'm not able to replicate this issue in other devices with the same chrome version. So I suppose this is not a problem with worker or manifest files. I would be very happy somebody could throw some light on this issue. 回答1: I

GCM webpush in background

两盒软妹~` 提交于 2019-12-11 03:56:07
问题 I implemented web push notifications. Steps to get a bug: Open website Subscribe for push notifications Send many pushes through gcm - all fine Close tab with site Send push and receive "double push" - first one is ok, second is "This site has been updated in background" Reopen website Send push - all fine I know this can happen when the service worker receives push and doesn't show notification. But I see normal notification, why I also see other strange notification? Can I get rid such

Web Push with VAPID: 400/401 Unauthorized Registration

*爱你&永不变心* 提交于 2019-12-10 09:09:25
问题 First of all, I've already check these questions, without any luck: Web Push API Chrome, returning "Unauthorized Registration" [WebPush][VAPID] Request fails with 400 UnauthorizedRegistration I am trying to implement web push notifications for a web app that I'm working on. Currently, I've achieved the following goals: Create a VAPID keys pair (with this guide). Register a service worker (only a service worker, I think that manifest.json is no longer required). Subscribe the user to the

Firefox web push “Invalid URL endpoint”

ⅰ亾dé卋堺 提交于 2019-12-08 07:29:30
问题 I try to send webpush to firefox curl -i -X PUT https://updates.push.services.mozilla.com/push/gAAAAABW5EzHyop8VZSH2jm9LJ7W8ybH3ISlbZHDGnd4RwW7h2Jb0IGTuSsP2BCoBxl0kJp-kXXL164xNzhxkTEztP1-IqVf9040VOEuy_htb1nnp-24W-RGgWgjtGK1kZYAb1k3xmAS HTTP/1.1 400 Bad Request Access-Control-Allow-Headers: content-encoding,encryption,crypto-key,ttl,encryption-key,content-type,authorization Access-Control-Allow-Methods: POST,PUT Access-Control-Allow-Origin: * Access-Control-Expose-Headers: location,www

Web Push notification Payload data is getting null

杀马特。学长 韩版系。学妹 提交于 2019-12-08 05:57:36
问题 Hi I'm trying to implement web push notification for web i followed the following example,except the server part for which i'm using python script to connect to gcm/fcm and generating payload .i'm getting the push event but the event.data coming null . from datetime import datetime from pyfcm import FCMNotification pushService = FCMNotification(api_key ='xxx'} registrationId="" messageTitle = "New update available" messageBody ="some message" dryRun = False extraData = {} extraData['title'] =

Firefox web push “Invalid URL endpoint”

允我心安 提交于 2019-12-07 14:16:33
I try to send webpush to firefox curl -i -X PUT https://updates.push.services.mozilla.com/push/gAAAAABW5EzHyop8VZSH2jm9LJ7W8ybH3ISlbZHDGnd4RwW7h2Jb0IGTuSsP2BCoBxl0kJp-kXXL164xNzhxkTEztP1-IqVf9040VOEuy_htb1nnp-24W-RGgWgjtGK1kZYAb1k3xmAS HTTP/1.1 400 Bad Request Access-Control-Allow-Headers: content-encoding,encryption,crypto-key,ttl,encryption-key,content-type,authorization Access-Control-Allow-Methods: POST,PUT Access-Control-Allow-Origin: * Access-Control-Expose-Headers: location,www-authenticate Content-Type: application/json Date: Tue, 15 Mar 2016 13:04:44 GMT Server: cyclone/1.1 Content

Is it possible to use the new Push Notifications support in Chrome without GCM?

帅比萌擦擦* 提交于 2019-12-07 05:33:20
问题 Can I use a push service other than Google's GCM when using the new Push API with service workers? 回答1: Today, Chrome is the only browser that supports the standard push API so right now the short answer is No. A longer answer involves doing different things for different browsers Safari offers desktop notifications via APNS and a proprietary API Firefox is shipping support for push notifications soon and presumably will use a different push server than GCM. So to summarize, it seems that

Web Push with VAPID: 400/401 Unauthorized Registration

柔情痞子 提交于 2019-12-05 13:49:07
First of all, I've already check these questions, without any luck: Web Push API Chrome, returning "Unauthorized Registration" [WebPush][VAPID] Request fails with 400 UnauthorizedRegistration I am trying to implement web push notifications for a web app that I'm working on. Currently, I've achieved the following goals: Create a VAPID keys pair ( with this guide ). Register a service worker (only a service worker, I think that manifest.json is no longer required). Subscribe the user to the server (subscription data will be stored in the database). Send a push notification with webpush gem.

Is it possible to use the new Push Notifications support in Chrome without GCM?

安稳与你 提交于 2019-12-05 09:49:44
Can I use a push service other than Google's GCM when using the new Push API with service workers? Today, Chrome is the only browser that supports the standard push API so right now the short answer is No. A longer answer involves doing different things for different browsers Safari offers desktop notifications via APNS and a proprietary API Firefox is shipping support for push notifications soon and presumably will use a different push server than GCM. So to summarize, it seems that different combinations of Browser/OS will require different push servers. In the future there is an IETF draft

How can we implement web push notification?

可紊 提交于 2019-12-04 21:06:36
How to implement push notification in browsers using the googles GCM service. What are the steps to implement the same. The basic steps that you will have to do if you want to add push notifications in browsers are the following: First of all, you need an HTTP S webpage (GCM requires it for browser notifications). Secondly, you need to add some javascript code into your webpage that will do the following points: Ask the user for push permissions Register the browser that are accessing into the webpage Activate a ServiceWorker that will be waiting for notifications (and when a notification is