short_idstring必填
User Short ID
https://api.sandbase.ai/v1/api/douyin/web/user-profile-by-short-idRetrieves Douyin web user profile details using an account short ID. Returns profile metadata, title information, and engagement counters.
[
{
"data": {
"data": {
"auth_cert_info": "",
"data": [],
"enter_mode": 0,
"enter_room_id": "",
"qrcode_url": "",
"room_status": 2,
"shark_decision_conf": "",
"similar_rooms": [],
"user": {
"avatar_thumb": {
"url_list": [
"https://p11.douyinpic.com/aweme/100x100/aweme-avatar/tos-cn-avt-0015_58421a13a73dd36d11611cbc679069e2.jpeg?from=3067671334",
"https://p3.douyinpic.com/aweme/100x100/aweme-avatar/tos-cn-avt-0015_58421a13a73dd36d11611cbc679069e2.jpeg?from=3067671334",
"https://p26.douyinpic.com/aweme/100x100/aweme-avatar/tos-cn-avt-0015_58421a13a73dd36d11611cbc679069e2.jpeg?from=3067671334"
]
},
"follow_info": {
"follow_status": 0,
"follow_status_str": "0"
},
"foreign_user": 0,
"id_str": "3781946367821918",
"nickname": "wanggggchen",
"open_id_str": "",
"sec_uid": "MS4wLjABAAAA9VpPOwQ4lckVN3BVC3KzqITqf_2ohUtDxeFQQFgbLy2BwOsROlX_ba2EVd_NUAIy"
}
},
"extra": {
"now": 1787219000195
},
"status_code": 0
}
}
]選擇一個範例,將其輸入與結果載入 playground。
This API takes a Douyin account short ID and returns the live room data linked to that account, along with a short user block. The response includes the room title, room status, and the account's nickname and sec_uid.
sec_uid so you can call other user endpoints.room_status and the room status value.curl -X POST "https://api.sandbase.ai/v1/api/douyin/web/user-profile-by-short-id" \
-H "Authorization: Bearer $SANDBASE_API_KEY" \
-H "Content-Type: application/json" \
-d '{"short_id": "2941976066"}'
The result is returned in outputs[0].data.
| Name | Type | Required | Description |
|---|---|---|---|
short_id | string | Yes | User Short ID |
Real response for the request above, trimmed: lists keep their first item and long strings are cut.
{
"data": {
"auth_cert_info": "",
"data": [
{
"AnchorABMap": {},
"admin_user_ids": [],
"admin_user_ids_str": [],
"admin_user_open_ids": [],
"admin_user_open_ids_str": [],
"fansclub_msg_style": 0,
"follow_msg_style": 0,
"gift_msg_style": 0,
"has_commerce_goods": false,
"id_str": "7561789775678769966",
"like_count": 0,
"linker_map": {}
}
],
"enter_mode": 0,
"enter_room_id": "7561789775678769966",
"partition_road_map": {},
"qrcode_url": "",
"room_status": 2,
"shark_decision_conf": "",
"similar_rooms": [],
"user": {
"avatar_thumb": {
"url_list": [
"https://p11.douyinpic.com/aweme/100x100/aweme-avatar/tos-cn-avt-0015_3beaaeb52d3…"
]
},
"follow_info": {
"follow_status": 0,
"follow_status_str": "0"
},
"foreign_user": 0,
"id_str": "92769419069",
"nickname": "抖音作者助手",
"open_id_str": "",
"sec_uid": "MS4wLjABAAAA-hAqMwU4p1xu2AlQSM4R38D7DhTKGOk6d-zYU_o0LxY"
}
},
"extra": {
"now": 1793691154702
},
"status_code": 0
}
| Field | Meaning |
|---|---|
data.user.nickname | Display name of the account. |
data.user.sec_uid | Encrypted user ID of the account. Other Douyin user endpoints accept this kind of ID. |
data.user.id_str | Numeric user ID of the account, returned as a string. |
data.user.avatar_thumb.url_list[] | Image URLs for the account's 100x100 avatar. Each entry points to a different image host. |
data.user.follow_info.follow_status | Follow state between the request context and the account. It is 0 in this response. |
data.enter_room_id | ID of the live room linked to the account. |
data.room_status | Numeric status of the live room. It is 2 in this response. |
data.data[].title | Title of the live room. |
data.data[].id_str | ID of the live room, returned as a string. It matches data.enter_room_id here. |
data.data[].like_count / data.data[].user_count_str | Like count and viewer count for the live room. Both are 0 in this response. |
short_id as a string, for example 2941976066.data.user.sec_uid value can be passed to Douyin User Profile (Web) to get a fuller profile.sec_uid to list the account's videos.$0.001 per successful call. Failed calls are not charged. It is included in the daily free quota of each organization.
開始建置
具備統一驗證與用量追蹤的平台 API 端點。
curl -X POST "https://api.sandbase.ai/v1/api/douyin/web/user-profile-by-short-id" \
-H "Authorization: Bearer $SANDBASE_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"short_id": "example"
}'請將您的 SandBase API 金鑰設定在伺服器環境中。請求使用 Bearer 驗證。
export SANDBASE_API_KEY="YOUR_API_KEY"請將金鑰保留在伺服器端,不要在瀏覽器程式碼中公開。
short_idstring必填User Short ID
這是此 API 的已儲存範例回應;檢視時不會發出即時請求。
[
{
"data": {
"data": {
"auth_cert_info": "",
"data": [],
"enter_mode": 0,
"enter_room_id": "",
"qrcode_url": "",
"room_status": 2,
"shark_decision_conf": "",
"similar_rooms": [],
"user": {
"avatar_thumb": {
"url_list": [
"https://p11.douyinpic.com/aweme/100x100/aweme-avatar/tos-cn-avt-0015_58421a13a73dd36d11611cbc679069e2.jpeg?from=3067671334",
"https://p3.douyinpic.com/aweme/100x100/aweme-avatar/tos-cn-avt-0015_58421a13a73dd36d11611cbc679069e2.jpeg?from=3067671334",
"https://p26.douyinpic.com/aweme/100x100/aweme-avatar/tos-cn-avt-0015_58421a13a73dd36d11611cbc679069e2.jpeg?from=3067671334"
]
},
"follow_info": {
"follow_status": 0,
"follow_status_str": "0"
},
"foreign_user": 0,
"id_str": "3781946367821918",
"nickname": "wanggggchen",
"open_id_str": "",
"sec_uid": "MS4wLjABAAAA9VpPOwQ4lckVN3BVC3KzqITqf_2ohUtDxeFQQFgbLy2BwOsROlX_ba2EVd_NUAIy"
}
},
"extra": {
"now": 1787219000195
},
"status_code": 0
}
}
]探索更多
| API | 價格 | 回應 |
|---|---|---|
Douyin | 每次呼叫 $0.001 | JSON |
Douyin | 每次呼叫 $0.001 | JSON |
Douyin | 每次呼叫 $0.001 | JSON |
Douyin | 每次呼叫 $0.001 | JSON |
Douyin | 每次呼叫 $0.001 | JSON |
Douyin | 每次呼叫 $0.03 | JSON |
問題
使用 POST 請求將您的 SandBase API 金鑰放在 Authorization 標頭(Bearer)中,並以 JSON 主體傳入參數,即可呼叫 https://api.sandbase.ai/v1/api/douyin/web/user-profile-by-short-id。您也可以直接在本頁的 Playground 試用,不必撰寫程式碼。
每次 $0.001,並從您的 SandBase 餘額中扣款。您只會為實際發出的呼叫付費;沒有訂閱方案。
必要:short_id (string)。 本頁的 Parameters 表格與 Playground 會列出每個欄位。
在同一個 HTTP 請求中回傳的 JSON 回應(同步)。 本頁的 README 包含範例回應。
不需要。Douyin User Profile by Short ID 是透過 SandBase 運作,因此一組 SandBase API 金鑰即可使用此端點以及目錄中的其他所有 API 和模型。您不需要另外申請 Douyin API 存取權。