You can deploy the xtremepush SDK for web push notifications with Google Tag Manager.
This can be done for supported Browser types i.e. Safari, Chrome and Firefox. We describe how to deploy using tag manager below. First take care of any Browser prerequisites and configure the features you want to use for your project on the xtremepush platform (Google Analytics Integration, Inbox etc.).
Once you have configured your project you are ready to deploy/update the SDK initialisation code. Instructions on how to deploy will be found in Settings > SDK Integration section of your project. After you have saved all your settings, instructions on how to initialise the SDK will be found here. This will include the JS you need to add to your pages and any manifest, service worker, or html files you may need to add to your websites origin.
The SDK integration page will look different depending on how you have configured for different browsers two example are given below, review the full integration guide for more info on prerequisites and configs:
When you are ready you can deploy with google tag manager
Google Tag Manager
Go to google tag manager and select the container for your website: https://tagmanager.google.com.
In your container select new tag:
Create the tag to deploy xtremepush as follows:
- Give it a name like xtremepush tag
- Set type as Custom HTML tag
- Go to your project on xtremepush and Copy the Custom HTML from the Settings > SDK Integration section of your project:
- Return to tag manager and paste the Custom HTML into HTML field
- Set tag to fire on all pages or the page of your choice
- Create your tag
After creating the tag click the publish button on the top right of tag manager to put xtremepush live on your site.
After publishing xtremepush to your site navigate to your url in supported browsers and check that the site is now asking for notification permissions.