diff --git a/docs/README.md b/docs/README.md index b9554b5..68c5d8d 100644 --- a/docs/README.md +++ b/docs/README.md @@ -3889,6 +3889,26 @@ type='1009' 获取其 id, 如`/search?keywords= 代码时间 &type=1009` **调用例子:** `/song/wiki/about?id=1958384591` +### 乐谱列表 + +说明: 调用此接口可以获取歌曲的乐谱列表 + +**接口地址:** `/sheet/list` + +**必选参数:** `id`: 歌曲 ID + +**调用例子:** `/sheet/list?id=1815684465` + +### 乐谱内容 + +说明: 调用此接口获取乐谱的内容 + +**接口地址:** `/sheet/preview` + +**必选参数:** `id`: **乐谱** ID + +**调用例子:** `/sheet/list?id=245206` + ## 离线访问此文档 diff --git a/module/sheet_list.js b/module/sheet_list.js new file mode 100644 index 0000000..014e8a6 --- /dev/null +++ b/module/sheet_list.js @@ -0,0 +1,20 @@ +// 乐谱列表 +const crypto = require('crypto') +module.exports = (query, request) => { + const data = { + id: query.id, + abTest: query.ab || 'b' + } + return request( + 'POST', + `https://interface3.music.163.com/eapi/music/sheet/list/v1`, + data, + { + crypto: 'eapi', + cookie: query.cookie, + proxy: query.proxy, + realIP: query.realIP, + url: '/api/music/sheet/list/v1', + }, + ) +} diff --git a/module/sheet_preview.js b/module/sheet_preview.js new file mode 100644 index 0000000..905562c --- /dev/null +++ b/module/sheet_preview.js @@ -0,0 +1,19 @@ +// 乐谱预览 +const crypto = require('crypto') +module.exports = (query, request) => { + const data = { + id: query.id, + } + return request( + 'POST', + `https://interface3.music.163.com/eapi//music/sheet/preview/info?id=${query.id}`, + data, + { + crypto: 'eapi', + cookie: query.cookie, + proxy: query.proxy, + realIP: query.realIP, + url: '/api//music/sheet/preview/info',// 我没写错! 他们就是这么请求的! + }, + ) +}