Telegram Bot for Paid Communities: Development and Pricing
How a Telegram paid community bot works, what it must build under the hood, which payment methods fit, and what it costs to commission one.
The Problem With Gating Access on Telegram
Telegram is built for open communication. That design philosophy is a strength for public communities and broadcast channels — and a genuine problem for anyone trying to charge for access.
No Native Paid-Access Layer
Telegram has no built-in mechanism to require payment before joining a group or channel. You can make a group private and distribute invite links, but the platform itself has no concept of a paying subscriber. Once someone has a link, they are in. Once they cancel, they stay in unless someone removes them manually.
Permanent Links Break the Model
This is the core structural problem. A permanent invite link — the default tool most community owners reach for — can be copied and forwarded. A subscriber who stops paying can share that link with ten non-paying friends. There is no way to detect this after the fact, and no way to prevent it without revoking the link entirely, which locks out everyone who used it legitimately.
Manual Enforcement Does Not Scale
Tracking who paid, when their subscription expires, and whether they are still a member is manageable for a handful of people. At fifty members it becomes a part-time job. At two hundred it breaks entirely. Human error, time zones, and the volume of renewals and cancellations make manual moderation unreliable by design.
Off-the-Shelf Tools Have a Ceiling
Third-party subscription platforms that layer on top of Telegram exist, but they come with fixed fee structures, limited payment provider choices, and no room for custom logic — tiered access, free trials, grace periods, or webhook-driven integrations with your existing stack.
This Is an Infrastructure Problem
A purpose-built telegram paid community bot solves all three issues at once: it controls who receives an invite, tracks when access should expire, and enforces that expiry automatically — without any manual intervention. The rest of this article explains exactly how.
What a Telegram Paid Community Bot Actually Does
The core job is simple to describe and precise to build: verify that a user has paid, generate a one-time invite link, admit them to the group or channel, track when their subscription expires, and remove them if they do not renew. Every other feature — tiers, trials, dashboards — sits on top of this foundation.
The One-Time Invite Link Mechanism
Telegram's Bot API lets a bot create invite links that are both single-use and time-limited. When a subscriber completes payment, the bot calls createChatInviteLink with member_limit set to 1. The resulting link works exactly once: the moment the subscriber joins, the link is consumed and cannot be used again.
This matters because it closes the obvious loophole. A subscriber who shares a one-time link with a friend cannot grant that friend access — the link is already dead. The paying subscriber is the only person who ever enters through it.
Why Permanent Links Break the Gate Entirely
A permanent invite link — the kind Telegram generates by default in group settings — can be copied, posted publicly, and used by anyone indefinitely. If a community owner shares one of these links as their "paid" access method, the paid gate does not exist. One subscriber can admit hundreds of non-paying members and there is no technical mechanism to detect or stop it. A bot that issues one-time links per verified payment is the only reliable solution.
The Subscriber Lifecycle
| Stage | What happens |
|---|---|
| Payment received | Bot verifies payment, generates a one-time invite link, sends it to the user |
| Member active | User joins; bot records membership start date and expiry date in the database |
| Expiry approaching | Bot sends a renewal reminder via direct message |
| Renewed | Bot updates the expiry date; member stays in the group |
| Not renewed | Bot calls kickChatMember or restrictChatMember; member loses access |
The bot operates silently for most of a subscriber's lifetime. Members interact with it only at two moments: initial payment and renewal. Between those points, the bot runs scheduled checks in the background without any visible presence in the group.
Telegram groups support up to 200,000 members (source: telegram.org), so the subscriber database and expiry-check jobs must be designed to handle that scale from the first deployment, not retrofitted later.
The Four Core Mechanics Every Paid Community Bot Needs
A paid community bot is only as reliable as its weakest mechanic. Miss any one of these four and the gating breaks — either users get in without paying, or paying users get kicked by mistake.
1. Payment Capture
The bot must confirm money received before it does anything else. Three paths exist:
- Telegram Payments API with a card provider (Stripe, Payme, etc.): the user pays inside Telegram via a native invoice; the bot receives a
successful_paymentupdate. Familiar checkout flow, but requires a connected payment provider and card details. - Telegram Stars: fully in-app, no card required. The bot sends a Stars invoice; on success it receives the same
successful_paymentupdate. Lower friction for users already holding Stars, but Stars are an in-app currency with their own conversion path to fiat. - External gateway webhook: the user pays on an outside page (Stripe Checkout, crypto processor, etc.); the gateway posts a signed webhook to the bot's endpoint, which then triggers the invite flow. More flexible for recurring billing but adds an external dependency.
Each path produces a payment reference the bot stores immediately. No reference, no invite.
2. Invite-Link Management
Permanent invite links break paid gating — anyone who copies the link can share it. The correct call is:
createChatInviteLink( chat_id, member_limit=1, expire_date=<unix_timestamp> )
This generates a single-use link that expires after one join or after the timestamp, whichever comes first. The bot stores the returned invite_link ID, then marks it consumed once the chat_member update confirms the user joined.
3. Subscription State Tracking
Every subscriber gets one database row:
| Field | Purpose |
|---|---|
user_id | Telegram user identifier |
plan | Tier name and billing interval |
payment_ref | Provider transaction ID |
start_date | When access began |
expiry_date | When access lapses |
renewal_status | active / reminded / lapsed |
This record is the single source of truth. Every enforcement decision reads from it.
4. Expiry Enforcement and Renewal Reminders
A scheduled job — typically running daily — queries for rows where expiry_date is past and renewal_status is not active. It then calls one of two Bot API methods:
kickChatMember: removes the user from the group entirely. They must rejoin via a new paid invite link. Use this for hard expiry with no grace period.restrictChatMember: keeps the user in the group but strips permissions (read-only or fully muted). Use this during a grace period — the user can still see a pinned renewal message but cannot post.
Before expiry hits, the bot sends a direct message with an inline payment button — typically 48 hours and again 24 hours out. This pre-expiry reminder is the simplest lever for reducing involuntary churn from users who simply forgot to renew.
Payment Integration Options and Their Trade-offs
Every paid community bot needs a way to capture money before it hands out access. There are three practical paths, and the one you choose shapes how the bot is built.
The Three Paths at a Glance
| Method | Friction | Recurring support | Withdrawal | Backend complexity |
|---|---|---|---|---|
| Telegram Stars | Very low — no card, no redirect | Manual re-purchase or bot-prompted renewal | Conversion required per Telegram's terms | Low — stays in-app |
| Card via Telegram Payments API | Low — native checkout sheet | Yes, via provider-side subscription tokens | Direct to your payment provider account | Medium — provider account and approval needed |
| External gateway (crypto or fiat) | Medium — depends on provider | Yes, if provider supports it | Depends on provider | High — public webhook + reconciliation logic |
Telegram Stars
Stars are Telegram's native in-app currency. A user pays without leaving the app, without entering card details, and without any redirect. The bot receives a payment confirmation event and can act on it immediately.
The trade-off is liquidity. Stars are not fiat. Converting them back to cash is subject to Telegram's own terms and conversion process. For communities where the audience already holds Stars — creators, gaming communities, Telegram-native audiences — this is often the right default. For a deeper look at how Stars work as a monetization layer, the studio's Telegram Stars monetization article covers the mechanics in full.
Card Payments via Telegram Payments API
Telegram's Payments API connects to approved providers — Stripe, Xsolla, and others — and presents a native checkout sheet inside the app. The user sees a familiar card form; the bot receives a successful payment callback.
Provider-side subscription tokens make recurring billing possible: the provider stores the payment method and charges it on schedule, sending the bot a webhook on each renewal. This path requires a provider account, approval, and integration work, but it keeps the checkout experience inside Telegram.
External Gateway via Webhook
For teams that need crypto payments (USDC, SOL, ETH) or non-card fiat options (PayPal, bank transfer), an external gateway is the answer. The gateway sends a webhook to a public endpoint on the bot's server when a payment clears. The bot then reconciles that event against its subscriber database and grants or renews access accordingly.
This path offers the most flexibility but demands the most backend logic: webhook verification, idempotency handling, and payment-to-subscriber matching all need to be built and tested carefully.
How the Choice Affects Architecture
Stars and Telegram Payments stay entirely inside Telegram's infrastructure — no public-facing payment endpoint is required. An external gateway introduces a public webhook URL, a reconciliation layer, and additional failure modes to handle. That complexity is reflected in build time and cost.
Payment integration is priced as an extra on top of the base bot build, alongside AI features and other third-party integrations.
Note: This is not financial or legal advice. Operators should verify their jurisdiction's requirements for collecting subscription payments, including any licensing, tax registration, or consumer protection obligations that apply to recurring billing.
Architecture: What Gets Built Under the Hood
A paid community bot is not a single script — it is a small distributed system with four cooperating components. Each one has a specific job, and if any of them is missing, the access control breaks down.
The Four Components
Bot process. A Node.js/TypeScript application connects to the Telegram Bot API in webhook mode (preferred for production) or long-polling. It handles incoming messages, payment callbacks from Telegram, and outbound API calls to manage chat membership.
PostgreSQL database. All subscriber state lives here — who paid, which plan, when access expires, and what their current status is. The studio uses Prisma as the ORM, which keeps the schema versioned and migrations reproducible.
Webhook endpoint. An HTTPS endpoint receives payment notifications from the external payment provider (Stripe, NOWPayments, or the Telegram Payments API callback). The endpoint validates the payload signature, then writes or updates the subscriber record.
Scheduled job runner. A cron-based process queries the database on a fixed schedule — typically every few hours — to find subscribers whose access has lapsed. This must run as a persistent process, not a serverless function. Serverless cold-start timing is unreliable for enforcement logic that needs to fire at a predictable time.
Database Schema
The core tables look like this:
| Table | Key columns |
|---|---|
subscribers | user_id, plan_id, payment_ref, starts_at, expires_at, status |
plans | plan_id, name, price, duration_days, trial_days |
payments_log | payment_id, user_id, provider, amount, currency, created_at |
Webhook Flow
Payment provider → POST /webhook → validate HMAC signature → upsert subscriber record (status = active, expires_at = now + plan.duration_days) → call createChatInviteLink (member_limit: 1, expire_date: +15 min) → sendMessage to user with the one-time link
The invite link is single-use and short-lived. Once the user joins, the link becomes invalid — a permanent link would let anyone who has ever seen it re-enter after being kicked.
Expiry Enforcement
The scheduled job runs this logic:
SELECT * FROM subscribers
WHERE expires_at < NOW() AND status = 'active'
For each result, the bot sends a renewal reminder via sendMessage, then — after a configurable grace period — calls kickChatMember to remove the user. The restrictChatMember call is available as a softer alternative: it can mute the user rather than remove them, which suits communities where lurking without posting is acceptable during a grace window.
Bot API Calls in Use
answerPreCheckoutQuery— required to confirm or reject a Telegram Payments checkout before the charge is appliedcreateChatInviteLink— generates the one-time, expiring link sent after paymentkickChatMember— removes an expired subscriber from the group or channelrestrictChatMember— applies permission restrictions without removalsendMessage— delivers confirmation, links, reminders, and renewal prompts
Hosting
The bot process and PostgreSQL instance run on the studio's own servers with SSL termination, daily backups, and uptime monitoring.
Tiered Plans, Trials, and Upsells: Features That Increase Revenue
A basic paid community bot handles one group and one price. That is enough to start, but most community owners eventually want more levers. The features below are common requests — each one adds real revenue potential and real complexity to the subscriber state machine.
Multiple Tiers
A bot can manage several groups or channels simultaneously, each with its own price, invite-link pool, and expiry logic. A typical setup:
| Tier | Group | Monthly Price | Access |
|---|---|---|---|
| Free | Public channel | $0 | Read-only announcements |
| VIP | Separate private group | $49 | Direct Q&A + early access |
Each tier is a separate entry in the database. The bot issues the correct one-time invite link based on which product the user paid for, and enforces expiry independently per group.
Free Trials
The bot generates a time-limited invite link without requiring payment. A trial record is written to the subscriber table with a trial_expires_at timestamp. The daily expiry job checks trial records the same way it checks paid subscriptions — when the trial lapses, the bot sends a conversion prompt and restricts access if the user does not upgrade.
Referral Codes
Telegram's /start command accepts a deep-link parameter: /start ref_abc123. The bot reads that parameter, looks up the referring member, and credits them with an extended subscription period. The referring member's expires_at field is updated in place — no separate referral table is strictly required, though one makes reporting cleaner.
Upsell Prompts
At renewal time, the bot's message to a standard-tier member can include an inline keyboard button that initiates the VIP payment flow directly. One tap, no navigation required.
Pause and Resume
A subscriber can pause for a defined window — say, up to 30 days per year. The bot stores paused_at and resume_at, halts the expiry countdown, and holds the user's group membership. This is particularly useful for communities with seasonal demand cycles.
Every one of these features touches the subscriber state machine. Adding them after launch is significantly more expensive than scoping them before build. Decide which features belong in version one before development starts.
The Admin Dashboard: What a Community Owner Needs to See
Running a paid community without visibility into who is subscribed, when they expire, and how much revenue is active is operationally blind. A purpose-built admin dashboard solves that.
Subscriber List
The core view is a table of every subscriber, past and present:
| Field | What it shows |
|---|---|
| Name / Username | Telegram display name and @handle |
| Plan | Which tier the subscriber is on |
| Payment Method | Stars, card, or crypto |
| Start Date | When access was first granted |
| Expiry Date | When the current period ends |
| Status | Active, Expired, Cancelled, Complimentary |
Sorting and filtering by status or plan lets you find edge cases quickly — a subscriber showing Active past their expiry date means the enforcement job has a problem.
Revenue View
A separate panel shows total active subscribers, monthly recurring revenue broken down by plan, and a scrollable payment history log. This is not a replacement for accounting software, but it gives the community owner a live snapshot without querying a database manually.
Manual Override
Admins need direct control over individual accounts:
- Extend expiry — add days or months without requiring a new payment, useful for handling support cases or disputes
- Cancel early — remove access immediately and flag the record as cancelled
- Issue a complimentary invite link — grant access outside the payment flow for partners, moderators, or promotional slots
Churn View
Cancelled and expired subscribers are listed separately with the date they left. Reviewing this view weekly helps identify whether drop-off clusters around a specific renewal date, plan tier, or payment method.
Export
CSV export of the full subscriber table covers accounting and CRM imports without manual data entry.
Interface Options
The dashboard can be built as a web interface using Next.js and PostgreSQL, or as a Telegram Mini App for operators who prefer to manage everything without leaving Telegram. Both options connect to the same database the bot writes to.
Telegram Communities (July 2026) and Why You Still Need a Bot
Telegram introduced the Communities feature on July 14, 2026. It lets operators link several groups, channels, and bots under a single umbrella — giving members a unified space to navigate between a public discussion group, a private signals channel, a VIP strategy room, and a bot, all without leaving a shared context.
That is a meaningful organisational improvement. It is not a monetisation layer.
What Communities Does and Does Not Do
| Capability | Telegram Communities | Paid Community Bot |
|---|---|---|
| Link multiple groups and channels | ✅ | ❌ |
| Unified member navigation | ✅ | ❌ |
| Verify payment before granting access | ❌ | ✅ |
| Generate one-time invite links | ❌ | ✅ |
| Track subscription expiry dates | ❌ | ✅ |
Call kickChatMember on lapse | ❌ | ✅ |
| Send renewal reminders | ❌ | ✅ |
Communities handles structure. The bot handles enforcement.
How They Work Together
Consider a community operator running three spaces: a free discussion group open to anyone, a paid signals group at one tier, and a VIP strategy group at a higher tier. Using Communities, all three sit under one roof and members see them as a coherent product. Using a bot, each paid group is gated independently — the bot verifies payment, issues a one-time invite link per group, and removes access when a subscription lapses. The organisational layer and the access-control layer do each job they are actually designed to do.
Without the bot, Communities gives you a tidy front door with no lock on it.
A Note on Token Gating
Token gating is a distinct architecture. It uses on-chain wallet verification — checking whether a wallet holds a required token or NFT — rather than processing a payment receipt and tracking a subscription lifecycle. If your access model is ownership-based rather than subscription-based, that is a separate pattern and a separate build. The studio covers that approach in the Mini App crypto communities article.
For subscription-based paid communities, a payment bot remains the correct tool regardless of how many groups you link together inside a Community.
Development Cost and What the Studio Builds
WEB3 Build Studio prices Telegram bots on a fixed-price model agreed after a short scoping call. You describe your community setup — number of groups, payment methods, plan tiers, and any admin tooling you need — and the studio comes back with a scope and a number. No open-ended hourly billing.
The Three Tiers
| Tier | Price | What it covers |
|---|---|---|
| Start | $300 | Single group, one payment method, basic expiry logic and kick enforcement |
Every tier includes design, build, deployment, and 30 days of bug fixes. Payment integrations and AI features — for example, an AI-powered onboarding flow or automated content delivery — are scoped and priced on top of the base figure.
What Gets Built
Regardless of tier, the studio engineers the system around your actual problem rather than adapting a template. A typical paid community bot build includes:
- Node.js bot process — handles commands, payment callbacks, and Telegram API calls
- PostgreSQL subscriber database — stores user state, plan type, payment reference, and expiry date
- Payment webhook integration — receives confirmation from your chosen provider and triggers the invite flow
- One-time invite link logic — generates a fresh, single-use link per subscriber after payment clears
- Scheduled expiry enforcement — daily job that checks expiry dates, sends renewal reminders, and calls
kickChatMemberorrestrictChatMemberwhen a subscription lapses - Admin dashboard or Mini App interface (Pro tier) — subscriber list, revenue view, expiry dates, and manual override controls
One team handles architecture, development, and deployment with no handoffs to separate contractors.
Monthly Care
For a community where access control is the product, unmonitored downtime is a direct revenue problem — the care plan covers that.
Get a Fixed Price
If you are ready to move past the limitations of off-the-shelf subscription tools, share your community setup with the studio and get a fixed-price scope within a few days.
Describe your community, your preferred payment method, and the number of tiers you need at web3buildstudio.com/#/contact — the studio will come back with a fixed price and a timeline.
Frequently asked questions
Can I use Telegram Stars to charge for community access?
Yes. Telegram Stars is Telegram's native in-app currency and a practical payment option for community access, especially if your audience is already active on Telegram. The bot handles the Stars transaction, confirms payment, and grants group access automatically. The main trade-off is that Stars payouts go through Telegram's own withdrawal process, so factor that into your revenue flow planning. If you need fiat, card, or crypto payments instead, those require integrating an external payment provider, which adds to the build cost.
What happens when a subscriber's payment fails or their subscription expires?
The bot should handle this automatically. On expiry, it checks whether a renewal payment has been received; if not, it revokes the user's invite link, removes them from the group, and sends a notification with a renewal prompt. For recurring billing through an external provider, a failed charge triggers the same removal flow after a configurable grace period. Getting this logic right matters more than most founders expect — a leaky expiry system means you are effectively giving away paid access.
Do I need a Mini App, or is a bot enough for a paid community?
A bot is enough for most setups. It can handle payment collection, access control, onboarding messages, and subscription management entirely through chat. A Mini App becomes worth the extra investment when you want a proper dashboard — subscription history, plan selection, referral tracking, or a member directory — presented in a web-style interface inside Telegram. If your community is straightforward (one or two tiers, simple billing), start with a bot. You can layer a Mini App on later once you know what your members actually need.
How does the bot prevent a cancelled subscriber from sharing their invite link with others?
Telegram invite links can be set to single-use or revoked after access is granted, which closes the obvious sharing loophole. The bot generates a unique, one-time link per payment confirmation and revokes it once used. On cancellation or expiry, the bot removes the user from the group directly via the Telegram API — so even if someone saved an old link, it no longer works. The weak point is screenshots or manual re-invites by existing members, which is a moderation problem, not a technical one.
Can the bot manage multiple paid groups or tiers from a single setup?
Yes. A single bot can control access across multiple groups and assign users to the correct one based on which plan they purchased. Tier logic — basic group, premium group, VIP group — is handled in the bot's backend: payment confirmed, tier identified, correct group invite issued. You can also give users access to multiple groups under one subscription. The complexity scales with the number of tiers and the billing rules between them, which affects scoping, but the architecture supports it cleanly from the start.
Does the Telegram Communities feature (July 2026) replace the need for a payment bot?
No. Telegram's native Communities feature organises groups and channels into a shared space, but it does not handle payment collection, subscription management, access revocation, or billing logic. Those still require a bot or an external system sitting in front of the group. What Communities changes is the user experience inside the group — navigation, structure, discovery — not the monetisation layer. If anything, a well-structured Community makes a paid group more valuable to members, which makes the payment infrastructure around it more important, not less.