This repository has been archived by the owner on Apr 28, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 171
How To support Samsung Apps
Anastasiia Karimova edited this page Mar 5, 2015
·
4 revisions
-
In the AndroidManifest.xml add the corresponding billing permission
<uses-permission android:name="com.sec.android.iap.permission.BILLING" />
-
Map the SKUs if required. Remember, Samsung Apps describes an item in terms of Item Group ID and Item ID.
//format "(digitst)group_id/(string)item_id" OpenIabHelper.mapSku(SKU_PREMIUM, OpenIabHelper.NAME_SAMSUNG, "100000100696/000001003746"); OpenIabHelper.mapSku(SKU_GAS, OpenIabHelper.NAME_SAMSUNG, "100000100696/000001003744"); OpenIabHelper.mapSku(SKU_INFINITE_GAS, OpenIabHelper.NAME_SAMSUNG, "100000100696/000001003747");
-
Instantiate
new OpenIabHelper
using an Activity instance. Activity context is required to callstartActivityForResult()
for SamsungAccount Activity. -
In the proguard config file add
# SAMSUNG -keep class com.sec.android.iap.**
To test your .apk with SamsungApps
-
for Samsung Apps
- Ensure SamsungApps is installed on your device
- Ensure Samsung IAP Service is installed on your device
-
for OpenIAB
# install for SamsungApps: adb install -i com.sec.android.app.samsungapps /path/to/YourApp.apk
SamsungApps.isSamsungTestMode = true