Code Monkey home page Code Monkey logo

qq-music-api's People

Contributors

dependabot[bot] avatar kadaliao avatar kervae avatar rain120 avatar rtakland avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

qq-music-api's Issues

交流群

建议创建个交流群,一起探讨

文档的网址挂掉了,可以处理一下吗

环境

系统:

nodejs 版本(koa2要求版本是7.6.0+):

出现问题

重现步骤

期待效果

重现步骤尽量详细,不能含糊不清

如果不是提建议,提 issues 如果不照着模版来将不会优先处理或直接关闭

请求数据编码集问题

你好,为什么我在浏览器测试接口,返回的数据不是中文,而是这种
"dissname": "\ufffd\ufffdѹ\ufffd\ufffdҩ \ufffd\ufffd \ufffd\ufffd\ufffdڰ\ufffdĦ\ufffd\ufffd\ufffd߷\ufffd\ufffd\ufffd"形式的

做个登录接口,登录有绿钻的号就可以获取收费歌曲以及无损格式等

Is your feature request related to a problem? Please describe.
#7

Describe alternatives you've considered
A clear and concise description of any alternative solutions or features you've considered.

Additional context
现在应该还不能获取收费歌曲吧,还有320k、无损格式,只能获取到128K的,如果有了登录接口,登录有绿钻的号就都能获取到了

QQ音乐的OpenAPI和SDK都是不对个人开发者开放的,这个项目是怎么做到的呢

Describe the bug
A clear and concise description of what the bug is.

To Reproduce
Steps to reproduce the behavior:

  1. Go to '...'
  2. Click on '....'
  3. Scroll down to '....'
  4. See error

Expected behavior
A clear and concise description of what you expected to happen.

Screenshots
If applicable, add screenshots to help explain your problem.

Desktop (please complete the following information):

  • OS: [e.g. iOS]
  • Browser [e.g. chrome, safari]
  • Version [e.g. 22]

Smartphone (please complete the following information):

  • Device: [e.g. iPhone6]
  • OS: [e.g. iOS8.1]
  • Browser [e.g. stock browser, safari]
  • Version [e.g. 22]

Additional context
Add any other context about the problem here.

没用户登陆的接口。。。

环境

系统:

nodejs 版本(koa2要求版本是7.6.0+):

出现问题

重现步骤

期待效果

重现步骤尽量详细,不能含糊不清

如果不是提建议,提 issues 如果不照着模版来将不会优先处理或直接关闭

搜索可以参考别人的这样子修改

链接地址是这:jsososo/QQMusicApi#168

module.exports = {

'/': async ({req, res, request, globalCookie, cache}) => {
const obj = {...req.query, ...req.body};
let { uin, qqmusic_key } = globalCookie.userCookie();
if (Number(obj.ownCookie)) {
uin = req.cookies.uin || uin;
}

const {
  pageNo = 1,
  pageSize = 20,
  key,
  t = 0, // 0:单曲,2:歌单,7:歌词,8:专辑,9:歌手,12:mv
  raw
} = req.query;
let total = 0;

if (!key) {
  return res.send({
    result: 500,
    errMsg: '关键词不能为空',
  });
}

// 缓存
const cacheKey = `search_${key}_${pageNo}_${pageSize}_${t}`;
const cacheData = cache.get(cacheKey);
if (cacheData) {
  res && res.send(cacheData);
  return cacheData;
}

const url = 'https://u.y.qq.com/cgi-bin/musicu.fcg'

const typeMap = {
  0: 'song',
  2: 'album',
  1: 'singer',
  3: 'songlist',
  7: 'lyric',
  12: 'mv',
};
if (!typeMap[t]) {
  return res.send({
    result: 500,
    errMsg: '搜索类型错误,检查一下参数 t',
  });
}

const params = {
  req_1: {
    method: "DoSearchForQQMusicDesktop",
    module: "music.search.SearchCgiService",
    param: {
      num_per_page: Number(pageSize),
      page_num: Number(pageNo),
      query: key,
      search_type: Number(t)
    }
  }
}
let result = {}

try {     
  result = await request({
    url,
    method: 'POST',
    data: params,
    headers: {
      Referer: 'https://y.qq.com'
    },
  });
} catch (error) {
  return res.send({
    result: 400,
    error
  })
}

// 直接返回原生数据
if (Number(raw)) {
  return res.send(result);
}
const response = {
  result: 100,
  data: {
    list: Number(t) === 0 ? formatSongList(result.req_1.data.body[typeMap[t]].list) : result.req_1.data.body[typeMap[t]].list,
    pageNo,
    pageSize,
    total: result.req_1.data.meta.sum,
    key: result.req_1.data.meta.query || key,
    t,
    type: typeMap[t],
  },
}
res.send(response);

},

// 热搜词
'/hot': async ({req, res, request}) => {
const {raw} = req.query;
const result = await request({
url: 'https://c.y.qq.com/splcloud/fcgi-bin/gethotkey.fcg',
});
if (Number(raw)) {
return res.send(result);
}
res.send({
result: 100,
data: result.data.hotkey,
});
},

// 快速搜索
'/quick': async ({req, res, request}) => {
const {raw, key} = req.query;
if (!key) {
return res.send({
result: 500,
errMsg: 'key ?',
});
}
const result = await request(
https://c.y.qq.com/splcloud/fcgi-bin/smartbox_new.fcg?key=${key}&g_tk=5381,
);
if (Number(raw)) {
return res.send(result);
}
return res.send({
result: 100,
data: result.data,
});
},
}

