Access UA Information
HyperKit.UA.GetCampaignType()
Section titled “HyperKit.UA.GetCampaignType()”Description
Section titled “Description”The GetCampaignType() method is a static method in the HyperKit.UA service that retrieves the current User Acquisition (UA) campaign type. This method is useful for determining the type of campaign associated with the user’s app installation or engagement.
Return Value
Section titled “Return Value”The method returns a CampaignType enum value, which can be one of the following:
- CPI_CPM: Cost Per Install or Cost Per Mille campaign
- AD_ROAS: Return On Ad Spend campaign
- IAP: In-App Purchase campaign
- BLENDED: A campaign that combines multiple types
- CPA_CPE: Cost Per Action or Cost Per Engagement campaign
- Unknown: The campaign type cannot be determined
- Organic: The user was not acquired through a paid campaign
Usage Example
Section titled “Usage Example”var currentCampaign = HyperKit.UA.GetCampaignType();
switch (currentCampaign){ case CampaignType.CPI_CPM: Console.WriteLine("This is a CPI or CPM campaign."); break; case CampaignType.AD_ROAS: Console.WriteLine("This is an AD ROAS campaign."); break; // ... handle other cases ... default: Console.WriteLine("Unknown or Organic campaign type."); break;}