Skip to main content
Share
Guides

Telegram Bot Payments in 2027: Stars for Digital Goods, Stripe for Physical Ones

Telegram requires Stars (XTR, empty provider_token) for digital goods, while physical goods can still use providers such as Stripe. How to send each invoice, beat the 10-second pre-checkout deadline, run Stars subscriptions, issue refunds and meet the /paysupport rule.

Content & Engineering
Nov 2, 2026
11 min read
Last verified October 2026
telegram bot paymentstelegram bot payments starstelegram stars paymenttelegram bot payment subscriptiontelegram stars payment failed
TL;DR

Telegram requires Stars (XTR, empty provider_token) for digital goods, while physical goods can still use providers such as Stripe. How to send each invoice, beat the 10-second pre-checkout deadline, run Stars subscriptions, issue refunds and meet the /paysupport rule.

Key Takeaways
  • Telegram requires bots that sell digital goods or services to charge in Telegram Stars (currency XTR, empty provider_token in sendInvoice).
  • Physical goods can still go through third-party providers such as Stripe.
  • Both cases use the same Bot API methods: sendInvoice , createInvoiceLink , answerPreCheckoutQuery and the successful_payment message.
  • What changes is two parameters and a handful of rules.

The short answer: what you sell decides how you charge

Telegram requires bots that sell digital goods or services to charge in Telegram Stars (currency XTR, empty provider_token in sendInvoice). Physical goods can still go through third-party providers such as Stripe.

Both cases use the same Bot API methods: sendInvoice, createInvoiceLink, answerPreCheckoutQuery and the successful_payment message. What changes is two parameters and a handful of rules. Telegram's Stars guide puts the rule flatly: your bot "must use Telegram Stars for the sale of digital goods and services inside Telegram apps", and "all transactions must be carried out in Telegram Stars, with currency tag XTR". The Bot API reference describes provider_token as "Pass an empty string for payments in Telegram Stars".

Digital goods and servicesPhysical goods and services
ExamplesPremium bot features, AI credits, paid content, subscriptions to a private channelClothing, food delivery, event tickets for a venue, an in-person appointment
currencyXTRA three-letter ISO 4217 code such as USD or EUR
provider_tokenEmpty string (or omit it)The token BotFather gives you for your provider
pricesExactly one itemA breakdown: product, tax, discount, delivery
Tips, shipping, name/phone/emailNot supported or ignoredSupported
SubscriptionsYes, via subscription_periodNo native recurring option
RefundsrefundStarPayment in the Bot APIThrough your payment provider
Who processes the moneyTelegram (users buy Stars in the app)Your provider; Telegram only relays the payment

The rest of this guide goes through each half in the order you will build it: the Stars invoice, the 10-second pre-checkout deadline, delivery, subscriptions, refunds, and then the provider path for physical goods. A troubleshooting table at the end covers the failures that come up most.

Why Telegram forces Stars for digital goods

Telegram's apps ship through the App Store and Google Play, and both stores have rules about how apps sell digital goods. Telegram's answer is Stars: users buy them through Apple or Google in-app purchases or through @PremiumBot, and bots charge in Stars. The Stars FAQ is explicit that this is not optional. Asked whether a bot can use a different currency or payment provider, it says no, and warns that Telegram may be unable to show mobile users a bot that sells digital goods any other way (Telegram, Bot Payments API for Digital Goods and Services).

Three follow-ups from the same FAQ settle the questions developers usually ask next:

  • "I already sell on my own website. Do I still need Stars?" Yes. Sales of digital goods inside Telegram apps must use Stars, whatever you do elsewhere.
  • "Can I take crypto instead?" No. Digital goods sold through bots and Mini Apps use Stars only.
  • "Can I send people a link to my Stripe checkout?" For digital goods, that is a third-party provider by another route, and the FAQ's answer is the same: Stars only.

The Bot Platform Developer Terms make it contractual. Section 6.2 says digital goods and services sold through bots "must be executed exclusively through the exchange of Telegram Stars", while section 6.1 lets developers sell physical goods by interfacing "solely and directly with third-party payment providers".