function formatSongList(list) {
if (!Array.isArray(list)) {
return []
}
return list.map((item) => {
// 美化歌曲数据
return {
singer: item.singer, // 、
name: item.title,
songid: item.id,
songmid: item.mid,
songname: item.title,

  albumid: item.album.id,
  albummid: item.album.mid,
  albumname: item.album.name,
  interval: item.interval,

  strMediaMid: item.file.media_mid,
  size128: item.file.size_128mp3,
  size320: item.file.size_320mp3,
  sizeape: item.file.size_ape,
  sizeflac: item.file.size_flac,
  pay: item.pay || {}
}

})
}

歌曲的播放地址怎么获取

获取歌曲VKey以后拼接?怎么拼?
看了一下代码,你拼接返回的playlist里的地址有的不能用:000uOIjc0Sp0qm

微信截图_20200315164246

还有playlist是空的情况:003aXrl30CqVro
微信截图_20200315165011

接口问题

获取所有歌手列表的接口没有看到唉

无法下载歌曲

搜索歌曲后,请问怎么下载歌曲呢?response.data.song.list 中歌曲的 "url": "http://stream10.qqmusic.qq.com/xxx.wma 下不动

🚀 qq-music-api v2.0.0

Hi 各位使用和 forked 的小伙伴们, 我正在计划着将本项目的版本更新一下,由于本人时间有限,所以恳请各位的支援,欢迎大家 PR 或者在此处👇 讨论。

issue visitor

Goals

  • 接口设计合理性
  • 加强代码可读性
    • 代码风格规范化
  • 加强接口可读性
    • 接口 URL
    • 接口参数
    • 接口返回
  • 加强文档可读性
    • 分类

更多请看👇详情描述

Status

  • User
  • Singer Rain120
    • 相似歌手 similar
    • 歌手信息 desc
  • Song
  • Search
  • MV
  • Album
  • Rank
  • Star
  • Radio
  • Disk
  • Recommend
  • Product
  • 文档

Branch

v2.0.0

Description

v2.0.0大版本修改是为了修复之前 接口设计可读性差 , API 不合理 等众多问题。

我们在旧版本的基础上, 针对性修改。所以对 接口参数, 接口返回, 路由 等方面做了一定的 优化, 我们推荐新用户使用当前时间最新版 v2.0.0

下面我们拿 singer.js 举个 🌰

singer.js

const YRequest = require('../module/y-axios');
const URequest = require('../module/URequest');
const { commonParams } = require('../module/config');
const moment = require('moment');
const { handleXml } = require('../util/xml');

const singerParams = Object.assign(commonParams, {
  g_tk: 1290642389,
  sign: 'zzafsjavizx8rzd4m36c2a7e17c9f884980ef9092cb8809e415',
  format: 'json',
});

