Installing Web Push Script on Your Site
To send web pushes from your website, you need to install a web push script in it.
1. Choosing a Subscription Type
Go to your personal profile > Settings > Web Push and select Double Opt-In or Single Opt-In.
- Double Opt-In is a two-step subscription process. It requires a user to allow your notifications in a request prompt and then to confirm subscription.
- Single Opt-In is a one-step subscription process. It requires a user to only allow your notifications in a request prompt.
2. Filling in Website Information
- Fill in Website name and URL.
- If you already have a Firebase Project for token collection, enter your keys in Integration with the token collection service. If you don't have a project, leave the fields empty. Keys will be generated automatically.
To set web pushes for Safari, unroll and configure the corresponding settings.
3. Generating Script
- Click Generate script. It will be generated automatically and displayed below.
- Download the installation file and insert it into your website's root directory. Copy the generated code and insert it into your website pages before the closing
head
tag.
- Click Check website status. If it’s Website not added, check whether you installed everything right. If it’s Website has been added, your site is ready for token collection.
- Click Back to go back to the settings. You’ll see the added site in the general list.
Updated 11 months ago