SDKBOX IAP: How to read "receiptCipheredPayload"
asnagni opened this issue · comments
asnagni commented
- cocos2d-x version: 3.17.2
- devices test on: iPhone X, 11, 12, 5, etc..
- developing environments
- NDK version:
- Xcode version: 13
- VS version:
- browser type and version:
Steps to Reproduce:
When I make the call "sdkbox::IAP::restore()" the handler "onRestored(sdkbox::Product const& p)" is called.
The "p.receiptCipheredPayload" is not empty, I would like to know how can I read the data of "receiptCipheredPayload". I tried to use "cocos2d::base64Decode()" but I'm garbage. Would someone know how to decode the "p.receiptCipheredPayload" returned.
- Make sure to purchase an non-consumable item
- Call the sdkbox::IAP::restore()
- In the handler onRestored(sdkbox::Product const& p) check "p.receiptCipheredPayload"
- Try to decode it with "cocos2d::base64Decode()"
Thank you,
Stay safe
asnagni commented
for iOS we need to communicate with the server.