kolIdstringจำเป็น
User kolId, can be obtained from the following interfaces: `douyin/xingtu/xingtu-kolid-by-uid`; `douyin/xingtu/xingtu-kolid-by-sec-user-id`; `douyin/xingtu/xingtu-kolid-by-unique-id`
https://api.sandbase.ai/v1/api/douyin/xingtu/kol-fans-portrait-v1Get the audience portrait of a Douyin KOL from XingTu: fan age, gender, region, device and interest distributions.
[
{
"data": {
"base_resp": {
"status_code": 0,
"status_message": ""
},
"distributions": [
{
"description": "18到23岁居多,占比34%",
"distribution_list": [
{
"distribution_key": "24-30",
"distribution_value": "175378"
},
{
"distribution_key": "50+",
"distribution_value": "82955"
},
{
"distribution_key": "31-40",
"distribution_value": "155328"
},
"… 2 more items in the full response"
],
"image": [
"18到23岁居多"
],
"origin_type": 1,
"type": 2,
"type_display": "年龄分布"
},
{
"description": "一线居多,占比31%",
"distribution_list": [
{
"distribution_key": "三线",
"distribution_value": "169066"
},
{
"distribution_key": "五线",
"distribution_value": "92861"
},
{
"distribution_key": "二线",
"distribution_value": "158147"
},
"… 2 more items in the full response"
],
"image": [
"一线居多"
],
"origin_type": 5,
"type": 32,
"type_display": "城市等级分布"
},
{
"description": "男性居多,占比54%",
"distribution_list": [
{
"distribution_key": "female",
"distribution_value": "403577"
},
{
"distribution_key": "male",
"distribution_value": "474927"
}
],
"image": [
"男性居多"
],
"origin_type": 0,
"type": 1,
"type_display": "性别分布"
},
"… 7 more items in the full response"
],
"last_update_time": "1791283846"
}
}
]เลือกตัวอย่างเพื่อโหลดอินพุตและผลลัพธ์ลงใน playground
Returns the audience portrait of a Douyin creator from XingTu. It needs a XingTu kolId and returns fan distributions such as age, province and city tier.
fansType to compare the general fan base with the fan group or loyal fan portrait.curl -X POST "https://api.sandbase.ai/v1/api/douyin/xingtu/kol-fans-portrait-v1" \
-H "Authorization: Bearer $SANDBASE_API_KEY" \
-H "Content-Type: application/json" \
-d '{"kolId": "7038603512770461703"}'
The result is returned in outputs[0].data.
| Name | Type | Required | Description |
|---|---|---|---|
kolId | string | Yes | User kolId, can be obtained from the following interfaces: douyin/xingtu/xingtu-kolid-by-uid; douyin/xingtu/xingtu-kolid-by-sec-user-id; douyin/xingtu/xingtu-kolid-by-unique-id |
fansType | string | No | Fans Type, supports the following parameters: _1: Fans Portrait - Default; _2: Fans Group Portrait; _5: Iron Fans Portrait |
Real response for the request above, trimmed: lists keep their first item and long strings are cut.
{
"base_resp": {
"status_code": 0,
"status_message": ""
},
"distributions": [
{
"description": "18到23岁居多,占比34%",
"distribution_list": [
{
"distribution_key": "50+",
"distribution_value": "84120"
}
],
"image": [
"18到23岁居多"
],
"origin_type": 1,
"type": 2,
"type_display": "年龄分布"
}
],
"last_update_time": "1793691185"
}
| Field | Meaning |
|---|---|
distributions[] | One block per audience dimension. The response shows age, province and city tier blocks. |
distributions[].type_display | Name of the dimension, for example 年龄分布 (age), 省份分布 (province) or 城市等级分布 (city tier). |
distributions[].description | Short text summary of the block, such as which age group or provinces have the largest share and their percentages. |
distributions[].distribution_list[].distribution_key | Label of one bucket, such as an age range like 24-30, a province name or a city tier like 二线. |
distributions[].distribution_list[].distribution_value | Value for that bucket, returned as a string. It looks like a fan count, and the buckets can be compared with each other. |
distributions[].type / origin_type | Numeric codes for the dimension. Use them to identify a block without matching on the display text. |
distributions[].image[] | Short label text for the block, such as the top age group or top provinces. |
last_update_time | Timestamp of the portrait as a string of Unix seconds. |
base_resp.status_code / base_resp.status_message | Status of the call. 0 with an empty message appears on success. |
kolId from Douyin XingTu KOL ID by User ID, Douyin XingTu kolId Lookup or Douyin XingTu KOL ID by Unique ID.fansType is optional. Use _1 for the fans portrait (default), _2 for the fan group portrait and _5 for the iron fans portrait.description and distribution_key texts, such as province names, come back in Chinese.$0.02 per successful call. Failed calls are not charged.
เริ่มสร้าง
เอ็นด์พอยต์ของ Platform API ที่มีการยืนยันตัวตนและการติดตามการใช้งานแบบรวมศูนย์
curl -X POST "https://api.sandbase.ai/v1/api/douyin/xingtu/kol-fans-portrait-v1" \
-H "Authorization: Bearer $SANDBASE_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"kolId": "7038603512770461703"
}'ตั้งค่า SandBase API key ของคุณในสภาพแวดล้อมฝั่งเซิร์ฟเวอร์ คำขอจะใช้การยืนยันตัวตนแบบ Bearer
export SANDBASE_API_KEY="YOUR_API_KEY"เก็บ key ไว้บนเซิร์ฟเวอร์ อย่าเปิดเผยในโค้ดฝั่งเบราว์เซอร์
kolIdstringจำเป็นUser kolId, can be obtained from the following interfaces: `douyin/xingtu/xingtu-kolid-by-uid`; `douyin/xingtu/xingtu-kolid-by-sec-user-id`; `douyin/xingtu/xingtu-kolid-by-unique-id`
fansTypestringFans Type, supports the following parameters: _1: Fans Portrait - Default; _2: Fans Group Portrait; _5: Iron Fans Portrait
บันทึกตัวอย่างการตอบกลับสำหรับ API นี้; จะไม่มีการส่งคำขอจริงเมื่อเปิดดู
[
{
"data": {
"base_resp": {
"status_code": 0,
"status_message": ""
},
"distributions": [
{
"description": "18到23岁居多,占比34%",
"distribution_list": [
{
"distribution_key": "24-30",
"distribution_value": "175378"
},
{
"distribution_key": "50+",
"distribution_value": "82955"
},
{
"distribution_key": "31-40",
"distribution_value": "155328"
},
"… 2 more items in the full response"
],
"image": [
"18到23岁居多"
],
"origin_type": 1,
"type": 2,
"type_display": "年龄分布"
},
{
"description": "一线居多,占比31%",
"distribution_list": [
{
"distribution_key": "三线",
"distribution_value": "169066"
},
{
"distribution_key": "五线",
"distribution_value": "92861"
},
{
"distribution_key": "二线",
"distribution_value": "158147"
},
"… 2 more items in the full response"
],
"image": [
"一线居多"
],
"origin_type": 5,
"type": 32,
"type_display": "城市等级分布"
},
{
"description": "男性居多,占比54%",
"distribution_list": [
{
"distribution_key": "female",
"distribution_value": "403577"
},
{
"distribution_key": "male",
"distribution_value": "474927"
}
],
"image": [
"男性居多"
],
"origin_type": 0,
"type": 1,
"type_display": "性别分布"
},
"… 7 more items in the full response"
],
"last_update_time": "1791283846"
}
}
]สำรวจเพิ่มเติม
| API | ราคา | การตอบกลับ |
|---|---|---|
Douyin XingTu KOL AudienceAPI นี้ Douyin | $0.02 ต่อการเรียก | JSON |
Douyin | $0.02 ต่อการเรียก | JSON |
Douyin | $0.02 ต่อการเรียก | JSON |
Douyin | $0.02 ต่อการเรียก | JSON |
Douyin | $0.02 ต่อการเรียก | JSON |
Douyin | $0.02 ต่อการเรียก | JSON |
คำถาม
ส่งคำขอ POST ไปที่ https://api.sandbase.ai/v1/api/douyin/xingtu/kol-fans-portrait-v1 โดยใส่ SandBase API key ของคุณใน Authorization header (Bearer) และส่งพารามิเตอร์เป็น JSON body คุณยังสามารถลองใช้ได้ใน Playground บนหน้านี้โดยไม่ต้องเขียนโค้ด
$0.02 ต่อครั้ง คิดจากยอดคงเหลือ SandBase ของคุณ คุณจะถูกเรียกเก็บเฉพาะคำขอที่คุณส่งเท่านั้น ไม่มีค่าสมาชิกรายเดือน
ที่ต้องระบุ: kolId (string). ตัวเลือก: fansType (string). ตาราง Parameters และ Playground ในหน้านี้แสดงทุกฟิลด์
การตอบกลับ JSON ที่ส่งกลับในคำขอ HTTP เดียวกัน (แบบซิงโครนัส) README บนหน้านี้มีตัวอย่างการตอบกลับ
ไม่จำเป็น Douyin XingTu KOL Audience ทำงานผ่าน SandBase ดังนั้น SandBase API key เดียวครอบคลุม endpoint นี้และทุก API กับโมเดลอื่นในแค็ตตาล็อก คุณไม่ต้องสมัครขอสิทธิ์เข้าถึง Douyin API แยกต่างหาก