百度实时热搜榜
百度实时热搜榜和top热搜
接口信息
| 项目 | 内容 |
|---|---|
| 接口地址 | https://api.code410.com/api/hot/baidu |
| 返回格式 | application/json |
| 请求方式 | HTTP GET POST/JSON |
| 更新日期 | 2023-09-03 |
| 调用权限 | 免费开放 |
| 每日限制 | 无限制 |
| 请求频率限制 | 1秒5次 |
请求示例
https://api.code410.com/api/hot/baidu请求 HEADER
| 名称 | 值 |
|---|---|
| Content-Type | application/x-www-form-urlencoded;charset; |
返回参数说明
| 名称 | 类型 | 说明 |
|---|---|---|
| code | int | 状态码 |
| msg | string | 状态信息 |
| data | string | 请求结果数据集 |
| data.content | string | 热搜榜数据集 |
| data.content.word | string | 热搜话题 |
| data.content.desc | string | 话题描述 |
| data.content.hotChange | string | 热度变化 |
| data.content.hotScore | string | 热度值 |
| data.content.index | string | 指数排名 (数值越小,排名越前) |
| data.content.hotTag | string | 热度标签 |
| data.content.hotTagImg | string | 热度标签图片 |
| data.content.img | string | 热搜图片 |
| data.content.url | string | 热搜链接 |
| data.topContent | string | TOP热搜榜数据集 |
| data.topContent.word | string | TOP热搜话题 |
| data.topContent.desc | string | TOP话题描述 |
| data.topContent.hotChange | string | TOP热度变化 |
| data.topContent.hotScore | string | TOP热度值 |
| data.topContent.index | string | TOP热搜排名 (数值越小,排名越前) |
| data.topContent.hotTag | string | TOP热度标签 |
| data.topContent.hotTagImg | string | TOP热度标签图片 |
| data.topContent.img | string | TOP热搜图片 |
| data.topContent.url | string | TOP热搜链接 |
| data.updateTime | string | 热搜更新时间 |
| data.typeName | string | 热搜类型 |
| debug | string/array | 调试数据 |
| exec_time | float | 执行耗时 |
| user_ip | string | 客户端IP |
错误码参照
| 错误码 | 类型 | 说明 |
|---|---|---|
| 403 | int | 没有权限 |
| 400 | int | 参数传递不正确 |
| 500 | int | 服务器内部错误 |
在线调试 / 完整文档
本接口为 信息查找 分类下的开放接口。完整文档、在线调试与示例代码请前往 https://api.code410.com/doc/200。
返回示例
{"code":200,"msg":"请求成功","data":{"content":[{"word":"2026高考作文出炉","desc":"","hotChange":"same","hotScore":"7808858","index":0,"hotTag":"5","hotTagImg":"https://search-operate.cdn.bcebos.com/88cd2b09219da7dc3af3fe179621061a.png","img":"https://fyb-1.cdn.bcebos.com/fyb/de6163834f53ca92c1273fff98ac9078.jpeg","url":"https://www.baidu.com/s?wd=2026%E9%AB%98%E8%80%83%E4%BD%9C%E6%96%87%E5%87%BA%E7%82%89&sa=fyb_news&rsv_dl=fyb_news"},{"word":"一年一度“小蝌蚪找妈妈现场”","desc":"6月7日,2026年高考第一门语文科目考完,考生出考场第一件事都在“找妈妈”。网友:一年一度“小蝌蚪找妈妈现场”。","hotChange":"same","hotScore":"7713789","index":1,"hotTag":"1","hotTagImg":"https://search-operate.cdn.bcebos.com/42e626c5469cc4cd3b91131bcfe53d44.png","img":"https://fyb-2.cdn.bcebos.com/hotboard_image/53e5b87c003b7042bb8ee78b2252691f","url":"https://www.baidu.com/s?wd=%E4%B8%80%E5%B9%B4%E4%B8%80%E5%BA%A6%E2%80%9C%E5%B0%8F%E8%9D%8C%E8%9A%AA%E6%89%BE%E5%A6%88%E5%A6%88%E7%8E%B0%E5%9C%BA%E2%80%9D&sa=fyb_news&rsv_dl=fyb_news"},{"word":"祝每一位高考生圆梦今夏","desc":"2026年6月7日全国高考开考,祝每一位高考生圆梦今夏!","hotChange":"same","hotScore":"7616477","index":2,"hotTag":"0","hotTagImg":null,"img":"https://fyb-2.cdn.bcebos.com/hotboard_image/e04ec97fc66fa1f0bdea771918eb3099","url":"https://www.baidu.c示例代码
// jQuery-Ajax
$.ajax({
url: 'https://api.code410.com/api/hot/baidu',
data: {
// 该接口无需参数
},
type: 'GET',
dataType: 'json',
success: function (data) {
console.log(data); // 请求成功,输出结果
},
error: function () {
console.log('请求失败');
}
});import requests
url = "https://api.code410.com/api/hot/baidu"
params = {
# 该接口无需参数
}
res = requests.get(url, params=params)
print(res.json())const https = require('https');
const url = 'https://api.code410.com/api/hot/baidu';
https.get(url, res => {
let data = '';
res.on('data', chunk => data += chunk);
res.on('end', () => console.log(JSON.parse(data)));
}).on('error', err => console.error(err));package main
import (
"fmt"
"io/ioutil"
"net/http"
)
func main() {
resp, err := http.Get("https://api.code410.com/api/hot/baidu")
if err != nil {
fmt.Println("http get error", err)
return
}
defer resp.Body.Close()
result, _ := ioutil.ReadAll(resp.Body)
fmt.Println(string(result))
}import java.io.BufferedReader;
import java.io.InputStreamReader;
import java.net.HttpURLConnection;
import java.net.URL;
public class Test {
public static void main(String[] args) {
try {
URL url = new URL("https://api.code410.com/api/hot/baidu");
HttpURLConnection conn = (HttpURLConnection) url.openConnection();
conn.setRequestMethod("GET");
conn.connect();
BufferedReader reader = new BufferedReader(new InputStreamReader(conn.getInputStream(), "UTF-8"));
String line;
StringBuilder sb = new StringBuilder();
while ((line = reader.readLine()) != null) sb.append(line);
reader.close();
System.out.println(sb.toString());
} catch (Exception e) {
e.printStackTrace();
}
}
}using System;
using System.Net.Http;
using System.Threading.Tasks;
class Program {
static async Task Main() {
HttpClient client = new HttpClient();
string url = "https://api.code410.com/api/hot/baidu";
HttpResponseMessage response = await client.GetAsync(url);
string body = await response.Content.ReadAsStringAsync();
Console.WriteLine(body);
}
}<?php
$url = "https://api.code410.com/api/hot/baidu";
$response = file_get_contents($url);
$data = json_decode($response, true);
print_r($data);curl "https://api.code410.com/api/hot/baidu"在线调试
该接口无需参数,直接点击下方按钮发起请求。
填写参数后点击「发起请求」查看实时返回结果。
