I am using the in-app billing in my android application, but I do not know how to integrate the in-app promotion with my app. I have tried to read this resource here, but I didn't understand any thing. the application is providing the payment methods except the redeem, please any help how to integrate it?
note: I'm using in-app billing v3
Integration of the in-app promotion with App Google provided a descriptive documentation which you can refer to implement in-app promotion.
Official Documentation says,
If your app supports the in-app purchase workflow(described in Making In-app Billing requests), your app
automatically supports in-app redemption of promo codes.
Here are some details
Supporting Promo Codes in Your App
To support promotion codes, your app must call the getPurchases() method whenever the app starts or resumes. This method returns a bundle of all current, unconsumed purchases, including purchases the user made by redeeming a promo code.
Calling getPurchases() on startup and resume guarantees that your app finds out about all purchases and redemptions the user may have made while the app wasn't running. Furthermore, if a user makes a purchase while the app is running and your app misses it for any reason, your app still finds out about the purchase the next time the activity resumes and calls getPurchases().
Refer this documentation for more details
https://developer.android.com/google/play/billing/billing_promotions.html#supporting
This is the checkbox you have to tick before creating promotion codes:
My app integrates In-app Promotions.
This requirement is very misleading. There's no such thing as in-app promotion integration. If your app integrates in-app purchases your are ready to go. I spent half an hour before realizing my app was already supporting in-app promotions because it simply supports in-app purchases
Related
I've developed an Android app and need clarity on what is required to offer it, via Google Play Store, as a subscription app (i.e. offer use of the app for a monthly fee). For now, no in-app purchases or in-app subscriptions are planned; the only subscription is for use of the app itself. All of the documentation I've read about subscriptions from the Google Play Store seems only to discuss in-app subscriptions.
My questions:
1) Is an overall app subscription treated/processed the same as an in-app subscription (i.e. via the app)?
2) If not, what portions of the Google documentation/guides on subscriptions do I implement? Everything that isn't expressly mentioned as being for in-app subscriptions/purchases?
3) Do I need a back-end server to manage/track app subscription info, or can subscriptions at the app level be managed via Google Play Console?
4) Is there a guide/example/tutorial somewhere that clearly explains how to implement what seems like a basic solution, a subscription app with no in-app purchases?
Examples of what I found during research:
Create a subscription - Play Console Help indicates:
Create a subscription
Using Google Play Billing, you can offer in-app products that charge users for content or services on a recurring basis, known as subscriptions. Subscriptions can include items like a collection of apps, games, or other content for a recurring fee within your app on Google Play.
In Google Play Console, subscriptions are only mentioned (from what I can see) under Store presence->In App Products->Subscriptions
I reviewed other questions on SO related to subscriptions, but virtually all appear to be focused on in-app subscriptions. One exception was Implementing a Yearly Subscription. Per the answer from GNUzilla, I understand the need to create a payment profile in Play Console. The second part of GNUzilla's answer references the now deprecated AIDL interface, so I instead reviewed the guide page for its replacement, Use the Google Play Billing Library | Android Developers. However, this also appears focused on in-app subscriptions. For example,
Enable the purchase of an in-app product
...
To start a purchase request from your app, call the launchBillingFlow() method from the UI thread. Pass a reference to a BillingFlowParams object containing the relevant data to complete the purchase, such as the product ID (skuId) of the item and product type (SkuType.INAPP for a one-time product or SkuType.SUBS for a subscription).
Is an overall app subscription treated/processed the same as an in-app subscription (i.e. via the app)?
There is no such app subscription feature Google has implemented. It always will be in-app subscriptions. User will download the app free/paid and login/signup into the app then the developer will show the subscriptions plan based upon the business case.
If not, what portions of the Google documentation/guides on subscriptions do I implement? Everything that isn't expressly mentioned as being for in-app subscriptions/purchases?
In-App subscriptions. Check here https://developer.android.com/google/play/billing/billing_subscriptions
Do I need a back-end server to manage/track app subscription info, or can subscriptions at the app level be managed via Google Play Console?
Yes, you need the backend for managing the real-time notifications. If you don't want to have the backend then you will miss lots of scenarios like your app don't what is the current subscription status. It is also good from a security point of view to verify the purchase in the backend.
Is there a guide/example/tutorial somewhere that clearly explains how to implement what seems like a basic solution, a subscription app with no in-app purchases?
You can check google documentation here. In the future, I will also publish the blog regarding this.
I'm using Cross Platform Native Plugins' Billing API to do the In-App Purchase stuffs.
In Android, for example, in normal situation,
after a user complete the in-app purchase payment,
the activity would turns back to unity's activity in several seconds,
and then the purchase info would be available from callback.
But, if the user has complete the payment, and close the app before callback has invoked, the purchase info would become lost ...
I've tried restore purchases, but it is only for "Non-Consumable" purchases, the Consumable purchases still lost.
Is there any way to retrieve back the lost purchase info?Especially for "Consumable" purchases?
Google has provide a Google Play Developer API for solving this IAP order question, which contains some ways to retrieve any iap order information that has been created(even not successfully paid).
Working with play store's order management page, finally get enough information to solve the question of iap order lost.
I want to add an android in-app payment method, so I followed instructions by this page using AIDL
I successfully added it and tried to do an effective payment using my personal google account. The payment was successful but I didn't receive the money.
I know that, implementing this type of purchase, a user can buy add-on app features or simply make a small donation. Isnt' it? Is there a better method to do that?
As Google say in billing testing: To test your Google Play Billing implementation with actual in-app purchases, you must use a test account. By default, the only test account registered is the one that's associated with your developer account.
Money not charged if you account equivalent to you Google Play account.
Also you can try to use more convenient library from google for in-app billing
I have created a android application. Subscription is free. However I have put ads inside application. Now I want provide option within app where people can buy ad-free version. And also provide option to restore purchase.
I went through Android docs didn't understand anything. Please provide a good tutorial.
Hey I had worked on InApp Purchase recently and I've successfully integrated in my existing app and ready to make it live. Initially when i had started doing this I've downloaded google InApp Billing Example called "Trivial Drive" from here.
But it didn't help me much as it has lots of issues and bugs, So I've decided do it on my own from scratch using new v3 api which you can find here. This tutorial has clear explanation that would help you and also if you have time, see this youtube video where google employee had explained clearly how to integrate it.
Also if you want quick example, I've a sample app which you can download from here.
The following video also explains how to integrate InApp Purchase. Please go through it.
https://www.youtube.com/watch?v=-h2ESH71hAI
Thank you
Refer this question on SO Implementing In App purchases in Android?. Also for official documentation of The In-app Billing Version 3 API refer this link http://developer.android.com/google/play/billing/api.html
This is how you create In app purchase inside your app.
1) In your developers console, go to your application and create a in app product(Name it as Ad-Free Access or what ever).(Note: to create a in app product you need to have a merchant account).
2) If you have a merchant account ready, create a InApp Product with the type of Subscription(One time or monthly or yearly) and price.
3) Once you have created the InApp product successfully, you can prompt the user to purchase an InApp product by quering a list of in app products in your app and ask user to purchase them.
Here is a link to query the InApp products:
4) Once a user purchase the product, based on the purchase status of the product, you can disable the ads in your app.
The Simple and very easy way to implement in-app through a library anjilab.
Just add the dependecy
implementation 'com.anjlab.android.iab.v3:library:1.0.44'
Add Permission, implement methods and you done.
For any issues you can see here
issues
I would like to implement in-app billing in my android app, but I am not sure how should I create for a developer payload. I don't have any information about user, only unique identifier created in the app to recognize it.
Is it possible to restore the purchase when the user buy a product, then uninstall the app and install it again? How to test it, because I didn't get any events when I tried to test it?
Yes, you can check the completed purchase after uninstall app and install it again.
All purchased items stored on the Play Server and particularly in your installed Google Play app. So after item is purchased once the information about purchase is stored and you can request it at any time untill you "consume" this purchase. "Consume" means reset the information about purchase to allow make new purchase with same ID. This is only for v3 if Android Billing Library, because all purchases in v3 are one-off (you can buy it only once) and have to be "consumed" to be purchased again.
The identifier of the purchase item is a simple string that you define in the Google Developer Console. You should login to the developer console, create new project for the future app, upload signed .apk (necessary), after that you have to select the project, move to "In-App products" section and there you can create necessary purchase items with purchase IDs. While purchase action in the application you should pass the matched purchaseID to the launchPurchaseFlow() method on the IabHelper object (these are all from v3 Billing Library). The information about purchased items can also be received by using matched purchaseID.
Official Google developer documentation has pretty decent amount of information about implementing and using Billing Library:
Implementing billing library guide
Administering In-App products in the developer console
Testing In-app billing. Sorry, cannot post link because of lack of reputation (2 links in answer only), but you can also find this section in the official android documentation. This section also has information about testing with special android test purchase IDs which doesn't require signed and uploaded .apk or any actual money-transfers