// /singe/similar?singermid=0025NhlN2yWrP4
const similarOld = async (ctx, next) => {
  const { singermid: singer_mid } = ctx.query;
  const options = {
    params: {
      format: 'json',
      outCharset: 'utf-8',
      utf8: 1,
      start: 0,
      num: 5,
      singer_mid,
    },
  };

  return await YRequest({
    url: '/v8/fcg-bin/fcg_v8_simsinger.fcg',
    method: 'get',
    options,
    thenable: res => {
      if (!singer_mid) {
        ctx.status = 400;
        ctx.body = {
          message: 'no singermid',
        };
        return;
      }
      Object.assign(ctx, {
        status: 200,
        body: {
          response: res.data,
        },
      });
    },
    catcher: error => {
      console.log('error', error);
      ctx.status = 400;
      ctx.body = { error };
    },
  });
};

// 周杰伦 /singe/similar?id=4558&singermid=0025NhlN2yWrP4
const similar = async (ctx, next) => {
  const { id: singerId, singermid: singerMid, pageSize: num = 5 } = ctx.query;
  console.log('similar error: not support pageSize');
  const data = {
    comm: {
      ct: 24,
      cv: 10000,
    },
    similarSingerList: {
      method: 'GetSimilarSingerList',
      param: {
        singerId: parseInt(singerId, 10),
        singerMid,
        // TODO: QQ 貌似不支持
        num: 5,
      },
      module: 'music.SimilarSingerSvr',
    },
  };

  const params = Object.assign(singerParams, {
    '-': 'getSimilarSingerList1112654390871275',
    data: JSON.stringify(data),
  });

  return await URequest({
    method: 'get',
    params,
    thenable: res => {
      if (!singerMid) {
        ctx.status = 400;
        ctx.body = {
          message: 'no singermid',
        };
        return;
      }
      Object.assign(ctx, {
        status: 200,
        body: {
          data: res.data,
        },
      });
    },
    catcher: error => {
      console.log('error', error);
      ctx.status = 400;
      ctx.body = { error };
    },
  });
};

module.exports = {
  getSimilarSingerOld: similarOld,
  getSimilarSinger: similar,
};

对于先前接入的用户, 我们也做了一些兼容性的接口处理, 主要是 路由的变化 mapping, 具体可以在 routers/map-router.js 👇中体现, 感谢你的关注和使用。

map-router.js

const context = require('.');

module.exports = {
  // INFO: singer Module
  // /getSimilarSinger?singermid=0025NhlN2yWrP4
  '/getSimilarSinger/:singermid?': {
    cb: context.getSimilarSingerOld,
  },
  // /singe/similar?id=4558&singermid=0025NhlN2yWrP4
  '/singer/similar/:id/:singermid/:pageNum?': {
    cb: context.getSimilarSinger,
  },
};

new-router.js

const Router = require('koa-router');
const router = new Router();
const mapRouter = require('./map-router');

Object.keys(mapRouter).forEach(key => {
  if (key && mapRouter[key]) {
    const { method = 'get', cb } = mapRouter[key];
    router[method](key, cb);
  }
});

module.exports = router;

请问是否有搜索歌曲详细信息的api

很不错的项目,谢谢作者的贡献!

我的需求是,给定一个歌曲的mid,我需要知道该歌曲的“名称”,“歌手”,“专辑“,”封面“等一系列信息(也就是搜索歌曲时返回的那些信息)。具体来说,功能类似于这个网易云api。我好像在文档里没找到相关的接口,希望能作者补充这个接口,谢谢!

How can I deploy this project on Github Pages?

Is your feature request related to a problem? Please describe.
No, just a feature request.

Describe the solution you'd like
I want to make a deployment document to teach you how to deploy this project on GitHub pages.

获取歌单列表参数bug

可选参数

错误的项:

  • page: 当前页数, 默认为1
  • limit: 取出歌单数量, 默认为 20

实际上:

  • page对应的是获取歌单列表的开始项
  • limit对应的是获取歌单列表的终止项

比如:
page=0,limit=19 表示获取从0到19的歌单列表。
如果要获取下一页的,应传参为:page=20,limit=39

部署问题

服务器部署报错 已经npm install了 运行app.js 不知道为什么
image

下载下来安装包跑了一遍提示404啊

环境

系统:

nodejs 版本(koa2要求版本是7.6.0+):

出现问题

重现步骤

期待效果

重现步骤尽量详细,不能含糊不清

如果不是提建议,提 issues 如果不照着模版来将不会优先处理或直接关闭

获取歌手专辑接口数据错误

Bug / Feature:

  • 获取歌手转接,预期返回专辑列表,返回的确是歌手热门歌曲列表,并且分页不对。
  • 另外没有获取歌手热门歌曲的接口。

