Unity iOS
Retrieve Price Points
Before you begin
Before retrieving your price points for the checkout, ensure that you’ve set up your price points in the Publisher Dashboard.
Retrieve price points
To retrieve your price points, call the following function:
This function triggers the OnPricePointsSuccess
callback upon success. The callback receives a PricePointsModel
object containing the following properties:
Property Name | Type | Description |
---|---|---|
pricingPoints | Array | List of available price points. |
pricingPointData | Object | Currency formatting metadata. |
pricingPoints
:
basePriceInUSD | string | The product’s base price in USD. |
localizedPrice | string | The product’s price in the local currency, adjusted by the multiplier . |
formattedPrice | string | The localized price in string format. |
pricingPointData
:
currencyCode | string | The ISO 4217 currency code. For example, USD for United States Dollar. |
currencySymbol | string | The symbol representing the currency. For example, ”$”. |
fractionalSeparator | string | The character used to separate decimal places . For example, ”.” or ”,”. |
milSeparator | string | The character used to separate thousands. For example, ”,” or ”.”. |
symbolPosition | string | The position of the currency symbol. For example, “Right” for after the amount, “Left” for before. |
spacing | boolean | Whether there is a space between the number and the currency symbol. |
multiplier | number | The factor by which the localizedPrice is multiplied. In the example below, the localized price is 200 and the multiplier is 100, so the final price will be $2.00. |
Example code
Below is an example response code for the function: