MCPcopy Create free account
hub / github.com/UndCover/PyramidStore / detailContent

Method detailContent

plugin/py_douyu.py:63–96  ·  view source on GitHub ↗
(self,array)

Source from the content-addressed store, hash-verified

61 result['total'] = 999999
62 return result
63 def detailContent(self,array):
64 aid = array[0]
65 url = "http://live.yj1211.work/api/live/getRoomInfo?platform=douyu&roomId={0}".format(aid)
66 rsp = self.fetch(url)
67 jRoot = json.loads(rsp.text)
68 jo = jRoot['data']
69 title = jo['roomName']
70 pic = jo['roomPic']
71 desc = str(jo['online'])
72 dire = jo['ownerName']
73 typeName = jo['categoryName']
74 remark = jo['categoryName']
75 vod = {
76 "vod_id": aid,
77 "vod_name": title,
78 "vod_pic": pic,
79 "type_name": typeName,
80 "vod_year": "",
81 "vod_area": "",
82 "vod_remarks": remark,
83 "vod_actor": '在线人数:' + desc,
84 "vod_director": dire,
85 "vod_content": ""
86 }
87 playUrl = '原画' + '${0}#'.format(aid)
88 vod['vod_play_from'] = '斗鱼直播'
89 vod['vod_play_url'] = playUrl
90
91 result = {
92 'list': [
93 vod
94 ]
95 }
96 return result
97 def searchContent(self,key,quick):
98 result = {}
99 return result

Callers

nothing calls this directly

Calls 1

fetchMethod · 0.95

Tested by

no test coverage detected