How to know users google play country from inside the android app? - android

We have some in-app products and subscriptions. The price varies from one country to another. The problem is that we dont know how to detect the country within the app. We are guessing based on a few things but what happens is that we guess the country and show him x price and when the user proceeds to google payment, google detects another country (based on playstore account?) and shows him y price. This is a violation of google policy and they want us to fix it. But how do we fix it? Is there an api which we can call to know the country which matches with google's understanding of the country.
(It has been repeated but about 8 years ago.. so i am not sure if something has changed since)

Why don't you try to get Locale from the system & perform operations further according to it..
Try this thing to get the current locale of the user
Locale current = ConfigurationCompat.getLocales(getResources().getConfiguration()).get(0);
If you need some more information regarding it, let me know.
-------------- EDIT ------------------
follow the link below for detailed information, it not possible to get the country linked with play store account for now. But you can trick around to fix it.
Determine Play Store Country

Related

Google Developer Account Terminated: What to do?

So we just launched a beta closed test, and our account was completely terminated. I believe the reason was a deceptive name.
We filed an appeal, but we're not sure what to do next. We had no idea our name was violating anything, and if this appeal doesn't go through, we have to publish this app. We some big financial backers, and getting the account terminated completely was kind of a shock to all of us.
So, what to do next, if the appeal doesn't go through? Should we make a new account, and republish the app? Should I contact someone and tell them I just need to change the name? We're kind of freaking out here.
Thank you.
Please write an email to googleplay-developer-support#google.com
Ask if they can reactivate your account with changing the name to resolve the issue. Otherwise sure you can pay 25€ to register a new developer account if that is an option for you.
Make sure your developer name (and your apps) are not deceptive, check if your app description matches to their actual features, check if your app and developer names are already used (simply google the names) and if you feel like it it is always a good idea to check copyright and name brands. (Trademark checks)
If you want to do a trademark check it is a good idea to consult a lawyer, however you can do a simple trademark check yourself which is almost always enough for a small android publisher. Go to a trademark research site for your region, for example UK and EU https://trademarks.ipo.gov.uk/ipo-tmtext . I can recommend to search for "text" and "contains any" to get the best results. For example text="adidas" contains-any in clothing will return that it is already registered, therefore you shouldn't call a fashion app "adidas" or a deceptive version like "adi-das" or alike.
Same here in US region. I used a name that's not a trademark or anything. It took them 2 months (which's supposed to be "Up to 7 days") to get back to me saying they won't reactivate my account. I've tried to appeal and reach their customer service (it shows "server error" on online chat and the online help page is a dead end too). You may seek a legal assistance to get their attention.

How can an age restriction be applied to an Android app?

I'm working on an Android app where a user must be 18 years or older to apply.
If there will be people under 18, the app would have negative public view which I do not want to deal with.
Is it somehow possible to be sure that my users are older than 17? Is there any service which could possibly accomplish this?
Ideal fictional solution: in my registration form the user writes his/her id number and I would check if he/she is old enough with fictional service.
One not very good solution which I found. There is an app called Muzmatch. It is dating app for Arabs. When the user register he have to use device camera to take picture of himself and send it to server.
I can do the same in my app and check if the user seems old enough but I think it's stupid idea.
Yes this is possible through the Google Play content rating system.
Check out the link: https://support.google.com/googleplay/android-developer/answer/188189?hl=en-GB
Scroll down to the Take your app’s rating questionnaire section and it'll run you through the steps to apply an age rating to your app.
In addition to this, maybe you could create a free in app purchase, that the user will have to buy when first entering the app. They would then need either a password or finger print in order to pay via Google Play.

Android In-App purchases with extra infomation