The line between the two is about what the user receives. If the thing bought is delivered and used inside Telegram or another app, it is digital. If it ships, or the service happens in the physical world, it is physical. When you are unsure, read section 6 of the developer terms before you build, because a bot rejected for the wrong payment method has to be rebuilt anyway.

Sending a Stars invoice

A Stars invoice is a normal sendInvoice call with three differences: currency is XTR, provider_token is empty, and prices holds one item whose amount is a whole number of Stars.

curl -X POST "https://api.telegram.org/bot<TOKEN>/sendInvoice" \
  -H "Content-Type: application/json" \
  -d '{
    "chat_id": 123456789,
    "title": "Pro features, 30 days",
    "description": "Unlimited exports and priority replies",
    "payload": "order_8f3a21",
    "provider_token": "",
    "currency": "XTR",
    "prices": [{ "label": "Pro, 30 days", "amount": 250 }]
  }'

The Bot API reference sets limits on each field, and the ones people trip over are:

  • title: 1-32 characters. description: 1-255 characters.
  • payload: 1-128 bytes, "not displayed to the user". Put your own order ID here. It comes back in the pre-checkout query and in successful_payment, so it is how you match a payment to an order.
  • prices: "Must contain exactly one item for payments in Telegram Stars". A tax line or discount line is an error in XTR.
  • max_tip_amount: "Not supported for payments in Telegram Stars."
  • need_name, need_phone_number, need_email, need_shipping_address, is_flexible: all "Ignored for payments in Telegram Stars." Telegram's Stars guide notes that buyers do not hand over personal details at all, so if you need an email address, ask for it in the conversation.

If you would rather post a payable link than an invoice message, for example from a Mini App or a button elsewhere, createInvoiceLink takes the same fields and returns a URL. For a bot it is also the only way to create a subscription, covered below.

One behaviour to decide on before launch: start_parameter. If you leave it empty, forwarded copies of the invoice keep a working Pay button, so anyone the message is forwarded to can pay the same invoice. If you set it, forwarded copies get a deep link to your bot instead. Shops usually want the second, so every buyer gets their own order.

Try it yourself
Build your first chatbot free
Free plan, no credit card required. Live on your site in about 10 minutes.
Start building free

The 10-second pre-checkout deadline

When the user taps Pay and confirms, Telegram sends your bot an update with a pre_checkout_query field. This is your last chance to say no: the item is sold out, the price changed, the order expired. The reference is strict about timing: "The Bot API must receive an answer within 10 seconds after the pre-checkout query was sent". The payments guide adds what happens if you miss it: the transaction is canceled.

# Approve
curl -X POST "https://api.telegram.org/bot<TOKEN>/answerPreCheckoutQuery" \
  -d "pre_checkout_query_id=<id>" -d "ok=true"

# Decline, with a message Telegram shows the user
curl -X POST "https://api.telegram.org/bot<TOKEN>/answerPreCheckoutQuery" \
  -d "pre_checkout_query_id=<id>" -d "ok=false" \
  -d "error_message=That plan is no longer available. Please choose another."

Ten seconds sounds generous until you look at what usually eats it:

  • The update never arrives. If you set allowed_updates on setWebhook or getUpdates to a short list such as ["message", "callback_query"], you will not receive pre_checkout_query, and every payment times out. An empty list gets every update type except chat_member, message_reaction and message_reaction_count, so the default is fine. Check the current value with our Telegram webhook checker, which reads getWebhookInfo.
  • A cold start or a slow queue. A serverless function waking up, or a worker queue that processes updates in order behind a slow job, can miss the deadline. Answer pre-checkout queries on a fast path before anything else.
  • Doing the work before answering. Check stock or order validity, answer, then do the rest. Do not deliver anything here.
  • A dead webhook. If updates are queueing up, pre-checkout queries queue with them and arrive too late. Our guide to pending_update_count shows how to tell.

Answering ok=true does not mean you have been paid. The Stars guide warns that "simply answering a pre_checkout_query does not guarantee a successful order or payment" (source).

Deliver on successful_payment, and keep the charge ID

The payment is final when your bot receives a message with a successful_payment field. Telegram's rule: "You must always check that you received a successful_payment update before delivering the goods". The object carries what you need to fulfil and, later, to refund:

FieldWhat to do with it
invoice_payloadYour order ID from sendInvoice. Look up the order and mark it paid.
currency, total_amountCheck them against the order. For XTR the amount is a whole number of Stars.
telegram_payment_charge_idStore it. You need it for refundStarPayment and for subscription changes.
provider_payment_charge_idThe provider's ID for physical-goods payments, for reconciling with Stripe or another provider.
is_recurring, is_first_recurring, subscription_expiration_datePresent for subscription payments. Use them to extend access.

The reference also adds a warning that applies to provider payments: "if the buyer initiates a chargeback with the relevant payment provider following this transaction, the funds may be debited from your balance". Make fulfilment idempotent, keyed on telegram_payment_charge_id, so a retried update never delivers twice.

Telegram Bot Commands Generator
Free tool - no signup, runs in your browser.
Open free tool

Stars subscriptions: createInvoiceLink with subscription_period

Recurring billing exists only in Stars. You create it with createInvoiceLink and a subscription_period, then send the link to the user.

curl -X POST "https://api.telegram.org/bot<TOKEN>/createInvoiceLink" \
  -H "Content-Type: application/json" \
  -d '{
    "title": "Pro monthly",
    "description": "Renews every 30 days",
    "payload": "sub_user_123456789",
    "currency": "XTR",
    "prices": [{ "label": "Pro monthly", "amount": 250 }],
    "subscription_period": 2592000
  }'

The rules, from the createInvoiceLink reference:

  • The currency must be XTR when subscription_period is used.
  • The period "must always be 2592000 (30 days)". No weekly or annual plans yet.
  • The price must not exceed 10,000 Stars.
  • Any number of subscriptions can be active at once, including several from the same user.

Each renewal arrives as another successful_payment with is_recurring set, and the first one also has is_first_recurring. Extend access to subscription_expiration_date rather than adding 30 days yourself.

To stop a subscription from your side, call editUserStarSubscription with the user's ID, the subscription's telegram_payment_charge_id and is_canceled=true. The reference says the subscription must stay active until the end of the current period, so cancelling stops the next renewal, not today's access. Passing is_canceled=false re-enables a subscription the bot cancelled.

Refunds, /paysupport and getting paid

A Stars refund is one call:

curl -X POST "https://api.telegram.org/bot<TOKEN>/refundStarPayment" \
  -d "user_id=123456789" \
  -d "telegram_payment_charge_id=<charge id from successful_payment>"

After a refund your bot receives a message with a refunded_payment field (a RefundedPayment object whose currency is "Currently, always XTR"). Use it to revoke access.

The obligations around refunds matter more than the method:

  • /paysupport is required. The developer terms say every bot "must be able to respond to the command /paysupport" and deal with payment requests. Telegram's own support will not handle your buyers' disputes.
  • Disputes are yours. Section 6.2.1 says Telegram "has no obligation to mediate or be a party to any such disputes". If a dispute ends in a refund, the Stars come out of your bot's balance.
  • Telegram does not refund users. The Stars terms say "All sales of Telegram Stars are final" and point users to the bot's developer, who "has the ability to refund your Stars at no penalty".
  • Offer /terms and /support as well. Both are on the Stars guide's go-live checklist.

Earned Stars can buy Telegram Ads for your bot, or be exchanged for a reward. The developer terms say Telegram "currently outsources the processing of rewards to Fragment", and that Stars "may not become available for advertising credits or rewards for up to 21 days after their receipt" (section 6.2.4, Bot Platform Developer Terms). Plan your cash flow around that hold. To check your balance and history from code, use getMyStarBalance and getStarTransactions (up to 100 transactions per call).

Physical goods: connecting Stripe or another provider

