Appmetrica Plugin

This plugin allows you log events and setup push with Appmetrica.

Platforms:

this plugin only works with iOS

Functions:

appmetrica.init(apiKey)

-- setup appmetrica

apiKey(string) api key from appmetrica dashboard

appmetrica.setUserProfileID(userID)

-- set user id

userID(string) set user id for device user

appmetrica.setLocationTracking(enableLocation)

-- enable location

enableLocation(boolean) enable location tracking

appmetrica.setVersion(verison)

-- set verison number

verison(number) verison of app

appmetrica.setGender(gender)

-- set gender for profile

gender(string) set as "male" or "female"

appmetrica.setAge(age)

-- set age for profile

age(number) set age of user

appmetrica.setName(name)

-- set name for profile

name(string) set name of user

appmetrica.setDidUserEnableNotifcation(boolean)

-- did you enable notifcation for user

didUserEnableNotifcation(boolean)

appmetrica.setCustomUserInfo(key, value)

-- custom data for user

key(string) custom key for user

value(string) custom value for user

appmetrica.reportEvent(eventName, data)

eventName(string) event name

data(table) data for the event

appmetrica.reportError(errorName, errorReason)

errorName(string) error name

errorReason(table) error reason

appmetrica.setupPush(isDevelopmentMode)

isDevelopmentMode(boolean)(optional) using in development mode (default is false)

appmetrica.reportEvent(eventName, data)

eventName(string) event name

data(table) data for the event

Runtime Event:

setup up runtime like so Runtime:addEventListener( "appmetrica", listener )

Returns: event.name = "appmetrica", event.type = "remotePush" or "didRegisterPush", event.isError = boolean, event.error = should return string or nil, event.data(occurs when event.type = "remotePush")(table) = contain aps data in table format see apple docs

Build Settings:

Helpful Links:

Example

Support

Get Plugin