PlaytoliaStore gives you the product catalog and the purchase flow. It syncs automatically after the player logs in.
Three identifiers, three jobs
Every product carries three identifiers. Confusion between these three identifiers is the most common cause of a product that isnull:
Fetching products
Product fields
Id, Code, Name, Description, Sku, Type (Consumable/NonConsumable/Subscription), Grants[]
Each Grant has: GrantId, GrantType, GrantAmount, Currency?
Making a purchase
onSuccess callback receives a PurchaseReceipt with the transaction ID, the store, and the purchased product. The onError callback receives a PurchaseError with a machine-readable error code, a stage, and a message. Both callbacks are optional.
When the purchase is successful, the SDK updates the wallet, the entitlements, and the subscriptions of the player automatically.
PurchaseReceipt
PurchaseError
Error codes
Listening to changes
Wallets
Track currency after purchases
Entitlements
Track non-consumable unlocks