Examples
With the SDK client configured, except from basic subscription to web push notifications, you can use it to create your own component for subscribing to web push notifications, segment your subscribers with tags, link them with your CRM database by setting custom id, or send data for automation purposes.
Custom subscribe button
Initialize SDK client
Use it to add web push registry functionality to button elements
3. To test if the subscription was successful, you can send a transactional web push notification via API
subscriberId
- from demox-token
- generate in the application access keys section
Set Custom ID
You can link web push subscriberId
with your own identifier by setting the customId
with client.setCustomId()
To be notified when customId
is set, you can integrate with a Webhook subscriber:update
Add subscriber tags
To add tags to subscriber, use client.appendTags()
Send automation data
When you have automation configured in the app.pushpushgo, you will need to feed it with data, by sending a beacon by client.send()
. Assume you have a selector with a name basket
defined in the application, and you need to set it's value for the automation. In addition lets operate on tags that might be used in automation conditions and set the Custom ID.
Last updated
Was this helpful?