bvakiti
bvakiti

Reputation: 3601

Without using service workers, how can I send web push notifications?

Is there any way to send push notifications without using service workers ?

Upvotes: 1

Views: 2308

Answers (2)

Alok Singhal
Alok Singhal

Reputation: 216

You can use various services like Pusher/Pubnub etc. to send push notifications on your behalf. For example using Pusher and Python, you can do something like this:

from pusher import Pusher

pusher = Pusher(
  app_id=u'APP_ID',
  key=u'APP_KEY',
  secret=u'APP_SECRET'
)

pusher.trigger(u'test_channel', u'my_event', {u'message': u'hello       world'})

Upvotes: 0

Marco Castelluccio
Marco Castelluccio

Reputation: 10782

No, in order to use the Push API, you need a Service Worker.

Upvotes: 4

Related Questions