How to Scrape Telegram Group Members with Apify A Step‑by‑Step Guide

How to Scrape Telegram Group Members with Apify: A Step‑by‑Step Guide

Key Takeaways

Topic Summary
Apify Telegram Scraper Setup Use Apify’s Telegram actor to extract members from public groups using QR-authenticated sessions and proxy rotation.
n8n Workflow Automation Automate the entire scraping, filtering, and member-inviting process in n8n using triggers, schedules, and conditional logic.
Parameter-Based Control Customize behavior via inputs like scrapeGroup, count, addToGroup, and proxyConfig.
Compliance & Limits Avoid rate limits by using randomized delays, minimal invites per run, and proxy networks for longer-term reliability.
Output Filtering & Use Scraped data includes username, last_seen, is_bot—which can be filtered, analyzed, or pushed to CRMs or Telegram bots.
Ethical & Legal Guidance Stay compliant with Telegram TOS and local data laws. Use automation responsibly, with opt-in value and clear messaging.
Recommended Services and Products
Done-for-You Telegram Scraper Setup We set up your custom Telegram scraper inside n8n from start to finish—includes actor config, proxy setup, scheduling, and filters.
Book Setup Service
Apify Telegram Scraper This Apify actor lets you scrape and optionally invite Telegram users—just authenticate via QR code and configure your group URLs.
Try the Scraper
Managed n8n Hosting & Automation Let us host your n8n instance, monitor performance, and provide ongoing automation support—perfect for long-term growth loops.
View Hosting Plans

Telegram continues to be one of the most effective platforms for building niche communities, distributing content, and engaging directly with audiences. But growing a Telegram channel organically takes time—and often requires competing for the attention of users already active in other groups. This is where automation comes in.

This article walks through how to set up a fully automated Telegram group scraping and member-adding pipeline using Apify and n8n. You’ll learn how to extract members from public groups, automatically invite them to your own, and schedule the process to run without manual intervention. All of this is done visually through n8n’s no-code interface, making it scalable and repeatable for marketers, community managers, or growth hackers looking to expand their Telegram presence efficiently.

Why Automate Telegram Scraping with Apify via n8n

Growing a Telegram community can be a manual and repetitive process. Tasks like identifying relevant groups, collecting member usernames, and inviting them to your own channel take significant time—and scale poorly. Automating this flow using Telegram scraping with Apify inside n8n provides a robust, repeatable alternative.

With the right configuration:

  • You can extract Telegram group members in bulk, capturing data like usernames, IDs, and activity status.
  • You can automatically invite scraped users to your own group or channel.
  • You can schedule the entire pipeline on a recurring basis (hourly, daily, etc.) without needing manual steps.

This automation is entirely no-code. It leverages the power of n8n as a visual automation platform and connects with Apify’s actor engine to do the heavy lifting. Once configured, the system can run in the background while keeping your outreach aligned, consistent, and scalable.

Using the Apify Actor for Group Scraping

The workflow relies on the Apify Actor called curious_coder/telegram-scraper-and-adder, which serves as the main engine for scraping and auto-inviting. This actor is purpose-built for scenarios involving Telegram group member extraction and automated Telegram growth.

Here’s how it works:

  • Scrapes group members from a public group or channel, collecting metadata such as user IDs, usernames, and bot detection.
  • Adds members directly to another group or channel if Telegram permissions allow.
  • Tolerates Telegram limits by supporting pagination and introducing random delays between user actions.
  • Handles authentication through a QR code session token, which is reused for future runs.

This actor is invoked via the Apify node in n8n, where you provide configuration options (e.g. group URL, number of members to scrape, and whether to add users immediately). The actor runs asynchronously and returns a JSON response that can then be used by other n8n nodes in the workflow.

Prerequisites: Setting Up n8n for Telegram Scraping

Everything required to run the workflow—scraping and automation—is handled inside n8n. Here’s what needs to be in place:

Apify API Token

  • Sign up for an Apify account.
  • Navigate to Integrations → Personal API Tokens.
  • Generate your token and save it.
  • Add the token to your n8n instance using the Apify credentials in the Apify node.

This allows n8n to trigger Apify actors and pull their output into the workflow.

Telegram Authentication

The Apify actor requires access to your Telegram account to perform actions:

  • Run the actor using the Apify node inside n8n.
  • A QR code will be displayed in Apify’s logs.
  • In the Telegram mobile app, go to Settings → Devices → Scan QR Code and authorize the session.
  • After successful login, the actor generates an authToken, which can be reused in future runs.

That token can be stored in an n8n environment variable or in a secure credential field for reusability.

n8n Telegram Node (Optional for Follow-up)

Once data is scraped and users are added, n8n’s native Telegram nodes can take over to:

  • Send welcome messages to new members.
  • Log activity to Google Sheets or Airtable.
  • Trigger alerts when a threshold number of users is added.

This eliminates the need for custom code or additional platforms—everything remains centralized and manageable from the n8n editor.

Input Parameters Deep Dive: Understanding How to Configure Your Scrape

