# Toutiao 头条 Scraper (`parsebird/toutiao-scraper`) Actor

Scrape Toutiao 今日头条 articles, videos, short videos and 微头条 posts from links or whole profiles. Get full article HTML, images, MP4 play URLs, author data, reads, likes, comments and shares. No login. Export JSON, CSV, Excel or use the API.

- **URL**: https://apify.com/parsebird/toutiao-scraper.md
- **Developed by:** [ParseBird](https://apify.com/parsebird) (community)
- **Security:** Limited permissions
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $2.49 / 1,000 items

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.
Since this Actor supports Apify Store discounts, the price gets lower the higher subscription plan you have.

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

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
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.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## 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.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

### Toutiao 头条 Scraper

**Toutiao Scraper** extracts public content from [Toutiao (今日头条)](https://www.toutiao.com/), ByteDance's Chinese news and content app. Paste Toutiao article, video or 微头条 links, or whole profile links. Each item comes back with its title, full article HTML, images, publish time, MP4 play URL for videos, author data and engagement counts: reads, likes, comments, shares and impressions. You don't need a Toutiao account, a cookie or an API key.

<table><tr>
<td style="border-left:4px solid #1C1917;padding:12px 16px;font-weight:600">
One row per Toutiao article, video, short video (小视频) or 微头条 post with 40+ data points, from single links or whole profiles filtered by tab or by the profile's own keyword search.
</td>
</tr></table>

##### Copy to your AI assistant

Copy this block into ChatGPT, Claude, Cursor, or any LLM to start using this actor.

```
Apify Actor: parsebird/toutiao-scraper. Scrapes public Toutiao (toutiao.com, 今日头条) articles, videos, short videos (小视频) and 微头条 posts without login. Call via ApifyClient: client.actor("parsebird/toutiao-scraper").call(run_input={"startUrls": ["https://www.toutiao.com/c/user/token/MS4wLjABAAAA3KU9ifwN12G41E6PJRpZgIfzVrXWQ4WPF66ns54c0uw/"], "profileTab": "article", "maxItems": 100}). Inputs: startUrls (string[]: article URLs like https://www.toutiao.com/article/7450114952884503059/, video URLs like https://www.toutiao.com/video/7464576063700468260/, 微头条 URLs like https://www.toutiao.com/w/1873147632243720/, profile URLs like https://www.toutiao.com/c/user/token/MS4w.../ or https://www.toutiao.com/c/user/51050126444/, m.toutiao.com and /group/ links, or bare item IDs), profileTab (string, default "all": all | article | video | short_video | wtt), profileSearchQuery (string, optional: keyword search inside each profile, replaces the tab), maxItems (integer, default 100, 0 = no limit: items per profile link), proxyConfiguration (optional). Output: one row per item: url, itemId, type (article | video | short_video | weitoutiao), title, abstract, content (article HTML or 微头条 text), publishTime (YYYY-MM-DD HH:MM, UTC+8), publishedAt (ISO 8601 UTC), cover, firstFrame (videos), imageList, source, isOriginal, keywords, videoCategories, authorData {name, userId, secUserId, userVerified, avatarUrl, description, userAuthType, userAuthInfo, followersCount, profileUrl}, statistics {playCount (videos), commentCount, buryCount, diggCount, shareCount, readCount, showCount, repinCount, forwardCount, danmuCount}, videoData {duration, height, width, size, bitrate, codecType, definition, fps, videoId, playUrl, backupUrl} or null, localCityInfo {code, name}, inputUrl, profileName, profileSecUserId, profileTab or profileSearchQuery, scrapedAt. Pricing: pay per item saved. Full API spec: https://apify.com/parsebird/toutiao-scraper/api. Get your token: https://console.apify.com/settings/integrations.
```

### What is Toutiao Scraper?

**Toutiao Scraper** turns Toutiao pages into structured data. Paste Toutiao links and click **Start**. You get clean rows of Toutiao data: headlines, full article bodies with their images, video files, author profiles and engagement counts. Download the results as **JSON, CSV or Excel**, or read them through the API.

It works as a **Toutiao API alternative**. Toutiao has no public data API for its articles and videos, so the Actor reads the same public pages and profile feeds that a logged-out visitor sees on toutiao.com. You never have to sign in or scan a QR code.

### What can Toutiao Scraper do?

- 📰 **Scrape Toutiao articles.** Get the title, abstract, full article HTML (`content`), every image in the article, keywords and the original source.
- 🎬 **Scrape Toutiao videos and short videos.** Get the cover, first frame, duration, resolution, file size, bitrate and a direct MP4 `playUrl`.
- 💬 **Scrape 微头条 posts.** Get the post text, images and engagement counts.
- 👤 **Scrape whole Toutiao profiles.** Paste a profile link and choose a tab: All (全部), Articles (文章), Videos (视频), Short videos (小视频) or 微头条. Set **Max items per profile**, or `0` for everything the feed returns.
- 🔍 **Search inside a profile.** Enter a keyword to get the same results as the profile page's own search box (搜索TA的作品).
- 📊 **Track engagement.** Every row carries reads, likes, comments, shares, saves, impressions (`showCount`) and, for videos, plays.
- 📅 **Schedule and monitor.** Re-run a profile daily with [Apify Schedules](https://docs.apify.com/platform/schedules) to catch new posts and watch counts grow.
- 🔌 **API and integrations.** Use the [Apify API](https://docs.apify.com/api/v2), or send results to Google Sheets, Zapier, Make, Slack or webhooks with [Apify integrations](https://docs.apify.com/platform/integrations). Export as JSON, CSV, Excel, XML or HTML.

### What data can you extract from Toutiao?

| Field | Description |
|-------|-------------|
| `url` · `itemId` | Canonical toutiao.com link and Toutiao item ID |
| `type` | `article`, `video`, `short_video` (小视频) or `weitoutiao` (微头条) |
| `title` · `abstract` | Headline and summary. For 微头条 posts the title is the start of the post text |
| `content` | Full article body as HTML (with `<img>` tags), or the 微头条 post text. Empty for videos |
| `publishTime` · `publishedAt` | Publish time as `YYYY-MM-DD HH:MM` in China time (UTC+8), and as ISO 8601 in UTC |
| `cover` · `imageList` · `firstFrame` | Cover image, all images in the article or post, and the video's first frame |
| `source` · `isOriginal` · `keywords` | The publishing account or outlet, Toutiao's original-content flag, and the page's SEO keywords |
| `authorData` | `name`, `userId` (numeric), `secUserId` (the `MS4w…` token used in profile links), `userVerified`, `avatarUrl`, `description`, `userAuthType`, `userAuthInfo` (verification text), `followersCount`, `profileUrl` |
| `statistics` | `readCount`, `diggCount` (likes), `commentCount`, `shareCount`, `repinCount` (saves), `showCount` (impressions), `forwardCount`, `buryCount`, `danmuCount`, plus `playCount` for videos |
| `videoData` | `duration` (s), `width`, `height`, `size` (bytes), `bitrate`, `codecType`, `definition`, `fps`, `videoId`, `playUrl`, `backupUrl`. `null` for articles and posts |
| `videoCategories` | Toutiao's category tags for the video, for example `video_music` |
| `localCityInfo` | `code` and `name` of the local-city channel Toutiao attaches to the page view (see the FAQ) |
| `inputUrl` · `profileName` · `profileSecUserId` · `profileTab` / `profileSearchQuery` | Which of your inputs produced the row |

### How to scrape Toutiao

1. Open [Toutiao Scraper](https://apify.com/parsebird/toutiao-scraper) on Apify Store and click **Try for free**.
2. In **Start URLs**, paste Toutiao links, one per line. Article, video, 微头条 and profile links can go in the same run. To get a link in the Toutiao app, tap **Share** and then **Copy link**.
3. For profile links, pick a **Profile tab**, or type a **Profile search query** to search inside the profile instead.
4. Set **Max items per profile** (`0` = no limit).
5. Click **Start**. When the run finishes, open the **Output** tab and download your Toutiao data as JSON, CSV, Excel, XML or HTML, or read it through the API.

### Input parameters

| Parameter | Type | Required | Default | Description |
|-----------|------|----------|---------|-------------|
| `startUrls` | string\[] | **Yes** | — | Toutiao article, video, 微头条 or profile links. `m.toutiao.com` links, `/group/` links and bare item IDs also work |
| `profileTab` | string | No | `all` | Profile tab to scrape: `all`, `article`, `video`, `short_video` or `wtt` (微头条) |
| `profileSearchQuery` | string | No | — | Keyword to search inside each profile. Replaces the tab when set |
| `maxItems` | integer | No | `100` | Items to save per profile link. `0` = no limit. Item links always count as one item each |
| `proxyConfiguration` | object | No | — | Optional proxy. Not needed for normal use |

**Example inputs**

Scrape one article:

```json
{ "startUrls": ["https://www.toutiao.com/article/7450114952884503059"] }
```

Scrape 100 articles from a profile:

```json
{
    "startUrls": ["https://www.toutiao.com/c/user/token/MS4wLjABAAAA3KU9ifwN12G41E6PJRpZgIfzVrXWQ4WPF66ns54c0uw/"],
    "profileTab": "article",
    "maxItems": 100
}
```

Scrape 50 items from a profile matching a keyword:

```json
{
    "startUrls": ["https://www.toutiao.com/c/user/token/MS4wLjABAAAA3KU9ifwN12G41E6PJRpZgIfzVrXWQ4WPF66ns54c0uw/"],
    "profileSearchQuery": "海阳",
    "maxItems": 50
}
```

### Output example

An article (the `content` HTML is shortened here):

```json
{
    "url": "https://www.toutiao.com/article/7450114952884503059/",
    "itemId": "7450114952884503059",
    "type": "article",
    "title": "“海阳船”再发“海阳箭”——谷神星一号海遥四运载火箭发射成功",
    "abstract": "齐鲁网·闪电新闻12月19日讯 12月19日下午，万众瞩目之下，由海阳总装出厂的谷神星一号海遥四运载火箭搭乘“东方航天港”号发射船……",
    "content": "<img src=\"https://p3-sign.toutiaoimg.com/tos-cn-i-axegupay5k/3f3872e7c89e4f2baccea3632c7077bf~tplv-tt-origin-web:gif.jpeg?…\" img_width=\"6000\" img_height=\"4000\" …><p>齐鲁网·闪电新闻12月19日讯 12月19日下午……</p>…",
    "publishTime": "2024-12-19 21:31",
    "publishedAt": "2024-12-19T13:31:15Z",
    "cover": "https://p3-sign.toutiaoimg.com/tos-cn-i-tjoges91tu/0db73b409bfcbc388e7995c7460eff7a~tplv-tt-shrink-asy2-web:640:0:….gif.jpeg?…",
    "imageList": [
        "https://p3-sign.toutiaoimg.com/tos-cn-i-axegupay5k/3f3872e7c89e4f2baccea3632c7077bf~tplv-tt-origin-web:gif.jpeg?…"
    ],
    "source": "闪电新闻",
    "isOriginal": false,
    "keywords": ["谷神星", "中国民营火箭发射", "火箭", "海阳", "山东", "航空"],
    "authorData": {
        "name": "闪电新闻",
        "userId": "51050126444",
        "secUserId": "MS4wLjABAAAA3KU9ifwN12G41E6PJRpZgIfzVrXWQ4WPF66ns54c0uw",
        "userVerified": true,
        "avatarUrl": "https://sf3-cdn-tos.toutiaostatic.com/img/user-avatar/14194628f142c924cb14b638f6b04d91~300x300.image",
        "description": "闪电新闻，先声夺人。山东广播电视台倾力打造的融媒体客户端。",
        "userAuthType": "5",
        "userAuthInfo": "闪电新闻官方账号",
        "followersCount": 5590433,
        "profileUrl": "https://www.toutiao.com/c/user/token/MS4wLjABAAAA3KU9ifwN12G41E6PJRpZgIfzVrXWQ4WPF66ns54c0uw/"
    },
    "statistics": {
        "commentCount": 1,
        "buryCount": 0,
        "diggCount": 3,
        "shareCount": 9,
        "readCount": 95,
        "showCount": 3479,
        "repinCount": 1,
        "forwardCount": 0,
        "danmuCount": 0
    },
    "videoData": null,
    "localCityInfo": { "code": "110000", "name": "北京" },
    "inputUrl": "https://www.toutiao.com/article/7450114952884503059/",
    "scrapedAt": "2026-11-05T12:10:41Z"
}
```

A video:

```json
{
    "url": "https://www.toutiao.com/video/7464576063700468260/",
    "itemId": "7464576063700468260",
    "type": "video",
    "title": "谁懂@张艺兴 《开天》Dance Break的震撼~#山东春晚",
    "abstract": "",
    "content": "",
    "publishTime": "2025-01-27 20:47",
    "publishedAt": "2025-01-27T12:47:29Z",
    "cover": "https://p3-sign.toutiaoimg.com/tos-cn-p-0004/b21bf563d6894858a92773f249f6dad3_1737982050~tplv-pk90l89vgd-crop-center-v4:864:486.jpeg?…",
    "firstFrame": "https://p3-sign.toutiaoimg.com/tos-cn-p-0004/d341e5d215e34dbe94744b714e7271a4_1737982051~tplv-pk90l89vgd-crop-center-v4:864:486.jpeg?…",
    "imageList": [],
    "source": "闪电新闻",
    "isOriginal": false,
    "keywords": ["张艺兴", "春晚", "山东"],
    "videoCategories": ["video_music"],
    "authorData": {
        "name": "闪电新闻",
        "userId": "51050126444",
        "secUserId": "MS4wLjABAAAA3KU9ifwN12G41E6PJRpZgIfzVrXWQ4WPF66ns54c0uw",
        "userVerified": true,
        "userAuthType": "5",
        "userAuthInfo": "闪电新闻官方账号",
        "followersCount": 5590433
    },
    "statistics": {
        "playCount": 1077,
        "commentCount": 2,
        "buryCount": 0,
        "diggCount": 28,
        "shareCount": 0,
        "readCount": 1077,
        "showCount": 22833,
        "repinCount": 0,
        "forwardCount": 1,
        "danmuCount": 0
    },
    "videoData": {
        "duration": 18.552,
        "height": 720,
        "width": 1280,
        "size": 3357052,
        "bitrate": 1447629,
        "codecType": "h264",
        "definition": "720p",
        "fps": 30,
        "videoId": "v03004g10000cubo0ofog65ukspllsf0",
        "playUrl": "https://v3-web.toutiaovod.com/…/video/tos/cn/tos-cn-v-0004c800/oQ3ATlg0iF6gABDZvnqt9egG7EQGfAODIvAOiB/?a=24&…&mime_type=video_mp4&…",
        "backupUrl": "https://v3-web.toutiaovod.com/…"
    },
    "localCityInfo": { "code": "110000", "name": "北京" },
    "inputUrl": "https://www.toutiao.com/video/7464576063700468260/",
    "scrapedAt": "2026-11-05T12:12:03Z"
}
```

### How much does it cost to scrape Toutiao?

Toutiao Scraper uses **pay-per-event** pricing. You pay for each item (article, video, short video or 微头条 post) saved to your dataset. Compute and proxy costs are included in the price. Inputs that return nothing, such as a deleted article, an invalid link or a duplicate, are free.

| Event | Free | Bronze | Silver | Gold |
|-------|------|--------|--------|------|
| Item (per 1,000) | $3.99 | $3.49 | $2.99 | $2.49 |

On the Free plan, 1,000 Toutiao items cost $3.99, so 100 items cost about $0.40. Use **Max items per profile** or a maximum cost per run in Apify Console to cap a run. The Actor stops cleanly when it reaches either limit.

### Use the Toutiao API from Python or JavaScript

Get your API token from [Apify Console](https://console.apify.com/settings/integrations), then call the Actor with the [Apify API client for Python](https://docs.apify.com/api/client/python) or [for JavaScript](https://docs.apify.com/api/client/js).

**Python**

```python
from apify_client import ApifyClient

client = ApifyClient("<YOUR_APIFY_TOKEN>")

run = client.actor("parsebird/toutiao-scraper").call(run_input={
    "startUrls": ["https://www.toutiao.com/c/user/token/MS4wLjABAAAA3KU9ifwN12G41E6PJRpZgIfzVrXWQ4WPF66ns54c0uw/"],
    "profileTab": "article",
    "maxItems": 100,
})

for item in client.dataset(run["defaultDatasetId"]).iterate_items():
    print(item["publishTime"], item["title"], item["statistics"]["readCount"])
```

**JavaScript**

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

const client = new ApifyClient({ token: '<YOUR_APIFY_TOKEN>' });

const run = await client.actor('parsebird/toutiao-scraper').call({
    startUrls: ['https://www.toutiao.com/video/7464576063700468260/'],
});

const { items } = await client.dataset(run.defaultDatasetId).listItems();
console.log(items[0].videoData.playUrl, items[0].statistics.playCount);
```

The full endpoint reference, including synchronous runs that return the dataset in one call, is on the [API tab](https://apify.com/parsebird/toutiao-scraper/api).

### Use cases

- **Media monitoring.** Follow news outlets and government accounts on Toutiao and collect every new article with its full text.
- **Content research.** Compare which headlines, formats and topics earn the most reads, likes and shares on a profile.
- **Influencer and account analysis.** Check a creator's followers, verification and the engagement on their recent posts.
- **Chinese-language NLP.** Build corpora of Chinese news articles and short posts with publish times and keywords.
- **Video archiving.** Save MP4 links, covers and metadata for the Toutiao videos you track.

### How it works

1. Each input is recognised as an article, video, 微头条 post or profile. Duplicates are merged.
2. For profile links, the Actor reads the profile's public feed for the chosen tab, or the profile's own search results for your keyword, page by page.
3. Each item's public toutiao.com page is opened and the data embedded in it is read, so profile items get the same full fields as single links. When Toutiao rate-limits item pages during a large run, the Actor fills the row from the profile feed and Toutiao's mobile article data instead, so the run keeps going (see the FAQ).
4. Rows are saved and charged as they come in. A run that Apify moves to another server resumes without duplicates.

### FAQ

**Do I need a Toutiao account, cookie or API key?**
No. The Actor reads public data the way a logged-out visitor sees it on toutiao.com.

**Which profile links work?**
Both forms: `https://www.toutiao.com/c/user/token/MS4w…/` and the numeric `https://www.toutiao.com/c/user/51050126444/`. Any author's `profileUrl` in the output also works as an input.

**How many items can I get from a profile?**
As many as Toutiao's profile feed returns for the tab. Set **Max items per profile** to `0` to keep going until the feed ends. Profile search returns what the profile page's own search box returns, which is often fewer items than the tab. For example, the prefilled profile has only 2 results for "dance" but more than 50 for "海阳".

**Can I download the videos?**
Yes. `playUrl` is a direct MP4 link, with `backupUrl` as a second server. The links are signed by Toutiao's video servers and expire after about an hour, so download the files soon after the run, or re-run the Actor to get fresh links.

**Why are `keywords` or `localCityInfo` empty on some rows?**
Toutiao limits how many item pages one IP address can open in a short time. When that happens on a large profile run, the Actor builds the rest of the rows from the profile feed and Toutiao's mobile article data. Those rows still have the title, full article body, images, author, counts and video files, but Toutiao doesn't include page keywords or `localCityInfo` there. For a single article link in that situation, `secUserId`, `userVerified`, the author `description`, `shareCount` and `showCount` can also be missing.

**Why do some articles have no cover or images?**
Those articles are text-only on Toutiao. `cover` is then `null` and `imageList` is empty.

**What is `localCityInfo`?**
It's the local-city channel Toutiao attaches to the page when the Actor opens it. Toutiao picks it from the visitor's location, so it is usually `北京` (110000) for every item. It doesn't tell you where the content was published. Use it only if you need the same field another tool gave you.

**Why can a creator's `followersCount` differ between rows?**
Toutiao's short-video player reports a different follower figure than its article pages for some creators. Each row carries the figure shown on that item's own page.

**Does it scrape comments?**
No. It doesn't scrape comment text. Every row includes `commentCount`.

**Why did an item return nothing?**
The item was deleted, made private or the link is wrong. The log lists it as "not found", and it isn't charged.

**Can I schedule recurring runs?**
Yes. Use [Apify Schedules](https://docs.apify.com/platform/schedules) to run hourly, daily or weekly.

**Can I use it with Make, Zapier, Google Sheets or an AI agent?**
Yes, through [Apify integrations](https://docs.apify.com/platform/integrations) and the [Apify API](https://docs.apify.com/api/v2). The Actor is also available to AI agents through the [Apify MCP server](https://docs.apify.com/platform/integrations/mcp).

**Something doesn't work. What should I do?**
Open an issue on the [Issues tab](https://apify.com/parsebird/toutiao-scraper/issues) with your run link. We read every report.

### Is it legal to scrape Toutiao?

This Actor only collects publicly available data that any logged-out visitor can see on toutiao.com. It doesn't log in or access private content. Articles and profiles can still include personal data, which is protected by laws such as China's Personal Information Protection Law (PIPL) and the EU's GDPR. Don't scrape personal data unless you have a legitimate reason, and check Toutiao's terms of service before you use the data. Articles are copyrighted by their authors, so get permission before you republish them. If you're unsure, consult a lawyer. Read more in Apify's guide: [Is web scraping legal?](https://blog.apify.com/is-web-scraping-legal/)

### Related Actors

| Actor | What it does |
|-------|--------------|
| [Baidu 百度 Search Scraper](https://apify.com/parsebird/baidu-search-scraper) | Baidu search results for any keyword, with Baidu's AI answer, news, videos and the 百度热搜 hot list |
| [Sogou WeChat Article Search Scraper](https://apify.com/parsebird/sogou-wechat-search-scraper) | WeChat Official Account articles found through Sogou's WeChat search |
| [Kuaishou 快手 Scraper](https://apify.com/parsebird/kuaishou-scraper) | Kuaishou videos with MP4 links, music and creator stats |
| [Bilibili 哔哩哔哩 Scraper](https://apify.com/parsebird/bilibili-scraper) | Bilibili videos, comments, danmaku and UP主 profiles |
| [NetEase Cloud Music Scraper](https://apify.com/parsebird/netease-cloud-music-scraper) | NetEase Cloud Music toplists and playlists with tracks, artists and popularity |
| [Taobao & Tmall Scraper](https://apify.com/parsebird/taobao-tmall-scraper) | Taobao and Tmall products by keyword, category, URL or shop, with prices, ratings and seller scores |

# Changelog

This Actor's version history is a separate document: https://apify.com/parsebird/toutiao-scraper/changelog.md

# Actor input Schema

## `startUrls` (type: `array`):

Add Toutiao links, one per line. Supported: article links (<code>https://www.toutiao.com/article/7450114952884503059/</code>), video links (<code>https://www.toutiao.com/video/7464576063700468260/</code>), 微头条 links (<code>https://www.toutiao.com/w/1873147632243720/</code>) and profile links (<code>https://www.toutiao.com/c/user/token/MS4wLjABAAAA…/</code>). Bare item IDs, <code>m.toutiao.com</code> links and <code>/group/</code> links also work.

## `profileTab` (type: `string`):

Choose which tab to scrape for profile links. Ignored when a profile search query is set.

## `profileSearchQuery` (type: `string`):

Enter a keyword to search inside each profile, like the profile page's own search box (搜索TA的作品). Leave empty to scrape the profile tab instead.

## `maxItems` (type: `integer`):

Set how many items to save from each profile link. Use <b>0</b> for no limit. Item links are always scraped and don't count toward this.

## `proxyConfiguration` (type: `object`):

Not needed for normal use. Only set a proxy if Toutiao starts refusing your runs.

## Actor input object example

```json
{
  "startUrls": [
    "https://www.toutiao.com/article/7450114952884503059/",
    "https://www.toutiao.com/c/user/token/MS4wLjABAAAA3KU9ifwN12G41E6PJRpZgIfzVrXWQ4WPF66ns54c0uw/"
  ],
  "profileTab": "all",
  "maxItems": 10
}
```

# Actor output Schema

## `dataset` (type: `string`):

No description

# 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 = {
    "startUrls": [
        "https://www.toutiao.com/article/7450114952884503059/",
        "https://www.toutiao.com/c/user/token/MS4wLjABAAAA3KU9ifwN12G41E6PJRpZgIfzVrXWQ4WPF66ns54c0uw/"
    ],
    "maxItems": 10
};

// Run the Actor and wait for it to finish
const run = await client.actor("parsebird/toutiao-scraper").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 = {
    "startUrls": [
        "https://www.toutiao.com/article/7450114952884503059/",
        "https://www.toutiao.com/c/user/token/MS4wLjABAAAA3KU9ifwN12G41E6PJRpZgIfzVrXWQ4WPF66ns54c0uw/",
    ],
    "maxItems": 10,
}

# Run the Actor and wait for it to finish
run = client.actor("parsebird/toutiao-scraper").call(run_input=run_input)

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

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

```

## CLI example

```bash
echo '{
  "startUrls": [
    "https://www.toutiao.com/article/7450114952884503059/",
    "https://www.toutiao.com/c/user/token/MS4wLjABAAAA3KU9ifwN12G41E6PJRpZgIfzVrXWQ4WPF66ns54c0uw/"
  ],
  "maxItems": 10
}' |
apify call parsebird/toutiao-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,parsebird/toutiao-scraper"
        }
    }
}
```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/RpZrU1feWsUYKUhuj/builds/2j7LxBuB8nSdmCMmc/openapi.json
