kussssh/IPO-Analyzer
0
1import urllib.request2import urllib.error3import json4 5hf_url = "https://kussssh-ipo-analyzer.hf.space/auth/login"6data = json.dumps({"email": "kushgupta2019@prospektlab.com", "password": "Gupta@123"}).encode("utf-8")7req = urllib.request.Request(hf_url, data=data, headers={"Content-Type": "application/json"})8 9try:10 with urllib.request.urlopen(req) as response:11 print(f"Status: {response.status}")12 print(response.read().decode("utf-8"))13except urllib.error.HTTPError as e:14 print(f"Error Status: {e.code}")15 print(f"Error Body: {e.read().decode('utf-8')}")16except Exception as e:17 print(f"Connection Failed: {e}")18 