Home
avatar

如果不存在过

百度实时热搜榜

百度实时热搜榜和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-Typeapplication/x-www-form-urlencoded;charset;

返回参数说明

名称类型说明
codeint状态码
msgstring状态信息
datastring请求结果数据集
data.contentstring热搜榜数据集
data.content.wordstring热搜话题
data.content.descstring话题描述
data.content.hotChangestring热度变化
data.content.hotScorestring热度值
data.content.indexstring指数排名 (数值越小,排名越前)
data.content.hotTagstring热度标签
data.content.hotTagImgstring热度标签图片
data.content.imgstring热搜图片
data.content.urlstring热搜链接
data.topContentstringTOP热搜榜数据集
data.topContent.wordstringTOP热搜话题
data.topContent.descstringTOP话题描述
data.topContent.hotChangestringTOP热度变化
data.topContent.hotScorestringTOP热度值
data.topContent.indexstringTOP热搜排名 (数值越小,排名越前)
data.topContent.hotTagstringTOP热度标签
data.topContent.hotTagImgstringTOP热度标签图片
data.topContent.imgstringTOP热搜图片
data.topContent.urlstringTOP热搜链接
data.updateTimestring热搜更新时间
data.typeNamestring热搜类型
debugstring/array调试数据
exec_timefloat执行耗时
user_ipstring客户端IP

错误码参照

错误码类型说明
403int没有权限
400int参数传递不正确
500int服务器内部错误

在线调试 / 完整文档

本接口为 信息查找 分类下的开放接口。完整文档、在线调试与示例代码请前往 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"

在线调试

该接口无需参数,直接点击下方按钮发起请求。

填写参数后点击「发起请求」查看实时返回结果。

免费