For physical goods and services, Telegram does not handle the money. The payments guide says "Telegram does not collect payment information and takes no commission", and that card details are held by the provider, so "neither Telegram nor the bot developers have access to it" (Telegram Bot Payments API). Telegram lists more than 20 providers. Which ones you can choose depends on where your business is registered, and BotFather shows the list.

  1. In @BotFather, send /mybots, pick the bot, and open Bot Settings > Payments.
  2. Choose a provider and finish its onboarding. BotFather then shows a provider token for that bot.
  3. Start with Stripe TEST MODE. Test cards such as 4242 4242 4242 4242 work and real cards do not. A live token contains :LIVE:, which is an easy way to check which one a deploy is using.
  4. Call sendInvoice with that token as provider_token, an ISO currency, and as many prices lines as you need (amounts in the smallest unit, so US$14.50 is 1450).

Physical invoices get features Stars invoices do not:

  • Shipping. Set need_shipping_address. Add is_flexible if the price depends on the address, and you will receive a shipping_query to answer with answerShippingQuery and a list of shipping options, or ok=false and an error message.
  • Tips. max_tip_amount plus up to four suggested_tip_amounts, in increasing order.
  • Customer details. need_name, need_phone_number and need_email, with optional forwarding to the provider.

Amount limits apply per currency. Telegram says they "roughly correspond to the limit of US$ 1-10000", and amounts must fit in 12 digits. The exact numbers are in currencies.json, which also gives each currency's exp (decimal places). The pre-checkout deadline and successful_payment rules are the same as for Stars.

Testing without spending real Stars

