Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
m0_66418769
NeteaseCloudMusicApi
提交
813e0a45
N
NeteaseCloudMusicApi
项目概览
m0_66418769
/
NeteaseCloudMusicApi
与 Fork 源项目一致
从无法访问的项目Fork
通知
2
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
N
NeteaseCloudMusicApi
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
813e0a45
编写于
12月 12, 2018
作者:
B
binaryify
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
优化电台节目接口,更新文档 #386 #394
上级
abba859b
变更
5
隐藏空白更改
内联
并排
Showing
5 changed file
with
35 addition
and
37 deletion
+35
-37
CHANGELOG.MD
CHANGELOG.MD
+5
-0
docs/README.md
docs/README.md
+2
-14
module/dj_program.js
module/dj_program.js
+15
-12
module/top_song.js
module/top_song.js
+12
-10
package.json
package.json
+1
-1
未找到文件。
CHANGELOG.MD
浏览文件 @
813e0a45
# 更新日志
### 3.0.8 | 2018.12.12
-
更新文档 #386 #394
-
优化电台节目接口
### 3.0.7 | 2018.11.21
-
修复歌单详情列表,排行榜,所有榜单失效的问题,更新文档 #380 #381
...
...
docs/README.md
浏览文件 @
813e0a45
...
...
@@ -706,16 +706,6 @@ mp3url 不能直接用 , 可通过 `/song/url` 接口传入歌曲 id 获取具
**必选参数 :**
`keywords`
: 关键词
**可选参数 :**
`limit`
: 返回数量 , 默认为 30
`offset`
: 偏移数量,用于分页 , 如
: 如 :( 页数 -1)
\*
30, 其中 30 为 limit 的值 , 默认为 0
`type`
: 搜索类型;默认为 1 即单曲 , 取值意义 : 1: 单曲 10: 专辑 100: 歌手 1000:
歌单 1002: 用户 1004: MV 1006: 歌词 1009: 电台
**接口地址 :**
`/search/suggest`
**调用例子 :**
`/search/suggest?keywords= 海阔天空`
...
...
@@ -807,10 +797,6 @@ mp3url 不能直接用 , 可通过 `/song/url` 接口传入歌曲 id 获取具
韩国:16
```
`limit`
: 取出数量 , 默认为 100
`offset`
: 偏移数量 , 用于分页 , 如 :( 评论页数 -1)
\*
100, 其中 100 为 limit 的值
**接口地址 :**
`/top/song`
**调用例子 :**
`/top/song?type=96`
...
...
@@ -1632,6 +1618,8 @@ type='1009' 获取其 id, 如`/search?keywords= 代码时间 &type=1009`
`offset` : 偏移数量,用于分页 , 如
: 如 :( 页数 -1)\*30, 其中 30 为 limit 的值 , 默认为 0
`asc` : 排序方式,默认为 `false` (新 => 老 ) 设置 `true` 可改为 老 => 新
**接口地址 :** `/dj/program`
**调用例子 :** `/dj/program?rid=336355127&limit=40` ( 对应 ' 代码时间 ' 的节目列表 )
...
...
module/dj_program.js
浏览文件 @
813e0a45
// 电台节目列表
const
{
toBoolean
}
=
require
(
'
../util
'
)
module
.
exports
=
(
query
,
request
)
=>
{
const
data
=
{
radioId
:
query
.
rid
,
limit
:
query
.
limit
||
30
,
offset
:
query
.
offset
||
0
,
asc
:
query
.
asc
}
return
request
(
'
POST
'
,
`https://music.163.com/weapi/dj/program/byradio`
,
data
,
{
crypto
:
'
weapi
'
,
cookie
:
query
.
cookie
,
proxy
:
query
.
proxy
}
)
}
\ No newline at end of file
const
data
=
{
radioId
:
query
.
rid
,
limit
:
query
.
limit
||
30
,
offset
:
query
.
offset
||
0
,
asc
:
toBoolean
(
query
.
asc
)
}
console
.
log
(
toBoolean
(
query
.
asc
))
return
request
(
'
POST
'
,
`https://music.163.com/weapi/dj/program/byradio`
,
data
,
{
crypto
:
'
weapi
'
,
cookie
:
query
.
cookie
,
proxy
:
query
.
proxy
}
)
}
module/top_song.js
浏览文件 @
813e0a45
// 新歌速递
module
.
exports
=
(
query
,
request
)
=>
{
const
data
=
{
areaId
:
query
.
type
||
0
,
// 全部:0 华语:7 欧美:96 日本:8 韩国:16
limit
:
query
.
limit
||
100
,
offset
:
query
.
offset
||
0
,
total
:
true
}
return
request
(
'
POST
'
,
`https://music.163.com/weapi/v1/discovery/new/songs`
,
data
,
{
crypto
:
'
weapi
'
,
cookie
:
query
.
cookie
,
proxy
:
query
.
proxy
}
)
const
data
=
{
areaId
:
query
.
type
||
0
,
// 全部:0 华语:7 欧美:96 日本:8 韩国:16
// limit: query.limit || 100,
// offset: query.offset || 0,
total
:
true
}
return
request
(
'
POST
'
,
`https://music.163.com/weapi/v1/discovery/new/songs`
,
data
,
{
crypto
:
'
weapi
'
,
cookie
:
query
.
cookie
,
proxy
:
query
.
proxy
}
)
}
package.json
浏览文件 @
813e0a45
{
"name"
:
"NeteaseCloudMusicApi"
,
"version"
:
"3.0.
7
"
,
"version"
:
"3.0.
8
"
,
"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.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录