sec_uidstringbắt buộc
User sec_uid
https://api.sandbase.ai/v1/api/douyin/app-v3/open-app-to-user-profileGenerates a Douyin app share link that redirects to a specific user profile using a provided user ID and secure user ID.
[
{
"data": {
"sec_uid": "example",
"short_url": "https://v.douyin.com/0hIiLTgIHZ4/",
"status": "success",
"uid": "example"
}
}
]Chọn một ví dụ để nạp đầu vào và kết quả của nó vào playground.
Returns a Douyin short link that opens the Douyin app on a specific user profile. It needs the user's uid and sec_uid.
uid and sec_uid pair resolves to a working profile link.curl -X POST "https://api.sandbase.ai/v1/api/douyin/app-v3/open-app-to-user-profile" \
-H "Authorization: Bearer $SANDBASE_API_KEY" \
-H "Content-Type: application/json" \
-d '{"sec_uid": "MS4wLjABAAAAr52fXcfmzqOZJM_smap9Uuxtm16h8BupkCVaCt89BENq3E91mHCvtz5Z5TkXPHq_", "uid": "92769419069"}'
The result is returned in outputs[0].data.
| Name | Type | Required | Description |
|---|---|---|---|
sec_uid | string | Yes | User sec_uid |
uid | string | Yes | User id |
Real response for the request above, trimmed: lists keep their first item and long strings are cut.
{
"sec_uid": "MS4wLjABAAAAr52fXcfmzqOZJM_smap9Uuxtm16h8BupkCVaCt89BENq3E91mHCvtz5Z5TkXPHq_",
"short_url": "https://v.douyin.com/Ihlbayv701k/",
"status": "success",
"uid": "92769419069"
}
| Field | Meaning |
|---|---|
short_url | Short Douyin link that opens the app on the requested user profile. |
status | Result of the request. The value is success when the link was generated. |
uid | The user ID from the request, echoed back. |
sec_uid | The secure user ID from the request, echoed back. |
uid and sec_uid are required. Send them as strings.$0.001 per successful call. Failed calls are not charged. It is included in the daily free quota of each organization.
Bắt đầu xây dựng
Endpoint API của nền tảng với xác thực và theo dõi mức sử dụng thống nhất.
curl -X POST "https://api.sandbase.ai/v1/api/douyin/app-v3/open-app-to-user-profile" \
-H "Authorization: Bearer $SANDBASE_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"uid": "example",
"sec_uid": "example"
}'Đặt SandBase API key của bạn trong môi trường máy chủ. Các request sử dụng xác thực Bearer.
export SANDBASE_API_KEY="YOUR_API_KEY"Giữ key của bạn trên máy chủ. Không hiển thị trong mã chạy trên trình duyệt.
sec_uidstringbắt buộcUser sec_uid
uidstringbắt buộcUser id
Đây là phản hồi ví dụ đã lưu cho API này; không có request thực nào được gửi khi xem mục này.
[
{
"data": {
"sec_uid": "example",
"short_url": "https://v.douyin.com/0hIiLTgIHZ4/",
"status": "success",
"uid": "example"
}
}
]Khám phá thêm
| API | Giá | Phản hồi |
|---|---|---|
Douyin | $0.001 mỗi lần gọi | JSON |
Douyin | $0.001 mỗi lần gọi | JSON |
Douyin | $0.001 mỗi lần gọi | JSON |
Douyin | $0.001 mỗi lần gọi | JSON |
Douyin | $0.001 mỗi lần gọi | JSON |
Douyin | $0.001 mỗi lần gọi | JSON |
Câu hỏi
Gửi yêu cầu POST đến https://api.sandbase.ai/v1/api/douyin/app-v3/open-app-to-user-profile với khóa API SandBase của bạn trong tiêu đề Authorization (Bearer) và các tham số trong phần thân JSON. Bạn cũng có thể thử trực tiếp trong Playground trên trang này mà không cần viết code.
$0.001 mỗi lần gọi, được tính từ số dư SandBase của bạn. Bạn chỉ bị tính phí cho các lần gọi bạn thực hiện; không có gói đăng ký.
Bắt buộc: sec_uid (string) và uid (string). Bảng Parameters và Playground trên trang này liệt kê mọi trường.
Phản hồi JSON được trả về trong cùng một yêu cầu HTTP (đồng bộ). README trên trang này có ví dụ phản hồi.
Không. Douyin User Profile Share Link chạy thông qua SandBase, nên chỉ cần một API key SandBase là đủ cho endpoint này và mọi API cùng model khác trong danh mục. Bạn không cần đăng ký riêng để có quyền truy cập API của Douyin.