Douyin-Search-API
获取综合搜索 V3/Fetch general search V3
Changed on[中文]
用途:
- 获取抖音综合搜索结果(V3 版本),返回视频、用户、相关搜索词等混合卡片。
- 相比 V1/V2 不支持排序与筛选条件,但翻页参数更简单,响应结构统一(config + items + pagination)。
备注:
- 首次请求 offset 传 0、page 传 1,search_id 与 backtrace 传空字符串。
- 翻页时把上一次响应 data.pagination 里的 offset、search_id、backtrace 原样传回,并把 page 加 1。
- data.pagination.has_more 为 0 表示已经到最后一页。
- 每页固定 10 条,不支持指定数量。page 上限为 200,超出会返回参数错误。
参数:
- keyword: 搜索关键词,如 "猫咪"
- offset: 翻页游标(首次请求传 0)
- page: 页码,取值 1~200(首次请求传 1)
- search_id: 搜索ID(首次请求传空字符串)
- backtrace: 翻页回溯标识(首次请求传空字符串)
请求体示例:
payload = {
"keyword": "猫咪",
"offset": 0,
"page": 1,
"search_id": "",
"backtrace": ""
}
返回(部分常用字段,实际返回字段更多,一切以实际响应为准):
- config: 本次搜索的配置信息(透传)
- items[]: 搜索结果卡片列表(已按卡片类型解包)
- 视频卡片:
- aweme_id: 视频ID
- desc: 视频描述
- create_time: 发布时间(时间戳)
- author: 作者信息(uid、sec_uid、nickname、avatar_thumb.url_list 等)
- video: 播放信息(play_addr.url_list、cover.url_list、duration 等)
- statistics: 互动数据(digg_count、comment_count、share_count、play_count)
- share_url: 视频分享链接
- 相关搜索词卡片: 推荐词条列表
- 其他类型卡片原样透传,不做丢弃
- 视频卡片:
- pagination: 翻页信息
- offset: 下一页的翻页游标(原样传回)
- cursor: 同 offset
- search_id: 下一页的搜索ID(原样传回)
- backtrace: 下一页的回溯标识(原样传回)
- has_more: 是否还有更多数据(1=有,0=无)
- next_page: 下一页页码(没有更多数据时为 null)
[English]
Purpose:
- Fetch Douyin general search results (V3), returning mixed cards: videos, users, related words, etc.
- Compared with V1/V2 it has no sorting or filtering options, but pagination is simpler and the response structure is unified (config + items + pagination).
Notes:
- For the first request set offset to 0, page to 1, and search_id / backtrace to empty strings.
- For pagination, pass back offset, search_id and backtrace from data.pagination of the previous response, and increment page by 1.
- data.pagination.has_more = 0 means the last page has been reached.
- Page size is fixed at 10 and cannot be changed. page is capped at 200; exceeding it returns a parameter error.
Parameters:
- keyword: Search keyword, e.g., "cat"
- offset: Offset cursor (0 for the first request)
- page: Page number, 1-200 (1 for the first request)
- search_id: Search ID (empty for the first request)
- backtrace: Backtrace identifier (empty for the first request)
Request Body Example:
payload = {
"keyword": "cat",
"offset": 0,
"page": 1,
"search_id": "",
"backtrace": ""
}
Response (common fields, actual response may contain more fields):
- config: Search configuration returned by the upstream (passed through)
- items[]: Result cards (already unwrapped by card type)
- Video card:
- aweme_id: Video ID
- desc: Video description
- create_time: Publish timestamp
- author: Author info (uid, sec_uid, nickname, avatar_thumb.url_list, etc.)
- video: Playback info (play_addr.url_list, cover.url_list, duration, etc.)
- statistics: Interaction data (digg_count, comment_count, share_count, play_count)
- share_url: External share link
- Related-words card: list of suggested keywords
- Unknown card types are passed through as-is
- Video card:
- pagination: Pagination info
- offset: Offset cursor for the next page (pass back as-is)
- cursor: Same as offset
- search_id: Search ID for the next page (pass back as-is)
- backtrace: Backtrace for the next page (pass back as-is)
- has_more: Whether more results are available (1=Yes, 0=No)
- next_page: Next page number (null when there are no more results)
post/api/v1/douyin/search/fetch_general_search_v3
Request
- Base URLhttps://api.tikhub.io (the document declares no server; this is the origin it was published from)
- AuthHTTP bearer
Request body
Response
Successful Response
Changes
- info
added the optional property
//to the response with the status - info
added the optional property
//to the response with the status
- info
- info
endpoint added
- info