Java – get the latest application version from Google playstore when multiple apks are uploaded
I uploaded multiple apks for my app on playstore to support it on all devices
The problem now is that when I use the following code to get my playstore version, it returns "change with device"
String playStoreUrl =“ http://play.google.com/store/apps/details?id= ”mContext. getPackageName();
//It retrieves the latest version by scraping the content of current version from play store at runtime Document doc = Jsoup.connect(String.valueOf(playStoreUrl)).get(); mAppStoreVersion = doc.getElementsByAttributeValue ("itemprop","softwareVersion").first().text();
Mappstoreversion is "varies with device" Is there any other way to get the latest application version from playstore?
Solution
For the "device specific" version, you can view your Google play publisher account Google play allows you to publish different apks for your applications Each is configured for a different device Therefore, each APK is a separate version of your application, but they share the same application list on Google play, and must share the same package name and sign with the same distribution key
For more information, please check the official Google documentation for multiple APK support