Answers / Douyin

How can I extract public comments from a Douyin (TikTok China) video via API?

Call GET /v1/douyin/comments?id=VIDEO_ID with your API key, or use get_comments with platform=douyin. PostToData flattens the discussion thread and returns top-level comments, user names, like counts (digg), and timestamps, avoiding the need for mobile signature (X-Gorgon) signing.

Douyin · comments · $0.003 a call · one verified website trial · updated 2026-11-13

Run it live

Calls run only when you press Run. Opening this page does not spend credit.

Loading…

Your results will appear here. Choose a platform and action, then press Run.

Real API calls require verification for one trial, or a signed-in account with prepaid credit.

From code

curl
curl "https://posttodata.com/v1/douyin/comments?id=7234567890123456789&limit=5" -H "Authorization: Bearer YOUR_API_KEY"
Python (requests)
import requests

r = requests.get(
    "https://posttodata.com/v1/douyin/comments",
    headers={"Authorization": "Bearer YOUR_API_KEY"},
    params={"id": "7234567890123456789", "limit": 5},
)
for item in r.json()["data"]["items"]:
    print(item["url"], item.get("text") or item.get("title"))
TypeScript / Node.js
const url = new URL("https://posttodata.com/v1/douyin/comments");
url.searchParams.set("id", "7234567890123456789");
url.searchParams.set("limit", "5");
const res = await fetch(url, {
  headers: { "Authorization": "Bearer YOUR_API_KEY" }
});
const data = await res.json();
console.log(data.data.items);
Go
req, _ := http.NewRequest("GET", "https://posttodata.com/v1/douyin/comments?id=7234567890123456789&limit=5", nil)
req.Header.Set("Authorization", "Bearer YOUR_API_KEY")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)

From your AI

Claude and ChatGPT clients that support OAuth can sign in without pasting a key. Follow the client setup guide. The command below is the API-key option for Claude Code.

Add the MCP server once
claude mcp add --transport http posttodata https://posttodata.com/mcp --header "Authorization: Bearer YOUR_API_KEY"

Then ask

“Extract the top comments for this Douyin video ID using PostToData, summarize viewer feedback, and cite the main points.”

The model calls get_comments with platform douyin.

Response Schema & Data Sample

Normalized JSON output structure returned by PostToData. All fields are strongly typed; missing upstream metrics return null rather than being omitted.

200 OK — JSON Response
{
  "meta": {
    "platform": "douyin",
    "action": "comments",
    "total_items": 1,
    "currency": "USD",
    "price_usd": "0.003"
  },
  "data": {
    "items": [
      {
        "id": "7234567890123456789",
        "type": "comment",
        "url": "https://douyin.com/example_id",
        "published_at": "2026-11-15T12:00:00Z",
        "text": "This matches the public discussion thread on the platform.",
        "author": {
          "id": "user_404",
          "username": "dev_community",
          "name": "Community User",
          "url": null
        },
        "metrics": {
          "likes": 38,
          "comments": 4,
          "shares": null,
          "views": null,
          "score": null
        },
        "parent_id": null
      }
    ]
  }
}

Good to know

  • Douyin comment calls list at $0.003 per successful call.
  • Bypasses complex mobile signing algorithms; returns clean UTF-8 Chinese text.
  • Search costs $0.03, but reading comments is only $0.003 per call.

Full reference in the docs. All Douyin endpoints are on the Douyin API page.

More answers