@aigens/aigens-sdk-netcore
v0.5.0
Published
Aigens SDK netcore
Downloads
20
Readme
@aigens/aigens-sdk-netcore
Aigens SDK netcore
Install
npm install @aigens/aigens-sdk-netcore
npx cap sync
API
fetchAlreadyGeneratedTokenFromFCM()
setDevicePushToken(...)
getDevicePushToken()
setNotificationOptions(...)
updateNotificationPermission(...)
requestNotificationPermission()
setDebugLevel(...)
updateUserProfile(...)
setUserIdentity(...)
login(...)
clearUserIdentity()
logoutAndClearUserIdentity(...)
setUserLocation(...)
setOptTracking(...)
hasOptedTracking()
setOptInAppMessage(...)
hasOptedInAppMessage()
trackEvent(...)
addListener('OnSmartechHandleDeeplinkEvent', ...)
addListener('OnCustomHTMLCallback', ...)
addListener('OnCustomHtmlInAppClick', ...)
- Interfaces
fetchAlreadyGeneratedTokenFromFCM()
fetchAlreadyGeneratedTokenFromFCM() => Promise<void>
setDevicePushToken(...)
setDevicePushToken(options: { token: string; }) => Promise<void>
| Param | Type |
| ------------- | ------------------------------- |
| options
| { token: string; } |
getDevicePushToken()
getDevicePushToken() => Promise<{ token: string; }>
Returns: Promise<{ token: string; }>
setNotificationOptions(...)
setNotificationOptions(options: { brandLogo: string; largeIcon: string; smallIcon: string; smallIconTransparent: string; transparentIconBgColor: string; placeHolderIcon: string; }) => Promise<void>
| Param | Type |
| ------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| options
| { brandLogo: string; largeIcon: string; smallIcon: string; smallIconTransparent: string; transparentIconBgColor: string; placeHolderIcon: string; } |
updateNotificationPermission(...)
updateNotificationPermission(options: { permission: "granted" | "denied"; }) => Promise<void>
| Param | Type |
| ------------- | --------------------------------------------------- |
| options
| { permission: 'granted' | 'denied'; } |
requestNotificationPermission()
requestNotificationPermission() => Promise<{ result: boolean; }>
Returns: Promise<{ result: boolean; }>
setDebugLevel(...)
setDebugLevel(options: { level: 0 | 1; }) => Promise<void>
| Param | Type |
| ------------- | ------------------------------- |
| options
| { level: 0 | 1; } |
updateUserProfile(...)
updateUserProfile(options: { member: any; }) => Promise<void>
| Param | Type |
| ------------- | ----------------------------- |
| options
| { member: any; } |
setUserIdentity(...)
setUserIdentity(options: { id: string; }) => Promise<void>
| Param | Type |
| ------------- | ---------------------------- |
| options
| { id: string; } |
login(...)
login(options: { id: string; }) => Promise<void>
| Param | Type |
| ------------- | ---------------------------- |
| options
| { id: string; } |
clearUserIdentity()
clearUserIdentity() => Promise<void>
logoutAndClearUserIdentity(...)
logoutAndClearUserIdentity(options: { booleanClearIdentity: boolean; }) => Promise<void>
| Param | Type |
| ------------- | ----------------------------------------------- |
| options
| { booleanClearIdentity: boolean; } |
setUserLocation(...)
setUserLocation(options: { latitude: number; longitude: number; }) => Promise<void>
| Param | Type |
| ------------- | ----------------------------------------------------- |
| options
| { latitude: number; longitude: number; } |
setOptTracking(...)
setOptTracking(options: { optTracking: boolean; }) => Promise<void>
| Param | Type |
| ------------- | -------------------------------------- |
| options
| { optTracking: boolean; } |
hasOptedTracking()
hasOptedTracking() => Promise<{ result: boolean; }>
Returns: Promise<{ result: boolean; }>
setOptInAppMessage(...)
setOptInAppMessage(options: { optInAppMessage: boolean; }) => Promise<void>
| Param | Type |
| ------------- | ------------------------------------------ |
| options
| { optInAppMessage: boolean; } |
hasOptedInAppMessage()
hasOptedInAppMessage() => Promise<{ result: boolean; }>
Returns: Promise<{ result: boolean; }>
trackEvent(...)
trackEvent(options: { event: string; params: any; }) => Promise<void>
| Param | Type |
| ------------- | -------------------------------------------- |
| options
| { event: string; params: any; } |
addListener('OnSmartechHandleDeeplinkEvent', ...)
addListener(eventName: 'OnSmartechHandleDeeplinkEvent', listenerFunc: (options: { deepLinkvalue: string; customPayloadvalue: any; }) => void) => Promise<PluginListenerHandle> & PluginListenerHandle
| Param | Type |
| ------------------ | -------------------------------------------------------------------------------------- |
| eventName
| 'OnSmartechHandleDeeplinkEvent' |
| listenerFunc
| (options: { deepLinkvalue: string; customPayloadvalue: any; }) => void |
Returns: Promise<PluginListenerHandle> & PluginListenerHandle
addListener('OnCustomHTMLCallback', ...)
addListener(eventName: 'OnCustomHTMLCallback', listenerFunc: (options: any) => void) => Promise<PluginListenerHandle> & PluginListenerHandle
| Param | Type |
| ------------------ | -------------------------------------- |
| eventName
| 'OnCustomHTMLCallback' |
| listenerFunc
| (options: any) => void |
Returns: Promise<PluginListenerHandle> & PluginListenerHandle
addListener('OnCustomHtmlInAppClick', ...)
addListener(eventName: 'OnCustomHtmlInAppClick', listenerFunc: (options: { s: string; s1: string; }) => void) => Promise<PluginListenerHandle> & PluginListenerHandle
| Param | Type |
| ------------------ | ------------------------------------------------------------- |
| eventName
| 'OnCustomHtmlInAppClick' |
| listenerFunc
| (options: { s: string; s1: string; }) => void |
Returns: Promise<PluginListenerHandle> & PluginListenerHandle
Interfaces
PluginListenerHandle
| Prop | Type |
| ------------ | ----------------------------------------- |
| remove
| () => Promise<void> |