Telegram runs a separate test environment, and the Stars guide says "You can freely test payments in Telegram Stars by connecting your bot to Telegram’s dedicated test environment". The test environment is completely separate from production, so you create a new user account and a new bot with @BotFather there, use the test API URL (https://api.telegram.org/bot<token>/test/METHOD_NAME, per Telegram's test environment docs), and run the whole flow end to end, including a refund.

A test checklist that catches most launch problems:

  1. Invoice sends. Then check the price in the client matches your prices.
  2. Pre-checkout is answered in under a second, with the bot under some load.
  3. Declining with ok=false shows your error_message.
  4. The successful_payment handler delivers exactly once, even if you replay the update.
  5. refundStarPayment works with the stored charge ID, and the refunded_payment message revokes access.
  6. /paysupport, /terms and /support all answer.

If the invoice call fails before you get this far, check the basics first: a revoked or mistyped token returns 401 Unauthorized (our token checker confirms which bot a token belongs to), and a user who blocked the bot returns 403 Forbidden: bot was blocked by the user.

When a payment fails: symptom, cause, fix

SymptomLikely causeFix
User taps Pay, then the payment is canceled after a spinnerNo answerPreCheckoutQuery within 10 secondsMake sure pre_checkout_query is in allowed_updates, and answer it before any slow work
XTR invoice rejectedMore than one prices item, or a non-empty provider_tokenOne price line, empty token, currency: "XTR"
Tips or shipping fields missing on a Stars invoiceExpected: they are not supported or ignored for XTRCollect details in the chat instead
Physical invoice works in test, fails liveDeploy still uses the TEST token, or the live provider onboarding is not finishedCheck the token contains :LIVE:; finish onboarding in BotFather
Goods delivered but no moneyDelivery triggered on pre-checkout instead of successful_paymentDeliver only on successful_payment
Delivered twiceUpdate retried after a slow webhook responseMake fulfilment idempotent on telegram_payment_charge_id
Cannot refund an old Stars paymentCharge ID never storedPersist telegram_payment_charge_id with every order
Two bot processes and payments arrive at randomTwo consumers on one token: 409 ConflictRun one consumer: polling or webhook, never both

For the full list of Bot API error strings and what each one means, see the Telegram error reference. For the per-chat and global sending limits that affect a bot sending many invoices at once, see Telegram limits. Most payment failures are not payment errors at all. They are ordinary delivery problems, the same ones covered in Telegram bot not responding.

Taking payments in a Conferbot Telegram bot

Conferbot has payments built into the flow: a Payment step you drop into any conversation, on Telegram and on every other channel the bot runs on. It runs on Stripe Checkout through your own Stripe account, connected once per workspace, and the bot keeps going on its own once the customer pays.

  • The amount is fixed on Conferbot's server, either a set price or a value the conversation collected, so it can't be edited in the chat.
  • On Telegram the step sends the secure checkout link inside the chat, then tracks the payment itself. You don't build anything to find out whether the customer paid.
  • The flow branches on the result: paid, failed or cancelled, and timed out. The payment's details are saved as variables, so the next message can confirm the order, retry, or hand over to a person in the shared inbox.
  • The same step works everywhere the bot is deployed. On your website the widget shows a pay card inside the chat; on WhatsApp, Messenger and the other channels it sends the link, exactly as on Telegram.

The rest of the conversation is built in the same no-code AI chatbot builder: collecting the order, answering questions with AI, and handing over to a person when needed.

One rule to plan around: Telegram requires digital goods and services sold inside Telegram to be paid in Stars. Conferbot's Payment step uses Stripe, not Telegram's own invoices or Stars, so use it for physical goods and real-world services. A bot that sells digital goods inside Telegram needs Telegram's Stars invoices, built against the Bot API as described above.

Share this article:

Was this article helpful?

Ready to build your chatbot?

Join the businesses. Deploy on website, WhatsApp, and 11 more channels in minutes. Free forever plan available.

No credit cardNo coding13+ channels
Start Building Free

Get chatbot insights delivered weekly

Join 5,000+ professionals getting actionable AI chatbot strategies, industry benchmarks, and product updates.

🎯Automate this with a free chatbot

Build and deploy in 10 minutes. No coding needed.

❓FAQ

Telegram Bot Payments in 2027 FAQ

Everything you need to know about chatbots for telegram bot payments in 2027.

🔍
Popular:

Only for digital goods and services. Telegram requires bots that sell digital goods or services inside its apps to charge in Telegram Stars (currency XTR, with an empty provider_token). Physical goods and real-world services can still be paid through a third-party provider such as Stripe, using a provider token from BotFather.

XTR is the currency code for Telegram Stars. You pass it as the currency in sendInvoice or createInvoiceLink, leave provider_token empty, and give exactly one price item whose amount is a whole number of Stars. successful_payment and refunded_payment messages report XTR as their currency.

10 seconds. The Bot API must receive answerPreCheckoutQuery within 10 seconds of sending the query, or the transaction is canceled. The usual causes of a timeout are an allowed_updates list that leaves out pre_checkout_query, a slow or cold-starting webhook, and doing fulfilment work before answering.

Yes, in Stars only. Call createInvoiceLink with currency XTR and subscription_period set to 2592000 (30 days, currently the only allowed value). The price must not exceed 10,000 Stars. Each renewal arrives as a successful_payment with is_recurring set, and editUserStarSubscription lets the bot cancel or re-enable renewal.

Call refundStarPayment with the user's ID and the telegram_payment_charge_id from the original successful_payment, so store that ID with every order. Your bot then receives a refunded_payment message. Telegram does not refund Stars purchases itself; it sends buyers to the bot's /paysupport command.

For physical goods and real-world services, yes. For digital goods or services sold inside Telegram, no: Telegram's Stars FAQ says those sales must use Stars, whatever outside website or payment provider you have.

Yes. Conferbot's Payment step takes payments inside the conversation on Telegram and every other channel, through Stripe Checkout on your own Stripe account. The amount is fixed on the server, the bot tracks the payment itself, and the flow continues on paid, failed or timed out. It uses Stripe rather than Telegram Stars, so use it for physical goods and real-world services; digital goods sold inside Telegram must be paid in Stars through Telegram's own invoices.

About the Author

Content & Engineering

The Conferbot team writes about building, deploying, and improving AI chatbots.

View all articles
Skip the blank canvas
Start from one of 250+ free chatbot templates for lead generation, support, e-commerce, and 20+ industries - customize and launch in minutes.
Browse free templates

Related Articles

From the reference shelf

Fact-checked reference pages and free tools for the platform this article covers.

Omnichannel Platform

One Chatbot,
Every Channel

Your chatbot works seamlessly across WhatsApp, Messenger, Slack, and 6 more platforms. Build once, deploy everywhere.

View All Channels
Conferbot
online
Hi! How can I help you today?
I need pricing info
Conferbot
Active now
Welcome! What are you looking for?
Book a demo
Sure! Pick a time slot:
#support
Conferbot
New ticket from Sarah: "Can't access dashboard"
Auto-resolved. Password reset link sent.