接口地址
https://api.guiguiya.com/api/hqrb?type=json
接口状态
正常 (HTTP 200) 上次检测:2026-05-19 10:12:45
📝 接口描述
提供每日最新环球时报(节假日除外)
📋 请求示例
【基础请求】
GET https://api.guiguiya.com/api/hqrb?type=json
【请求头】
Content-Type: application/json
Accept: application/json
【参数说明】
GET请求参数通过URL传递:
https://api.guiguiya.com/api/hqrb?type=json?参数名1=参数值1&参数名2=参数值2
【调用示例】
# cURL
curl -X GET 'https://api.guiguiya.com/api/hqrb?type=json' \
-H 'Content-Type: application/json'
# JavaScript (Fetch)
fetch('https://api.guiguiya.com/api/hqrb?type=json', {
method: 'GET',
headers: { 'Content-Type': 'application/json' }
})
.then(res => res.json())
.then(data => console.log(data));
# PHP (cURL)
<?php
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, 'https://api.guiguiya.com/api/hqrb?type=json');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'GET');
curl_setopt($ch, CURLOPT_HTTPHEADER, ['Content-Type: application/json']);
$response = curl_exec($ch);
curl_close($ch);
echo $response;
?>
# Python (requests)
import requests
url = 'https://api.guiguiya.com/api/hqrb?type=json'
response = requests.get(url)
print(response.json())
📤 真实返回示例
{
"code": 200,
"msg": "环球时报获取成功",
"pdfUrl": "https:\/\/hqdp.globaltimes.cn\/home\/digital\/file\/IMAGE\/beb39f335b6708107ebd26ab0299380c\/hd1b0519-finish.jpg",
"id": "2056513916590116865",
"datetime": "2026-05-19",
"author": "环球时报电子版-鬼鬼API"
}
🔧 JavaScript (Fetch)
fetch('/api/proxy.php?url=https%3A%2F%2Fapi.guiguiya.com%2Fapi%2Fhqrb%3Ftype%3Djson', {
method: 'GET',
headers: { 'Content-Type': 'application/json' }
})
.then(res => res.json())
.then(data => console.log(data))
.catch(err => console.error(err));
🐘 PHP (cURL)
<?php
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, 'https://api.guiguiya.com/api/hqrb?type=json');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'GET');
$response = curl_exec($ch);
curl_close($ch);
echo $response;
?>
📡 Python (requests)
import requests
url = 'https://api.guiguiya.com/api/hqrb?type=json'
response = requests.request('GET', url)
print(response.json())