基础信息
查看接口基本信息和返回格式免责声明
本平台提供的API服务均来自互联网,可能包含生成式AI内容。所有返回内容仅供参考,平台不对内容的准确性、完整性、时效性或适用性做任何保证。使用者应自行判断并承担使用风险。
接口描述
获取酷我官方音源,多阶级音质选择
七日请求统计
本周总请求: -
日均: -
请求方式
GET
POST 推荐
请求地址
https://dome.api.yunmge.com/api/song_kuwo
返回方式
JSON
默认返回格式,包含完整数据结构
返回预览
JSON
{
"code": 200,
"data": {
"index": 1,
"song_id": "321260769",
"name": "唯一",
"artist": "G.E.M. 邓紫棋",
"album": "T.I.M.E.",
"duration": "04:13",
"cover": "http://img2.kuwo.cn/star/albumcover/800/s4s61/37/4021488843.jpg",
"all_bitrates": [
{
"bitrate": 128,
"label": "128kmp3",
"play_url": "http://er.sycdn.kuwo.cn/bec3c569e2b357f63fdc6c2e1eabf36b/696a83bc/resource/30106/trackmedia/M500001ziKgJ3o5Ipp.mp3"
},
{
"bitrate": 192,
"label": "192kmp3",
"play_url": "http://er.sycdn.kuwo.cn/bec3c569e2b357f63fdc6c2e1eabf36b/696a83bc/resource/30106/trackmedia/M500001ziKgJ3o5Ipp.mp3"
},
{
"bitrate": 320,
"label": "320kmp3",
"play_url": "http://er.sycdn.kuwo.cn/b89c36f49434b510d1df22f83a115e6f/696a83bc/resource/30106/trackmedia/M800001ziKgJ3o5Ipp.mp3"
},
{
"bitrate": 2000,
"label": "2000kflac",
"play_url": "http://er.sycdn.kuwo.cn/d05b4a82310e0216585f95b4b5cd4bef/696a83bc/resource/1307392909/trackmedia/F000001ziKgJ3o5Ipp.flac"
},
{
"bitrate": 4000,
"label": "4000kflac",
"play_url": "http://er.sycdn.kuwo.cn/0aa74dccb234a029265712fe26e4dd5f/696a83bd/resource/30106/trackmedia/M500001ziKgJ3o5Ipp.mp3"
},
{
"bitrate": "flac",
"label": "2000kflac",
"play_url": "http://er.sycdn.kuwo.cn/e85f6e9f40d1765756bbbdd3dae0890a/696a83bd/resource/1307392909/trackmedia/F000001ziKgJ3o5Ipp.flac"
},
{
"bitrate": "hires",
"label": "4000kflac",
"play_url": "http://er.sycdn.kuwo.cn/0aa74dccb234a029265712fe26e4dd5f/696a83bd/resource/30106/trackmedia/M500001ziKgJ3o5Ipp.mp3"
}
],
"available_bitrates": [
128,
192,
320,
2000,
4000,
"flac",
"hires"
],
"lyrics": {
"raw": [
{
"lineLyric": "唯一 - G.E.M. 邓紫棋",
"time": "0.2"
},
{
"lineLyric": "词:潘云安",
"time": "2.05"
},
{
"lineLyric": "曲:潘云安",
"time": "3.48"
},
{
"lineLyric": "改编词曲:G.E.M. 邓紫棋",
"time": "4.85"
},
{
"lineLyric": "制作人:G.E.M. 邓紫棋/T-Ma",
"time": "7.23"
},
{
"lineLyric": "编曲:G.E.M. 邓紫棋/T-Ma",
"time": "9.72"
},
{
"lineLyric": "你真的懂唯一的定义",
"time": "15.27"
},
{
"lineLyric": "并不简单如呼吸",
"time": "21.13"
},
{
"lineLyric": "你真的希望你能厘清",
"time": "28.44"
},
{
"lineLyric": "若没交心怎么说明",
"time": "34.44"
},
{
"lineLyric": "我真的爱你 句句不轻易",
"time": "40.24"
},
{
"lineLyric": "眼神中飘移",
"time": "53.82"
},
{
"lineLyric": "总是在关键时刻清楚洞悉",
"time": "59.56"
},
{
"lineLyric": "你的不坚定 配合我颠沛流离",
"time": "67.37"
},
{
"lineLyric": "死去中清醒 明白你背着我聪明",
"time": "80.25"
},
{
"lineLyric": "那些我 想说的 没说的 话",
"time": "108.2"
},
{
"lineLyric": "有时我 怀疑呢 只是我 傻瓜",
"time": "114.7"
},
{
"lineLyric": "但如果真的爱 不会算计",
"time": "121.45"
},
{
"lineLyric": "爱是不嫉妒 不张狂 不求自己",
"time": "124.45"
},
{
"lineLyric": "无关你的回应 永不止息",
"time": "128.14"
},
{
"lineLyric": "你知道",
"time": "132.84"
},
{
"lineLyric": "我真的爱你 没人能比拟",
"time": "133.6"
},
{
"lineLyric": "眼神没肯定",
"time": "146.89"
},
{
"lineLyric": "总是在关键时刻清楚洞悉",
"time": "152.75"
},
{
"lineLyric": "你的不坚定 配合我颠沛流离",
"time": "160.27"
},
{
"lineLyric": "死去中清醒 明白你背着我聪明",
"time": "173.52"
},
{
"lineLyric": "我知道",
"time": "186.12"
},
{
"lineLyric": "爱本质无异 是因为人多得拥挤",
"time": "186.98"
},
{
"lineLyric": "你不想证明 证明我是你唯一",
"time": "200.3"
},
{
"lineLyric": "证明我是你唯一",
"time": "212.85"
},
{
"lineLyric": "混音:Claudia Koh",
"time": "218.19"
},
{
"lineLyric": "母带:T-Ma",
"time": "219.14"
},
{
"lineLyric": "OP:更漂亮音乐工作室",
"time": "220.65"
},
{
"lineLyric": "SP:相信音乐国际股份有限公司",
"time": "222.7"
}
],
"formatted": "[00:00.200]唯一 - G.E.M. 邓紫棋
[00:02.050]词:潘云安
[00:03.480]曲:潘云安
[00:04.850]改编词曲:G.E.M. 邓紫棋
[00:07.230]制作人:G.E.M. 邓紫棋/T-Ma
[00:09.720]编曲:G.E.M. 邓紫棋/T-Ma
[00:15.270]你真的懂唯一的定义
[00:21.130]并不简单如呼吸
[00:28.440]你真的希望你能厘清
[00:34.440]若没交心怎么说明
[00:40.240]我真的爱你 句句不轻易
[00:53.820]眼神中飘移
[00:59.560]总是在关键时刻清楚洞悉
[01:07.370]你的不坚定 配合我颠沛流离
[01:20.250]死去中清醒 明白你背着我聪明
[01:48.200]那些我 想说的 没说的 话
[01:54.700]有时我 怀疑呢 只是我 傻瓜
[02:01.450]但如果真的爱 不会算计
[02:04.450]爱是不嫉妒 不张狂 不求自己
[02:08.140]无关你的回应 永不止息
[02:12.840]你知道
[02:13.600]我真的爱你 没人能比拟
[02:26.890]眼神没肯定
[02:32.750]总是在关键时刻清楚洞悉
[02:40.270]你的不坚定 配合我颠沛流离
[02:53.520]死去中清醒 明白你背着我聪明
[03:06.120]我知道
[03:06.980]爱本质无异 是因为人多得拥挤
[03:20.300]你不想证明 证明我是你唯一
[03:32.850]证明我是你唯一
[03:38.190]混音:Claudia Koh
[03:39.140]母带:T-Ma
[03:40.650]OP:更漂亮音乐工作室
[03:42.700]SP:相信音乐国际股份有限公司"
}
}
}计费标准
了解接口的计费方式和价格
免费接口
免费
完全免费
所有用户均可免费调用,无需付费
QPS限制
普通用户
60
次/分钟
会员用户
999999
次/分钟
每日请求次数
普通用户
999999
次/天
会员用户
999999
次/天
安全认证
了解接口的认证方式和访问凭证管理 Token 认证
实名认证
无需实名认证
本接口对所有用户开放,无需实名认证即可访问
认证方式
推荐
Header 认证
通过 HTTP Header 传递认证信息
Authorization
Bearer {access_token}或通过curl请求参数传递:
curl
curl "https://dome.api.yunmge.com/api/song_kuwo?token=YOUR_TOKEN"
参数文档
查看接口请求参数和返回字段说明 请求参数
| 参数名 | 类型 | 必填 | 默认值 | 可选值 | 说明 |
|---|---|---|---|---|---|
| token | string | 必填 | 无 | 登录后显示你的请求token | 接口请求唯一认证标识! |
| name | string | 必填 | 告白气球 | 无 | 歌曲名称 |
| n | string | 必填 | 无 | 无 | 歌曲序号 |
| num | string | 可选 | 10 | 1-40 | 歌曲数量 |
返回参数
| 字段名 | 类型 | 说明 |
|---|---|---|
code
|
int | 返回状态码 |
index
|
int | 序号 |
song_id
|
int | id |
name
|
string | 名称 |
artist
|
string | 歌手 |
album
|
string | 专辑 |
duration
|
string | 时长 |
cover
|
string | 封面 |
all_bitrates
|
array | 歌曲列表 |
all_bitrates.bitrate
|
string | 音质 |
all_bitrates.label
|
string | 音质标识 |
all_bitrates.play_url
|
string | 歌曲链接 |
lyrics
|
string | 歌词 |
formatted
|
string | 文本歌词 |
状态码
了解接口返回的状态码含义及处理方式 接口状态码
| 状态码 | 说明 |
|---|---|
| 200 | 请求成功 |
| 351 | 多错误,自行请求查看 |
服务器状态码
| 状态码 | 说明 |
|---|---|
| 500 | 服务器错误 |
| 501 | 请求接口不存在 |
| 502 | 请求接口已下架 |
| 503 | 请求接口维护中 |
| 504 | 缺少请求token参数 |
| 505 | 请求token不存在 |
| 506 | 请求token已被封禁 |
| 507 | 请求token额度不足 |
| 508 | 今日请求token已达上限 |
| 509 | 请求ip不在token白名单内 |
| 510 | 请求token无权使用当前接口 |
| 511 | 接口请求频率过高,请稍后再试 |
| 512 | 该接口未开启在线测试功能 |
| 513 | 今日在线测试次数已达上限 |
| 514 | 今日该接口请求次数已达上限 |
| 515 | 该接口为会员专属接口,请携带会员token |
| 516 | 该接口为会员专属接口,请开通会员 |
| 517 | 接口请求过于频繁,已被临时限制 |
| 518 | 该接口需要实名认证,请先完成实名认证 |
| 519 | 当前Token今日请求次数已达上限 |
| 520 | 当前Token已被禁止使用 |
| 521 | 请求token余额不足 |
| 522 | 请求token额度和余额均不足 |
| 530 | 接口服务异常,请稍后再试 |
| 531 | 接口响应超时 |
| 532 | 接口返回数据格式错误 |
| 533 | 接口请求失败 |
在线测试
在线调试接口,实时查看响应结果 发起请求
GET/POST
示例代码
多种语言的接口调用示例PHP
JavaScript
NodeJs
Python
Go
Java
C#
C
C++
易语言
PHP
<?php
$API_TOKEN = 'YOUR_TOKEN';
$API_URL = 'https://dome.api.yunmge.com/api/song_kuwo';
$params = array(
'token' => 'YOUR_TOKEN',
'name' => '告白气球',
'n' => '无',
'num' => '10',
);
$res = api::send($API_URL, $params, 'GET/POST');
print($res);
class api {
public static function send($url, $data, $type) {
$data = http_build_query($data);
$ch = curl_init();
if ($type == 'POST') {
curl_setopt($ch, CURLOPT_URL, $url);
curl_setopt($ch, CURLOPT_POST, true);
curl_setopt($ch, CURLOPT_POSTFIELDS, $data);
} else {
curl_setopt($ch, CURLOPT_URL, $url . '?' . $data);
}
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_TIMEOUT, 10);
curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);
$res = curl_exec($ch);
curl_close($ch);
return $res;
}
}JavaScript
$.ajax({
url: 'https://dome.api.yunmge.com/api/song_kuwo',
data: {
token: 'YOUR_TOKEN',
name: '告白气球',
n: '无',
num: '10',
},
type: 'GET/POST',
dataType: 'json',
success: function(data) {
console.log(data);
},
error: function(err) {
console.log('请求失败', err);
}
});Python
import requests
url = "https://dome.api.yunmge.com/api/song_kuwo"
data = {
"token": "YOUR_TOKEN",
"name": "告白气球",
"n": "无",
"num": "10",
}
response = requests.post(url, data=data)
print(response.json())Java
import java.net.HttpURLConnection;
import java.net.URL;
import java.io.*;
public class ApiRequest {
public static void main(String[] args) throws Exception {
URL url = new URL("https://dome.api.yunmge.com/api/song_kuwo");
HttpURLConnection conn = (HttpURLConnection) url.openConnection();
conn.setRequestMethod("GET/POST");
conn.setConnectTimeout(10000);
BufferedReader reader = new BufferedReader(
new InputStreamReader(conn.getInputStream()));
String line;
StringBuilder result = new StringBuilder();
while ((line = reader.readLine()) != null) {
result.append(line);
}
reader.close();
System.out.println(result.toString());
}
}Go
package main
import (
"fmt"
"io/ioutil"
"net/http"
"strings"
)
func main() {
data := "token=YOUR_TOKEN&name=%E5%91%8A%E7%99%BD%E6%B0%94%E7%90%83&n=%E6%97%A0&num=10"
resp, _ := http.Post("https://dome.api.yunmge.com/api/song_kuwo",
"application/x-www-form-urlencoded", strings.NewReader(data))
defer resp.Body.Close()
body, _ := ioutil.ReadAll(resp.Body)
fmt.Println(string(body))
}C#
using System;
using System.Net.Http;
using System.Threading.Tasks;
class Program {
static async Task Main() {
using var client = new HttpClient();
var data = new FormUrlEncodedContent(new Dictionary<string, string> {
{"token", "YOUR_TOKEN"},
{"name", "告白气球"},
{"n", "无"},
{"num", "10"},
});
var response = await client.PostAsync("https://dome.api.yunmge.com/api/song_kuwo", data);
var result = await response.Content.ReadAsStringAsync();
Console.WriteLine(response);
}
}NodeJs
const https = require('https');
const querystring = require('querystring');
const postData = querystring.stringify({
'token': 'YOUR_TOKEN',
'name': '告白气球',
'n': '无',
'num': '10',
});
const options = {
hostname: 'dome.api.yunmge.com',
path: '/api/song_kuwo',
method: 'POST',
headers: { 'Content-Type': 'application/x-www-form-urlencoded' }
};
const req = https.request(options, res => {
let data = '';
res.on('data', d => data += d);
res.on('end', () => console.log(data));
});
req.write(postData);
req.end();
C
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <curl/curl.h>
static size_t WriteCallback(void *contents, size_t size, size_t nmemb, void *userp) {
((char*)userp)[0] = '\0';
strcat(userp, contents);
return size * nmemb;
}
int main() {
CURL *curl;
CURLcode res;
char response[4096] = {0};
curl_global_init(CURL_GLOBAL_DEFAULT);
curl = curl_easy_init();
if(curl) {
curl_easy_setopt(curl, CURLOPT_URL, "https://dome.api.yunmge.com/api/song_kuwo");
curl_easy_setopt(curl, CURLOPT_POST, 1L);
curl_easy_setopt(curl, CURLOPT_POSTFIELDS, "token=YOUR_TOKEN&name=%E5%91%8A%E7%99%BD%E6%B0%94%E7%90%83&n=%E6%97%A0&num=10");
curl_easy_setopt(curl, CURLOPT_WRITEFUNCTION, WriteCallback);
curl_easy_setopt(curl, CURLOPT_WRITEDATA, response);
curl_easy_setopt(curl, CURLOPT_TIMEOUT, 10L);
res = curl_easy_perform(curl);
if(res == CURLE_OK) printf("%s\n", response);
curl_easy_cleanup(curl);
}
curl_global_cleanup();
return 0;
}C++
#include <iostream>
#include <string>
#include <curl/curl.h>
size_t WriteCallback(void* contents, size_t size, size_t nmemb, std::string* userp) {
userp->append((char*)contents, size * nmemb);
return size * nmemb;
}
int main() {
CURL* curl = curl_easy_init();
std::string response;
if (curl) {
curl_easy_setopt(curl, CURLOPT_URL, "https://dome.api.yunmge.com/api/song_kuwo");
curl_easy_setopt(curl, CURLOPT_POST, 1L);
curl_easy_setopt(curl, CURLOPT_POSTFIELDS, "token=YOUR_TOKEN&name=%E5%91%8A%E7%99%BD%E6%B0%94%E7%90%83&n=%E6%97%A0&num=10");
curl_easy_setopt(curl, CURLOPT_WRITEFUNCTION, WriteCallback);
curl_easy_setopt(curl, CURLOPT_WRITEDATA, &response);
curl_easy_setopt(curl, CURLOPT_TIMEOUT, 10L);
CURLcode res = curl_easy_perform(curl);
if (res == CURLE_OK) std::cout << response << std::endl;
curl_easy_cleanup(curl);
}
curl_global_cleanup();
return 0;
}易语言
.版本 2 .支持库 spec .局部变量 url, 文本型 .局部变量 params, 文本型 .局部变量 result, 文本型 url = "https://dome.api.yunmge.com/api/song_kuwo" params = "token=YOUR_TOKEN&name=%E5%91%8A%E7%99%BD%E6%B0%94%E7%90%83&n=%E6%97%A0&num=10" result = 编码_URL解码 (网页_访问 (url, , params)) 调试输出 (result)
AI开发文档
导出接口文档供AI助手快速理解接口结构
复制下方内容粘贴给AI助手,即可快速生成对接代码。
JSON 格式
0 KB