Unsubscribe to an event
Updated
sprChat('unsubscribeToUpdate')
This API can be used if we don’t want to listen particular type of events from live chat widget that have already been subscribed.
Parameters:
(every parameter is optional unless marked *):
Name | Typescript type | Description | Default Value |
topic* | string | Update that was previously subscribed to. | - |
subscriber* |
| Pass the same subscriber fn which we want to unsubscribe(reference needs to be the same). | - |
Examples
unsubscribe to live chat’s availability event
window.sprChat('unsubscribeToUpdate', { |
unsubscribe to notification count of all the conversation
window.sprChat('unsubscribeToUpdate', { |
unsubscribe to externalEvent trigged by bot/rule flow
window.sprChat('unsubscribeToUpdate', { |
unsubscribe to live chat is load successfully or not
window.sprChat('unsubscribeToUpdate', { |
unsubscribe to different analytics events of live chat
window.sprChat('unsubscribeToUpdate', { |
unsubscribe to see open new conversation is created or not
window.sprChat('unsubscribeToUpdate', { |
unsubscribe to send external event
window.sprChat('unsubscribeToUpdate', { |