# Telegram Channel Scraper: Posts, Views, Reactions & Media (`clearfeed-labs/telegram-channel-scraper`) Actor

Scrape public Telegram channels without an account or API key: posts with text, views, reactions, media links, link previews, forwards and polls, plus channel subscribers. Filter by date or keyword. Fast and cheap.

- **URL**: https://apify.com/clearfeed-labs/telegram-channel-scraper.md
- **Developed by:** [Clearfeed Labs](https://apify.com/clearfeed-labs) (community)
- **Categories:** Social media, News, Automation
- **Security:** Limited permissions
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $0.75 / 1,000 posts

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

## Telegram Channel Scraper: Posts, Views, Reactions & Media

Scrape **public Telegram channels** without a Telegram account, phone number or API key. For each channel you get its posts with **text, views, reactions, media links, link previews, forwards, replies and polls**, plus a channel row with **subscribers**, description, verified badge and photo, video and link counts.

### Why use it

- **Media & brand monitoring:** track news, crypto, finance or brand channels and measure reach with views and reactions.
- **Research & AI datasets:** export channel archives as clean text with dates for analysis, sentiment or RAG.
- **Competitive and market intelligence:** compare channel growth and engagement across competitors.
- **Alerts:** schedule it with "only posts newer than 1 day" to get just the new posts.

### Input

- **Channels:** `durov`, `@telegram`, `https://t.me/nytimes`, `https://t.me/s/bloomberg`, or a single post such as `https://t.me/durov/531`.
- **Max posts per channel:** newest posts come first. Set 0 to get channel info only.
- **Date filters:** `postsNewerThan` and `postsOlderThan` take `2025-06-01`, an ISO time, or `7 days`. With a date window the scraper jumps straight to that period.
- **Keyword search:** uses Telegram's own search inside each channel (also works for `#hashtags`).

```json
{ "channels": ["durov", "telegram", "https://t.me/nytimes"], "maxPostsPerChannel": 200, "postsNewerThan": "30 days" }
```

### Output (post)

`channel`, `postId`, `url`, `date`, `text`, `textHtml` (optional), `views`, `reactions` (emoji, count, paid stars), `reactionsTotal`, `media` (photos, videos with URL, thumbnail and duration, documents, audio), `linkPreview`, `poll`, `hashtags`, `mentions`, `links`, `forwardedFrom`, `replyToUrl`, `authorSignature`, `edited`, `channelTitle`, `channelSubscribers`.

### Pricing

You pay per **post** and per **channel info row**. Error rows (invalid input, channel not found) are not charged. Set a maximum charge per run and the Actor stops at your limit.

### Limits

- Only **public channels** with Telegram's web preview (t.me/s/…) enabled can be scraped. When an owner has disabled the preview, you get the channel info row only.
- Private channels, invite links (t.me/+…), groups' member lists, user accounts and bots are **not supported**, by design. The Actor collects no personal data about members.
- Some large videos show only a thumbnail on the web preview (`unsupportedMedia: true`).
- View and reaction counts are rounded the way Telegram shows them (e.g. 1.2K).

# Actor input Schema

## `channels` (type: `array`):

Public channel usernames or links, one per line: durov, @telegram, https://t.me/nytimes, https://t.me/s/bloomberg. A post link (https://t.me/durov/531) scrapes just that post. Private invite links (t.me/+...) and user accounts are not supported.

## `maxPostsPerChannel` (type: `integer`):

Newest posts first. 0 = channel info only.

## `postsNewerThan` (type: `string`):

Date (YYYY-MM-DD), ISO timestamp or relative like "7 days", "24 hours", "3 months". Stops paging once older posts are reached.

## `postsOlderThan` (type: `string`):

Date (YYYY-MM-DD, inclusive), ISO timestamp or relative. Use together with "newer than" for a date window; the scraper jumps straight to that period.

## `searchQuery` (type: `string`):

Only posts matching this keyword or #hashtag (Telegram's own channel search).

## `includeChannelInfo` (type: `boolean`):

One row per channel with title, description, subscribers, photo/video/link counts, verified badge and avatar.

## `includeTextHtml` (type: `boolean`):

Adds the formatted post body (bold, links, quotes) as HTML next to the plain text.

## `maxConcurrency` (type: `integer`):

Channels scraped in parallel.

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

Used only when Telegram rate-limits direct requests.

## Actor input object example

```json
{
  "channels": [
    "durov",
    "telegram",
    "https://t.me/nytimes"
  ],
  "maxPostsPerChannel": 100,
  "includeChannelInfo": true,
  "includeTextHtml": false,
  "maxConcurrency": 10,
  "proxyConfiguration": {
    "useApifyProxy": true
  }
}
```

# Actor output Schema

## `posts` (type: `string`):

No description

## `channels` (type: `string`):

No description

## `all` (type: `string`):

No description

## `summary` (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 = {
    "channels": [
        "durov",
        "telegram",
        "https://t.me/nytimes"
    ],
    "proxyConfiguration": {
        "useApifyProxy": true
    }
};

// Run the Actor and wait for it to finish
const run = await client.actor("clearfeed-labs/telegram-channel-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 = {
    "channels": [
        "durov",
        "telegram",
        "https://t.me/nytimes",
    ],
    "proxyConfiguration": { "useApifyProxy": True },
}

# Run the Actor and wait for it to finish
run = client.actor("clearfeed-labs/telegram-channel-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 '{
  "channels": [
    "durov",
    "telegram",
    "https://t.me/nytimes"
  ],
  "proxyConfiguration": {
    "useApifyProxy": true
  }
}' |
apify call clearfeed-labs/telegram-channel-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,clearfeed-labs/telegram-channel-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/cYT5Z8A3ndrBBj0vR/builds/KqBcaTr6ev0D3EPcV/openapi.json
