Last active
November 25, 2025 10:58
-
-
Save progressify/8b01426de3e56b81bad8de6ca400b767 to your computer and use it in GitHub Desktop.
Check latest app version release on Stores
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
| import requests | |
| from time import time | |
| def get_ios_app_details(bundle_id, country='it'): | |
| """ | |
| Retrieve the version and details of an iOS app via the iTunes API. (No external dependencies required.) | |
| :param bundle_id: The app's bundle ID (e.g., 'com.instagram.layout') | |
| :param country: The store's country code (e.g., 'it' for Italy, 'us' for the USA) | |
| """ | |
| base_url = "https://itunes.apple.com/lookup" | |
| params = { | |
| 'bundleId': bundle_id, | |
| 'country': country, | |
| '_': int(time()) | |
| } | |
| try: | |
| response = requests.get(base_url, params=params, timeout=10) | |
| data = response.json() | |
| if data['resultCount'] == 0: | |
| print(f"No apps found with bundle '{bundle_id}' in store '{country}'.") | |
| return None | |
| app_info = data['results'][0] | |
| return { | |
| 'name': app_info.get('trackName'), | |
| 'version': app_info.get('version'), | |
| 'release_date': app_info.get('currentVersionReleaseDate'), | |
| 'seller': app_info.get('sellerName') | |
| } | |
| except Exception as e: | |
| print(f"Request error: {e}") | |
| return None |
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
| requests==2.32.5 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment