跳到主要内容

获取文章列表

HTTP request 分页获取 Web3 内容列表。列表接口不返回文章正文。

  • GET /api/v3/content/articles/list

权重(IP): 1

请求头

请求头是否必须描述
locale内容语言,默认 en_US。可选值:ar_ARaz_AZde_DEen_USes_419es_ARes_ESfa_IRfr_FRin_IDit_ITja_JPpl_PLpt_BRpt_PTru_RUuk_UKvi_VNzh_CNzh_TW

请求参数

参数名类型是否必须适用板块描述
sectionString全部一次仅支持一个值:wikinewslearnquestions
categoryStringwikinews分类过滤,最长 64 个字符;用于 news 时与 categoryFilter 互斥。
categoryFilterStringnews排除指定分类,最长 64 个字符;与 category 互斥。
tagNameString全部按关联标签名称过滤。
titleStringwikinewsquestions标题模糊搜索,最长 200 个字符。
prioritySortBooleannews是否按优先级排序,默认 false
levelStringlearnBeginnerIntermediateAdvanced;与 excludeLevel 互斥。
excludeLevelStringlearn排除一个学习等级;与 level 互斥。
excludeDocumentIdStringquestions排除指定 documentId,通常用于相关推荐查询。
excludeContentKeyStringquestions排除 contentKey。
withCountBoolean全部是否返回 totalpages,默认 false
pageInteger全部页码,从 1 开始,默认 1
pageSizeInteger全部每页数量,默认 25,最大 200
populateThumbnailBooleanwikinewslearn是否返回 thumbnail,默认 falsequestions 会忽略该参数。
populateTagListsBoolean全部是否返回 tagLists,默认 false
populateCoinsBoolean全部是否返回 coinsMaps,默认 false

请求示例

curl "https://api-spot.weex.com/api/v3/content/articles/list?section=news&categoryFilter=events&prioritySort=true&page=1&pageSize=10&withCount=true&populateThumbnail=true&populateTagLists=true&populateCoins=true" \
-H "ACCESS-KEY:*******" \
-H "ACCESS-SIGN:*******" \
-H "ACCESS-PASSPHRASE:*****" \
-H "ACCESS-TIMESTAMP:1659076670000" \
-H "locale: zh_CN" \
-H "Content-Type: application/json"

返回参数

字段名类型描述
totalLong总记录数,withCount=false 时为 null
pageInteger当前页码。
pageSizeInteger每页数量。
pagesInteger总页数,withCount=false 时为 null
hasNextPageBoolean是否存在下一页。
itemsArticleListItem[]文章列表。

ArticleListItem

字段名类型适用板块描述
idLong全部内容 ID。
documentIdString全部文档 ID。
v4IdString全部兼容旧版本数据的 ID。
sectionString全部wikinewslearnquestions
titleString全部当前语言标题。
summaryStringwikinewsquestions内容摘要,learnnull
contentKeyString全部内容标识。
enabledBooleanwikinewsquestions是否启用,learnnull
enabledDateLongwikinewsquestions启用时间,UTC 毫秒时间戳;learnnull
categoryStringwikinews内容分类。
imgCategoryStringwikiWiki 图片分类。
linkStringnews外部来源链接。
sourceSiteStringnews来源站点。
outerPicStringnews外部来源图片。
originalSourceUrlStringnews原始来源 URL。
priorityIntegernews新闻优先级。
dateLonglearn学院内容日期,UTC 毫秒时间戳。
levelStringlearnBeginnerIntermediateAdvanced
outerIdString全部外部内容 ID。
outerLocaleIdLongwikilearnquestions外部语言 ID,newsnull
sourceLangStringwikilearnquestions来源语言,newsnull
titleEnString全部英文标题。
translationBooleanwikilearnquestions翻译标识,newsnull
translationStatusStringwikilearnquestions翻译状态,newsnull
thumbnailObjectwikinewslearn板块不支持、未请求或无缩略图时为 null
tagListsArray全部未请求时为 null;请求后没有标签时为空数组。
coinsMapsArray全部未请求时为 null;请求后没有币种时为空数组。
publishedAtLong全部发布时间,UTC 毫秒时间戳。
createdAtLong全部创建时间,UTC 毫秒时间戳。
updatedAtLong全部更新时间,UTC 毫秒时间戳。

返回示例

{
"total": 8102,
"page": 1,
"pageSize": 10,
"pages": 811,
"hasNextPage": true,
"items": [
{
"id": 1811667,
"documentId": "nixq62735vbptclw9y0xti6f",
"v4Id": null,
"section": "news",
"title": "市场新闻标题",
"summary": "市场新闻摘要。",
"contentKey": null,
"enabled": true,
"enabledDate": 1781062934160,
"category": "news-flash",
"imgCategory": null,
"link": "https://example.com/article",
"sourceSite": "rootData",
"outerPic": null,
"originalSourceUrl": "https://example.com/article",
"priority": null,
"date": null,
"level": null,
"outerId": "rootData_2270427",
"outerLocaleId": null,
"sourceLang": null,
"titleEn": "Market news title",
"translation": null,
"translationStatus": null,
"thumbnail": null,
"tagLists": [],
"coinsMaps": [],
"publishedAt": 1781062922400,
"createdAt": 1781062922391,
"updatedAt": 1781062935084
}
]
}