Search Unity

  1. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

Question How to get Receipt of Purchased Items

Discussion in 'iOS and tvOS' started by Rachan, Dec 1, 2023.

  1. Rachan


    Dec 3, 2012
    Hi there!

    I really want to know how to get all receipts of purchased items in Unity IAP
    I used this script on OnInitialized of IAP

    and my Items all is Consumable not Subscript
    Code (CSharp):
    1. foreach (var product in controller.products.all)
    2.         {
    3.             if (product.hasReceipt)
    4.             {
    5.                  // this Item already purchased
    6.             }
    7.         }
    But the result still all false, even I used to buy something in my game,
    or I purchasing in Sandbox mode, it still count?