复现:

  • 访问 /getSingerAlbum?singermid=0025NhlN2yWrP4&page=3 可以复现bug
  • 期望增加/getSingerHotsong接口

未找到刷新登陆接口/user/refresh

文档有提及刷新登陆接口 /user/refresh,但是没有找到.希望能补充一下~
21-08-22 🐚 新增刷新登陆 & mv 点赞 & bug fix,这个Commit提交是不是漏掉了.

docker支持

请问可以再docker下配置么?因为网易云那个我是在docker下运行的,机器本身cpu比较特殊。。。。斐讯N1,

好像彻底用不了了?

image

/soso/fcgi-bin/client_search_cp {
  opts: {
    params: {
      w: '周杰伦',
      n: 10,
      p: 1,
      catZhida: 1,
      remoteplace: 'txt.yqq.song',
      format: 'json',
      outCharset: 'utf-8',
      ct: 24,
      qqmusic_ver: 1298,
      t: 0,
      aggr: 1,
      cr: 1,
      lossless: 0,
      flag_qc: 0,
      platform: 'yqq.json'
    },
    g_tk: 1124214810,
    loginUin: '0',
    hostUin: 0,
    inCharset: 'utf8',
    outCharset: 'utf-8',
    notice: 0,
    platform: 'yqq.json',
    needNewCode: 0,
    headers: { referer: 'https://c.y.qq.com/', host: 'c.y.qq.com' }
  }
}
/soso/fcgi-bin/client_search_cp request error
error Error: Request failed with status code 404
    at createError (/root/qq-music-api/node_modules/axios/lib/core/createError.js:16:15)
    at settle (/root/qq-music-api/node_modules/axios/lib/core/settle.js:17:12)
    at IncomingMessage.handleStreamEnd (/root/qq-music-api/node_modules/axios/lib/adapters/http.js:269:11)
    at IncomingMessage.emit (node:events:525:35)
    at endReadableNT (node:internal/streams/readable:1359:12)
    at processTicksAndRejections (node:internal/process/task_queues:82:21) {
  config: {
    url: 'https://c.y.qq.com/soso/fcgi-bin/client_search_cp',
    method: 'get',
    headers: {
      Accept: 'application/json, text/plain, */*',
      referer: 'https://c.y.qq.com/',
      host: 'c.y.qq.com',
      'User-Agent': 'axios/0.21.4'
    },
    params: {
      w: '周杰伦',
      n: 10,
      p: 1,
      catZhida: 1,
      remoteplace: 'txt.yqq.song',
      format: 'json',
      outCharset: 'utf-8',
      ct: 24,
      qqmusic_ver: 1298,
      t: 0,
      aggr: 1,
      cr: 1,
      lossless: 0,
      flag_qc: 0,
      platform: 'yqq.json'
    },
    transformRequest: [ [Function: transformRequest] ],
    transformResponse: [ [Function: transformResponse] ],
    timeout: 10000,
    withCredentials: true,
    adapter: [Function: httpAdapter],
    responseType: 'json;text/plain;charset=utf-8;',
    xsrfCookieName: 'XSRF-TOKEN',
    xsrfHeaderName: 'X-XSRF-TOKEN',
    maxContentLength: -1,
    maxBodyLength: -1,
    validateStatus: [Function: validateStatus],
    transitional: {
      silentJSONParsing: true,
      forcedJSONParsing: true,
      clarifyTimeoutError: false
    },
    g_tk: 1124214810,
    loginUin: '0',
    hostUin: 0,
    inCharset: 'utf8',
    outCharset: 'utf-8',
    notice: 0,
    platform: 'yqq.json',
    needNewCode: 0,
    data: undefined
  },
  request: <ref *1> ClientRequest {
    _events: [Object: null prototype] {
      abort: [Function (anonymous)],
      aborted: [Function (anonymous)],
      connect: [Function (anonymous)],
      error: [Function (anonymous)],
      socket: [Function (anonymous)],
      timeout: [Function (anonymous)],
      prefinish: [Function: requestOnPrefinish]
    },
    _eventsCount: 7,
    _maxListeners: undefined,
    outputData: [],
    outputSize: 0,
    writable: true,
    destroyed: false,
    _last: true,
    chunkedEncoding: false,
    shouldKeepAlive: false,
    maxRequestsOnConnectionReached: false,
    _defaultKeepAlive: true,
    useChunkedEncodingByDefault: false,
    sendDate: false,
    _removedConnection: false,
    _removedContLen: false,
    _removedTE: false,
    _contentLength: 0,
    _hasBody: true,
    _trailer: '',
    finished: true,
    _headerSent: true,
    _closed: false,
    socket: TLSSocket {
      _tlsOptions: [Object],
      _secureEstablished: true,
      _securePending: false,
      _newSessionPending: false,
      _controlReleased: true,
      secureConnecting: false,
      _SNICallback: null,
      servername: 'c.y.qq.com',
      alpnProtocol: false,
      authorized: true,
      authorizationError: null,
      encrypted: true,
      _events: [Object: null prototype],
      _eventsCount: 10,
      connecting: false,
      _hadError: false,
      _parent: null,
      _host: 'c.y.qq.com',
      _readableState: [ReadableState],
      _maxListeners: undefined,
      _writableState: [WritableState],
      allowHalfOpen: false,
      _sockname: null,
      _pendingData: null,
      _pendingEncoding: '',
      server: undefined,
      _server: null,
      ssl: [TLSWrap],
      _requestCert: true,
      _rejectUnauthorized: true,
      parser: null,
      _httpMessage: [Circular *1],
      timeout: 10000,
      [Symbol(res)]: [TLSWrap],
      [Symbol(verified)]: true,
      [Symbol(pendingSession)]: null,
      [Symbol(async_id_symbol)]: 61,
      [Symbol(kHandle)]: [TLSWrap],
      [Symbol(lastWriteQueueSize)]: 0,
      [Symbol(timeout)]: Timeout {
        _idleTimeout: 10000,
        _idlePrev: [TimersList],
        _idleNext: [TimersList],
        _idleStart: 3346,
        _onTimeout: [Function: bound ],
        _timerArgs: undefined,
        _repeat: null,
        _destroyed: false,
        [Symbol(refed)]: false,
        [Symbol(kHasPrimitive)]: false,
        [Symbol(asyncId)]: 70,
        [Symbol(triggerId)]: 65
      },
      [Symbol(kBuffer)]: null,
      [Symbol(kBufferCb)]: null,
      [Symbol(kBufferGen)]: null,
      [Symbol(kCapture)]: false,
      [Symbol(kSetNoDelay)]: false,
      [Symbol(kSetKeepAlive)]: false,
      [Symbol(kSetKeepAliveInitialDelay)]: 0,
      [Symbol(kBytesRead)]: 0,
      [Symbol(kBytesWritten)]: 0,
      [Symbol(connect-options)]: [Object]
    },
    _header: 'GET /soso/fcgi-bin/client_search_cp?w=%E5%91%A8%E6%9D%B0%E4%BC%A6&n=10&p=1&catZhida=1&remoteplace=txt.yqq.song&format=json&outCharset=utf-8&ct=24&qqmusic_ver=1298&t=0&aggr=1&cr=1&lossless=0&flag_qc=0&platform=yqq.json HTTP/1.1\r\n' +
      'Accept: application/json, text/plain, */*\r\n' +
      'referer: https://c.y.qq.com/\r\n' +
      'host: c.y.qq.com\r\n' +
      'User-Agent: axios/0.21.4\r\n' +
      'Connection: close\r\n' +
      '\r\n',
    _keepAliveTimeout: 0,
    _onPendingData: [Function: nop],
    agent: Agent {
      _events: [Object: null prototype],
      _eventsCount: 2,
      _maxListeners: undefined,
      defaultPort: 443,
      protocol: 'https:',
      options: [Object: null prototype],
      requests: [Object: null prototype] {},
      sockets: [Object: null prototype],
      freeSockets: [Object: null prototype] {},
      keepAliveMsecs: 1000,
      keepAlive: false,
      maxSockets: Infinity,
      maxFreeSockets: 256,
      scheduling: 'lifo',
      maxTotalSockets: Infinity,
      totalSocketCount: 1,
      maxCachedSessions: 100,
      _sessionCache: [Object],
      [Symbol(kCapture)]: false
    },
    socketPath: undefined,
    method: 'GET',
    maxHeaderSize: undefined,
    insecureHTTPParser: undefined,
    path: '/soso/fcgi-bin/client_search_cp?w=%E5%91%A8%E6%9D%B0%E4%BC%A6&n=10&p=1&catZhida=1&remoteplace=txt.yqq.song&format=json&outCharset=utf-8&ct=24&qqmusic_ver=1298&t=0&aggr=1&cr=1&lossless=0&flag_qc=0&platform=yqq.json',
    _ended: true,
    res: IncomingMessage {
      _readableState: [ReadableState],
      _events: [Object: null prototype],
      _eventsCount: 3,
      _maxListeners: undefined,
      socket: [TLSSocket],
      httpVersionMajor: 1,
      httpVersionMinor: 1,
      httpVersion: '1.1',
      complete: true,
      rawHeaders: [Array],
      rawTrailers: [],
      aborted: false,
      upgrade: false,
      url: '',
      method: null,
      statusCode: 404,
      statusMessage: 'Not Found',
      client: [TLSSocket],
      _consuming: false,
      _dumped: false,
      req: [Circular *1],
      responseUrl: 'https://c.y.qq.com/soso/fcgi-bin/client_search_cp?w=%E5%91%A8%E6%9D%B0%E4%BC%A6&n=10&p=1&catZhida=1&remoteplace=txt.yqq.song&format=json&outCharset=utf-8&ct=24&qqmusic_ver=1298&t=0&aggr=1&cr=1&lossless=0&flag_qc=0&platform=yqq.json',
      redirects: [],
      [Symbol(kCapture)]: false,
      [Symbol(kHeaders)]: [Object],
      [Symbol(kHeadersCount)]: 12,
      [Symbol(kTrailers)]: null,
      [Symbol(kTrailersCount)]: 0
    },
    aborted: false,
    timeoutCb: null,
    upgradeOrConnect: false,
    parser: null,
    maxHeadersCount: null,
    reusedSocket: false,
    host: 'c.y.qq.com',
    protocol: 'https:',
    _redirectable: Writable {
      _writableState: [WritableState],
      _events: [Object: null prototype],
      _eventsCount: 3,
      _maxListeners: undefined,
      _options: [Object],
      _ended: true,
      _ending: true,
      _redirectCount: 0,
      _redirects: [],
      _requestBodyLength: 0,
      _requestBodyBuffers: [],
      _onNativeResponse: [Function (anonymous)],
      _currentRequest: [Circular *1],
      _currentUrl: 'https://c.y.qq.com/soso/fcgi-bin/client_search_cp?w=%E5%91%A8%E6%9D%B0%E4%BC%A6&n=10&p=1&catZhida=1&remoteplace=txt.yqq.song&format=json&outCharset=utf-8&ct=24&qqmusic_ver=1298&t=0&aggr=1&cr=1&lossless=0&flag_qc=0&platform=yqq.json',
      _timeout: null,
      [Symbol(kCapture)]: false
    },
    [Symbol(kCapture)]: false,
    [Symbol(kNeedDrain)]: false,
    [Symbol(corked)]: 0,
    [Symbol(kOutHeaders)]: [Object: null prototype] {
      accept: [Array],
      referer: [Array],
      host: [Array],
      'user-agent': [Array]
    },
    [Symbol(kUniqueHeaders)]: null
  },
  response: {
    status: 404,
    statusText: 'Not Found',
    headers: {
      server: 'nginx',
      date: 'Fri, 29 Jul 2022 11:37:47 GMT',
      'content-type': 'text/html',
      'content-length': '0',
      connection: 'close',
      'cache-control': 'no-cache'
    },
    config: {
      url: 'https://c.y.qq.com/soso/fcgi-bin/client_search_cp',
      method: 'get',
      headers: [Object],
      params: [Object],
      transformRequest: [Array],
      transformResponse: [Array],
      timeout: 10000,
      withCredentials: true,
      adapter: [Function: httpAdapter],
      responseType: 'json;text/plain;charset=utf-8;',
      xsrfCookieName: 'XSRF-TOKEN',
      xsrfHeaderName: 'X-XSRF-TOKEN',
      maxContentLength: -1,
      maxBodyLength: -1,
      validateStatus: [Function: validateStatus],
      transitional: [Object],
      g_tk: 1124214810,
      loginUin: '0',
      hostUin: 0,
      inCharset: 'utf8',
      outCharset: 'utf-8',
      notice: 0,
      platform: 'yqq.json',
      needNewCode: 0,
      data: undefined
    },
    request: <ref *1> ClientRequest {
      _events: [Object: null prototype],
      _eventsCount: 7,
      _maxListeners: undefined,
      outputData: [],
      outputSize: 0,
      writable: true,
      destroyed: false,
      _last: true,
      chunkedEncoding: false,
      shouldKeepAlive: false,
      maxRequestsOnConnectionReached: false,
      _defaultKeepAlive: true,
      useChunkedEncodingByDefault: false,
      sendDate: false,
      _removedConnection: false,
      _removedContLen: false,
      _removedTE: false,
      _contentLength: 0,
      _hasBody: true,
      _trailer: '',
      finished: true,
      _headerSent: true,
      _closed: false,
      socket: [TLSSocket],
      _header: 'GET /soso/fcgi-bin/client_search_cp?w=%E5%91%A8%E6%9D%B0%E4%BC%A6&n=10&p=1&catZhida=1&remoteplace=txt.yqq.song&format=json&outCharset=utf-8&ct=24&qqmusic_ver=1298&t=0&aggr=1&cr=1&lossless=0&flag_qc=0&platform=yqq.json HTTP/1.1\r\n' +
        'Accept: application/json, text/plain, */*\r\n' +
        'referer: https://c.y.qq.com/\r\n' +
        'host: c.y.qq.com\r\n' +
        'User-Agent: axios/0.21.4\r\n' +
        'Connection: close\r\n' +
        '\r\n',
      _keepAliveTimeout: 0,
      _onPendingData: [Function: nop],
      agent: [Agent],
      socketPath: undefined,
      method: 'GET',
      maxHeaderSize: undefined,
      insecureHTTPParser: undefined,
      path: '/soso/fcgi-bin/client_search_cp?w=%E5%91%A8%E6%9D%B0%E4%BC%A6&n=10&p=1&catZhida=1&remoteplace=txt.yqq.song&format=json&outCharset=utf-8&ct=24&qqmusic_ver=1298&t=0&aggr=1&cr=1&lossless=0&flag_qc=0&platform=yqq.json',
      _ended: true,
      res: [IncomingMessage],
      aborted: false,
      timeoutCb: null,
      upgradeOrConnect: false,
      parser: null,
      maxHeadersCount: null,
      reusedSocket: false,
      host: 'c.y.qq.com',
      protocol: 'https:',
      _redirectable: [Writable],
      [Symbol(kCapture)]: false,
      [Symbol(kNeedDrain)]: false,
      [Symbol(corked)]: 0,
      [Symbol(kOutHeaders)]: [Object: null prototype],
      [Symbol(kUniqueHeaders)]: null
    },
    data: ''
  },
  isAxiosError: true,
  toJSON: [Function: toJSON]
}

  AssertionError [ERR_ASSERTION]: status code must be a number
      at Object.set status [as status] (/root/qq-music-api/node_modules/koa/lib/response.js:86:5)
      at Object.assign (/root/qq-music-api/node_modules/delegates/index.js:92:31)
      at Function.assign (<anonymous>)
      at /root/qq-music-api/routers/context/getSearchByKey.js:22:10
      at Generator.next (<anonymous>)
      at asyncGeneratorStep (/root/qq-music-api/routers/context/getSearchByKey.js:1:103)
      at _next (/root/qq-music-api/routers/context/getSearchByKey.js:3:194)
      at processTicksAndRejections (node:internal/process/task_queues:95:5)

Require multi music info from batch mid

Is your feature request related to a problem? Please describe.
The music info API request from issue #8 is handled perfectly! However, the new API does not support querying multi music info. Querying multi music info at once is useful when you are trying to load a bunch of music (say, a new music playlist). Querying their info one by one is time-inefficient and will easily result in the block of raw QQ API (I think :P).

Describe the solution you'd like
I want a new (or modification of the origin) API, which I can get a list of music info back. One can refer to this netease API for the detailed design :).

Thanks for the great work again!

npm install 无法完成

作者你好,我是后端程序员想使用你提供的这些API,所以我拉取了此项目。但是在npm install 的时候一致会卡在一个地方。
image
这个应该如何处理

有播放歌曲的api么?

不好意思哈, 因为不是很好根据模板描述, 就不按照模板来了

我想问下现在有播放歌曲的api了么? 我看了下api结构图是有的, 但是没有找到。 搜索接口返回的url 类似 "url": "http://stream10.qqmusic.qq.com/718478.wma", 这个, 直接请求的话是404

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.