Skip to main content

Unofficial python api for google play

Project description

Google play python API Build Status

This project contains an unofficial API for google play interactions. The code mainly comes from GooglePlayAPI project which is not maintained anymore. The code was updated with some important changes:

  • ac2dm authentication with checkin and device info upload
  • updated search and download calls
  • select the device you want to fake from a list of pre-defined values (check device.properties) (defaults to a OnePlus One)

Build

This is the recommended way to build the package, since setuptools will take care of generating the googleplay_pb2.py file needed by the library (check the setup.py)

$ python setup.py build

Usage

Check scripts in test directory for more examples on how to use this API.

from gpapi.googleplay import GooglePlayAPI

mail = "mymail@google.com"
passwd = "mypasswd"

api = GooglePlayAPI(locale="en_US", timezone="UTC", device_codename="hero2lte")
api.login(email=mail, password=passwd)

result = api.search("firefox")

for doc in result:
    if 'docid' in doc:
        print("doc: {}".format(doc["docid"]))
    for cluster in doc["child"]:
        print("\tcluster: {}".format(cluster["docid"]))
        for app in cluster["child"]:
            print("\t\tapp: {}".format(app["docid"]))

For first time logins, you should only provide email and password. The module will take care of initalizing the api, upload device information to the google account you supplied, and retrieving a Google Service Framework ID (which, from now on, will be the android ID of your fake device).

For the next logins you should save the gsfId and the authSubToken, and provide them as parameters to the login function. If you login again with email and password, this is the equivalent of re-initalizing your android device with a google account, invalidating previous gsfId and authSubToken.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

ak-gpapi-2.0.0.tar.gz (63.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

ak_gpapi-2.0.0-py3-none-any.whl (63.3 kB view details)

Uploaded Python 3

File details

Details for the file ak-gpapi-2.0.0.tar.gz.

File metadata

  • Download URL: ak-gpapi-2.0.0.tar.gz
  • Upload date:
  • Size: 63.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/5.0.0 CPython/3.12.2

File hashes

Hashes for ak-gpapi-2.0.0.tar.gz
Algorithm Hash digest
SHA256 fd5534ba5bb4fe23800fc49fd5fd1f1588314eceda0589007fb4aaf959339c79
MD5 e4aa4e4b32e22003496017c4439cdaea
BLAKE2b-256 f514cd00e3336e050d1e3a6d39b1045ece60e251119f3b396c881ff0d2ae25d8

See more details on using hashes here.

File details

Details for the file ak_gpapi-2.0.0-py3-none-any.whl.

File metadata

  • Download URL: ak_gpapi-2.0.0-py3-none-any.whl
  • Upload date:
  • Size: 63.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/5.0.0 CPython/3.12.2

File hashes

Hashes for ak_gpapi-2.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 80aecd8339373ea3bea458b8fe2c852f2b880b5114d248b1b62ea8275120b316
MD5 4068f04045daf7158cb47d56a2cc2651
BLAKE2b-256 4123e5af5088656171285bb2c02e55147fbfa7b26f6f2cc5a0b996a4a546c7f3

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page