Sand AISand AI MAGI-2MAGI-2 现已上线 SandBase:支持原生音频的 1080p 视频立即试用

TikTok Livestream Homepage Recommendations

API 文档
https://api.sandbase.ai/v1/api/tiktok/web/live-recommend

Returns recommended livestreams from the TikTok homepage for a specified category tag. Requires selecting a category tag to retrieve relevant active broadcast recommendations.

价格
$0.001美元 / 次调用
方法
POST
响应
JSON
参数
1 个必填 · 0 个可选

Playground

输入
输出示例
响应outputs · 570 B · 20 行
[
  {
    "data": {
      "cookie": "tt_chain_token=0k5cdiqY7uSA4maNu10+1w==;",
      "extra": {
        "banner": {},
        "cost": 11,
        "log_pb": {
          "impr_id": "20260928164204C897FED4A8A211C3C344",
          "session_id": 7690503684375580000
        },
        "max_time": 1790584924619,
        "now": 1790584924619,
        "unread_extra": "{\"channel_id\":1111006,\"req_from\":\"pc_web_game_sub_feed_refresh\",\"gen_time\":1790584924,\"is_backup\":0}"
      },
      "status_code": 0,
      "tt_chain_token": "0k5cdiqY7uSA4maNu10+1w=="
    }
  }
]

示例

选择一个示例,将其输入和结果加载到 playground 中。

API README

TikTok Livestream Homepage Recommendations API

Returns a list of recommended livestream rooms from the TikTok homepage for one live category tag. It needs a related_live_tag value such as VALORANT.

Use cases

  • Pull the current livestream cards shown for a game category such as VALORANT.
  • Collect cover images of recommended live rooms to show in an external dashboard.
  • Check whether more recommendations exist for a tag before you request another batch.
  • Store the rid of each result to match a recommendation batch with a later analysis.

Request

curl -X POST "https://api.sandbase.ai/v1/api/tiktok/web/live-recommend" \
  -H "Authorization: Bearer $SANDBASE_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"related_live_tag": "VALORANT"}'

The result is returned in outputs[0].data.

Parameters

NameTypeRequiredDescription
related_live_tagstringYesRelated live tag (live category). The available values are not fixed; call /fetch_live_recommend_tabs first to get the currently available tag list, then pick one to pass in.

Example response

Real response for the request above, trimmed: lists keep their first item and long strings are cut.

{
  "cookie": "tt_chain…",
  "data": [
    {
      "data": {
        "age_restricted": {},
        "anchor_tab_type": 7,
        "blurred_cover": {
          "avg_color": "#FAE6DC",
          "height": 100,
          "uri": "tos-maliva-avt-0068/e1c653d347180dc3f095dd5185877b22",
          "url_list": [
            "https://p16-common-sign.tiktokcdn.com/tos-maliva-avt-0068/e1c653d347180dc3f095dd…"
          ],
          "width": 100
        },
        "client_version": 13800,
        "commerce_info": {},
        "cover": {
          "uri": "720x720/tos-maliva-avt-0068/e1c653d347180dc3f095dd5185877b22",
          "url_list": [
            "https://p16-common-sign.tiktokcdn.com/tos-maliva-avt-0068/e1c653d347180dc3f095dd…"
          ]
        },
        "cover_type": 1,
        "enlarge_view_info": {
          "enabler_enlarge_view": true,
          "landscape_view": 1,
          "portrait_view": 1
        }
      },
      "flare_info": {},
      "rid": "202611031544263DDB5AFB9E6F854E228A",
      "room_event_tracking": "pc_web_game_sub_feed_refresh:1111006:normal:1:0",
      "type": 1
    }
  ],
  "extra": {
    "banner": {},
    "cost": 113,
    "has_more": true,
    "log_pb": {
      "impr_id": "202611031544263DDB5AFB9E6F854E228A",
      "session_id": 7703847894004796178
    },
    "max_time": 1793691866273,
    "now": 1793691866273,
    "total": 12,
    "unread_extra": "{\"channel_id\":1111006,\"req_from\":\"pc_web_game_sub_feed_refresh\",\"gen_time\":17936…"
  },
  "status_code": 0,
  "tt_chain_token": "0k5cdiqY…"
}

Response fields

FieldMeaning
data[].data.cover.url_listImage URLs for the 720x720 cover of the livestream. Each entry points to the same image in a different CDN host or format (webp or jpeg).
data[].data.blurred_cover.url_listURLs of a small 100x100 blurred version of the cover.
data[].data.blurred_cover.avg_colorAverage color of the blurred cover as a hex code. Use it as a placeholder color while the image loads.
data[].data.feed_room_label.url_listImage URLs for a label shown on the room card. It appears only on some items.
data[].data.anchor_tab_typeNumeric tab type for the livestream entry. The response shows 7 for all items.
data[].ridRequest ID shared by all items in the same response. It matches extra.log_pb.impr_id.
data[].room_event_trackingTracking string for the feed that returned the item. It includes the feed name pc_web_game_sub_feed_refresh.
extra.has_moreShows true when more recommendations are available.
extra.totalTotal count reported for this response.
extra.now / extra.max_timeTimestamps in milliseconds, in the same format as 1793691866273.

Notes

  • Get valid related_live_tag values from TikTok Stream Recommendation Tabs first. The list of tags changes, so do not hard-code it.
  • The only request parameter is related_live_tag. The response gives extra.has_more but this API has no pagination parameter.
  • Each item in data[] wraps its details in a second data object, so the full path is data[].data.
  • The response also returns tt_chain_token and cookie at the top level.

Pricing

$0.001 per successful call. Failed calls are not charged. It is included in the daily free quota of each organization.

探索更多

相关 APIs

全部 APIs
API价格响应
TikTok$0.001 每次调用JSON
TikTok$0.001 每次调用JSON
TikTok$0.001 每次调用JSON
TikTok$0.001 每次调用JSON
TikTok$0.001 每次调用JSON
TikTok$0.05 每次调用JSON

指南:TikTok API pricing: official access vs per-call dataBest TikTok API in 2026: Pricing Compared

问题

常见问题

如何使用 TikTok Livestream Homepage Recommendations API?

向 https://api.sandbase.ai/v1/api/tiktok/web/live-recommend 发送 POST 请求,在 Authorization 请求头中使用您的 SandBase API key(Bearer),并将参数作为 JSON 请求体传入。您也可以直接在本页的 Playground 中试用,无需编写代码。

TikTok Livestream Homepage Recommendations API 的价格是多少?

每次调用 $0.001,从您的 SandBase 余额中扣费。您只需为实际调用付费;无需订阅。

TikTok Livestream Homepage Recommendations API 接受哪些参数?

必填:related_live_tag (string)。 Parameters 表和本页的 Playground 列出了每个字段。

TikTok Livestream Homepage Recommendations API 返回什么?

在同一个 HTTP 请求中返回的 JSON 响应(同步)。 本页的 README 包含一个示例响应。

我需要 TikTok 开发者账户或 API key 吗?

不需要。TikTok Livestream Homepage Recommendations 通过 SandBase 运行,因此一个 SandBase API key 即可覆盖此端点以及目录中的其他所有 API 和模型。您无需单独申请 TikTok API 访问权限。