This commit is contained in:
2023-06-20 22:34:27 +08:00
parent 3cf3965a6e
commit 95f09a96b8
9 changed files with 729 additions and 2 deletions

2
router/sendTorrent.js Normal file
View File

@@ -0,0 +1,2 @@
const Router = require("koa-router")

22
router/videoInfo.js Normal file
View File

@@ -0,0 +1,22 @@
const Router = require("koa-router")
const { route } = require(".")
const { serach, getinfo } = require("../util/douban")
const router = new Router({
prefix:"/videoInfo"
})
router.get("/search",async (ctx)=>{
let name = ctx.query.name
let info = await serach(name)
ctx.body = info
})
route.get("/getinfo",async (ctx)=>{
let url = ctx.query.url
let info = await getinfo(url)
ctx.body = info
})
module.exports = router