freeapis

Telegram Bot

Simplified HTTP version of the MTProto API for bots

Authentication
API Key
HTTPS
Yes
CORS
Unknown
Category
Social

Overview

The Telegram Bot API lets you build bots that send and receive messages, photos, documents, polls, and more inside Telegram — with zero hosting cost for the API itself. Bots are controlled over plain HTTPS calls; Telegram pushes updates to you either via long polling or webhooks.

Getting Started

  1. Talk to @BotFather in Telegram and run /newbot.
  2. Copy the bot token — it looks like 123456789:AAHf....
  3. Verify it works (this is what an invalid token returns — HTTP 401):
curl "https://api.telegram.org/bot123456789:AAHf.../getMe"
  1. Send your first message:
curl -X POST "https://api.telegram.org/botTOKEN/sendMessage" \
  -d chat_id=123456789 -d text="Hello from my bot!"

How updates arrive

Mode How it works Best for
Long polling call getUpdates, Telegram holds the connection until an update arrives small bots, no public server
Webhook set a public HTTPS URL with setWebhook, Telegram POSTs updates to it production bots

Authentication

  • The token IS the authentication — it’s embedded in the URL path (/bot<TOKEN>/method), not in a header.
  • Keep it secret: anyone with the token controls your bot. Use environment variables, never commit it.
  • getMe is the standard token health-check.

Rate Limits & Notes

  • No hard rate limit is documented, but Telegram expects bots to respect humans: don’t spam the same chat.
  • The API does not set CORS headers — call it from a server, not from browser JavaScript.
  • sendPhoto/sendDocument accept file IDs, URLs, or multipart/form-data uploads.
  • For heavy traffic, use webhooks + max_connections instead of polling.

FAQ

Is the Telegram Bot API free? Yes — creating bots and calling the API is free.

Do I need a server for my bot? Only for webhook mode. Long-polling (getUpdates) works from any process that can make HTTPS calls.

Can I call it from the browser? Not directly — the API doesn’t send CORS headers and the token would be exposed. Always call from your backend.

More in Social

APIAuthHTTPSCORS
4chan

Simple image-based bulletin board dedicated to a variety of topics

No authYesYes
Ayrshare

Social media APIs to post, get analytics, and manage multiple users social media accounts

API KeyYesYes
aztro

Daily horoscope info for yesterday, today, and tomorrow

No authYesUnknown
Blogger

The Blogger APIs allows client applications to view and update Blogger content

OAuthYesUnknown
Bluesky

Decentralized social networking via the AT protocol

No authYesYes