0

My android app is published in google play store. I want to do,

  1. User get notified when there is new version of app.
  2. User must get notified when they are using an older version of app.

The problem I face is,

  1. If the user turns off automatic check for update option in google play store, they no longer get notified by the default option.
  2. If my user using the older version of my app, it will create problem for me in data management.(conflict problem etc.,)

So what i want is, the user opens my app, checks for the current version code of the app and compare with version code of the app that is in google play store.

I find it difficult to get the version code of the app that is in play store.

I tried following links to get the version code of the app on google play store but of not help.

SO question

https://code.google.com/p/android-market-api/

[How to allow users to check for the latest app version from inside the app?

please help..

How can i programmatically get the version code of the app that is on play store.

Or is there any way that by which I can manually trigger the default built-in event as handled by google play services?

Community
  • 1
  • 1
ZeeZipper
  • 83
  • 1
  • 9

2 Answers2

1

why don't you save your latest version in a google document on google drive and from your application read that value?

Here is the api

Buda Gavril
  • 21,409
  • 40
  • 127
  • 196
  • 1
    instead of keeping the document in google drive, even i can keep the document on my server itself. and in this method i need to change the latest in the document manually. Now i'm looking for a method which can perform this action automatically when i update the version code of my app in google play store. – ZeeZipper Apr 20 '15 at 07:11
  • while there is no public API for that, you can't say that you will find a solution for sure, because even if you will find some workaround, maybe over a week, it would now work because google can change it's data format/feed/etc... – Buda Gavril Apr 20 '15 at 07:19
  • hmm are you sure there is no way that i can get the version code of my app which is in play store? – ZeeZipper Apr 20 '15 at 07:23
  • I'm not aware of a public api for play store that returns this value... you can check if amazon app store has some api and you can read that value from there if is there an api, but the last time when I've searched an api for play store, I didn't found an official api. – Buda Gavril Apr 20 '15 at 08:08
  • okay thanks for your response. currently i'm trying this (https://code.google.com/p/android-market-api/). let me see whether it works or not... – ZeeZipper Apr 20 '15 at 09:14
  • Keep in mind that even if this works now, it may not work in a week since this is not an official api. – Buda Gavril Apr 20 '15 at 09:17
  • (https://code.google.com/p/android-market-api/) it was working fine but i don't know what should i give in query. Actually it is meant to give the app name or package name but when i give that it is saying returning nothing.but when i give some thing else like some other app's name or package name is it returning me that app's details. but i couldn't get mine! and now finally ended up using the version name... (BETA 1.1 , BETA 1.2..,etc.,) – ZeeZipper Apr 21 '15 at 08:05
  • i would be happy if i get any help regarding my issue. :) – ZeeZipper Apr 21 '15 at 08:08
  • i ended up keeping the current version number in my server... thanks. – ZeeZipper Jul 16 '15 at 10:57
  • It seems that code.google.com/p/android-market-api is not working at now. E.g. calling https://androidquery.appspot.com/api/market?app=com.google.android.youtube you'll never get a response. – Joe Aspara Feb 29 '16 at 10:57
0

Actually, solution that based on Google page html is not stable and need to be changed whenever Google update their layout. In addition, the version number from Google page is truly versionName but not versionCode. For example: Regard to build.gradle file, versionCode is 5 and versionName is 5.1. For this case, Google store page will show us Current version is 5.1 but not 5.

kansaz
  • 31
  • 5