Once the Apify actor is authenticated and set up in n8n, configuring it correctly is critical to pulling useful, actionable Telegram data. The Apify node inside n8n requires several input fields for the curious_coder/telegram-scraper-and-adder actor to run as expected.

Here’s a breakdown of the most important input parameters and what they control:

authToken

This is the session authentication token you receive after logging into Telegram via Apify’s QR code flow. It’s a reusable credential that allows the actor to impersonate your session to scrape and optionally add members.

scrapeGroup

This is the public Telegram group or channel URL you want to extract members from. Example:

https://t.me/some_competitor_group

Ensure the group is public, and your Telegram account has access.

addToGroup (Optional)

This is the destination group or channel where members will be auto-added after scraping. Leave this empty if you only want to extract members.

https://t.me/your_target_group

Make sure the authenticated Telegram account has permission to invite members to this group.

startPage and count

These two fields control pagination:

  • startPage: The page to start scraping from (default is 1).
  • count: The number of pages to scrape. One page typically returns between 20 to 50 users, depending on group activity.

For example, setting startPage: 1 and count: 3 will extract users from the first three pages of the group’s member list.

Example JSON Payload

When configuring the Apify actor node in n8n, the fields are set through the “Input” tab. Here’s an example of what your configuration might look like inside a Set node that precedes the Apify actor execution:

{
  "authToken": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9...",
  "scrapeGroup": "https://t.me/some_competitor_group",
  "addToGroup": "https://t.me/your_target_group",
  "startPage": 1,
  "count": 2
}

This configuration will extract the first two pages of members from some_competitor_group and attempt to invite them to your_target_group.

Rate-Limiting and Proxy Configuration

Telegram is aggressive in limiting automation behavior that looks spammy. To avoid detection or bans, it’s important to understand how the actor handles rate-limiting and how you can improve stability using proxies.

Why Telegram Blocks Bots

Telegram monitors the following behaviors to identify and restrict bot-like activity:

  • High-frequency scraping or adding
  • Inviting too many users in a short time
  • Accounts operating repeatedly from the same IP address

These actions may result in temporary limitations or permanent bans of your Telegram account.

Built-in Protections

The curious_coder actor includes multiple strategies to help reduce the risk of getting blocked:

  • Random delays between user interactions
  • Pagination controls that limit how many members are scraped per run
  • A SessionPool to reuse session tokens across runs without logging in again

These features simulate human behavior, making the automation harder for Telegram’s system to flag as suspicious.

Using Proxies with Apify

Apify allows actors to run through proxy networks for enhanced anonymity. This becomes essential when you scale your operations across large or multiple groups.

In the Apify configuration section of the n8n node, you can optionally define:

  • proxyConfiguration: Specify whether to use Apify’s shared, residential, or custom proxy groups
  • maxUsageCount: Set how often a single proxy can be reused before it’s rotated

This adds an important layer of protection, especially when running high-volume or frequent scraping jobs. Proxy rotation helps prevent your Telegram session from being tied to a single IP address, lowering the risk of rate-limiting or bans.

 

Step-by-Step: Triggering the Workflow in n8n

Once everything is set—authentication token, group URLs, pagination parameters—you can start building the full automation flow within n8n.

Here’s a typical n8n pipeline for Telegram scraping and member importing:

Step 1: Manual Trigger or Schedule

Use a Manual Trigger to test the flow during development.

Later, replace this with a Cron node to run the scraping job on a schedule (for example, daily at midnight).

Step 2: Set Node – Input Parameters

Create a Set node that holds the JSON input parameters discussed in Section 4.

These parameters are then mapped to fields expected by the Apify actor.

Step 3: Apify Node – Run Actor

Use the “Apify: Run Actor” node in n8n.

  • Set the actor ID to curious_coder/telegram-scraper-and-adder.
  • Pass in the data from the Set node.
  • Enable the option “Wait for Actor Run to Finish” to ensure the output is available for the next steps.

Step 4: Parse Actor Output

Add a HTTP Request or Webhook node to fetch the actor’s output dataset from Apify once the run is complete.

Convert the raw response into structured JSON objects, each representing one Telegram user.

Step 5: Optional Post-Processing

Depending on your use case, follow up with one or more of the following actions:

  • Use Telegram nodes to send automated welcome messages to new members.
  • Filter inactive or bot accounts using logic nodes or expressions.
  • Store scraped user data into tools like Airtable, Google Sheets, or a connected CRM.

This complete pipeline allows you to run the scrape–add–analyze loop entirely within n8n, without requiring external scripts or code.

Interpreting Scrape Results: What You Get Back

The output from the Apify actor is a JSON array of Telegram user profiles. Understanding the structure of this data helps with filtering and prioritizing your outreach strategy.

Example Output

[
  {
    "id": 1582452473,
    "username": "john_doe",
    "first_name": "John",
    "last_seen": "recently",
    "is_bot": false,
    "status": "member"
  }
]

