Webpush solution architecture
Webpush for Chrome

-
Browser downloads Xtremepush javascript SDK from CDN.
-
SDK uses browser API to register service worker.
-
SDK uses browser API to subscribe for push notifications.
-
Browser communicates with GCM to subscribe and retrieve push token.
-
SDK sends the token to Xtremepush via HTTPS API.
-
Xtremepush servers communicates with GCM to send a message via secure connection.
-
GCM sends a push event to browser.
-
Browser executes a push callback handled in service worker.
-
Service worker fetches push message content from Xtremepush via HTTPS API.
-
Service worker uses browser API to show notification.
Webpush for Safari

-
Browser downloads Xtremepush javascript SDK from CDN
-
SDK uses browser API to subscribe for push notifications
-
Browser fetches push notification package from Xtremepush
-
Browser communicates with APNS to subscribe and retrieve push token
-
SDK sends the token to Xtremepush via HTTPS API
-
Xtremepush servers communicates with APNS to send an encrypted via secure connection
-
APNS delivers push message to browser
-
Browser shows a notification using OS API