MCPcopy Index your code
hub / github.com/Mashiro2000/HeyTapTask / getTaskList

Method getTaskList

TaskCenter.py:86–105  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

84 # 位置:我的 -> 任务中心
85 # 函数作用:获取任务数据以及判断CK是否正确
86 def getTaskList(self):
87 url = 'https://store.oppo.com/cn/oapi/credits/web/credits/show'
88 headers = {
89 'Host': 'store.oppo.com',
90 'Connection': 'keep-alive',
91 'source_type': '501',
92 'clientPackage': 'com.oppo.store',
93 'Accept': 'application/json, text/plain, */*',
94 'Accept-Encoding': 'gzip, deflate',
95 'Accept-Language': 'zh-CN,en-US;q=0.9',
96 'X-Requested-With': 'com.oppo.store',
97 'Referer': 'https://store.oppo.com/cn/app/taskCenter/index?us=gerenzhongxin&um=hudongleyuan&uc=renwuzhongxin'
98 }
99 response = self.sess.get(url=url,headers=headers).json()
100 if response['code'] == 200:
101 self.taskData = response['data']
102 return True
103 else:
104 notify(f"{self.dic['user']}\t失败原因:{response['errorMessage']}")
105 return False
106
107 # 每日签到
108 # 位置: APP → 我的 → 签到

Callers 1

startMethod · 0.95

Calls 1

notifyFunction · 0.70

Tested by

no test coverage detected