Property | Defined By | ||
---|---|---|---|
kiip : Kiip [static] [read-only]
The current instance of the Kiip singleton. | Kiip |
Method | Defined By | ||
---|---|---|---|
Kiip(appId:String, appSecret:String, secondAppId:String = null, secondAppSecret:String = null, logCallback:Function = null) Do Not call this directly; use Kiip.create() or Kiip.utils to get current instance. | Kiip | ||
create(appId:String, appSecret:String, secondAppId:String = null, secondAppSecret:String = null, logCallback:Function = null):Kiip [static]
Initializes the Kiip Extension. | Kiip | ||
isSupported():Boolean [static] Determine if the current platform supports the extension (iOS or Android). | Kiip | ||
saveMoment(momentId:String, value:Number = -1):void
Save the given moment. | Kiip | ||
setAlias(alias:String):void
Set the alias associated with the user. | Kiip | ||
setBirthday(birthday:Date):void
Set the birthday associated with the current user. | Kiip | ||
setEmail(email:String):void
Set the email associated with the current user. | Kiip | ||
setGender(gender:String):void
Set the gender to associate with the current user. | Kiip |
Event | Summary | Defined By | ||
---|---|---|---|---|
Dispatched when premium content has been received | Kiip | |||
Dispatched when a modal view has been dismissed | Kiip | |||
Dispatched when a modal view has been displayed | Kiip | |||
Dispatched when a moment has saved | Kiip | |||
Dispatched when a notification has been clicked | Kiip | |||
Dispatched when a Notification has been dismissed | Kiip | |||
Dispatched hwne a Notification has been displayed | Kiip | |||
Dispatched when a Kiip Poptart has been dismissed | Kiip | |||
Dispatched when a Kiip Poptart has been displayed | Kiip | |||
Called when a branded moment has failed to save | Kiip | |||
Called when the Kiip session has failed to end | Kiip | |||
Called when the Kiip session has been ended | Kiip | |||
Called when the Kiip session has failed to start | Kiip | |||
Called when the Kiip session has been started | Kiip | |||
Dispatched when a swarm has been joined. | Kiip |
Constant | Defined By | ||
---|---|---|---|
VERSION : String = 1.0.0 [static] Version | Kiip |
kiip | property |
kiip:Kiip
[read-only] The current instance of the Kiip singleton. You must call Kiip.create() before this property is available.
public static function get kiip():Kiip
Error — if Kiip.create() was not called before first accessing this property.
|
Kiip | () | Constructor |
public function Kiip(appId:String, appSecret:String, secondAppId:String = null, secondAppSecret:String = null, logCallback:Function = null)
Do Not call this directly; use Kiip.create() or Kiip.utils to get current instance.
ParametersappId:String | |
appSecret:String | |
secondAppId:String (default = null )
| |
secondAppSecret:String (default = null )
| |
logCallback:Function (default = null )
|
create | () | method |
public static function create(appId:String, appSecret:String, secondAppId:String = null, secondAppSecret:String = null, logCallback:Function = null):Kiip
Initializes the Kiip Extension. You should check Kiip.isSupported() first to ensure the platform is supported (iOS or Android.) If you are targeting iOS only or Android only, pass two parameters: your app ID and secret from the Kiip Dashboard. If you are targeting both iOS and Android from one code base, pass the keys and secrets in this order: iosAppId,iosSecret,androidId,androidAppSecret. Kiip is a Singleton and you may have only one instance. After creation, you may access the instance through the static property Kiip.kiip.
Parameters
appId:String — the app key from the Kiip dashboard
| |
appSecret:String — the app secret from the Kiip dashboard
| |
secondAppId:String (default = null ) — optionally, if targeting iOS and Android, your Android app key
| |
secondAppSecret:String (default = null ) — optionally, if targeting iOS and Android, your Android app secret
| |
logCallback:Function (default = null )
|
Kiip — initialized instance of Kiip extension interface.
|
Error — if Kiip has already been initialized.
|
isSupported | () | method |
public static function isSupported():Boolean
Determine if the current platform supports the extension (iOS or Android).
ReturnsBoolean |
saveMoment | () | method |
public function saveMoment(momentId:String, value:Number = -1):void
Save the given moment. After calling saveMoment(), KiipEvent.MOMENT_SAVED or KiipEvent.MOMENT_SAVE_FAILED will be dispatched. Depending on your Kiip dashboard settings, a notification may than be displayed, dispatching KiipEvent.NOTIFICATION_DISPLAYED. After the notification is finished, KiipEvent.NOTIFICATION_DISMISSED will be dispatched. If the user clicks the notification, KiipEvent.NOTIFICATION_CLICKED will be dispatched. If a modal view is subsequently opened, KiipEvent.MODAL_DISPLAYED will be dispatched, followed by KiipEvent.MODAL_DISMISSED on its closing.
Parameters
momentId:String — the momentId to save, set in the Kiip dashboard
| |
value:Number (default = -1 ) — optional value to attach to the moment
|
See also
setAlias | () | method |
public function setAlias(alias:String):void
Set the alias associated with the user.
Parameters
alias:String — the user alias to set
|
setBirthday | () | method |
public function setBirthday(birthday:Date):void
Set the birthday associated with the current user.
Parameters
birthday:Date — Date object representing the birthday
|
setEmail | () | method |
public function setEmail(email:String):void
Set the email associated with the current user.
Parameters
email:String — email address to set
|
setGender | () | method |
public function setGender(gender:String):void
Set the gender to associate with the current user.
Parameters
gender:String — one of the KiipGender.MALE or KiipGender.FEMALE constants
|
ArgumentError — if gender is not one of KiipGender.MALE or KiipGender.FEMALE
|
See also
CONTENT_RECEIVED | Event |
com.kiip.extensions.events.KiipEvent
Dispatched when premium content has been received
MODAL_DISMISSED | Event |
com.kiip.extensions.events.KiipEvent
Dispatched when a modal view has been dismissed
MODAL_DISPLAYED | Event |
com.kiip.extensions.events.KiipEvent
Dispatched when a modal view has been displayed
MOMENT_SAVED | Event |
NOTIFICATION_CLICKED | Event |
com.kiip.extensions.events.KiipEvent
Dispatched when a notification has been clicked
NOTIFICATION_DISMISSED | Event |
com.kiip.extensions.events.KiipEvent
Dispatched when a Notification has been dismissed
NOTIFICATION_DISPLAYED | Event |
com.kiip.extensions.events.KiipEvent
Dispatched hwne a Notification has been displayed
POPTART_DISMISSED | Event |
com.kiip.extensions.events.KiipEvent
Dispatched when a Kiip Poptart has been dismissed
POPTART_DISPLAYED | Event |
com.kiip.extensions.events.KiipEvent
Dispatched when a Kiip Poptart has been displayed
SAVE_MOMENT_FAILED | Event |
com.kiip.extensions.events.KiipEvent
Called when a branded moment has failed to save
SESSION_END_FAILED | Event |
com.kiip.extensions.events.KiipEvent
Called when the Kiip session has failed to end
SESSION_ENDED | Event |
SESSION_START_FAILED | Event |
com.kiip.extensions.events.KiipEvent
Called when the Kiip session has failed to start
SESSION_STARTED | Event |
com.kiip.extensions.events.KiipEvent
Called when the Kiip session has been started
SWARM_JOINED | Event |
VERSION | Constant |
public static const VERSION:String = 1.0.0
Version