Class Promo
Class that provides a static interface to IAP Promo purchases.
Namespace: UnityEngine.Purchasing
Syntax
public class Promo : object
Constructors
Promo()
No longer used because this class is static. Creates a Promo object, but there is no reason to do this.
Declaration
public Promo()
Methods
InitiatePromoPurchase(String)
Initiates a purchasing command for a promo product. Legacy for original promo Ads SDK.
Declaration
public static bool InitiatePromoPurchase(string itemRequest)
Parameters
Type | Name | Description |
---|---|---|
String | itemRequest | The JSON item request command for purchase. |
Returns
Type | Description |
---|---|
Boolean | If the command was successful or not. |
InitiatePurchasingCommand(String)
Initiates a purchasing command for a promo product.
Declaration
public static bool InitiatePurchasingCommand(string command)
Parameters
Type | Name | Description |
---|---|---|
String | command | The JSON item request command for purchase. |
Returns
Type | Description |
---|---|
Boolean | If the command was successful or not. |
IsReady()
Check if the IAP Promo setup is ready.
Declaration
public static bool IsReady()
Returns
Type | Description |
---|---|
Boolean | Whether or not promo products have been proviced to Ads. |
QueryPromoProducts()
Queries the list of available promo products.
Declaration
public static string QueryPromoProducts()
Returns
Type | Description |
---|---|
String | The list of promo products as raw JSON. |
Version()
Check the version of IAP Promo.
Declaration
public static string Version()
Returns
Type | Description |
---|---|
String | The package version used, if known. |