> ## Documentation Index
> Fetch the complete documentation index at: https://docs.scrapeunblocker.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Scrape a public Telegram channel: info and posts

> Reads a public Telegram channel's web preview. Returns `channel` (`username`, `title`, `description`, `avatar`, `verified`, `subscribers` and the other `counters`) and `posts`, newest first: `id`, `url`, `date` (ISO-8601 UTC), `text` (plain), `textHtml`, `views`, `author` (signature), `edited`, `forwardedFrom`, `replyTo`, `media` (photo / video / animation / round_video / voice / audio / document / sticker, with CDN `url`, `thumbnail`, `duration`), `poll`, `linkPreview`, `reactions` (a custom-emoji reaction has its `customEmojiId`, plus the standard `emoji` and `image` Telegram falls back to when the page shows that emoji anywhere), `buttons`, `links`, `hashtags` (the tags Telegram links; a bare '#7' is text) and `mentions`. One page (about 20 posts) by default; `max_posts` (up to 500) pages back through history; `before`, `after` and `since` bound the range, `q` searches inside the channel and `post_id` returns one post. `nextBefore` continues a capped answer. Only channels have a public preview: users, bots, groups and private channels answer 404. Billed one request per page fetched (`pagesFetched`).



## OpenAPI

````yaml /api-reference/openapi.json post /social/telegram-channel
openapi: 3.1.0
info:
  title: ScrapeUnblocker API
  description: >-
    Public API for the ScrapeUnblocker proxy/anti-bot service. Authenticate
    every request with the `x-scrapeunblocker-key` header. Documented here:
    page-source extraction, Google SERP scraping, image fetch, and the dedicated
    plugin endpoints (search engines, marketplaces, reviews, travel, social and
    more). All other paths exist for internal operations and are intentionally
    hidden from this spec.
  version: 3.0.0
servers:
  - url: https://api.scrapeunblocker.com
    description: Production
security: []
paths:
  /social/telegram-channel:
    post:
      tags:
        - Plugins
      summary: 'Scrape a public Telegram channel: info and posts'
      description: >-
        Reads a public Telegram channel's web preview. Returns `channel`
        (`username`, `title`, `description`, `avatar`, `verified`, `subscribers`
        and the other `counters`) and `posts`, newest first: `id`, `url`, `date`
        (ISO-8601 UTC), `text` (plain), `textHtml`, `views`, `author`
        (signature), `edited`, `forwardedFrom`, `replyTo`, `media` (photo /
        video / animation / round_video / voice / audio / document / sticker,
        with CDN `url`, `thumbnail`, `duration`), `poll`, `linkPreview`,
        `reactions` (a custom-emoji reaction has its `customEmojiId`, plus the
        standard `emoji` and `image` Telegram falls back to when the page shows
        that emoji anywhere), `buttons`, `links`, `hashtags` (the tags Telegram
        links; a bare '#7' is text) and `mentions`. One page (about 20 posts) by
        default; `max_posts` (up to 500) pages back through history; `before`,
        `after` and `since` bound the range, `q` searches inside the channel and
        `post_id` returns one post. `nextBefore` continues a capped answer. Only
        channels have a public preview: users, bots, groups and private channels
        answer 404. Billed one request per page fetched (`pagesFetched`).
      operationId: telegram_channel_social_telegram_channel_post
      parameters:
        - name: channel
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            description: >-
              Public channel: username ('durov'), '@durov', or a t.me link
              ('https://t.me/durov', 'https://t.me/s/durov'). A post link
              ('https://t.me/durov/400') returns that one post.
            title: Channel
          description: >-
            Public channel: username ('durov'), '@durov', or a t.me link
            ('https://t.me/durov', 'https://t.me/s/durov'). A post link
            ('https://t.me/durov/400') returns that one post.
        - name: max_posts
          in: query
          required: false
          schema:
            anyOf:
              - type: integer
              - type: 'null'
            description: >-
              Posts to collect, newest first (1-500), paging back through the
              channel's history; each page fetched is billed as one request.
              Omit it for one page, billed once: the newest posts (a page has 20
              message slots and an album fills one per photo, so it can hold
              fewer posts).
            title: Max Posts
          description: >-
            Posts to collect, newest first (1-500), paging back through the
            channel's history; each page fetched is billed as one request. Omit
            it for one page, billed once: the newest posts (a page has 20
            message slots and an album fills one per photo, so it can hold fewer
            posts).
        - name: before
          in: query
          required: false
          schema:
            anyOf:
              - type: integer
              - type: 'null'
            description: >-
              Only posts with an id below this one. Pass `nextBefore` of a
              previous response to continue where it stopped.
            title: Before
          description: >-
            Only posts with an id below this one. Pass `nextBefore` of a
            previous response to continue where it stopped.
        - name: after
          in: query
          required: false
          schema:
            anyOf:
              - type: integer
              - type: 'null'
            description: 'Stop at this post id: only posts with a higher id are returned.'
            title: After
          description: 'Stop at this post id: only posts with a higher id are returned.'
        - name: since
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            description: >-
              Stop at this date: only posts published on or after it (YYYY-MM-DD
              or an ISO-8601 datetime, UTC when no offset is given).
            title: Since
          description: >-
            Stop at this date: only posts published on or after it (YYYY-MM-DD
            or an ISO-8601 datetime, UTC when no offset is given).
        - name: q
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            description: 'Search inside the channel: only posts matching this text.'
            title: Q
          description: 'Search inside the channel: only posts matching this text.'
        - name: post_id
          in: query
          required: false
          schema:
            anyOf:
              - type: integer
              - type: 'null'
            description: Return only this post (a post id of the channel).
            title: Post Id
          description: Return only this post (a post id of the channel).
        - name: proxy_country
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            description: Exit-IP country (ISO-2). Blank lets us pick the exit.
            title: Proxy Country
          description: Exit-IP country (ISO-2). Blank lets us pick the exit.
      responses:
        '200':
          description: >-
            JSON with `channel`, a `posts` array, `postsReturned`,
            `pagesFetched`, `hasMore` and `nextBefore`.
          content:
            application/json:
              schema: {}
        '400':
          description: Invalid parameters.
        '404':
          description: No public channel preview under that name, or no such post.
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
        '502':
          description: Telegram returned no usable page.
        '504':
          description: Fetch timed out.
      security:
        - ScrapeUnblockerKey: []
components:
  schemas:
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          type: array
          title: Location
        msg:
          type: string
          title: Message
        type:
          type: string
          title: Error Type
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError
  securitySchemes:
    ScrapeUnblockerKey:
      type: apiKey
      in: header
      name: x-scrapeunblocker-key
      description: Your ScrapeUnblocker API key. Apply on every request.

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.