I have an .apk
file. And I want to know that which category the app belongs ( category example: Gaming, Entertainment, Sports, etc ).
FYI: Google Play services to get category of an apk
is not required. Some other feasible solution is welcome.
It is not possible to retrieve a Play Store category directly from the .apk file.
However, you can scan the contents of the .apk file programmatically by searching for keywords in AndroidManifest.xml
and Strings.xml
In an Android application, you can
exec("cat /sdcard/unzippedapk/res/Strings.xml | grep -i game OR sports OR social media")
and measure the output to see if there are matches.
Your other option is to grab the package name, and query play.google.com
and parse the HTML:
HTTP Get: https://play.google.com/store/apps/details?id=com.XXXX.XXXXX&hl=en
Relevant HTML segment:
<span itemprop="genre">Productivity</span>
Hope this helps
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.