I use IAP in my iOS application and I use the latest version of SwiftyStoreKit Framework to help me with my purchases.
I completed all the tasks of the preliminary cursor, such as setting up a developer account in itunes connect, creating Provision profiles for the application, making new expendable and non-consumer purchases in TestFlight, adding these purchases to the application information (ready to be sent), and creating a sandbox user . I debugged the following this answer , this and this one .
Now the problem is that whenever I send a request for product information, I get the following error. RetrieveResults(retrievedProducts: Set([]), invalidProductIDs: Set(["com.mycompany.app.consumable"]), error: nil)
and when I try to purchase a product, I get this error Purchase Failed: SKError(_nsError: Error Domain=SKErrorDomain Code=3 "Invalid product id: com.mycompany.app.consumable" UserInfo={NSLocalizedDescription=Invalid product id: com.mycompany.app.consumable})
Recovering purchases and checking receipts seems to work fine ...
Any pointers would be very helpful.
Thanks.
UPDATE:
Now I left the SwiftyStoreKit structure and use Appleβs own way to use SKProductsRequest Apple, where I configured the delegate functions and all the requirements, then I run the SKProductsRequest.start () function call, and it still returns me a set of invalid product identifiers.
For the new method, I am setting up a new project, as well as preparation profiles for package identifiers and the itunes connect application. I can download the itunes connection app for testflight too! So the identifiers seem correct.
ios swift3 in-app-purchase
Munib
source share