@aigens/aigens-sdk-appboy
v5.0.5
Published
Aigens Order.Place aigens-sdk-appboy Plugin
Downloads
243
Readme
@aigens/aigens-sdk-appboy
Aigens Order.Place Core Plugin
Install
npm install @aigens/aigens-sdk-appboy
npx cap sync
API
checkPermissions()
requestPermissions()
registerForRemoteNotifications()
setRegisteredPushToken(...)
changeUser(...)
logCustomEvent(...)
logPurchase(...)
disableSdk()
enableSdk()
wipeData()
requestImmediateDataFlush()
setAppboyMember(...)
setFirstName(...)
setLastName(...)
setEmail(...)
setGender(...)
setDateOfBirth(...)
setCountry(...)
setHomeCity(...)
setPhoneNumber(...)
setPushNotificationSubscriptionType(...)
setEmailNotificationSubscriptionType(...)
setUserAttributionData(...)
setBoolCustomUserAttribute(...)
setStringCustomUserAttribute(...)
setDoubleCustomUserAttribute(...)
setDateCustomUserAttribute(...)
setIntCustomUserAttribute(...)
setCustomUserAttributeArray(...)
unsetCustomUserAttribute(...)
incrementCustomUserAttribute(...)
addToCustomAttributeArray(...)
removeFromCustomAttributeArray(...)
addAlias(...)
setLanguage(...)
addToSubscriptionGroup(...)
removeFromSubscriptionGroup(...)
getDeviceId()
addListener('afterInAppMessageViewClosed', ...)
addListener('afterInAppMessageViewOpened', ...)
addListener('beforeInAppMessageViewClosed', ...)
addListener('beforeInAppMessageViewOpened', ...)
addListener('onInAppMessageButtonClicked', ...)
addListener('onInAppMessageClicked', ...)
addListener('onInAppMessageDismissed', ...)
- Interfaces
- Type Aliases
checkPermissions()
checkPermissions() => Promise<PermissionStatus>
Returns: Promise<PermissionStatus>
requestPermissions()
requestPermissions() => Promise<PermissionStatus>
Returns: Promise<PermissionStatus>
registerForRemoteNotifications()
registerForRemoteNotifications() => Promise<any>
Returns: Promise<any>
setRegisteredPushToken(...)
setRegisteredPushToken(options: { token: string; }) => Promise<any>
| Param | Type |
| ------------- | ------------------------------- |
| options
| { token: string; } |
Returns: Promise<any>
changeUser(...)
changeUser(options: { userId: string; }) => Promise<any>
| Param | Type |
| ------------- | -------------------------------- |
| options
| { userId: string; } |
Returns: Promise<any>
logCustomEvent(...)
logCustomEvent(options: { eventName: string; properties?: object; }) => Promise<any>
| Param | Type |
| ------------- | -------------------------------------------------------- |
| options
| { eventName: string; properties?: object; } |
Returns: Promise<any>
logPurchase(...)
logPurchase(options: { productId: string; price: string; quantity: number; currency: string; properties?: object; }) => Promise<any>
| Param | Type |
| ------------- | ----------------------------------------------------------------------------------------------------------- |
| options
| { productId: string; price: string; quantity: number; currency: string; properties?: object; } |
Returns: Promise<any>
disableSdk()
disableSdk() => Promise<any>
Returns: Promise<any>
enableSdk()
enableSdk() => Promise<any>
Returns: Promise<any>
wipeData()
wipeData() => Promise<any>
Returns: Promise<any>
requestImmediateDataFlush()
requestImmediateDataFlush() => Promise<any>
Returns: Promise<any>
setAppboyMember(...)
setAppboyMember(options: AppboyMember) => Promise<any>
| Param | Type |
| ------------- | ----------------------------------------------------- |
| options
| AppboyMember |
Returns: Promise<any>
setFirstName(...)
setFirstName(options: { firstName: string; }) => Promise<any>
| Param | Type |
| ------------- | ----------------------------------- |
| options
| { firstName: string; } |
Returns: Promise<any>
setLastName(...)
setLastName(options: { lastName: string; }) => Promise<any>
| Param | Type |
| ------------- | ---------------------------------- |
| options
| { lastName: string; } |
Returns: Promise<any>
setEmail(...)
setEmail(options: { email: string; }) => Promise<any>
| Param | Type |
| ------------- | ------------------------------- |
| options
| { email: string; } |
Returns: Promise<any>
setGender(...)
setGender(options: { gender: 'f' | 'm' | 'o' | 'u'; }) => Promise<any>
| Param | Type |
| ------------- | -------------------------------------------------- |
| options
| { gender: 'f' | 'm' | 'o' | 'u'; } |
Returns: Promise<any>
setDateOfBirth(...)
setDateOfBirth(options: { year: number; month: number; day: number; }) => Promise<any>
| Param | Type |
| ------------- | ---------------------------------------------------------- |
| options
| { year: number; month: number; day: number; } |
Returns: Promise<any>
setCountry(...)
setCountry(options: { country: string; }) => Promise<any>
| Param | Type |
| ------------- | --------------------------------- |
| options
| { country: string; } |
Returns: Promise<any>
setHomeCity(...)
setHomeCity(options: { homeCity: string; }) => Promise<any>
| Param | Type |
| ------------- | ---------------------------------- |
| options
| { homeCity: string; } |
Returns: Promise<any>
setPhoneNumber(...)
setPhoneNumber(options: { phoneNumber: string; }) => Promise<any>
| Param | Type |
| ------------- | ------------------------------------- |
| options
| { phoneNumber: string; } |
Returns: Promise<any>
setPushNotificationSubscriptionType(...)
setPushNotificationSubscriptionType(options: { subscriptionState: 'optedIn' | 'subscribed' | 'unsubscribed'; }) => Promise<any>
| Param | Type |
| ------------- | -------------------------------------------------------------------------------- |
| options
| { subscriptionState: 'optedIn' | 'subscribed' | 'unsubscribed'; } |
Returns: Promise<any>
setEmailNotificationSubscriptionType(...)
setEmailNotificationSubscriptionType(options: { subscriptionState: 'optedIn' | 'subscribed' | 'unsubscribed'; }) => Promise<any>
| Param | Type |
| ------------- | -------------------------------------------------------------------------------- |
| options
| { subscriptionState: 'optedIn' | 'subscribed' | 'unsubscribed'; } |
Returns: Promise<any>
setUserAttributionData(...)
setUserAttributionData(options: { network: string; campaign: string; adGroup: string; creative: string; }) => Promise<any>
| Param | Type |
| ------------- | -------------------------------------------------------------------------------------- |
| options
| { network: string; campaign: string; adGroup: string; creative: string; } |
Returns: Promise<any>
setBoolCustomUserAttribute(...)
setBoolCustomUserAttribute(options: { key: string; value: boolean; }) => Promise<any>
| Param | Type |
| ------------- | --------------------------------------------- |
| options
| { key: string; value: boolean; } |
Returns: Promise<any>
setStringCustomUserAttribute(...)
setStringCustomUserAttribute(options: { key: string; value: string; }) => Promise<any>
| Param | Type |
| ------------- | -------------------------------------------- |
| options
| { key: string; value: string; } |
Returns: Promise<any>
setDoubleCustomUserAttribute(...)
setDoubleCustomUserAttribute(options: { key: string; value: number; }) => Promise<any>
| Param | Type |
| ------------- | -------------------------------------------- |
| options
| { key: string; value: number; } |
Returns: Promise<any>
setDateCustomUserAttribute(...)
setDateCustomUserAttribute(options: { key: string; value: number; }) => Promise<any>
| Param | Type |
| ------------- | -------------------------------------------- |
| options
| { key: string; value: number; } |
Returns: Promise<any>
setIntCustomUserAttribute(...)
setIntCustomUserAttribute(options: { key: string; value: number; }) => Promise<any>
| Param | Type |
| ------------- | -------------------------------------------- |
| options
| { key: string; value: number; } |
Returns: Promise<any>
setCustomUserAttributeArray(...)
setCustomUserAttributeArray(options: { key: string; value: string[]; }) => Promise<any>
| Param | Type |
| ------------- | ---------------------------------------------- |
| options
| { key: string; value: string[]; } |
Returns: Promise<any>
unsetCustomUserAttribute(...)
unsetCustomUserAttribute(options: { key: string; }) => Promise<any>
| Param | Type |
| ------------- | ----------------------------- |
| options
| { key: string; } |
Returns: Promise<any>
incrementCustomUserAttribute(...)
incrementCustomUserAttribute(options: { key: string; value: number; }) => Promise<any>
| Param | Type |
| ------------- | -------------------------------------------- |
| options
| { key: string; value: number; } |
Returns: Promise<any>
addToCustomAttributeArray(...)
addToCustomAttributeArray(options: { key: string; value: string; }) => Promise<any>
| Param | Type |
| ------------- | -------------------------------------------- |
| options
| { key: string; value: string; } |
Returns: Promise<any>
removeFromCustomAttributeArray(...)
removeFromCustomAttributeArray(options: { key: string; value: string; }) => Promise<any>
| Param | Type |
| ------------- | -------------------------------------------- |
| options
| { key: string; value: string; } |
Returns: Promise<any>
addAlias(...)
addAlias(options: { aliasName: string; aliasLabel: string; }) => Promise<any>
| Param | Type |
| ------------- | ------------------------------------------------------- |
| options
| { aliasName: string; aliasLabel: string; } |
Returns: Promise<any>
setLanguage(...)
setLanguage(options: { language: string; }) => Promise<any>
| Param | Type |
| ------------- | ---------------------------------- |
| options
| { language: string; } |
Returns: Promise<any>
addToSubscriptionGroup(...)
addToSubscriptionGroup(options: { groupId: string; }) => Promise<any>
| Param | Type |
| ------------- | --------------------------------- |
| options
| { groupId: string; } |
Returns: Promise<any>
removeFromSubscriptionGroup(...)
removeFromSubscriptionGroup(options: { groupId: string; }) => Promise<any>
| Param | Type |
| ------------- | --------------------------------- |
| options
| { groupId: string; } |
Returns: Promise<any>
getDeviceId()
getDeviceId() => Promise<any>
Returns: Promise<any>
addListener('afterInAppMessageViewClosed', ...)
addListener(eventName: 'afterInAppMessageViewClosed', listenerFunc: (res: any) => void) => Promise<PluginListenerHandle> & PluginListenerHandle
| Param | Type |
| ------------------ | ------------------------------------------ |
| eventName
| 'afterInAppMessageViewClosed' |
| listenerFunc
| (res: any) => void |
Returns: Promise<PluginListenerHandle> & PluginListenerHandle
addListener('afterInAppMessageViewOpened', ...)
addListener(eventName: 'afterInAppMessageViewOpened', listenerFunc: (res: any) => void) => Promise<PluginListenerHandle> & PluginListenerHandle
| Param | Type |
| ------------------ | ------------------------------------------ |
| eventName
| 'afterInAppMessageViewOpened' |
| listenerFunc
| (res: any) => void |
Returns: Promise<PluginListenerHandle> & PluginListenerHandle
addListener('beforeInAppMessageViewClosed', ...)
addListener(eventName: 'beforeInAppMessageViewClosed', listenerFunc: (res: any) => void) => Promise<PluginListenerHandle> & PluginListenerHandle
| Param | Type |
| ------------------ | ------------------------------------------- |
| eventName
| 'beforeInAppMessageViewClosed' |
| listenerFunc
| (res: any) => void |
Returns: Promise<PluginListenerHandle> & PluginListenerHandle
addListener('beforeInAppMessageViewOpened', ...)
addListener(eventName: 'beforeInAppMessageViewOpened', listenerFunc: (res: any) => void) => Promise<PluginListenerHandle> & PluginListenerHandle
| Param | Type |
| ------------------ | ------------------------------------------- |
| eventName
| 'beforeInAppMessageViewOpened' |
| listenerFunc
| (res: any) => void |
Returns: Promise<PluginListenerHandle> & PluginListenerHandle
addListener('onInAppMessageButtonClicked', ...)
addListener(eventName: 'onInAppMessageButtonClicked', listenerFunc: (res: any) => void) => Promise<PluginListenerHandle> & PluginListenerHandle
| Param | Type |
| ------------------ | ------------------------------------------ |
| eventName
| 'onInAppMessageButtonClicked' |
| listenerFunc
| (res: any) => void |
Returns: Promise<PluginListenerHandle> & PluginListenerHandle
addListener('onInAppMessageClicked', ...)
addListener(eventName: 'onInAppMessageClicked', listenerFunc: (res: any) => void) => Promise<PluginListenerHandle> & PluginListenerHandle
| Param | Type |
| ------------------ | ------------------------------------ |
| eventName
| 'onInAppMessageClicked' |
| listenerFunc
| (res: any) => void |
Returns: Promise<PluginListenerHandle> & PluginListenerHandle
addListener('onInAppMessageDismissed', ...)
addListener(eventName: 'onInAppMessageDismissed', listenerFunc: (res: any) => void) => Promise<PluginListenerHandle> & PluginListenerHandle
| Param | Type |
| ------------------ | -------------------------------------- |
| eventName
| 'onInAppMessageDismissed' |
| listenerFunc
| (res: any) => void |
Returns: Promise<PluginListenerHandle> & PluginListenerHandle
Interfaces
PermissionStatus
| Prop | Type | Description | Since |
| ------------- | ----------------------------------------------------------- | -------------------------------------------- | ----- |
| receive
| PermissionState | Permission state of receiving notifications. | 1.0.0 |
AppboyMember
| Prop | Type |
| ----------------- | ---------------------------------------------------------- |
| firstName
| string |
| lastName
| string |
| email
| string |
| gender
| 'f' | 'm' | 'o' | 'u' |
| dateOfBirth
| { year: number; month: number; day: number; } |
| country
| string |
| homeCity
| string |
| phoneNumber
| string |
PluginListenerHandle
| Prop | Type |
| ------------ | ----------------------------------------- |
| remove
| () => Promise<void> |
Type Aliases
PermissionState
'prompt' | 'prompt-with-rationale' | 'granted' | 'denied'