https://api.cenguigui.cn/api/huluxia/?msg=需要搜索的软件名&page=页数&limit=返回数量
GET
JSON
正常启用
以下参数为接口所需调用信息
| 参数 | 是否必填 | 类型 | 说明 | 示例 |
|---|---|---|---|---|
| msg | 是 | 是 | 需要搜索的软件名称 | |
| page | 否 | 否 | 页数,默认1 | |
| limit | 否 | 否 | 返回数量,默认20 |
https://api.cenguigui.cn/api/huluxia/?msg=音乐&page=1&limit=20
{
"code": 200,
"msg": "请求成功",
"data": [
{
"name": "音乐时刻",
"username": "互联网",
"appPrivacyPolicy": "https://huodong.huluxia.com/hlx/toolPrivacy.html",
"pic": "https://cdn.u1.huluxia.com/g4/M01/CD/E0/rBAAdmTfEDyAEq-LAACev1c0b6U978.png",
"size": "7.26",
"version": "1.1.6",
"appauthorization": "免费",
"categoryname": "视听阅记",
"desc": "无广告的安卓音乐APP\n\n\t可以搜索、播放和下载各大平台的音乐,同时支持播放和下载MV。首页有精选歌单实时更新,也可导入外部歌单。软件内置四个搜索引擎,可以自定义下载路径、命名规则、导入歌词等。\n\n\t ",
"localurl": {
"name": "普通下载",
"url": "https://cdn.volcengine.huluxia.com/game/2024/03/13/77.90474(1.1.6)H080SqvD.apk"
},
"download": "https://cdn.volcengine.huluxia.com/game/2024/03/13/77.90474(1.1.6)H080SqvD.apk"
}
],
"tips": "软件搜索"
}
// JavaScript调用示例
fetch("https://api.cenguigui.cn/api/huluxia/?msg=音乐&page=1&limit=20", {
method: "GET",
headers: {
"Content-Type": "application/json"
}
})
.then(response => response.json())
.then(data => console.log(data))
.catch(error => console.error("Error:", error));
# Python调用示例
import requests
url = "https://api.cenguigui.cn/api/huluxia/?msg=音乐&page=1&limit=20"
response = requests.get(url)
print(response.json())
// Java调用示例
import java.net.URI;
import java.net.http.HttpClient;
import java.net.http.HttpRequest;
import java.net.http.HttpResponse;
import java.time.Duration;
public class ApiExample {
public static void main(String[] args) throws Exception {
HttpClient client = HttpClient.newBuilder()
.version(HttpClient.Version.HTTP_2)
.connectTimeout(Duration.ofSeconds(10))
.build();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("https://api.cenguigui.cn/api/huluxia/?msg=音乐&page=1&limit=20"))
.build();
client.sendAsync(request, HttpResponse.BodyHandlers.ofString())
.thenApply(HttpResponse::body)
.thenAccept(System.out::println)
.join();
}
}
<?php
// PHP调用示例
$url = "https://api.cenguigui.cn/api/huluxia/?msg=音乐&page=1&limit=20";
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, $url);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
$response = curl_exec($ch);
curl_close($ch);
$result = json_decode($response, true);
print_r($result);
?>
// C#调用示例
using System;
using System.Net.Http;
using System.Threading.Tasks;
class Program
{
static async Task Main()
{
using var client = new HttpClient();
var url = "https://api.cenguigui.cn/api/huluxia/?msg=音乐&page=1&limit=20";
var response = await client.GetAsync(url);
var result = await response.Content.ReadAsStringAsync();
Console.WriteLine(result);
}
}
// 响应结果将显示在这里