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
akarimova edited this page Oct 22, 2014
·
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 "group_id/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 following steps are needed:
- Ensure SamsungApps is installed on your device
- Ensure Samsung IAP Service is installed on your device
- Install your .apk with special option to help OpenIAB choose SamsunApps
# install for SamsungApps: adb install -i com.sec.android.app.samsungapps /path/to/YourApp.apk