Menu

Predefined Events

1. Ad Impression

Automatically reported when displaying ads within the app, which is essential for ROI analysis and monetization-related metrics in user analysis. (Event Name:  "_appImp")

export function trackAdImpressionWithAttributes(adImpressionEventAttribute:SEAdImpressionEventAttribute);

SEAdImpressionEventAttribute parameters:

      Please report the corresponding fields from mediation to SolarEngine following https://help.solar-engine.com/en/docs/Impression-level-revenue-integration.

ParameterDescriptionTypeRequired
adNetworkPlatformMonetization platform (Value: platform name)
csj: 穿山甲 China Mainland version
pangle: 穿山甲 International version
tencent: 腾讯优量汇
baidu: 百度百青藤
kuaishou: 快手
oppo: OPPO
vivo:vivo
mi: 小米
huawei: 华为
applovin: AppLovin
sigmob: Sigmob
mintegral:Mintegral
oneway: OneWay
vungle: Vungle
facebook: Facebook
admob: AdMob
unity: UnityAds
is: IronSource
adtiming: AdTiming
klein: 游可赢
fyber: Fyber
chartboost: Chartboost
adcolony: Adcolony
Stringyes
ad_typeAd types:
1:Rewarded Video
2:Splash
3:Interstitial
4:Fullscreen Video
5:Banner
6:Native
7:Native Video
8:Banner (MPU)
9:Instream Video
10:MREC
0:Other
Numberyes
adNetworkAppIDThe App ID on monetization platforms.Stringno
adNetworkPlacementIDAd Unit ID on monetization platforms.Stringyes
mediationPlatformMediation platforms commonly used:
max
ironsource
admob
hyperbid
topon
cas
Tradplus
Tobid

If your mediation platform is not on the list, you can name it yourself, only that the name cannot exceed 32 characters.
Send "custom" if no mediation platform is used.
Stringyes
ecpm=revenue of 1,000 ad impressions
(0 or negative values are invalid.)
(Mininum Unit:  e.g. USD, CNY, etc.)
Numberyes
currencyRevenue Currency Type (following ISO 4217)Stringyes
renderedWhether the ad is rendered successfully.
YES: success
NO: Failed.
If you do not need to pass in this indicator, please pass YES.
Booleanyes
customProperties/Objectno

Sample Code

let attribute:SEAdImpressionEventAttribute = {

  adNetworkPlatform:"AdMob",
  adType:AdType.Interstitial,
  adNetworkAppID:"AdMob appid",
  adNetworkPlacementID:"AdMob placementid",
  mediationPlatform:"MAX",
  currency:"USD",
  ecpm:1.234, //Here the unit is' USD ', please note the unit conversion
  rendered:true,
  customProperties:{"key1":"value1","key2":"value2"}
  // You can choose not to set customProperties. 
  // Note: Please do not report custom properties starting with "_", otherwise SDK will abandon its value by default.
}
SolarEngine.trackAdImpressionWithAttributes(attribute);

2. In-App Purchase

       Automatically reported when in-app purchase is made. (Event Name: "_appPur") This is a key event for training the purchase prediction model.

export function trackIAPWithAttributes(iapEventAttribute:SEIAPEventAttribute);

SEIAPEventAttribute parameters:

ParameterDescriptionTypeRequired
orderIdThe order ID generated by the system for this purchaseStringno
payAmountThe amount paid for this purchase (Unit: e.g. USD, CNY, etc.)Numberyes
currencyThe currency type of payment (following ISO 4217)Stringyes
payTypePayment methods, such as export const Alipay = "alipay";
export const Weixin = "weixin";
export const ApplePay = "applepay";
export const Paypal = "paypal";
Stringno
productIDPurchased item IDStringno
productNamePurchased item nameStringno
productCountQuantity of items purchasedNumberno
payStatusPayment status
1: success
2: failed
3: restored
SEIAPStatusyes
failReasonReason for payment failureStringno
customProperties/Objectno

Note:

 The failureReason parameter is only be passed in when the payStatus parameter is Failed. For other statuses, simply pass "".

Sample Code

