Data APIs · Douyin
Douyin data APIs for AI agents
morigraph has 5 Douyin data APIs that Claude, ChatGPT, Cursor, Codex or your own code can call, including profile, user posts, video and video comments. You need no Douyin developer account or API key, only one morigraph connection. Calls cost from 0.02 credits, about $2.00 for 1,000 calls, paid from one balance.
- APIs
- 5
- Price
- 0.02 to 0.24 credits a call
- Call it from
- MCP, command line and HTTP API
- Needs
- One morigraph connection. No Douyin account or API key
Three ways to call it
Every data API is run by one tool, data_api, with the API's id and its arguments. The example is Douyin Profile.
In your assistant (MCP). Connect once, then ask in plain words
claude mcp add --transport http --scope user morigraph https://morigraph.com/mcp
Use morigraph's Douyin Profile data API with {"secUserId":"MS4wLjABAAAANXSltcLCzDGmdNFI2Q_QixVTr67NiYzjKOIP5s03CAE"} and summarise what comes back.From a terminal or script (CLI)
npx @morigraph/cli@latest login
morigraph call data_api --json-args '{"api":"douyin.profile","input":{"secUserId":"MS4wLjABAAAANXSltcLCzDGmdNFI2Q_QixVTr67NiYzjKOIP5s03CAE"}}'From your own code (HTTP API)
curl https://api.morigraph.com/v1/tools/data_api \
-H "Authorization: Bearer $MORIGRAPH_API_KEY" \
-H "Content-Type: application/json" \
-d '{"api":"douyin.profile","input":{"secUserId":"MS4wLjABAAAANXSltcLCzDGmdNFI2Q_QixVTr67NiYzjKOIP5s03CAE"}}'5 Douyin data APIs
| API | Id | Price |
|---|---|---|
| Douyin Profile | douyin.profile | 0.02 credits a call |
| Douyin User Posts | douyin.user_posts | 0.024 credits a call |
| Douyin Video | douyin.video | 0.02 credits a call |
| Douyin Video Comments | douyin.video_comments | 0.024 credits a call |
| Douyin Video Search | douyin.search_videos | 0.24 credits a call |
Douyin Profile
Look up a public Douyin profile by sec_user_id and return normalized profile statistics.
| Argument | Type | Required | What it is |
|---|---|---|---|
secUserId | string | yes | Douyin sec_user_id for the public account. |
Returns bio followers following image likes nickname posts secUserId shortId uniqueId userId
The call
data_api({"api":"douyin.profile","input":{"secUserId":"MS4wLjABAAAANXSltcLCzDGmdNFI2Q_QixVTr67NiYzjKOIP5s03CAE"}})Douyin User Posts
List public posts from a Douyin user with normalized engagement data and pagination.
| Argument | Type | Required | What it is |
|---|---|---|---|
cursor | string or integer | no | Pagination cursor: pass the previous response's nextCursor; omit for the first page. A raw integer cursor is still accepted. |
limit | integer | no | Requested page size. Values up to 20 are recommended. Default 20. |
secUserId | string | yes | Douyin sec_user_id for the public account. |
sort | newest | most-popular | no | Post order: newest, most-popular. Default "newest". |
Returns authorImage authorNickname authorSecUserId authorUniqueId authorUserId authorVerified caption comments createdUtc durationMs hasMore height id image likes nextCursor posts region saves shares url views width
The call
data_api({"api":"douyin.user_posts","input":{"limit":20,"secUserId":"MS4wLjABAAAANXSltcLCzDGmdNFI2Q_QixVTr67NiYzjKOIP5s03CAE","sort":"newest"}})Douyin Video
Fetch a public Douyin video by share URL with normalized author and engagement data.
| Argument | Type | Required | What it is |
|---|---|---|---|
url | string | yes | Public Douyin video share URL. |
Returns authorImage authorNickname authorSecUserId authorUniqueId authorUserId authorVerified caption comments createdUtc durationMs height id image likes region saves shares url videoUrl views width
The call
data_api({"api":"douyin.video","input":{"url":"https://www.douyin.com/video/6894784055775071503"}})Douyin Video Comments
List public comments on a Douyin video with author and engagement data.
| Argument | Type | Required | What it is |
|---|---|---|---|
cursor | string or integer | no | Pagination cursor: pass the previous response's nextCursor; omit for the first page. A raw integer cursor is still accepted. |
videoId | string | yes | Douyin aweme_id for the video. |
Returns authorImage authorNickname authorSecUserId authorUniqueId authorUserId comments createdUtc hasMore id ipLabel likes nextCursor replyCount text total videoId
The call
data_api({"api":"douyin.video_comments","input":{"videoId":"7448118827402972455"}})Douyin Video Search
Search public Douyin videos by keyword with sorting, time, duration, and content filters.
| Argument | Type | Required | What it is |
|---|---|---|---|
backtrace | string | no | Backtrace token returned by the previous page. |
cursor | string or integer | no | Pagination cursor: pass the previous response's nextCursor; omit for the first page. A raw integer cursor is still accepted. |
duration | 0 | 0-1 | 1-5 | 5-10000 | no | Duration filter in minutes: any, under 1, 1 to 5, or over 5. Default "0". |
publishedWithin | 0 | 1 | 7 | 180 | 0 | 1 | 7 | 180 | no | Publication window in days. Use the canonical JSON integer 0 for any time, 1 for one day, 7 for seven days, or 180 for 180 days; legacy numeric strings remain accepted. Default 0. |
query | string | yes | Keyword to search for. |
searchId | string | no | Search ID returned by the previous page. |
sort | relevance | most-liked | date-posted | no | Sort order: relevance (Douyin's comprehensive ranking), most-liked, date-posted. Default "relevance". |
Returns authorImage authorNickname authorUniqueId authorUserId authorVerified backtrace caption comments createdUtc durationMs hasMore height id image likes nextCursor region saves searchId shares url videoUrl videos views width
The call
data_api({"api":"douyin.search_videos","input":{"duration":"0","publishedWithin":0,"query":"机器人","sort":"relevance"}})Good to know
- The price shown is the usual one. A call can cost more when the first source fails and another serves it; the most it can cost is shown beside each API, and
max_creditssets your own limit. - These APIs return public data. What you may do with it depends on the platform's terms and the privacy law where you operate, and that responsibility is yours.
- A failed call is not charged.
When to choose something else
Choose a provider that specialises in Douyin data when you need it at high volume, on a schedule, or as bulk exports: you will get volume pricing and more control. Choose the platform's official API when you need data from your own account. These APIs are for an agent that needs an answer now, alongside other tools on the same balance.
Questions
Do I need a Douyin API key or developer account?
No. morigraph supplies the access. You connect morigraph once to your assistant, or use one morigraph API key from your own code, and call any of the 5 APIs on this page.
What does Douyin data cost through morigraph?
Between 0.02 and 0.24 credits a call depending on the API, where a credit is about 10 cents. That is from about $2.00 for 1,000 calls. You pay per call from one balance, with no separate subscription.
Can Claude, ChatGPT or Cursor get Douyin data?
Yes. Add morigraph as an MCP server, sign in once, then ask in plain words. Your assistant finds the right API with one search and runs it with one call.
Which Douyin data APIs are available?
Douyin Profile, Douyin User Posts, Douyin Video, Douyin Video Comments and Douyin Video Search.
Prices and availability read from the production service on . A credit is about 10 cents of tool use; see pricing. Your assistant can quote the exact cost before a paid call.