DEV Community

Cover image for You don't need Telegram's API to read a public channel — 100 messages, no credentials
Sami
Sami

Posted on

You don't need Telegram's API to read a public channel — 100 messages, no credentials

Every guide to getting data out of Telegram starts the same way: register an app at my.telegram.org, get an api_id and api_hash, install Telethon, log in with a phone number, keep the session file alive, handle the flood-wait errors.

That is the right answer if you need to read a private group, send messages, or act as a user.

For public channels it is the wrong answer, and it costs you a phone number, a session to babysit, and a rate limit.

The endpoint most people miss

Telegram serves a full HTML preview of any public channel at t.me/s/<channel> — note the /s/. Not the t.me/<channel> link you share, which is just an "open in app" splash. The /s/ variant is the channel itself, server-rendered.

I pulled Pavel Durov's channel through it a few minutes ago. 100 messages, 18 seconds, no credentials of any kind. One record, trimmed:

{
  "message_id": "534",
  "date": "2026-07-23T15:15:33+00:00",
  "text": "Very impressed with Georgia…",
  "views": "1290000",
  "views_display": "1.29M",
  "author": "Pavel Durov",
  "channel_verified": true
}
Enter fullscreen mode Exit fullscreen mode

The full record carries 26 fields: message id and permalink, text and text_html, view count, reactions and a reactions total, forward source (name and url), reply-to id, hashtags, mentions, links, media type and media url, plus channel metadata — subscriber count, verified flag, username.

99 of the 100 messages came back with text. The one that didn't was a media-only post, which is correct.

What that costs you

No api_id. No phone number. No session file. No login. No proxy — Telegram serves this from its own CDN and doesn't fight you for it, because it's the same HTML it serves any logged-out browser.

Compare that to the Telethon path for the same 100 public messages: an account, a registered app, a session to keep alive, and a rate limiter to respect.

Where the preview genuinely runs out

I'm not going to pretend it replaces the API. It doesn't:

  • Private or invite-only channels — invisible. The preview only exists for public ones.
  • Member lists — not exposed. Subscriber count yes; who they are, no.
  • Deep archives — it paginates, but it's slower than the API going far back.
  • Anything write-side — sending, joining, reacting. Obviously.

If you need those, you need Telethon and an account. For everything else — monitoring a channel, tracking reach, harvesting a corpus, watching a competitor's announcements — the preview is strictly less work.

Pulling it

The Telegram Channel Scraper on Apify runs the preview path by default, and keeps telethon_api as a mode for when you genuinely need an account:

{
  "channels": ["https://t.me/durov"],
  "mode": "web_preview",
  "maxMessagesPerChannel": 100,
  "extractReactions": true
}
Enter fullscreen mode Exit fullscreen mode

Pass several channels in one run and they share the same job. Turn on deltaMode with a schedule and each run only bills for messages it hasn't seen before — which is what you want when you're watching a channel over weeks instead of taking one snapshot.

The general point

Before you register for an API, check what the platform already renders for a logged-out browser. Telegram, like a lot of platforms, has a public read path that exists for link previews and SEO, and it's often complete enough that the credentialed path is solving a problem you don't have.

The tell is usually a URL variant nobody documents. Here it's one extra path segment.

Top comments (0)