Created
July 24, 2019 05:31
-
-
Save ruslux/5760e41241e209f87b89a8f2431360ae to your computer and use it in GitHub Desktop.
google_api.py
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
bundle_id = 'gogoyuedu.book.job.news.learn.read' | |
api_key = 'Alkene-608a20735120.json' | |
validator = GooglePlayVerifier(bundle_id, api_key) | |
try: | |
validation_result = validator.verify(purchase_json['token'], sub_code, is_subscription=True) | |
except errors.GoogleError as exc: | |
logging.error('Purchase validation failed {}'.format(exc)) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment