BBC Sport News
BBC Sport News 用于获取 BBC Sport 页面中的体育资讯列表数据。
- 按体育分类抓取 BBC Sport 列表页内容
- 支持按地区发起请求
- 返回文章、视频、直播等内容卡片
- 适用于抓取首页或具体体育分类下的新闻流
使用 XCrawl 获取 BBC Sport News
使用方式
curl -s -X POST 'https://run.xcrawl.com/v1/data' \
-H 'Authorization: Bearer $XCRAWL_API_KEY'\
-H 'Content-Type: application/json' \
-d '{
"engine": "bbc_sport_news",
"location": "US",
"sport_type": "football"
}'请求参数说明:
engine固定为bbc_sport_newslocation用于指定请求地区sport_type用于指定体育分类,例如football、cricket、formula1
响应示例
{
"result": [
{
"url": "https://www.bbc.com/sport/",
"topic_title": "BBC Sport",
"description": "Sports news and live sports coverage including scores, results, video, audio and analysis...",
"item_count": 72,
"video_count": 20,
"live_count": 3,
"results": [
{
"position": 1,
"headline": "Premier League news conferences: Slot 'feels support'; Howe '100% committed'",
"summary": "All the latest from Premier League managers...",
"url": "https://www.bbc.com/sport/football/live/cy41pmdnwwlt",
"content_type": "live",
"attribution": "Football",
"image_url": "https://ichef.bbci.co.uk/ace/standard/480/..."
}
]
}
]
}参数说明
必填参数
| 参数 | 类型 | 说明 |
|---|---|---|
location | string | 指定请求地区。 |
sport_type | string | 指定体育分类。 |
参数补充说明
location默认值为USlocation支持多个地区值,例如US、HK、CA、GB、JPsport_type支持football、cricket、formula1、rugby-union、rugby-league、tennis、golf、boxing、athletics
响应字段
| 字段 | 类型 | 说明 |
|---|---|---|
url | string | 抓取的 BBC Sport 页面链接。 |
base_url | string | 用于补全相对链接的站点基础地址。 |
page_title | string | 页面标题。 |
canonical_url | string | 页面声明的规范链接。 |
route | string | 页面内部路由值。 |
page_path | string | 归一化后的页面路径。 |
sport_key | string | 当前体育栏目标识。 |
topic_title | string | 页面标题或专题标题。 |
description | string | 页面级描述文本。 |
language | string | 页面语言代码。 |
item_count | number | 返回内容总数。 |
video_count | number | 视频内容数量。 |
live_count | number | 直播内容数量。 |
result_count | number | 结果对象数量。 |
meta | object | 页面级元数据。 |
results | array | 内容卡片列表。 |
结果项字段
results[] 中每一项通常包含以下字段:
| 字段 | 类型 | 说明 |
|---|---|---|
position | number | 结果位置,从 1 开始。 |
source_kind | string | 来源容器类型。 |
group_key | string | 内容容器标识。 |
group_title | string | 内容容器标题。 |
headline | string | 内容标题。 |
summary | string | 内容摘要。 |
url | string | 内容链接。 |
path | string | 内容相对路径。 |
content_type | string | 内容类型,例如 article、video、live。 |
promo_type | string | 原始卡片类型。 |
item_type | string | 原始内容类型。 |
service | string | 服务标识,通常为 sport。 |
urn | string | 内容资源标识。 |
content_title | string | 独立内容标题字段。 |
is_live | boolean | 是否为直播内容。 |
last_published | string | 原始发布时间文本。 |
duration_seconds | number | 视频时长,单位为秒。 |
subitem_count | number | 子项数量。 |
attribution | string | 归属分类或栏目。 |
attribution_url | string | 归属分类链接。 |
posted_label | string | 发布时间标签。 |
posted_text | string | 简短发布时间文本。 |
posted_alt_text | string | 展开的发布时间文本。 |
comments | number | 评论数量。 |
comments_url | string | 评论链接。 |
image_url | string | 主图链接。 |
image_alt | string | 图片替代文本。 |
image_width | number | 图片宽度。 |
image_height | number | 图片高度。 |
image_loading | string | 图片加载策略。 |
image_tracking_id | string | 图片跟踪标识。 |
image_srcset | string | 响应式图片 srcset 信息。 |