let attribute:SEIAPEventAttribute = {
  productID:"product id",
  productName:"product name",
  productCount:3,
  orderId:"order id",
  payAmount:3.14,
  currency:"USD",
  // const Alipay    = "alipay";
  // const Weixin    = "weixin";
  // const ApplePay  = "applepay";
  // const Paypal    = "paypal";
  payType:Paypal,
  payStatus:SEIAPStatus.Success,
  failReason:"",
  customProperties:{"key":"iap customProperties value"}
// You can choose not to set customProperties. 
// Please do not report custom properties starting with "_", otherwise SDK will abandon its value by default.

SolarEngine.trackIAPWithAttributes(attribute);

3. Ad Click

Call trackAdClickWithAttributes to report in-app ad click events:

export function trackAdClickWithAttributes(adClickEventAttribute:SEAdClickEventAttribute);

SEAdClickEventAttribute parameters:

ParameterDescriptionTypeRequired
adNetworkPlatformMonetization platforms, for example (value: name),
csj:穿山甲国内版
pangle:穿山甲国际版
tencent:腾讯优量汇
baidu:百度百青藤
kuaishou:快手
oppo:OPPO
vivo:vivo
mi:小米
huawei:华为
applovin:Applovin
sigmob:Sigmob
mintegral:Mintegral
oneway:OneWay
vungle:Vungle
facebook:Facebook
admob:AdMob
unity:UnityAds
is:IronSource
adtiming:AdTiming
klein:游可赢
fyber:Fyber
chartboost:Chartboost
adcolony:Adcolony
Stringyes
adTypeAd types, for example (value: explanation),
1:Rewarded Video Ads
2:Splash Ads
3:Interstitial Ads
4:Full Screen Videos
5:Banner Ads
6:In-Feed Ads
7:Native Video Ads
8:Playable Ads
9:Pre-movie Ads
0:Other
Numberyes
adNetworkPlacementIDAd unit ID on monetization platforms.Stringyes
mediationPlatformMediation platforms commonly used:
max
ironsource
admob
hyperbid
topon
cas
Tradplus
Tobid

If your mediation platform is not on the list, you can name it yourself, only that the name cannot exceed 32 characters.
Send "custom" if no mediation platform is used.
Stringyes
customProperties/Objectno

Sample Code

let attribute:SEAdClickEventAttribute = {

  adNetworkPlatform: "AdNetwork platform",
  adType:AdType.Interstitial,
  adNetworkPlacementID:"AdNetwork placementid",
  mediationPlatform:"mediation name",
  customProperties:{"key":"adclick customProperties value"}
// You can choose not to set customProperties. 
// Please do not report custom properties starting with "_", otherwise SDK will abandon its value by default.
}
SolarEngine.trackAdClickWithAttributes(attribute);

4. Registration

Call trackRegisterWithAttributes to report the registration event:

export function trackRegisterWithAttributes(registerEventAttribute:SERegisterEventAttribute);

SERegisterEventAttribute parameters:

ParameterDescriptionTypeRequired
registerTypeRegistration types such as "WeChat", "QQ" and other custom valuesStringYes (No more than 32 characters)
registerStatusRegistration status such as "success"StringNo
customPropertiesCustom PropertiesObjectNo

Sample Code

let attribute:SERegisterEventAttribute = {

  registerType:"WeChat",
  registerStatus:"success",
  customProperties:{"key":"register customProperties value"}
// You can choose not to set customProperties. 
// Please do not report custom properties starting with "_", otherwise SDK will abandon its value by default.
}
SolarEngine.trackRegisterWithAttributes(attribute);

5. Login

Call trackLoginWithAttributes to report the login event:

export function trackLoginWithAttributes(loginEventAttribute:SELoginEventAttribute);

SELoginEventAttribute parameters:

ParameterDescriptionTypeRequired
loginTypeLogin type such as "WeChat", "QQ" and other custom valuesStringYes
loginStatusLogin status such as "success"StringNo
customPropertiesCustom PropertiesObjectNo

Sample Code

  let attribute:SELoginEventAttribute = {
    loginType:"WeChat",
    loginStatus:"failed",
    customProperties:{"key":"login customProperties value"}
// You can choose not to set customProperties. 
// Please do not report custom properties starting with "_", otherwise SDK will abandon its value by default.
  }
  SolarEngine.trackLoginWithAttributes(attribute);

6. In-App Order

Call trackOrderWithAttributes to report in-app order event:

export function trackOrderWithAttributes(orderEventAttribute:SEOrderEventAttribute);

SEOrderEventAttribute parameters:

ParameterDescriptionTypeRequired
orderIDOrder IDStringNo (No more than 128 characters)
payAmountThe payment amount of the order (Unit: e.g. USD, CNY, etc.)doubleYes
currencyThe currency type of the order (following ISO 4217)StringYes
payTypePayment methods, such as :

export const Alipay = "alipay";
export const Weixin = "weixin";
export const ApplePay = "applepay";
export const Paypal = "paypal";

Other payment methods can be customized.
StringNo, no more than 32 characters
statusOrder StatusStringYes
customPropertiesCustom PropertiesObjectNo

Sample Code

let attribute:SEOrderEventAttribute = {
  orderID:"order id",
  payAmount:3.1415926,
  currency:"USD",
  payType:Paypal,
  status:"success",
  customProperties:{"key":"order customProperties value"}
// You can choose not to set customProperties. 
// Please do not report custom properties starting with "_", otherwise SDK will abandon its value by default.
}
SolarEngine.trackOrderWithAttributes(attribute);

7.  Self-Reported Attribution Results

Enables the reporting of attribution results data from a third-party or self-attribution platform to SolarEngine. The timing of reporting can be customized by developers. (Event Name: "_appAttr")

export function trackAppAttrWithAttributes(appAttrEventAttribute:SEAppAttrEventAttribute);

SEAppAttrEventAttribute parameters:

ParameterDescriptionTypeRequired
adNetworkChannel ID (should match the channel ID in ROI analysis)Stringyes
subChannelSub-channels for advertisingStringno
adAccountIDAd account ID for advertisingStringno
adAccountNameAd account name for advertisingStringno
adCampaignIDAd campaign ID for advertisingStringno
adCampaignNameAd campaign name for advertisingStringno
adOfferIDAd offer ID for advertisingStringno
adOfferNameAd offer name for advertisingStringno
adCreativeIDAd creative ID for advertisingStringno
adCreativeNameAd creative name for advertisingStringno
attributionPlatformMMPStringyes
customPropertiesCustom PropertiesObjectno

Sample Code

let attribute:SEAppAttrEventAttribute = {
  adNetwork:"toutiao",
  subChannel:"103300",
  adAccountID:"1655958321988611",
  adAccountName:"xxxFPS18",
  adCampaignID:"1680711982033293",
  adCampaignName:"FPS-Campaign157-1024",
  adOfferID:"1685219082855528",
  adOfferName:"FPS-Offer406-1024",
  adCreativeID:"1680128668901378",
  adCreativeName:"Auto-created20210901178921",
  attributionPlatform:"Attribution Platformxxx",
  customProperties:{"customProperties":"app attr customProperties value"}
  // You can choose not to set customProperties. 
  // Please do not report custom properties starting with "_", otherwise SDK will abandon its value by default.
}
SolarEngine.trackAppAttrWithAttributes(attribute);


Previous
Preset Events
Next
Custom Events
Last modified: 2024-12-05Powered by