# Weibo Hot Search Scraper (`opspilot.cc/weibo-hot-search-scraper`) Actor

Fetch the Weibo realtime hot search list (top ~100 trends) via TikHub. Pick a preset (realtime\_hot / entertainment / social / technology / life) or pass a raw containerid, and a page number.

- **URL**: https://apify.com/opspilot.cc/weibo-hot-search-scraper.md
- **Developed by:** [wang wei](https://apify.com/opspilot.cc) (community)
- **Categories:** Social media
- **Stats:** 2 total users, 1 monthly users, 80.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

$0.10 / actor start

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/actors/running/actors-in-store.md#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

## Weibo Hot Search Scraper

Fetch the Weibo realtime hot search list (top ~100 trends) via the upstream Chinese social data API. Built for marketing monitoring, trend research, and public sentiment scraping.

**One run = one upstream request.** Pick a preset (`realtime_hot` / `entertainment` / `social` / `technology` / `life`) or pass a raw `containerid`, and a page number (1..5). Each page returns ~20 trends; the full hot list is ~100 across pages 1..5.

- **Actor ID:** `TF51J1LwZ2AayIXzd`
- **Build:** `0.1.6`
- **Source:** A hosted Chinese social data API provider (Weibo endpoints)

### What it does

| Input | Output |
|---|---|
| `preset=realtime_hot` + `page=1` (defaults) | ~20 trend items with rank, post\_id, mid, text, source, reposts/comments/attitudes counts, and a flat user profile. Raw upstream payload preserved in `rawData`. |

### Quick start

```json
{
  "preset": "realtime_hot",
  "page": 1
}
```

Output dataset has one item per trend:

```json
{
  "rank": 1,
  "post_id": "5328347665010605",
  "mid": "5328347665010605",
  "created_at": "Wed Aug 05 00:22:22 +0800 2026",
  "text": "现在拍戏都这么拼吗 [允悲] 女演员工伤 偷胯婆的微博视频",
  "text_length": 57,
  "source": "iPhone 17 Pro Max",
  "pic_ids": [],
  "reposts_count": 142,
  "comments_count": 523,
  "attitudes_count": 1820,
  "user": {
    "user_id": 7491687377,
    "screen_name": "偷胯婆",
    "verified": true,
    "verified_type": 0,
    "followers_count": "2.3万"
  },
  "rawData": { /* full upstream status object */ }
}
```

### Input fields

| Field | Required | Default | Notes |
|---|---|---|---|
| `preset` | no | `realtime_hot` | One of `realtime_hot`, `entertainment`, `social`, `technology`, `life`. |
| `containerid` | no | (preset) | Raw Weibo `containerid` for custom lists. Overrides `preset` when both provided. |
| `page` | no | `1` | Page number (1..5). Each page returns ~20 trends. |

> 5 default presets cover the official Weibo top lists. Per our internal SOP §40 — every value the upstream supports must be exposed — all 5 are wired here. To use a custom containerid, copy it from any public Weibo endpoint response or pass your own string.

### Pricing

Free users are limited to **5 runs per day**. Paid users (`APIFY_USER_IS_PAYING=1`) have unlimited runs. The Actor itself adds no markup — you pay the upstream provider per request plus the standard Apify compute unit cost.

### Output

The Actor pushes one item per trend to the default dataset and writes a `SUMMARY` record to the default key-value store with run details (preset, container id, page, total from upstream, free-run counter, etc.).

### Use it together with the other Weibo Actors

This Actor is the **step ① entry point** of the 3-Actor Weibo MVP-2 set. Use it together with:

| Where in the pipeline | Actor | Console | Use it to |
|---:|---|---|---|
| before / step ① | **Weibo Hot Search Scraper** (you are here) | (step ① — entry point) | step ① — fetch the realtime hot list, get `post_id` and `screen_name` of each trend |
| after / step ② | [Weibo Keyword Search Scraper](https://console.apify.com/actors/rXAua7eiA6jxRogdF) | [Console](https://console.apify.com/actors/rXAua7eiA6jxRogdF) | step ② — search posts by keyword with 7 type filters and 4 time scopes |
| after / step ③ | [Weibo Post Detail Scraper](https://console.apify.com/actors/vgIzEKOSpFKlEDVo5) | [Console](https://console.apify.com/actors/vgIzEKOSpFKlEDVo5) | step ③ — pull full post text + up to ~150 comments for one `post_id` |

**You are here:** **Weibo Hot Search Scraper** — run this on its own for the upstream use case described above.

### Why this Actor exists

Apify has ~50,000 Actors and almost zero Weibo scrapers. This Actor is the first of a planned **Weibo MVP-2** set (5 Actors covering hot search, keyword search, user profile, post detail + comments, and channel feed) that targets the gap.

### Source & credits

Data source: a hosted Chinese social data API provider (Weibo endpoints). The provider charges per upstream request; this Actor adds no markup.

### License

MIT

# Actor input Schema

## `preset` (type: `string`):

Which hot list to fetch. Defaults to `realtime_hot` (热搜榜). Each preset dispatches to a dedicated upstream web\_v2 endpoint (verified 2026-09-10).

## `containerid` (type: `string`):

Legacy raw Weibo `containerid`. web\_v2 endpoints ignore this; kept for input-schema compatibility only. Leave blank.

## `page` (type: `integer`):

Page number (1..5). Each page returns ~20 trends; default of 1 keeps every run cheap.

## Actor input object example

```json
{
  "preset": "realtime_hot",
  "containerid": "",
  "page": 1
}
```

# Actor output Schema

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

One normalized dataset item per Weibo trend, with the original source record preserved in rawData.

## `summary` (type: `string`):

Preset, container id, page, pages fetched, request count, unique items, free-run counter, error details.

# 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("opspilot.cc/weibo-hot-search-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 = {}

# Run the Actor and wait for it to finish
run = client.actor("opspilot.cc/weibo-hot-search-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 '{}' |
apify call opspilot.cc/weibo-hot-search-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,opspilot.cc/weibo-hot-search-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/TF51J1LwZ2AayIXzd/builds/2hPwGi2CklYOCoONc/openapi.json
