{"id":21997651,"url":"https://github.com/osfunapps/os-android-play-console-automation-py","last_synced_at":"2025-04-30T21:05:51.238Z","repository":{"id":57449675,"uuid":"337780997","full_name":"osfunapps/os-android-play-console-automation-py","owner":"osfunapps","description":"This module will automate a bunch of Google Play actions like publish apk/app bundle and image handling","archived":false,"fork":false,"pushed_at":"2023-01-05T13:55:15.000Z","size":14,"stargazers_count":4,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2024-11-18T13:00:53.519Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/osfunapps.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.txt","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2021-02-10T16:21:06.000Z","updated_at":"2024-05-08T07:19:22.000Z","dependencies_parsed_at":"2022-09-14T10:51:03.590Z","dependency_job_id":null,"html_url":"https://github.com/osfunapps/os-android-play-console-automation-py","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/osfunapps%2Fos-android-play-console-automation-py","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/osfunapps%2Fos-android-play-console-automation-py/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/osfunapps%2Fos-android-play-console-automation-py/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/osfunapps%2Fos-android-play-console-automation-py/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/osfunapps","download_url":"https://codeload.github.com/osfunapps/os-android-play-console-automation-py/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":227223679,"owners_count":17750386,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-29T22:17:35.856Z","updated_at":"2024-11-29T22:17:36.520Z","avatar_url":"https://github.com/osfunapps.png","language":"Python","funding_links":[],"categories":["others"],"sub_categories":[],"readme":"Introduction\n------------\nThis module will automate a bunch of Google Play console actions:\n* Publish/Update an Android APK/App Bundle programmatically (dynamically), from an Android project, faster and without Android Studio, to the Google Play Store\n* Clear an App screenshots from a certain category, even by language, in an app listing in the Google Play Console\n* Clear an app's logo or feature graphic by language in an app listing in the Google Play Console\n* Add any images (screenShots, TV Banner, Logo, Feature Graphic and more) to an existing Android app in the Google Play Console.\n\n## Installation\n\nInstall via pip:\n```python\npip install os_android_play_console_automation\n```\n\n# Prerequisites\n\n\u003cB\u003e Google Play Console API isn't open automatically. You should enable it from your Google Play Console account.\u003c/b\u003e\n\nTo do so, log in to your Google Play Console account and:\n\n1. At the left pane, navigate to \u003cb\u003eSettings -\u003e API Access -\u003e Agree to link your project\u003c/b\u003e\n2. At the API access page, under \u003cb\u003e\"OAuth clients\"\u003c/b\u003e click on \u003cb\u003e\"View in Google Cloud Console\"\u003c/b\u003e\n3. Under OAuth 2.0 Client IDs click on your client id (usually \"Google Play Android Developer\")\n4. At the top, click on \"DOWNLOAD JSON\" and save the file in a secure location on your computer\n5. \u003cb\u003e IMPORTANT: change the JSON file name to be client_secrets.json \u003c/b\u003e so Google's algorithm could read it\n\n\n## Usage\n\nAfter you've downloaded the ```client_secrets.json``` file, you can use this tool to automate actions.\n## Publish an APK\n\n```python\nfrom os_android_play_console_automation import publisher\n\npublisher.publish_apk(package_name='com.my.package',  # the app's package name\n                      apk_file_path='path/to/apk.apk',  # the path to the released apk file\n                      client_secrets_path='path/to/client_secret.json',  # the client_secret.json file you made in the previous section \n                      publish_percents=0.95,  # 95% published publish_percents\n                      version_code=2  # the apk version code\n                      )   \n```\n\n## Publish an App Bundle\n\n```python\nfrom os_android_play_console_automation import publisher\n\npublisher.publish_app_bundle(package_name='com.my.package',  # the app's package name\n                             app_bundle_path='path/to/app_bundle.aab',  # the path to the released .aab file\n                             client_secrets_path='path/to/client_secret.json',  # the client_secret.json file you made in the previous section \n                             publish_percents=0.95,  # 95% published publish_percents\n                             version_code=2  # the apk version code\n                             )   \n```\n\n\n## Update APK/App Bundle\n\n```python\nfrom os_android_play_console_automation import publisher\n\npublisher.update_version(package_name='com.my.package',\n                         client_secrets_path='path/to/client_secret.json',\n                         publish_percents=0.95,  # 95% published publish_percents\n                         version_code=2)  # the apk version code\n```\n\n# Clearing and uploading image types\n\n```ImageType``` defines the type of images group you wish to alter. For example, ```ImageType.ICON``` will target a change in your app's logo.\n\nYou can see all of the ```ImageType``` [here](os_android_play_console_automation/types/ImageType.py).\n\n## Clear Images\n\nYou can clear a bunch of images by request. \n\nFor example, the next command will clear all the phone screenshots in the english language.\n\n```python\nfrom os_android_play_console_automation import publisher\nfrom os_android_play_console_automation.types.ImageType import ImageType\n\npublisher.clear_images(client_secrets_path='path/to/client_secret.json',  # your client secrets,\n                       package_name='com.my.package',  # the identifier of the app in the store\n                       image_type=ImageType.PHONE_SCREENSHOTS,  # the type of image here (try ImageType.ICON) \n                       language_initials='en-US')  # can be any initials you want (the en-US is the default)\n```\n\n## Upload Images\n\nYou can add images (one by one) by request. \n\nFor example, the next command will add all the phone screenshots in the english language.\n\n```python\nfrom os_android_play_console_automation import publisher\nfrom os_android_play_console_automation.types.ImageType import ImageType\n\nscreenshot_lst = ['path/to/img/1.png', 'path/to/img/2.png']\nfor ss in screenshot_lst:\n    publisher.push_image(client_secrets_path='path/to/client_secret.json',  # your client secrets\n                         package_name='com.my.package',  # the identifier of the app in the store\n                         image_type=ImageType.PHONE_SCREENSHOTS,  # the type of image here (try ImageType.ICON)\n                         path_to_image=ss,\n                         language_initials='en-US')  # can be any initials you want (the en-US is the default)\n```\n\n\n\n## Links\nIf you all about automation, why use Android Studio?:  \n* [os_android_apk_builder-py](https://github.com/osfunapps/os_android_apk_builder-py) will create an Android apk/app bundle programmatically (dynamically), from an Android project, faster and without Android Studio    \n* More Android and iOS automation tools can be found in [my profile](https://github.com/osfunapps) \n\n## Licence\nMIT","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fosfunapps%2Fos-android-play-console-automation-py","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fosfunapps%2Fos-android-play-console-automation-py","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fosfunapps%2Fos-android-play-console-automation-py/lists"}