# Telegram Channel Posts Scraper – Comments & Media (`fetch_cat/telegram-channel-posts-scraper`) Actor

Export public Telegram channel posts, comment counts and optional public comments with text, authors, dates, media, views, filters, and monitoring fields.

- **URL**: https://apify.com/fetch\_cat/telegram-channel-posts-scraper.md
- **Developed by:** [Hanna Nosova](https://apify.com/fetch_cat) (community)
- **Categories:** Social media, News, Developer tools
- **Stats:** 29 total users, 22 monthly users, 96.8% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $0.02 / 1,000 post extracteds

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/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

## Telegram Channel Posts Scraper

Export posts from public Telegram channels with text, timestamps, views, reactions, links, media URLs, and source post URLs.

Use this Actor to collect public Telegram channel posts for social listening, news monitoring, crypto and market research, media analysis, brand tracking, and recurring channel dashboards. Results can be downloaded as CSV, JSON, Excel, XML, RSS, or used through the Apify Dataset API.

> **Automate Telegram channel workflows in n8n:** Use the ready-made [Export Telegram channel posts to Google Sheets with Apify](https://n8n.io/workflows/17733-export-telegram-channel-posts-to-google-sheets-with-apify/) workflow for a searchable archive, or [Monitor Telegram channel intelligence with Apify, OpenAI, Google Sheets, and Telegram](https://n8n.io/workflows/17734-monitor-telegram-channel-intelligence-with-apify-openai-google-sheets-and-telegram/) to classify new posts and send alerts.

### At a glance

- **Public channel export**: Enter Telegram channel handles, usernames, or public channel URLs.
- **Post data rows**: Export post IDs, URLs, dates, text, views, forwards, replies, reactions, links, and media URLs.
- **Date filtering**: Limit posts with `sinceDate` and `untilDate`.
- **Monitoring ready**: Schedule recurring channel checks for news, crypto, research, or brand monitoring.
- **API export**: Send Telegram post rows to spreadsheets, BI tools, alerting systems, databases, or AI agents.

### Ready-to-run examples

Use these saved Store examples as starting points. Open any example to prefill the Actor input, then adjust URLs, keywords, limits, or filters for your own run.

- **[Monitor a public Telegram channel](https://apify.com/fetch_cat/telegram-channel-posts-scraper/examples/telegram-public-channel-monitoring)**
- **[Build a Telegram social listening sample](https://apify.com/fetch_cat/telegram-channel-posts-scraper/examples/telegram-social-listening-sample)**
- **[Export Telegram channel posts with media](https://apify.com/fetch_cat/telegram-channel-posts-scraper/examples/telegram-channel-media-posts)**
- **[Export Telegram channel text posts](https://apify.com/fetch_cat/telegram-channel-posts-scraper/examples/telegram-channel-text-export)**
- **[Compare public Telegram channel posts](https://apify.com/fetch_cat/telegram-channel-posts-scraper/examples/compare-public-telegram-channels)**
- **[Scrape Durov Telegram channel posts](https://apify.com/fetch_cat/telegram-channel-posts-scraper/examples/scrape-durov-telegram-posts)**
- **[View all ready-to-run examples](https://apify.com/fetch_cat/telegram-channel-posts-scraper/examples)** (7 examples)

### What can it do?

Telegram Channel Posts Scraper extracts posts from public Telegram channels and saves one dataset row per post.

- **Scrape public channels**: Use channel handles, public usernames, `t.me` links, or public channel URLs.
- **Collect post metadata**: Save post text, date, URL, views, replies, forwards, reactions, and links.
- **Include media URLs**: Add public media URLs when available and requested.
- **Filter history**: Use date inputs to keep runs focused.
- **Export repeatable datasets**: Use Apify downloads, API calls, schedules, webhooks, and integrations.

### Common workflows

- **Social listening**: Monitor public Telegram channels for brand, topic, or market mentions.
- **News monitoring**: Track public posts from media, research, and announcement channels.
- **Crypto research**: Export public channel posts for project, token, or community analysis.
- **Market intelligence**: Watch competitor, vendor, industry, or regional channels.
- **Content archiving**: Store public post rows for later review and analysis.
- **AI summaries**: Feed post text and links into summarization, classification, or alerting workflows.

### What data can you extract?

The Actor returns one dataset row per public Telegram channel post.

| Field | Description |
| --- | --- |
| `channelHandle` | Input channel handle or URL |
| `channelUsername` | Public Telegram channel username |
| `channelTitle` | Channel title when available |
| `postId` | Telegram post ID |
| `postUrl` | Public post URL |
| `date` | Post date |
| `postedAt` | Normalized post timestamp when available |
| `text` | Public post text |
| `views` | Public view count when available |
| `forwards` | Forward count when available |
| `replyCount` | Reply count when available |
| `replies` | Reply metadata when available |
| `reactions` | Public reactions when available |
| `links` | Links found in the post |
| `mediaUrls` | Public media URLs when included and available |
| `rawHtmlSnippet` | Optional raw HTML snippet |
| `scrapedAt` | Timestamp when the row was saved |

### Pricing

This Actor uses Apify pay-per-event pricing. The prices below come from the current Actor pricing configuration. Apify public plans map to Store discount tiers, so the table shows both the user-facing plan context and the pricing tier name. The final price shown in Apify depends on the user account plan and any custom agreement.

| Event | What is charged | Price |
| --- | --- | ---: |
| `start` | One-time fee charged when a run starts. Covers fixed startup cost (init, proxy warmup, first HTTP setup). | $0.005 |

| Event | What is charged | Free / no discount | Starter / Bronze | Scale / Silver | Business / Gold | Custom / Platinum | Custom / Diamond |
| --- | --- | ---: | ---: | ---: | ---: | ---: | ---: |
| `post` | Charged per post extracted. | $0.04225 / 1,000 | $0.03674 / 1,000 | $0.02866 / 1,000 | $0.02204 / 1,000 | $0.0147 / 1,000 | $0.01029 / 1,000 |

Apify may also charge platform usage for compute, storage, proxies, or data transfer outside this Actor pricing. Check the Actor run and the Apify Pricing tab for the exact cost shown to your account.

### Input configuration

| Setting | JSON key | Use it for | Example |
| --- | --- | --- | --- |
| Channels | `channels` | Public Telegram handles, usernames, or channel URLs. | `["telegram"]` |
| Maximum posts | `maxPosts` | Cap saved post rows and spend. | `25` |
| Maximum posts per channel | `maxPostsPerChannel` | Balance multi-channel runs so one active channel does not consume the full run. | `10` |
| Maximum history pages per channel | `maxPagesPerChannel` | Bound Telegram pagination for older history windows. | `20` |
| Only posts since date | `sinceDate` | Keep posts on or after this date. | `2026-07-01` |
| Only posts until date | `untilDate` | Keep posts on or before this date. | `2026-07-03` |
| Only posts after ID | `afterPostId` | Resume after one global Telegram message ID checkpoint. | `430` |
| Per-channel post ID checkpoints | `afterPostIds` | Resume different channels from different message IDs. | `{"telegram":430}` |
| Include media URLs | `includeMedia` | Save public media URLs when available. | `true` |
| Include raw HTML snippet | `includeRawHtmlSnippet` | Save a small raw HTML snippet for debugging or custom parsing. | `false` |
| Include public comments | `includeComments` | Save public discussion comments for posts that expose them. | `false` |
| Include comment count | `includeCommentCount` | Fetch accurate public discussion counts; disable to reduce requests. | `true` |
| Maximum comments per post | `maxCommentsPerPost` | Limit embedded public comments per saved post. | `20` |
| Minimum comments | `minComments` | Keep only posts with at least this many public comments. | `0` |
| Proxy configuration | `proxyConfiguration` | Optional Apify Proxy settings. | `{"useApifyProxy":true}` |
| Safe run-time limit | `runTimeSecs` | Stop before the platform timeout and preserve saved posts. | `270` |

### Example input

```json
{
  "channels": ["telegram"],
  "maxPosts": 25,
  "sinceDate": "2026-07-01",
  "includeMedia": true
}
```

### Example output

```json
{
  "channelUsername": "telegram",
  "channelTitle": "Telegram News",
  "postId": "123",
  "postUrl": "https://t.me/telegram/123",
  "date": "2026-07-03",
  "postedAt": "2026-07-03T10:00:00.000Z",
  "text": "Example public channel post",
  "views": 12000,
  "forwards": 45,
  "replyCount": 10,
  "reactions": [{"emoji": "like", "count": 100}],
  "links": ["https://example.com"],
  "mediaUrls": ["https://..."],
  "scrapedAt": "2026-07-03T12:00:00.000Z"
}
```

### How to run it

1. Open the Actor on Apify.
2. Add one or more public Telegram channels.
3. Set `maxPosts`.
4. Add optional date filters.
5. Choose whether to include media URLs or raw HTML snippets.
6. Start the run and export the dataset.

### Search tips

- **Use public channels only**: Private channels and groups are not supported.
- **Start with one channel**: Confirm output shape before adding a large channel list.
- **Use date filters**: Keep recurring runs focused with `sinceDate`.
- **Enable media only when needed**: Media URLs can make rows larger.
- **Schedule monitoring**: Reuse the same channel list for daily or weekly snapshots.

### Limits and caveats

- The Actor extracts public Telegram channel posts only.
- It does not access private channels, private groups, user chats, or login-gated data.
- Some public counters, reactions, replies, or media URLs may be missing depending on Telegram page output.
- Very large channels may require focused limits and date windows.

### API usage

**cURL**

```bash
curl -X POST 'https://api.apify.com/v2/acts/fetch_cat~telegram-channel-posts-scraper/runs?token=YOUR_APIFY_TOKEN' \
  -H 'Content-Type: application/json' \
  -d '{"channels":["telegram"],"maxPosts":25,"includeMedia":true}'
```

**Node.js**

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

const client = new ApifyClient({ token: process.env.APIFY_TOKEN });
const run = await client.actor('fetch_cat/telegram-channel-posts-scraper').call({
  channels: ['telegram'],
  maxPosts: 25,
  includeMedia: true,
});
const { items } = await client.dataset(run.defaultDatasetId).listItems();
console.log(items);
```

**Python**

```python
from apify_client import ApifyClient
import os

client = ApifyClient(os.environ['APIFY_TOKEN'])
run = client.actor('fetch_cat/telegram-channel-posts-scraper').call(run_input={
    'channels': ['telegram'],
    'maxPosts': 25,
    'includeMedia': True,
})
items = client.dataset(run['defaultDatasetId']).list_items().items
print(items)
```

### MCP and AI agents

This Actor can be used through the official Apify MCP server at `https://mcp.apify.com`.

**Claude CLI setup**

```bash
claude mcp add apify --transport http https://mcp.apify.com?tools=fetch_cat/telegram-channel-posts-scraper
```

**JSON config**

```json
{
  "mcpServers": {
    "apify": {
      "url": "https://mcp.apify.com?tools=fetch_cat/telegram-channel-posts-scraper"
    }
  }
}
```

**Example prompts**

- "Scrape the latest 25 posts from the public Telegram channel `telegram`."
- "Export public Telegram posts from `durov` since 2026-07-01 and include media URLs."
- "Compare recent public posts from `telegram` and `durov` for social listening."

Use the same JSON keys shown in the input configuration table, such as `channels`, `maxPosts`, `sinceDate`, `untilDate`, and `includeMedia`.

### FAQ

#### Can it scrape private Telegram channels?

No. It extracts public channel pages only.

#### Can it scrape Telegram groups?

No. This Actor is for public Telegram channels.

#### Can I scrape multiple channels in one run?

Yes. Add multiple values to `channels`.

#### Can I export to CSV or Excel?

Yes. Apify datasets can be downloaded as CSV, JSON, Excel, XML, RSS, HTML, or accessed through the API.

### Related scrapers

- [Reddit Scraper](https://apify.com/fetch_cat/reddit-scraper)
- [Substack Posts Scraper](https://apify.com/fetch_cat/substack-posts-scraper)
- [Hacker News Search Scraper](https://apify.com/fetch_cat/hacker-news-search-scraper)
- [Google News Scraper](https://apify.com/fetch_cat/google-news-scraper)
- [Telegram Public Profiles Scraper](https://apify.com/fetch_cat/telegram-public-profiles-scraper)

### Support

If a run fails, returns no data, or a field looks wrong, open an issue from the Actor page.

Please include the Apify run ID or run URL, input JSON, one example public URL, query, or input item, what you expected, and what the dataset returned. Small reproducible inputs make parsing or site-layout issues much faster to fix.

### Privacy and data handling

This Actor runs with Apify limited permissions and only processes data needed for the documented run. It uses content lookup inputs and public posts, profiles, videos, comments, or channel metadata needed for the requested output to produce the output dataset and sends requests to public Telegram Channel Posts pages/endpoints; results are stored in Apify run storage for your account. FetchCat does not use your inputs or outputs for advertising, does not use them for model training, and does not retain them outside the Apify run except for transient support debugging when you explicitly share run details. You are responsible for using the Actor lawfully, respecting the target site's terms, and avoiding unnecessary personal or sensitive data in inputs.

# Actor input Schema

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

Public Telegram channel usernames or URLs. Examples: telegram, @telegram, https://t.me/s/telegram, https://t.me/telegram.

## `maxPosts` (type: `integer`):

Maximum number of posts to save across all channels.

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

Optional per-channel cap for balanced multi-channel runs. The overall maxPosts limit still applies.

## `maxPagesPerChannel` (type: `integer`):

Safety cap for Telegram history pagination. Increase it for older date windows while keeping the run-time limit in mind.

## `sinceDate` (type: `string`):

Optional ISO date. The actor skips older visible posts when timestamps are available, for example 2026-01-01.

## `untilDate` (type: `string`):

Optional ISO date. The actor skips newer visible posts when timestamps are available, for example 2026-06-01.

## `afterPostId` (type: `integer`):

Optional exclusive message-ID lower bound for incremental monitoring. Use afterPostIds when channels need different checkpoints.

## `afterPostIds` (type: `object`):

Optional object mapping channel usernames to exclusive last-seen post IDs, for example {"telegram": 430, "durov": 350}.

## `includeMedia` (type: `boolean`):

Extract public image/video preview URLs when Telegram exposes them in the public preview HTML.

## `includeRawHtmlSnippet` (type: `boolean`):

Advanced debugging option. Adds a short raw HTML snippet for each post.

## `includeComments` (type: `boolean`):

Fetch public comments for posts whose linked discussion is publicly available. Private, deleted, login-gated, or disabled discussions are not accessed.

## `includeCommentCount` (type: `boolean`):

Fetch the accurate public discussion count for each post. Enabled by default; disable it to reduce requests when replyCount is not needed.

## `maxCommentsPerPost` (type: `integer`):

Maximum number of the most recent public comments to include in each post row when Include public comments is enabled.

## `minComments` (type: `integer`):

Keep only posts with at least this many public comments. A value above 0 checks Telegram's public discussion count for each candidate post.

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

Optional Apify Proxy settings.

## `runTimeSecs` (type: `integer`):

Stop before the platform timeout, preserve saved posts, and write RUN\_SUMMARY diagnostics.

## Actor input object example

```json
{
  "channels": [
    "telegram",
    "durov"
  ],
  "maxPosts": 20,
  "maxPagesPerChannel": 20,
  "includeMedia": true,
  "includeRawHtmlSnippet": false,
  "includeComments": false,
  "includeCommentCount": true,
  "maxCommentsPerPost": 20,
  "minComments": 0,
  "proxyConfiguration": {
    "useApifyProxy": false
  },
  "runTimeSecs": 270
}
```

# Actor output Schema

## `overview` (type: `string`):

API URL for dataset items in the overview view containing scraped public Telegram post rows.

## `runSummary` (type: `string`):

API URL for the RUN\_SUMMARY key-value-store record with per-channel status, counts, and run diagnostics.

# 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": [
        "telegram",
        "durov"
    ],
    "maxPosts": 20,
    "maxPagesPerChannel": 20,
    "includeMedia": true,
    "includeRawHtmlSnippet": false,
    "includeComments": false,
    "includeCommentCount": true,
    "maxCommentsPerPost": 20,
    "minComments": 0
};

// Run the Actor and wait for it to finish
const run = await client.actor("fetch_cat/telegram-channel-posts-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": [
        "telegram",
        "durov",
    ],
    "maxPosts": 20,
    "maxPagesPerChannel": 20,
    "includeMedia": True,
    "includeRawHtmlSnippet": False,
    "includeComments": False,
    "includeCommentCount": True,
    "maxCommentsPerPost": 20,
    "minComments": 0,
}

# Run the Actor and wait for it to finish
run = client.actor("fetch_cat/telegram-channel-posts-scraper").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 '{
  "channels": [
    "telegram",
    "durov"
  ],
  "maxPosts": 20,
  "maxPagesPerChannel": 20,
  "includeMedia": true,
  "includeRawHtmlSnippet": false,
  "includeComments": false,
  "includeCommentCount": true,
  "maxCommentsPerPost": 20,
  "minComments": 0
}' |
apify call fetch_cat/telegram-channel-posts-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "command": "npx",
            "args": [
                "mcp-remote",
                "https://mcp.apify.com/?tools=fetch_cat/telegram-channel-posts-scraper",
                "--header",
                "Authorization: Bearer <YOUR_API_TOKEN>"
            ]
        }
    }
}

```

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/acts/IXhSSJjFf5fz1XAir/builds/01EZyJeL1vGs1YmMR/openapi.json
