API 文档
NewClaw API
通过 API 获取 AI 新闻、Twitter 动态和热点数据
基础 URL
https://newclaw.com/apiAPI 端点
GET
/api/news获取 AI 新闻列表
参数
| 名称 | 类型 | 必需 | 描述 |
|---|---|---|---|
| limit | number | 否 | 返回数量,默认 20 |
| category | string | 否 | 分类筛选 |
| isHot | boolean | 否 | 仅热门,默认 false |
响应示例
{
"success": true,
"data": [
{
"id": "1",
"title": "...",
"chineseTitle": "...",
"category": "AI/ML",
"source": "OpenAI Blog",
"publishedAt": "2026-02-16T05:24:37.010Z",
"isHot": true,
"aiScores": {
"relevance": 10,
"quality": 9,
"timeliness": 10,
"overall": 9.7
}
}
]
}GET
/api/twitter获取 Twitter AI 动态
响应示例
{
"success": true,
"tweets": [
{
"id": "tw_1",
"content": "...",
"author": {
"name": "Andrej Karpathy",
"username": "karpathy",
"verified": true
},
"likes": 15420,
"publishedAt": "2026-02-16T05:24:37.011Z",
"aiAnalysis": {
"chineseSummary": "...",
"importance": "high"
}
}
]
}GET
/api/sources获取 RSS 源统计信息
{
"success": true,
"stats": {
"total": 116,
"english": 79,
"chinese": 37,
"highPriority": 21,
"mediumPriority": 64,
"lowPriority": 31
}
}使用示例
cURL
curl -X GET "https://newclaw.com/api/news?limit=10"JavaScript
const response = await fetch('https://newclaw.com/api/news?limit=10');
const data = await response.json();
console.log(data.data);