Skip to content

心动模式/智能播放 ​

登录后调用此接口,可获取心动模式/智能播放列表

接口信息 ​

项目值
接口地址/playmode/intelligence/list
请求方式GET / POST
需要登录是
对应模块playmode_intelligence_list
文档分类推荐与发现

请求参数 ​

参数类型必填默认值说明
idstring✅-歌曲 id
pidstring✅-歌单 id
sidstring—-要开始播放的歌曲的 id

HTTP 示例 ​

bash
GET /playmode/intelligence/list?id=33894312&pid=24381616
GET /playmode/intelligence/list?id=33894312&pid=24381616&sid=36871368

编程式调用 ​

ts
import { playmodeIntelligenceList } from 'hana-music-api';

const result = await playmodeIntelligenceList({
  id: '33894312',
  pid: '24381616',
});

console.log(result.body);

返回内容 ​

body.data 是心动模式列表,每条记录自己的 id 收紧,songInfo 是宽松字段并复用 LooseSong(嵌套歌曲编号也宽松,坏 id 只丢编号,不会让整条 songInfo 消失);alg、recommended、message 宽松。结构定义和类型是 PlaymodeIntelligenceListBody,见 返回体结构。录制从原始 149 条截到 3 条(context.truncated 记录原始长度);缺少 pid 或探测到的另一个歌单时,SDK 按上游业务码转交,不报 502。本批没有找到可达的空 data,数组本身允许为空。

补充说明 ​

说明 : 登录后调用此接口,可获取心动模式/智能播放列表 必选参数 : id : 歌曲 id

pid : 歌单 id

可选参数 :sid : 要开始播放的歌曲的 id

接口地址 : /playmode/intelligence/list

调用例子 : /playmode/intelligence/list?id=33894312&pid=24381616,/playmode/intelligence/list?id=33894312&pid=24381616&sid=36871368

Released under the MIT License.