#!/usr/bin/env python3 import json, sys, urllib.request if len(sys.argv) < 2: print("Usage: get_level_data.py [school idol no]") quit() with urllib.request.urlopen("https://allstars.kirara.ca/api/private/cards/ordinal/" + sys.argv[1] + ".json") as url: j = json.loads(url.read().decode())["result"][0] for s in j["stats"]: print(j["id"],",",s[0],",",s[1],",",s[2],",",s[3])