feat: 增加歌曲动态封面接口

This commit is contained in:
overwriter 2024-09-22 10:11:28 +08:00
parent 61983799fe
commit 8ee4167087
3 changed files with 23 additions and 0 deletions

View File

@ -434,6 +434,7 @@ banner({ type: 0 }).then((res) => {
288. 已购买单曲 288. 已购买单曲
289. 歌曲是否喜爱 289. 歌曲是否喜爱
290. 用户是否互相关注 290. 用户是否互相关注
291. 歌曲动态封面
## 单元测试 ## 单元测试

View File

@ -0,0 +1,9 @@
// 歌曲动态封面
const createOption = require('../util/option.js')
module.exports = (query, request) => {
const data = {
songId: query.id,
}
return request(`/api/songplay/dynamic-cover`, data, createOption(query))
}

View File

@ -306,6 +306,7 @@
288. 已购买单曲 288. 已购买单曲
289. 歌曲是否喜爱 289. 歌曲是否喜爱
290. 用户是否互相关注 290. 用户是否互相关注
291. 歌曲动态封面
## 安装 ## 安装
@ -4803,6 +4804,18 @@ bitrate = Math.floor(br / 1000)
**调用例子 :** `/user/mutualfollow/get?uid=32953014` **调用例子 :** `/user/mutualfollow/get?uid=32953014`
### 歌曲动态封面
说明 : 调用此接口, 传入歌曲id, 获取歌曲动态封面
**必选参数 :**
`id`: 歌曲 id
**接口地址 :** `/song/dynamic/cover`
**调用例子 :** `/song/dynamic/cover?id=2101179024`
## 离线访问此文档 ## 离线访问此文档
此文档同时也是 Progressive Web Apps(PWA), 加入了 serviceWorker, 可离线访问 此文档同时也是 Progressive Web Apps(PWA), 加入了 serviceWorker, 可离线访问