A B C D E F G H I J K L M N O P Q R S T U V W X Y Z

A

Perform AJAX call of type DELETE. I could not use simply delete as method name, since it will throw error on IE
url: 'string',
data: object,
dataType: 'string' // DEFAULT: 'json',
successCallback: function() {} // DEFAULT: log the response
errorCallback: function() {} // DEFAULT: log the response

Perform AJAX call of type GET
url: 'string',
data: object,
dataType: 'string' // DEFAULT: 'json',
successCallback: function() {} // DEFAULT: log the response
errorCallback: function() {} // DEFAULT: log the response

Perform AJAX call of type POST
url: 'string',
data: object,
dataType: 'string' // DEFAULT: 'json',
successCallback: function() {} // DEFAULT: log the response
errorCallback: function() {} // DEFAULT: log the response

Perform AJAX call of type PUT
url: 'string',
data: object,
dataType: 'string' // DEFAULT: 'json',
successCallback: function() {} // DEFAULT: log the response
errorCallback: function() {} // DEFAULT: log the response

Setup APIs method used by iWin to perform AJAX calls

Return list of all available endpoints

Return API URL of passed endpoint, eventually replaced with parameters (must be and object { key : 'value' })

D

Return ago time (humanized) based on language date. Instance of momentjs.
Get Moment

Return now() date. Instance of momentjs.
Get Moment

Return the Development Status of your App. Useful to log via App.error.log()
Available options: true or false

Set the Development Status of your App. Useful to log via App.error.log()
Available options: true or false

E

Alert a message. HTML supported. Instance of Vex.
Get Vex

Confirm dialog with message. HTML supported. Instance of Vex.
Get Vex

Log a message via console if window.console && iWin.getDevelopmentStatus() == true. HTML supported

Prompt dialog with message and placeholder. HTML supported. Instance of Vex.
Get Vex

Throw new Error.

I

Return the true or false if the device is Mobile

Set the Mobile options. Useful to force a behaviour
Available options: true or false

Return the true or false if the device is Retina

Set the Retina options. Useful to force a behaviour
Available options: true or false

Return the true or false if the device is in StandAlone mode

Set the StandAlone options. Useful to force a behaviour
Available options: true or false

L

Setup iWin Language class. Language must be present in iWin.language.availableLanguages Array.

Set the Language options. Language must be present in iWin.language.availableLanguages Array.

Return the Language.

Set the availableLanguages options. Languages must be an Array ['it', 'en', 'fr', 'de', 'pt', 'es'].

Return the availableLanguages.

Set the DefaultLanguage. Useful as fallback option. Language must be present in iWin.language.availableLanguages Array.

Return the DefaultLanguage.

P

Setup iWin Play class. Parameters and Sweepstake will be evaluated and validated.

Return the sweepstakeID.

Return the sweepstakeApiKey.

Return the playerID.

Return the playerToken.

Evalute sweepstakeID and sweepstakeApiKey

Validate Sweepstake. Started/Ended/Enabled...

Register new Player. sweepstakePlayerID will be casted to string.
extraFields, if present, must be of type object

When Player is registered correctly sweepstakePlayerID and sweepstakePlayerToken are automatically filled out.

Play. ugcFields, if present, must be of type object

Retrieve all Awards or single Award if objectID is not null.
sortOptions:

{
    'sort' : 'DESC' // or ASC
},
{
    'order' : 'object_id' // or any field valid for Player
},
{
    'limit' : 50 // max is 200
},
{
    'offset' : 0
},
{
    'fields' : 'object_id,created_at' // comma separated list of fields you want to retrieve
}

Retrieve all Plays or single Play if objectID is not null.
sortOptions:

{
    'sort' : 'DESC' // or ASC
},
{
    'order' : 'object_id' // or any field valid for Player
},
{
    'limit' : 50 // max is 200
},
{
    'offset' : 0
},
{
    'fields' : 'object_id,created_at' // comma separated list of fields you want to retrieve
}

Retrieve all Players or single Player if objectID is not null.
sortOptions:

{
    'sort' : 'DESC' // or ASC
},
{
    'order' : 'object_id' // or any field valid for Player
},
{
    'limit' : 50 // max is 200
},
{
    'offset' : 0
},
{
    'fields' : 'object_id,created_at' // comma separated list of fields you want to retrieve
}

When single Player is found, sweepstakePlayerID and sweepstakePlayerToken are automatically filled out.

Retrieve all ExtraFields or single ExtraField if objectID is not null.
sortOptions:

{
    'sort' : 'DESC' // or ASC
},
{
    'order' : 'object_id' // or any field valid for Player
},
{
    'limit' : 50 // max is 200
},
{
    'offset' : 0
},
{
    'fields' : 'object_id,created_at' // comma separated list of fields you want to retrieve
}

Retrieve all UgcFields or single UgcField if objectID is not null.
sortOptions:

{
    'sort' : 'DESC' // or ASC
},
{
    'order' : 'object_id' // or any field valid for Player
},
{
    'limit' : 50 // max is 200
},
{
    'offset' : 0
},
{
    'fields' : 'object_id,created_at' // comma separated list of fields you want to retrieve
}

T

Return slugged string.
Ex: Instant Win = instant-win

Return toLowerCase string.

Return toUpperCase string.

Return stripped string.
Ex: Instant Win : Instant Win

Return true or false if search is contained in string

U

Return true or false if item is contained in items (Array)

Return true or false if number is integer