skillfed

gpsoauth

A python client library for Google Play Services OAuth.

gpsoauth v2.0.0 751.2K downloads/30d#5,157 on PyPI141
Permissive license MIT AGING released

What it is and what it does

gpsoauth is a Python client library that implements Google Play Services' master token authentication flow, allowing your code to obtain OAuth tokens for Google services using email and password credentials. It wraps the cryptographic handshake and HTTP requests needed to authenticate as an Android device, which is useful when you need to programmatically access Google services that expect Play Services authentication—for example, accessing Google Music or other Google APIs that mobile apps use.

The library depends on pycryptodomex for cryptographic operations, requests and urllib3 for HTTP communication. It supports Python 3.9 through 3.13 and is classified as production-stable. The package has been maintained since its early releases and remains in the top tier of PyPI packages by download volume, though the last release was over a year ago.

Use it for:

  • Authenticate to Google Music or other Google services that expect Android Play Services credentials.
  • Build a bot or automation tool that needs to log into a Google account and access Play Services–protected APIs.
  • Reverse-engineer or interact with Google services that use the master token flow for authentication.
  • Integrate Google account authentication into a Python application without using official Google SDKs.

Worth the install?

AI-flagged interpretation of the facts on this page — verify before relying

Implements Google Play Services OAuth authentication for Python, enabling the master token flow to obtain access tokens for Google services.

Yes, if you need to authenticate to Google Play Services APIs and understand the security implications. The library is stable and permissively licensed, with low install friction. However, the aging maintenance status and release gap mean you should verify that Google's authentication endpoints have not changed and that the flow still works with current account security policies before relying on it in production.

Install

gpsoauth on PyPI

pip

pip install gpsoauth

uv

uv add gpsoauth

poetry

poetry add gpsoauth

Installing gpsoauth

Before you install

Low install friction with a pure-Python wheel distribution. Maintenance status is aging—last release was over a year ago—but the repository remains active with a recent commit and no archived status.

License in practice

MIT license permits commercial and private use with minimal restrictions; you must retain the license notice but face no copyleft obligations.

Quickstart

pip install gpsoauth

import gpsoauth

master_response = gpsoauth.perform_master_login('user@gmail.com', 'password', 'android_id')
master_token = master_response['Token']

auth_response = gpsoauth.perform_oauth(
    'user@gmail.com', master_token, 'android_id',
    service='sj', app='com.google.android.music', client_sig='...')
token = auth_response['Auth']

Requires valid Google account credentials and a valid Android device ID; Google may reject requests if account security policies or device verification fail.

Verify before relying

  • Whether Google's authentication endpoints remain stable or if changes to their security policies have broken the master token flow.
  • Current compatibility with modern Google account security features (2FA, app passwords, device verification).
  • Whether the library is actively maintained or in maintenance-only mode given the release gap.

Package facts

License MIT (permissive)
Python support supports the current Python release (<4.0,>=3.9)
Install friction low — pure-Python wheel
Runtime dependencies 3 — pycryptodomex, requests, urllib3
Maintenance aging — 406 days since the last release
Last repo commit
First released
Downloads 751,186/month — #5,157 on PyPI (30-day window, as of 2026-08-14)
Known vulnerabilities none known (OSV.dev, checked 2026-08-14)

Evidence: gpsoauth-2.0.0-py3-none-any.whl

Development Status :: 5 - Production/StableIntended Audience :: DevelopersLicense :: OSI Approved :: MIT LicenseOperating System :: OS IndependentProgramming Language :: PythonProgramming Language :: Python :: 3Programming Language :: Python :: 3.10Programming Language :: Python :: 3.11Programming Language :: Python :: 3.12Programming Language :: Python :: 3.13Programming Language :: Python :: 3.9Typing :: Typed

Tags

google play services oauthandroid master token authenticationgoogle account oauth pythonplay services login flowgoogle service authentication
oauthgoogle-servicesauthentication

More Internet packages