Public Classes
ReferralHero Kotlin / Java SDK
There are mainly 2 classes used by the ReferralHero SDK as the Kotlin Data classes for storing and accessing various related properties efficiently, allowing the SDK to easily manage and structure large sets of data.
Also, it is much easier for the developers integrating our SDK to understand data being returned or passed as part of the various methods or callbacks, making the whole integration process simple.
ReferralParams
SubscriberData
1. ReferralParams
This class provides various methods to set several user referral details like name, email, device, etc. This class is used mainly to pass referral details data to the SDK while accessing its public method or while updating the user information.
ReferralParams setter method for Java
Method
Description
setTransactionId(String value)
The unique ID of the transaction. Useful for tracking referrals for purchases.
setConversionCategory(String value)
The type of referral. Useful for creating reports.
settConversionValue(Int value)
The monetary value of the referral.
setDevice(String value)
The device used by the subscriber to sign up. Used for analytics.
setEmail(String value)
The email of the subscriber.
setDomain(String value)
The URL for the referral link.
setName(String value)
The name of the subscriber.
setReferrer(String value)
Set a referrer for the subscriber by providing the referrer's referral code or email.
setUuid(String value)
The list UUID.
setOsType(String value)
The os type of device used by the subscriber.
setSource(String value)
The source of the subscriber. Used for analytics.
setCryptoWalletAddress(String value)
The crypto wallet address
setExtraField(String value)
The extra field of the subscriber.
setExtraField2(String value)
The extra field 2 of the subscriber.
setIpAddress(String value)
The ip address of the device used by the subscriber.
setPoints(Int value)
The number of points for the subscriber. Only applicable for "contest" campaigns.
setPhoneNumber(String value)
The Phone Number of subscriber
setScreenSize(String value)
The screen size of the device used by the subscriber.
setSubscriber_id(String value)
Set Subscriber ID
setSocial(String value)
Social shares like facebook,instagram,email,whatsapp etc..
setDoubleOptIn(boolean value)
If set to false, the subscriber will not receive a confirmation email.
NOTE:
The parameters need to be sent in the correct order for our system to automatically generate a referral.
2. Subscriber Data
This class contains various member variables, each specifying some Subscriber related data.
Here is subscriber Data Class Code in Kotlin
3. List Subscriber Data
This class contains various member variables, each specifying some Subscriber related data.
Here is subscriber Data Class Code in Kotlin
Last updated