I ask this question expecting the answer to be 'not possible', as I have attempted to research this already and found no fruit! I thought that I would give the community a chance to weigh in however.
I have a working in-app billing system, but what I want is to be able to provide a little extra bit of infomation with the billing request. Something that would show up in my market place stats.
My users have the option of buying several different levels of product (sort of a Base, Premium and Gold-Star sort of thing). When they purchase the product they provide me with a string that represents the specific thing they want the product about (such as the house number and postcode if the product was about a house).
What I want is to be able to see that extra bit of information in my market place reports, so when I see someone who has requested a refund I can see on what exact item they purchased the product. I have looked at the DEVELOPER_PAYLOAD but I don't think that it will do what I want.
If I can't find a solution this way then I will end up performing a service call and storing the data myself, but I thought I would ask you guys first!
Sorry for being vague about my app and the products it returns but I don't want to expose my app yet (plus it holds no bearing on the question!).
EDIT
Now that I have added a bounty I would like to limit the answers. As I mentioned in my original question my backup plan will me a service call to my system registering the google reference and "data packet" for the purchase.
What I am most interested in is a way to do this where my information would end up in the my market place reports. For instance, if you were to offer a physical item with your in app purchase, how would a user record shipping instructions/etc. There is a place for this in the market reports, so surely there is a way to add the data?
You can certainly use DEVELOPER_PAYLOAD for this. However, Google doesn't process it in anyway and it won't show up in reports (not sure if they store it at all). So what you need to do is send transaction info (the JSON string you receive) to your own sever, parse it and store/process/whatever the developerPayload. You can combine this with signature verification and transaction reporting if you want to. One thing to beware of is that the size is limited to 512 bytes. If you send a request with a longer string, the whole transaction will fail, and the error message is not friendly at all ('IAB-DPTL' or some such).
Of course if you need more that this, you can simply build your own webservice and send whatever data you want. If it includes personal info, etc. make sure you let people know about it and/or they can turn it off.
In order to see this in the report, assuming you have a limited set of "dynamic" data, you would probably have to create a different set of in-app items per each "item" in your game.
Then, of course, you let the game handle which list the user sees according to the "dynamic" data.
That's the only way you would see it in the reports without your own web service handling it.
For those that may find this question via Google!
It seems that the easy answer to my question is NO. You can not add extra information to your market stats with regards to in app purchases.
As I mentioned in my question (and some answers said) the work around would be to upload the transaction string to your server and then compare it to market stats yourself (using the export function from the market perhaps).
I now intend to write a system to extract market stats (likely from the csv download feature) and match it up to the strings from the IAPs. If I ever get around to writing it I will share it with the community.

In App Purchase Getting product details programmatically

Is it possible to get the price of In App Products programmatically?
I would like to show the price of the in app product on my buy button. Is there any service provided by android like "getInAppProductPrice(productId)".
The reason I need this is because, if I edit the price of a product at a later time, I would like to get it reflected in my application buy button automatically rather than hard code the price.
In the android market checkout screen, the price is shown. So some service should be available? Is it open to us ?
V3 of in app billing now has such helper functions, you want getSkuDetails()
http://developer.android.com/google/play/billing/billing_reference.html#getSkuDetails
Unfortunately it does not support getting a list of all available products which would be nice to have
Android Market API was working fine till Dec 15th 2011. It is not working as of now.That API used to give information on the market app. You can retrieve data, but I have never heard of anything which would help the developer to programmatically change the pricing details.

get app download count from android market

I can use android-market-api to get nearly all information about my app from Android Market.
But with published function from android-market-api, I cannot get download count number as it is in the Publisher's page (market.android.com/publish)
Is there any way to get this number with my android market developer account?
Thank you.
You can try using Google Analytics in your app (you'll get a lot of useful stats) and then use Analytics API to track download counts and source.
Are you looking for the exact numeric download count or a range? Because downloadsCountText (which you can get) will give you the latter.
I'm confusing by how you asked the question. If you have no access to the Google Developer Console, you can only search for it on Google Play and get an estimated range.
If you do, select the app, then click the first tab at left called "Statistics". It will give you a more detailed sales graph.

Categories

Resources