question

qtoppler avatar image
qtoppler asked

What determines if Sandbox mode is used?

Could someone please tell me what determines if Sandbox mode is used for IAP? It appears our production app is using Sandbox mode (by looking at debug output).
iap
10 |5000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

1 Answer

Anshul@Amazon avatar image
Anshul@Amazon answered
We can determine if an IAP is using SandBox mode based on the Boolean parameter "isSandboxMode" of callback method onSdkAvailable(). As per the documentation, onSdkAvailable(boolean isSandboxMode) - This callback is invoked once you register your PurchasingObserver with the PurchasingManager - This method tells you if the Purchasing Framework is running in sandbox mode with test data, or in production mode with real data - If your app is downloaded via the Amazon Client, isSandboxMode will return false - The initiating method should be called within the onStart() lifecycle method If an IAP is running in SandBox mode, then the isSanboxMode Boolean will return true. Complete documentation on IAP API's is available at https://developer.amazon.com/sdk/in-app-purchasing/documentation/developer-guide.html
10 |5000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.