Key Fields

  • id: The unique Telegram user ID.
  • username: The user’s public handle, if available.
  • first_name: The user’s display name.
  • last_seen: Shows how recently the user was active (e.g., recently, within a week, long time ago).
  • is_bot: A boolean flag indicating whether the account is a bot.
  • status: The user’s role in the source group (e.g., member, admin, creator).

How to Use This Data

  • Filter out bots by removing entries where is_bot is true.
  • Prioritize engagement by selecting users with last_seen values like “recently” or “within a week.”
  • Log Telegram IDs and usernames for follow-up messages via Telegram bots or for CRM logging.

When used with smart filters and categorization, this dataset becomes a high-value source for targeted community growth and outreach campaigns.

Automate Member Adding & Growth Scheduling

Once the Apify actor is integrated and your Telegram session is authenticated, the process of adding scraped members to your own Telegram group can also be automated from within n8n.

Auto-Adding Members to Your Channel

If the addToGroup field is set, and your Telegram account has permission to invite users, the Apify actor will attempt to add each scraped user automatically. However, Telegram has invite limits per account, typically allowing around 50–100 invites per day, depending on your account’s reputation.

To stay compliant and avoid throttling:

  • Set the count parameter conservatively (e.g., 1 or 2 pages).
  • Let the actor introduce random delays between each invite.
  • Schedule scraping and adding to occur in cycles (e.g., every 24 hours).

Automating with n8n’s Scheduler

Using the Cron node in n8n, you can run the entire process—scraping, adding, and post-processing—on an automated schedule. Example use cases include:

  • Daily growth loops: Pull members from a competitor group each day and add them to your own.
  • Weekly outreach: Extract members and feed them into a lead nurturing funnel or DM campaign.
  • Recurring monitoring: Identify new members from a group and store them in Airtable or a database.

You can also add a filter layer in n8n to exclude previously scraped Telegram user IDs to avoid repeated invites.

Post-Integration with Other Apps

After users are scraped and optionally added, n8n can forward this data to other apps:

  • CRMs (e.g., Pipedrive, HubSpot)
  • Google Sheets (for reporting or manual vetting)
  • Telegram Bot Node (to send welcome or promo messages)
  • Email marketing tools (if opt-in)

n8n acts as a full automation hub, handling not just the scrape/add flow, but what happens afterward—engagement, tracking, reporting, and more.

Handling Failures & Telegram Bans

Telegram’s infrastructure is sensitive to scraping and bot-like behavior. Although the Apify actor includes built-in mechanisms to avoid flags, it’s important to be aware of the most common pitfalls—and how to recover from them.

Common Issues

  • Could not find input entity: Usually caused by private groups, invalid links, or expired invite URLs.
  • Auth token errors: The session may have expired or been invalidated due to inactivity or an IP change.
  • Bans or soft blocks: Telegram may temporarily restrict the account from joining or inviting users.

Prevention Tactics

  • Use rotating proxies to delay detection if running frequent scrapes.
  • Keep sessions fresh by re-authenticating periodically via the QR flow.
  • Throttle scraping volume by limiting users per run and increasing the time between actions.

Recovery

If an account is soft-banned (e.g., unable to invite users for a few days), stop all automated flows and switch to a backup account if needed. Ensure re-authentication is done from the same IP range or proxy to avoid additional flags.

By designing your flow around these limitations, you reduce the chance of interruption and maximize the longevity of your scraping system.

Best Practices & Legal / Ethical Notes

Scraping Telegram group members—especially for the purpose of adding them to your own community—carries both technical and legal risks. To use these tools responsibly, follow these best practices.

Legal Considerations

  • Check local data privacy laws. In some jurisdictions, scraping user data—even if public—may be considered a privacy violation.
  • Understand Telegram’s Terms of Service. Automated scraping and unsolicited invitations may breach their platform rules.

Ethical Best Practices

  • Avoid spammy behavior. Do not mass-invite or DM users aggressively.
  • Respect opt-in norms. Offer value and always make it easy to unsubscribe or ignore.
  • Focus on quality. Use scraped data to grow a meaningful and engaged community—not just large numbers.

Balancing automation with ethical outreach ensures your Telegram growth strategy is not only scalable but also sustainable and respectful.

Wrap-Up: From Scrape to Growth in One Flow

This guide walked through the full pipeline of using Apify’s Telegram scraper inside n8n to:

  • Authenticate and configure Apify to connect to Telegram
  • Scrape members from any public group or channel
  • Optionally auto-add those members to your own Telegram community
  • Schedule, monitor, and extend the process using n8n automations

The combination of Apify’s actor engine and n8n’s modular workflows makes it possible to scale Telegram audience building with minimal manual effort. From scraping to messaging to follow-up, everything can be automated in a repeatable loop.

Whether you’re growing a marketing list, building a community, or testing outreach strategies, this system gives you the control and flexibility to scale smartly.

If you’d like a custom workflow built or need help setting up this process, click here to book a call or order the automation.

Leave a Comment

Your email address will not be published. Required fields are marked *