<aside> šŸ’” For those who want to dig a little bit deeper with Birdie widget

</aside>

First, make sure you have already installed Birdie widget as explained here

Widget Registration

This is a complete list of parameters you can register in Birdie settings:

window.birdieSettings = {
		app_id:"xxxxxxxx",
		contact_name: "Alexander the Great",
		contact_email: "[email protected]",
		contact_id: "ebf45a994-32d28c4",
};

HTML Markup / No code

Any element into your page with the class name zstw_open will be automatically registered as a launcher, for example:

<a href="#" class="zstw_open">Click here</a>
<button class="zstw_open">Open the widget, if not already opened</button>

Events

You can hook into 5 different events: onRecorderOpened, onRecorderClosed, onRecordingStarted, onRecordingStopped, onRecordingPosted You must register them from the birdieSettings object, as shown into the example below:

window.my_callback_recorder_opened = function() {
	console.log("The recorder popup has been opened")
	// you own codeā€¦
};
window.my_callback_recorder_closed = function() {
	console.log("The recorder popup has been closed")
	// you own codeā€¦
};
window.my_callback_recording_started = function() {
	console.log("The recording has just started")
	// you own codeā€¦
};
window.my_callback_recording_stopped = function() {
	console.log("The recording has just stopped")
	// you own codeā€¦
};
window.my_callback_recording_posted = function(link) {
	console.log("The recording was sent, the sharing link is:", link)
	// you own code can use the the sharing link given as parameterā€¦
};

window.birdieSettings = {
	 // other settingsā€¦
	 **onRecorderOpened**: my_callback_recorder_opened,
   **onRecorderClosed**: my_callback_recorder_closed,
   **onRecordingStarted**: my_callback_recording_started,
   **onRecordingStopped**: my_callback_recording_stopped,
   **onRecordingPosted**: my_callback_recording_posted
};

Birdie Snippet Co-browsing events

window.birdieCallback = function(**event**) { 
   	console.log("birdieCallback event:", **event**) 
		// your own codeā€¦ 
		/* **event** value will be a String, one of: 
			session_request_started
			session_request_canceled
			session_request_denied
			session_request_accepted
			call_request_started
			call_request_canceled
			call_request_denied
			call_request_accepted
			session_started
			session_stopped
		*/
}
window.birdieSettings={
  onBirdieAction: birdieCallback
};