MCPcopy
hub / github.com/smallfawn/QLScriptPublic / sso_login_v2

Function sso_login_v2

tianyi.py:178–190  ·  view source on GitHub ↗
(ticket)

Source from the content-addressed store, hash-verified

176 return None
177
178def sso_login_v2(ticket):
179 payload = {"portal": "45", "channelId": CHANNEL_ID, "ticket": ticket}
180 headers = {
181 'User-Agent': "CtClient;11.3.0;Android;12;Redmi K30 Pro;MDAyNDUy!#!MTgwMjQ",
182 'Content-Type': "application/json"
183 }
184 r = requests.post("https://ai.imusic.cn/vapi/vue_login/sso_login_v2",
185 data=json.dumps(payload), headers=headers)
186 if r.status_code == 200:
187 data = r.json()
188 if data.get("token"):
189 return data.get("token"), r.cookies.get_dict()
190 return None, None
191
192
193class InviteAPI:

Callers 2

process_new_year_lotteryFunction · 0.85
process_accountFunction · 0.85

Calls 2

postMethod · 0.45
getMethod · 0.45

Tested by

no test coverage detected