website logo
HomeGo to Dashboard
User Guide
How-To Videos
Developers
Navigate through spaces
⌘K
Getting Started
Introduction
Compatibility
Terminology
SDK Installation
Shopify
Any Website
Dukaan
Angular 2+
WooCommerce
WordPress
Android Native
iOS Native
Flutter
Cordova
Ionic
React Native
Data Integration
Data Models
Mandatory Events
Mandatory Properties
Call to Action
System Events
Device Properties
Docs powered by archbee 

CTA Callback in Web

2min

CTA Configuration

Cooee SDK supports callback on any action of in-app notifications actions by returning a map of key-value pairs i.e. objects in JavaScript. You can check more CTA options on Call to Action page.

JS
|
document.addEventListener('onCooeeCTA', function(event) {
    const payload = event.detail;

    if (!payload) return;

    if (payload.actionType === "VIEW_ITEM") {
        // Take the user to the given item's page. Item id will be in "payload.id"
    } else if (payload.actionType == "GO_TO_SCREEN") {
        // Take user to the given screen name
    }
}, false);




Updated 03 Mar 2023
Did this page help you?
Yes
No
PREVIOUS
Tracking Logout on Web
NEXT
Dukaan
Docs powered by archbee 
TABLE OF CONTENTS
CTA Configuration