Platforms
Douyin
Read Douyin accounts and their posts and series, posts with their comments and replies, hashtags, sounds, the hot search list, recommended posts and live rooms.
Read accounts with their latest posts and series, a post with its comments, replies and posts like it, hashtags and sounds, the hot search list, what Douyin recommends and live rooms.
Quick Reference
| Property | Value |
|---|---|
| Endpoints | 15 |
| Accounts by | secUid or url |
| Posts by | url or id |
| Share links | v.douyin.com/…, wherever a url is taken |
| An account's posts | Its latest, about 10 |
| Comments a page | 20 |
| Replies | The first 50 |
| Transcripts | No |
| Counts | Likes, comments, shares and saves; no plays |
Accounts
| Endpoint | Returns | Credits |
|---|---|---|
profile | An account with its followers, likes and post count. | 2 |
profile/playlists | An account's series (合集). | 1 |
profile/posts | An account's latest posts, about 10. | 2 |
live | A live room, on air or not. | 1 |
Read an Account
import { SocialAPI } from "@socialapihq/sdk";
const client = new SocialAPI({ apiKey: process.env.SOCIALAPI_API_KEY });
const { data } = await client.douyin.profile({ secUid: "MS4wLjABAAAA8U_l6rBzmy7bcy6xOJel4v0RzoR_wfAubGPeJimN__4" });{
"data": {
"id": "104255897823",
"username": "rmrbxmt",
"displayName": "人民日报",
"bio": "参与、沟通、记录时代。",
"avatarUrl": "https://p3-pc.douyinpic.com/aweme/1080x1080/aweme-avatar/tos-cn-avt-0015_21b4383e542b8991bcd33d33eeda7d8d.jpeg?from=2956013662",
"url": "https://www.douyin.com/user/MS4wLjABAAAA8U_l6rBzmy7bcy6xOJel4v0RzoR_wfAubGPeJimN__4",
"verified": true,
"private": false,
"followers": 203912912,
"following": 35,
"likes": 19445869999,
"posts": 12986,
"externalUrl": null,
"createdAt": null,
"ext": {
"secUid": "MS4wLjABAAAA8U_l6rBzmy7bcy6xOJel4v0RzoR_wfAubGPeJimN__4",
"shortId": null,
"verification": "人民日报官方账号",
"ipLocation": null,
"live": false,
"series": 0,
"coverUrl": "https://p3-pc-sign.douyinpic.com/obj/douyin-user-image-file/a0fed342d45f11ee57830326fa8bb1b1?lk3s=93de098e&x-expires=1795971600&x-signature=BQcW6nFUv7nzrCmTA6wyIHE29%2BM%3D&from=2480802190"
}
}
}- An account's
followers,following,likesandpostsare exact. - Its
usernameis its Douyin id (抖音号) where it chose one, else its short number;ext.secUidis what its link names. - Its
extalso has Douyin's verification, where Douyin shows it posting from and whether it is live.
Posts and Series
- An account's posts are its latest, about 10, with the ones it pinned (
ext.pinned): the one page Douyin shows a visitor. They cost 2 credits each. - Series (合集) are an account's collections; a series' posts page to its last episode, 10 at a time.
Live Rooms
- A room is read by its link (
live.douyin.com/<n>) or that number. - On air, it has its title, viewers, likes and its stream's playlist, which expires.
- Off air,
liveisfalse. A room is kept for a minute.
Posts
| Endpoint | Returns | Credits |
|---|---|---|
playlist/posts | A series' posts, in order, 10 a page. | 1 |
post | One post with its likes, comments, shares and saves. | 2 |
post/comments | A post's comments, 20 a page. | 1 |
post/comment/replies | A comment's replies, up to 50. | 1 |
post/related | Posts like a post, 10. | 1 |
Post Fields
- The
statshave likes, comments, shares and saves. Douyin shows no play counts, soviewsisnull. - A post's
ext.kindisvideoorimages(a photo set, whose pictures are itsmedia). - A video's
mediahas its cover, size and length; its file is signed for the address that asked, so no link is given. - Its
exthas its title, its sound, its series and Douyin's categories for it.
Comments and Replies
Comments come 20 a page, each with its author, likes, reply count and where it was written from (ext.ipLabel), at 1 credit a comment. Replies are read by the comment's id as commentId: the first 50, which is what Douyin shows a visitor, each naming its comment as parentId and the reply it answers as ext.replyTo, at 1 credit a reply.
Discovery
| Endpoint | Returns | Credits |
|---|---|---|
hashtag | A hashtag with its views. | 1 |
search/suggestions | What Douyin's search box suggests for a query. | 1 |
sound | A sound with the number of posts using it. | 1 |
sound/posts | Posts using a sound. | 1 |
trending | Douyin's hot search list, about 50. | 10 |
trending/posts | Recommended posts, 10, or a category's. | 1 |
- Trending is Douyin's hot search list (抖音热榜), about 50 searches with their rank, heat and page;
boardpickshot,entertainment,societyorchallenge(hashtags). It costs 10 credits. - Trending posts are what Douyin recommends now, 10 at a time, from its home page or a
category:food,games,anime,sports,music,knowledge,film,carsorpets. - A hashtag has its views; a sound the number of posts using it, and its posts.
- Search suggestions are what Douyin's search box offers for a query.