From 1eda0471bfc3bfae7b470d081ae5f1c6ce792182 Mon Sep 17 00:00:00 2001 From: Suika <290760339@qq.com> Date: Thu, 1 Jul 2021 20:43:11 +0800 Subject: [PATCH 1/2] =?UTF-8?q?=E6=8A=8A=E7=BC=BA=E5=A4=B1=E7=9A=84?= =?UTF-8?q?=E5=87=BD=E6=95=B0=E5=92=8C=E7=BB=93=E6=9E=84=E4=BD=93=E5=A3=B0?= =?UTF-8?q?=E6=98=8E=E5=8A=A0=E4=B8=8A?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 我也太铸币了吧呜呜呜 --- plugin_diana/fansDaily.go | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) diff --git a/plugin_diana/fansDaily.go b/plugin_diana/fansDaily.go index 087071f3..86c9cc6f 100644 --- a/plugin_diana/fansDaily.go +++ b/plugin_diana/fansDaily.go @@ -6,6 +6,18 @@ import ( "github.com/wdvxdr1123/ZeroBot/message" ) +type follower struct { + Mid int `json:"mid"` + Uname string `json:"uname"` + Video int `json:"video"` + Roomid int `json:"roomid"` + Rise int `json:"rise"` + Follower int `json:"follower"` + GuardNum int `json:"guardNum"` + AreaRank int `json:"areaRank"` +} + + // 开启日报推送 func init() { zero.OnFullMatch("/开启粉丝日报", zero.AdminPermission). @@ -88,3 +100,19 @@ func fansData(groupID int64) { return true }) } + +// 请求api +func fensiapi(uid string) *follower { + + url := "https://api.vtbs.moe/v1/detail/" + uid + resp, err := http.Get(url) + if err != nil { + panic(err) + } + defer resp.Body.Close() + result := &follower{} + if err := json.NewDecoder(resp.Body).Decode(result); err != nil { + panic(err) + } + return result +} From 956c741c386c7e6ce50714bc9963ce3eb2a3b51e Mon Sep 17 00:00:00 2001 From: Kanri Date: Fri, 2 Jul 2021 12:57:58 +0800 Subject: [PATCH 2/2] =?UTF-8?q?=F0=9F=99=88=20=E5=BF=BD=E7=95=A5=20.idea?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .gitignore | 3 +- .idea/ZeroBot-Plugin.iml | 9 ------ .idea/modules.xml | 8 ----- .idea/vcs.xml | 6 ---- .idea/workspace.xml | 64 ---------------------------------------- 5 files changed, 2 insertions(+), 88 deletions(-) delete mode 100644 .idea/ZeroBot-Plugin.iml delete mode 100644 .idea/modules.xml delete mode 100644 .idea/vcs.xml delete mode 100644 .idea/workspace.xml diff --git a/.gitignore b/.gitignore index ceace8fd..bed9a349 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,4 @@ data/SetuTime/cache data/SetuTime/search -data/manager \ No newline at end of file +data/manager +.idea/ \ No newline at end of file diff --git a/.idea/ZeroBot-Plugin.iml b/.idea/ZeroBot-Plugin.iml deleted file mode 100644 index 5e764c4f..00000000 --- a/.idea/ZeroBot-Plugin.iml +++ /dev/null @@ -1,9 +0,0 @@ - - - - - - - - - \ No newline at end of file diff --git a/.idea/modules.xml b/.idea/modules.xml deleted file mode 100644 index 447d2aba..00000000 --- a/.idea/modules.xml +++ /dev/null @@ -1,8 +0,0 @@ - - - - - - - - \ No newline at end of file diff --git a/.idea/vcs.xml b/.idea/vcs.xml deleted file mode 100644 index 94a25f7f..00000000 --- a/.idea/vcs.xml +++ /dev/null @@ -1,6 +0,0 @@ - - - - - - \ No newline at end of file diff --git a/.idea/workspace.xml b/.idea/workspace.xml deleted file mode 100644 index fd386a1b..00000000 --- a/.idea/workspace.xml +++ /dev/null @@ -1,64 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - true - - \ No newline at end of file