Linking Growth Action [Web]
Follow
Introduction
DFINERY Growth Action provides functions to help customers engage with their engagement marketing activities.
- Reference link: [Learn about Growth Action services]
Using the functions provided by DFINERY, you can create audience groups and conduct personalized marketing targeting each audience.
[[Quote:Guide:Normal]] To use Growth Action, you must use the DFINERY paid plan.[ Contact Us ]
supported browsers
Growth Action's web push notifications are supported by at least the following browser versions.
Window | Mac | Android | iOS | |
I.E. | X | - | - | - |
MS Edge | 17+ | 17+ | 17+ | - |
Google Chrome | 50+ | 50+ | 50+ | Push Unsupported |
Mozilla Firefox | 47+ | 47+ | 105+ | Push Unsupported |
Apple Safari | - | 10+ | - | Push Unsupported |
Samsung browser | - | - | 4+ | - |
DFINERY Console Settings
To use Growth Action Push, you first need Web Push Setting in the console.
Web Push Setting is done through the Growth Action -> Settings -> Web Push Setting menu after accessing the DFINERY console.
Please refer to the guide below for settings related to push in the DFINERY console.
- Reference link: [Web push settings]
[[Quote:Guide:General]] In-Web Message does not require any separate settings in the console.
Web SDK settings
Integrating Web SDK
In order to use Growth Action in a web environment, the Web SDK must be connected by default.
- Reference link: [Web SDK Integration Guide]
Web SDK init additional settings
To use Web Push, you must check whether to use push when initing the SDK as follows.
<head> … <!-- AdBrix Web SDK init --> <script> window.adbrix.init({ appkey: 'your_appkey', webSecretkey: 'your_webSecretKey', // Add push-related settings push: { enable: true; serviceWorkerOptions: { file_name: 'service-worker.js', file_path: '/', scope: '/' }, }, // In Web Message additional settings inWebMessage: { enable: true; openInNewWindow: true; zIndex: 9999; fetchListener: function(message){
console.log('fetch_listener ' + message); }, clickListener: function(actionId, actionType, actionArg, isClosed){ console.log('click_listener ' + actionId + actionType + actionArg + isClosed); }, }, }); </script> … </head>
The options used when initing the SDK for Push use are as follows.
Push
Specifies options for using push.
Keys | Type | Note |
enable | bool | Option to enable or disable push service |
serviceWorkerOptions | ServiceWorkerOptions | Service Worker usage options [What is a service worker?] |
ServiceWorkerOptions
Specifies ServiceWorkseOption for push usage.
Keys | Type | Note |
file_name | string | Service worker file name |
file_path | string | Service Worker file path |
scope | string | Service Worker coverage |
If you do not have your own ServiceWorker file, download and apply it (unzip and apply after downloading). [Download]
If you already have a ServiceWorker file in use, add the script as shown below.
//AdBrix Push Service worker importScripts('https://static.adbrix.io/web-sdk/latest/service-worker.min.js');
In-Web Message Option
Specifies options for using In-Web Message.
Name | Description | Type | Example |
enable | Whether to use in-web messaging or not | boolean | true: use false: do not use |
openInNewWindow | Whether or not it opens in a new window/opens in the current window when you click on an in-web message and go to a specific link | boolean | true: Open in new window false: Open in current window |
fetchListener | An event is retrieved when fetching pop-up message data from the server. | function | message: message after fetch completion |
clickListener | Gets an event when a click event occurs within a pop-up message. | function | actionId: ID of the click action actionType: Type of the click action actionArg: Variable of the click action isClosed: Whether to close the pop-up message |
zIndex | Sets the zIndex of the pop-up message display window. | number | Default: 99999999 |
One
Notification consent settings
This is a function that allows you to set and retrieve the users notification consent value stored on the DFINERY server.
Set your consent to receive notifications
Set the users notification consent value with the DFINERY server.
- Sample Code
const subscriptionStatus = { //Add Only Updated information "informative_notification_flag": true, "marketing_notification_flag": true, "marketing_notification_flag_for_push_channel": true, "marketing_notification_flag_for_sms_channel": true, "marketing_notification_flag_for_kakao_channel": true, "marketing_notification_at_night_flag": true, "marketing_notification_at_night_flag_for_push_channel": true, "marketing_notification_at_night_flag_for_sms_channel": true, "marketing_notification_at_night_flag_for_kakao_channel": true, }; adbrix.setSubscriptionStatus(subscriptionStatus).then(result => { if (result.is_success) { // If it's Success } });
- subscriptionStatus object information
Name | Note | Type | Example |
informative_notification_flag | Whether to consent to informational notifications | boolean | true |
marketing_notification_flag | Whether to agree to advertising notifications | boolean | true |
marketing_notification_flag_for_push_channel | Agree to advertising notifications (push channel) | boolean | true |
marketing_notification_flag_for_sms_channel | Agree to advertising notifications (text channel) | boolean | true |
marketing_notification_flag_for_kakao_channel | Agree to advertising notifications (Notification Talk channel) | boolean | true |
marketing_notification_at_night_flag | Whether to agree to nightly advertising notifications | boolean | true |
marketing_notification_at_night_flag_for_push_channel | Agree to nightly advertising notifications (push channel) | boolean | true |
marketing_notification_at_night_flag_for_sms_channel | Agree to nightly advertising notifications (text channel) | boolean | true |
marketing_notification_at_night_flag_for_kakao_channel | Agree to nightly advertising notifications (Notification Talk channel) | boolean | true |
- Result
Name | Note | Type | Example |
is_success | API success or not | boolean | true |
result_code | result code | number | 2000 |
result_message | Result message (for debugging in case of failure) | string | Internal Server Error. |
Get notification consent
The currently set notification consent information is retrieved from the DFINERY server.
- Sample Code
adbrix.getSubscriptionStatus().then(result => { if (result.is_success) { const info_flag = result.informative_notification_flag; const mkt_flag = result.marketing_notification_flag; const mkt_push = result.marketing_notification_flag_for_push_channel; const mkt_sms = result.marketing_notification_flag_for_sms_channel; const mkt_kakao = result.marketing_notification_flag_for_kakao_channel; const night_flag = result.marketing_notification_at_night_flag; const night_flag_push = result.marketing_notification_at_night_flag_for_push_channel; const night_flag_sms = result.marketing_notification_at_night_flag_for_sms_channel; const night_flag_kakao = result.marketing_notification_at_night_flag_for_kakao_channel; } });
- getSubscriptionStatus information
Name | Note | Type | Example |
is_success | API success or not | boolean | true |
result_code | result code | number | 2000 |
result_message | Result message (for debugging in case of failure) | string | Internal Server Error. |
informative_notification_flag | Whether to consent to informational notifications | boolean | undefined | true |
marketing_notification_flag | Whether to agree to advertising notifications | boolean | undefined | true |
marketing_notification_flag_for_push_channel | Agree to advertising notifications (push channel) | boolean | undefined | true |
marketing_notification_flag_for_sms_channel | Agree to advertising notifications (text channel) | boolean | undefined | true |
marketing_notification_flag_for_kakao_channel | Agree to advertising notifications (Notification Talk channel) | boolean | undefined | true |
marketing_notification_at_night_flag | Whether to agree to nightly advertising notifications | boolean | undefined | true |
marketing_notification_at_night_flag_ for_push_channel |
Agree to nightly advertising notifications (push channel) | boolean | undefined | true |
marketing_notification_at_night_flag_ for_sms_channel |
Agree to nightly advertising notifications (text channel) | boolean | undefined | true |
marketing_notification_at_night_flag_ for_kakao_channel |
Agree to nightly advertising notifications (Notification Talk channel) | boolean | undefined | true |
[[Quote:Guide:Normal]] If there is no history of notification reception information settings, "undefined" is returned.
Web Push
Call push subscription notification
To receive a push, call the push subscription notification API so that the user can receive the push at a certain point in time. If the user approves the push subscription in the subscription notification, you can receive pushes from now on.
This will no longer be called if the user has already approved the push subscription notification.
//AdBrix Push subscription alarm await adbrix.push.showPrompt();
[[Quote:Guide:Normal]] For alternative domains, a push subscription notification will be called and when the user approves, the push subscription pop-up window you have set will be called.
KakaoTalk settings
Settings for using Kakao notification talk and friend talk. *kakaoId: 10-digit Kakao ID received through Kakao Sync API
-
setKakaoId(kakaoId: string): Promise
-
SetCiPropertyResult
- is_success: Whether it was applied normally on the server or not
- result_code: Get result code
- result_message: Get result message
-
SetCiPropertyResult
-
guide
adbrix.setKakaoId('1234567890').then(result => { if(result.is_success){ ... }
//If the format of kakaoId is incorrect, isSuccess becomes false. });
[[Quote:Danger:Small]] This API is available after logging in.
SMS settings
Settings for using SMS. * PHONE_NUMBER: Country code that complies with E.164 + value excluding “+” from the number (example: 8210********)
-
setPhoneNumber(phoneNumber: string): Promise
-
SetCiPropertyResult
- is_success: Whether it was applied normally on the server or not
- result_code: Get result code
- result_message: Get result message
-
SetCiPropertyResult
- guide
adbrix.setPhoneNumber('821012345678').then(result => { if(result.is_success){ ... }
//If the number format is wrong, isSuccess becomes false. });
[[Quote:Warning:Small]] PHONE_NUMBER: Country code that complies with E.164 + value excluding “+” from the number (Example: 8210********)
[[Quote:Danger:Small]] This API is available after logging in.
[[Quote:Danger:Small]] There are no separate specifications for the SDK, but the required specifications may differ depending on the usage (e.g. KakaoTalk Biz Message), so please check and enter them.
In-Web Message
The logic of retrieving and displaying In-Web Message data is basically automatically handled by the SDK, so users do not need to call the API separately.
For In-Web Message settings, see Additional Web SDK init settings and In-Web Message Options.