# Douyin（抖音） Data API - Chinese TikTok Data API (`nourishing_fort/douyin-data-api`) Actor

Complete Douyin (抖音) data API for KOL analysis, brand monitoring, social listening, and trend research. Returns clean JSON with video details, comments, user profiles, danmaku, and more. Free tier - 100 events/month.

- **URL**: https://apify.com/nourishing\_fort/douyin-data-api.md
- **Developed by:** [quan qing](https://apify.com/nourishing_fort) (community)
- **Categories:** Social media, Lead generation, Videos
- **Stats:** 3 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $4.99 / 1,000 results

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.

Learn more: https://docs.apify.com/platform/actors/running/actors-in-store#pay-per-event

## What's an Apify Actor?

Actors are web data automations that power AI and operations. They run on the Apify platform to scrape websites, process data, connect APIs, and automate workflows.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.
Actors are written with capital "A".

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.
The best way to integrate Actors is as follows.

- **AI agents and MCP clients** — the [Apify MCP server](https://docs.apify.com/integrations/mcp.md) at `https://mcp.apify.com` (remote, streamable HTTP, OAuth on first use).
- **Agentic workflows and local Actor development** — [Agent Skills](https://apify.com/.well-known/agent-skills/index.json) with the [Apify CLI](https://docs.apify.com/cli/docs.md): `npm install -g apify-cli`, then `apify login`.
- **JavaScript/TypeScript projects** — the official [JS/TS client](https://docs.apify.com/api/client/js/docs.md): `npm install apify-client`.
- **Python projects** — the official [Python client](https://docs.apify.com/api/client/python/docs.md): `pip install apify-client`.
- **Any other language** — the [REST API](https://docs.apify.com/api/v2.md).

For usage examples, see the [API](#api) section below.

For more details, see Apify documentation as [Markdown index](https://docs.apify.com/llms.txt) and [Markdown full-text](https://docs.apify.com/llms-full.txt).

# README

## Douyin Data API — Chinese TikTok Data

> **9 verified Douyin (抖音) data actions for KOL analysis, brand monitoring, social listening, and trend research.**
>
> Clean JSON. No login. No setup. Just run.

***

### 🎯 What You Get

A complete Douyin (Chinese TikTok) data layer in one Actor:

- ✅ **Video search & metadata** — keyword search, full video details, real-time stats
- ✅ **Comments & danmaku** — regular comments and live bullet comments (弹幕)
- ✅ **User analytics** — profiles, video lists, user search
- ✅ **Comprehensive search** — mixed content search (login-aware)
- ✅ **Clean JSON output** — consistent schema across all endpoints
- ✅ **Pagination built-in** — request up to 1,000 items per run with auto-cursor handling

***

### 🚀 Quick Start

No setup, no API keys, no configuration. Just run.

#### Web Console

1. Open this Actor page on Apify Store
2. Click **Try actor** → fill in the parameters (e.g. `action`, `keyword`, `max_items`)
3. Click **Start** → results appear in **Dataset** tab

#### Python (API)

```python
from apify_client import ApifyClient

client = ApifyClient(token="YOUR_APIFY_TOKEN")
run = client.actor("nourishing_fort/douyin-data-api").call(run_input={
    "action": "search_video",
    "keyword": "World Cup",
    "max_items": 50,
})
items = client.dataset(run["defaultDatasetId"]).list_items().items
```

#### MCP / AI Agent

```json
{
  "mcpServers": {
    "apify": {
      "url": "https://mcp.apify.com/?tools=nourishing_fort/douyin-data-api"
    }
  }
}
```

***

### ✅ Available Actions (9)

| # | Action | Description | Returns |
|---|---|---|---|
| 1 | `search_video` | Search videos by keyword | Up to 1,000 videos |
| 2 | `video_detail` | Get full video metadata | 1 video |
| 3 | `video_comments` | Get comments for a video | Up to 1,000 comments |
| 4 | `user_profile` | Get user profile (by `sec_user_id` or `uid`) | 1 user |
| 5 | `user_videos` | Get all videos from a user | Up to 1,000 videos |
| 6 | `user_search` | Search users by keyword | Up to 1,000 users |
| 7 | `danmaku` | Live bullet comments (弹幕) | Up to 1,000 danmaku |
| 8 | `video_real_statistics` | Real-time play count (App-side) | 1 video stats |
| 9 | `general_search_v3` | Comprehensive search (login-aware) | Up to 1,000 mixed results |

***

### 📥 Input Examples

```json
// 1. Search videos
{ "action": "search_video", "keyword": "World Cup", "max_items": 100 }

// 2. Video detail
{ "action": "video_detail", "aweme_id": "7661486561430752563" }

// 3. Video comments
{ "action": "video_comments", "aweme_id": "7661486561430752563", "max_items": 30 }

// 4. User profile
{ "action": "user_profile", "sec_user_id": "MS4wLjABAAAA..." }

// 5. User videos
{ "action": "user_videos", "sec_user_id": "MS4wLjABAAAA...", "max_items": 100 }

// 6. User search
{ "action": "user_search", "keyword": "体育" }

// 7. Danmaku
{ "action": "danmaku", "aweme_id": "7465287615521066266" }

// 8. Real video statistics
{ "action": "video_real_statistics", "aweme_id": "7661486561430752563" }

// 9. General search V3
{ "action": "general_search_v3", "keyword": "世界杯" }
```

***

### 📤 Output Format

Clean JSON with consistent field names across all actions.

#### Video item

```json
{
  "video_id": "7661486561430752563",
  "title": "...",
  "published_at": "2024-12-30T15:30:00Z",
  "duration_ms": 32000,
  "author": { "user_id": "...", "display_name": "...", "verified": false },
  "metrics": { "likes": 12345, "comments": 678, "shares": 90, "favorites": 234, "plays": 500000 },
  "media": { "cover": "https://...", "play_urls": ["https://..."] },
  "hashtags": ["话题1", "话题2"]
}
```

#### Comment item

```json
{
  "comment_id": "...",
  "text": "...",
  "published_at": "2024-12-30T15:30:00Z",
  "likes": 42,
  "author": { "user_id": "...", "display_name": "..." }
}
```

#### User item

```json
{
  "user_id": "...",
  "sec_user_id": "MS4wLjABAAAA...",
  "display_name": "...",
  "verified": false,
  "signature": "...",
  "metrics": { "followers": 100000, "following": 200, "likes": 5000000, "videos": 350 }
}
```

***

### 💰 Pricing

This Actor is **pay-per-event** on Apify Store. You pay only for successful results returned.

- 100 free events per month to try
- After that, prices start from **$4.99 / 1,000 results**
- Apify platform fee of 20% is deducted automatically
- No subscription, no commitment — pay as you go

See the **Pricing** tab on this Actor page for full per-event pricing.

***

### 📋 Changelog

**v1.0.0** (2026-07-13)

- Initial public release with 9 verified actions
- Pagination support up to 1,000 items per run
- MCP server integration for AI agents

***

### 🤝 Support

For bulk pricing or custom integrations:

- Open an issue on this Actor's page
- Apify Discord community

# Actor input Schema

## `action` (type: `string`):

Which data to retrieve. 1=search videos, 2=video detail, 3=comments, 4=user profile, 5=user videos, 6=search users, 7=danmaku, 8=real stats, 9=general search. Each action = 1 event charged.

## `keyword` (type: `string`):

Required for: search\_video, user\_search, general\_search\_v3. Leave empty to skip.

## `aweme_id` (type: `string`):

Required for: video\_detail, video\_comments, danmaku, video\_real\_statistics. Format: 19-digit number. Leave empty to skip.

## `sec_user_id` (type: `string`):

Required for: user\_profile, user\_videos. Starts with MS4wLjABAAAA... Leave empty to skip.

## `uid` (type: `string`):

Alternative to sec\_user\_id for: user\_profile. Leave empty to skip.

## `cursor` (type: `integer`):

Use returned cursor for next page (0 for first)

## `max_items` (type: `integer`):

Maximum number of items to return (1-1000, default 100)

## Actor input object example

```json
{
  "action": "search_video",
  "cursor": 0,
  "max_items": 100
}
```

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {};

// Run the Actor and wait for it to finish
const run = await client.actor("nourishing_fort/douyin-data-api").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = {}

# Run the Actor and wait for it to finish
run = client.actor("nourishing_fort/douyin-data-api").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print("💾 Check your data here: https://console.apify.com/storage/datasets/" + run["defaultDatasetId"])
for item in client.dataset(run["defaultDatasetId"]).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{}' |
apify call nourishing_fort/douyin-data-api --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "command": "npx",
            "args": [
                "mcp-remote",
                "https://mcp.apify.com/?tools=nourishing_fort/douyin-data-api",
                "--header",
                "Authorization: Bearer <YOUR_API_TOKEN>"
            ]
        }
    }
}

```

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/KcWOaibx0AWX7twWg/builds/gmcCj9ESBVVHguNz6/openapi.json
