-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add Support for Threema / Discord / Microsoft Teams/ Signal !
- Wire Messenger - Threema - Discord - Microsoft Teams - Skype for Business - Signal
- Loading branch information
Showing
7 changed files
with
71 additions
and
1 deletion.
There are no files selected for viewing
This file contains 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
Binary file not shown.
Binary file not shown.
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
#I'm a swift dev so i want to use lower camel case ... :( | ||
# This code is uploaded at https://github.com/YuigaWada/GetBundleId | ||
|
||
import urllib.request, json, re | ||
from urllib.parse import urlparse | ||
|
||
|
||
pattern = "id([0-9]+)" | ||
header = "https://itunes.apple.com/lookup?id=" | ||
def get_bundleid(target_url): | ||
raw_url = remove_query(target_url) | ||
search_id = re.compile(pattern).search(raw_url) | ||
|
||
if not search_id: | ||
return None | ||
|
||
|
||
app_id = search_id.group(1) | ||
if app_id.isdecimal(): | ||
json_url = header+app_id | ||
|
||
# print("loading "+json_url+" ...") | ||
with urllib.request.urlopen(json_url) as url: | ||
data = json.loads(url.read().decode()) | ||
|
||
results = [] | ||
for result in data["results"]: | ||
results.append(result["bundleId"]) | ||
|
||
return results | ||
|
||
return None | ||
|
||
def remove_query(target_url): | ||
o = urlparse(target_url) | ||
return o.scheme + "://" + o.netloc + o.path | ||
|
||
def main(): | ||
print("Input URL of your target app (in the App Store): ") | ||
text = str(input().split()) | ||
bundleids = get_bundleid(text) | ||
|
||
if bundleids: | ||
for bundleid in bundleids: | ||
print("\n\nBundleId: " + bundleid) | ||
else: | ||
print("invaild url") | ||
|
||
|
||
|
||
main() |
This file contains 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