提交 901bde66 编写于 作者: B binaryify

增加获取首页新碟上架数据以及更新听歌排行 #431,更新搜索建议接口 #416

上级 49b3b46c
# 更新日志
### 3.2.0 | 2019.01.19
- 增加获取首页新碟上架数据以及更新听歌排行
- 更新搜索建议接口
### 3.1.0 | 2019.01.06
- 修复评论接口返回 460 Cheating 的问题
......
......@@ -109,6 +109,8 @@
87. 新歌速递
88. 喜欢音乐列表(无序)
89. 收藏的 MV 列表
90. 获取最新专辑
91. 听歌打卡
## 环境要求
......
......@@ -724,9 +724,11 @@ mp3url 不能直接用 , 可通过 `/song/url` 接口传入歌曲 id 获取具
**必选参数 :** `keywords` : 关键词
**可选参数 :** `type` : 如果传 'mobile' 则返回移动端数据
**接口地址 :** `/search/suggest`
**调用例子 :** `/search/suggest?keywords= 海阔天空`
**调用例子 :** `/search/suggest?keywords= 海阔天空` `/search/suggest?keywords= 海阔天空&type=mobile`
### 搜索多重匹配
......
......@@ -4,8 +4,9 @@ module.exports = (query, request) => {
const data = {
s: query.keywords || ''
}
let type = query.type == 'mobile' ? 'keyword' : 'web'
return request(
'POST', `https://music.163.com/weapi/search/suggest/keyword`, data,
{crypto: 'weapi', cookie: query.cookie, proxy: query.proxy}
'POST', `https://music.163.com/weapi/search/suggest/` + type, data,
{ crypto: 'weapi', cookie: query.cookie, proxy: query.proxy }
)
}
\ No newline at end of file
{
"name": "NeteaseCloudMusicApi",
"version": "3.1.0",
"version": "3.2.0",
"description": "网易云音乐 NodeJS 版 API",
"scripts": {
"start": "node app.js",
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册