2276f8db2c
Previously, the ac2dm was meant to be saved in the application state, and later used for subsequent logins, along with the gsfId. This is not correct, because the app needs it only for the first login, and then remains unused in the application state. The correct behaviour is to save the gsfId and the authSubToken, and provide only these two values for subsequent logins Signed-off-by: Domenico Iezzi <domenico.iezzi.201@gmail.com> |
||
---|---|---|
Documentation | ||
gpapi | ||
.gitignore | ||
.travis.yml | ||
googleplay.proto | ||
README.md | ||
requirements.txt | ||
setup.py | ||
test.py |
Google play python3 API
This project contains an unofficial API for google play interactions. The code mainly comes from GooglePlayAPI project which was written for python2 and it's not maintained anymore. The code was ported to python3 with some important changes:
- ac2dm authentication with checkin and device info upload
- updated search and download calls
- using headers of a Nexus 6P. Add you own device under
device.properties
file
Usage
Check the test.py module for a simple example.
An important note about login function:
def login(self, email=None, password=None, gsfId=None, authSubToken=None)
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 a 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 only, this is the equivalent of re-initalizing your android device with a google account.
API reversing
Since I started playing with a more recent version of the GooglePlay API on LineageOS 14.1 (Android 7.1) using mitmproxy, I gathered some information about new APIs. Checkout the Documentation folder for more details on single API endpoints.
Development status
- Investigate how paid apps download works
- Investigate if it's possible to dowload apk with obb files