[TSM.ID].[11031972] PXE : Platform X Ecosystem I [118 Module -LIVE-]
This commit is contained in:
@@ -0,0 +1,15 @@
|
||||
import urllib.request
|
||||
import json
|
||||
|
||||
url = "https://iam.ultramodul.xyz/api/auth/login"
|
||||
data = json.dumps({"email": "tsm@tsm.id", "password": "wrong"}).encode("utf-8")
|
||||
|
||||
req = urllib.request.Request(url, data=data, headers={"Content-Type": "application/json"}, method="POST")
|
||||
|
||||
try:
|
||||
with urllib.request.urlopen(req) as f:
|
||||
print(f.read().decode('utf-8'))
|
||||
except Exception as e:
|
||||
print(e)
|
||||
if hasattr(e, 'read'):
|
||||
print(e.read().decode('utf-8'))
|
||||
Reference in New Issue
Block a user