initiate New Purchase
fun initiateNewPurchase(activity: Activity, zsPlan: ZSPlan, offerId: String = "", zsCustomFields: ArrayList<ZSCustomField> = ArrayList(), purchasesUpdatedListener: PurchaseUpdationListener)
Will subscribe to the particular plan ZSPlan. The subscription will be activated in Play Store and a corresponding subscription will also be created in Zoho Billing.
Parameters
activity
The current activity from which the purchase is initiated.
zs Plan
The plan object ZSPlan to which the user wants to subscribe.
offer Id
The offer id which has to be applied to the plan while subscribing. If no offer is to be applied, pass an empty string. Pass offer Id if the offer is developer determined.
zs Custom Fields
An optional array of custom fields ZSCustomField to be sent along with the subscription data to Zoho Billing.
purchases Updated Listener
An interface which handles the success or failure result of the purchase flow.