Send Messages to
Telegram with Ease

Simple, powerful API to integrate Telegram notifications into your applications in minutes

🚀 Get Started Free 📚 Read Documentation

✨ Why MessageGateBot?

Everything you need to send notifications via Telegram

Lightning Fast

Built with FastAPI for maximum performance and minimal latency

🔐

Secure by Default

No data logging, end-to-end encryption, and secure API key management

🎨

Rich Formatting

Full HTML support for beautiful, formatted messages

📸

Media Support

Send photos, documents, and files with captions

🎯

Topic Targeting

Send to specific forum topics in Telegram groups

🔌

Easy Integration

Simple REST API with multipart/form-data support

🚀 Quick Start

Get up and running in 3 simple steps

Open MessageGateBot

Go to @MessageGateBot on Telegram and send /start

Get Your API Key

Use /key command to retrieve your unique API key

Start Sending Messages

Use the API with your key to send messages, photos, and documents

⚠️ Security Note: In group chats, only admins and owners can retrieve or generate API keys. Keys are sent privately to your DM for security.

👥 Groups, Channels & Topics

Send messages to groups, channels, and specific forum topics

📱 Private Chat (DM)

Send /key to @MessageGateBot in a direct message. You'll receive a unique API key that sends messages to your personal chat.

👥 Groups & Channels

Add Bot to Group/Channel

Add @MessageGateBot to your group or channel. For channels, make sure the bot has "Post Messages" permission.

Get Group API Key

As an admin or owner, send /key in the group. The bot will send your API key privately to your DM.

Send to Group

Use the API key to send messages directly to your group or channel!

🎯 Forum Topics (Super Groups)

Each forum topic gets its own unique API key! Perfect for organizing notifications by project, environment, or category.

Enable Forum Topics

Convert your group to a supergroup and enable "Topics" in group settings.

Get Topic API Key

In any topic thread, send /key. You'll receive a unique API key for that specific topic.

Send to Specific Topic

Messages sent with a topic's API key will appear only in that topic thread!

💡 Pro Tip: Create different topics for Production, Staging, Development, Alerts, Logs, etc. Each topic gets its own API key, making it easy to organize and route notifications to the right place!

📊 Use Cases

🔔

Production Alerts

Send critical alerts to a "Production" topic while keeping dev notifications separate

📊

Daily Reports

Auto-send analytics, metrics, or reports to a dedicated "Reports" topic

🐛

Error Monitoring

Route application errors to a "Bugs" or "Errors" topic for easy tracking

🚀

Deployment Notifications

Notify team about deployments in a "CI/CD" topic

💬

Customer Support

Forward customer inquiries to a "Support" topic in your team channel

📈

Sales Notifications

Get instant notifications for new orders in a "Sales" topic

💻 Code Examples

Copy-paste ready code for instant integration

📨 Send Text Message

Python text_message.py
import requests

def send_text_message(message: str) -> None:
    url = 'https://t69.me'
    api_key = "your-api-key-here"  # Replace with your actual API key

    # Recommended: Use X-API-Key header
    headers = {
        'X-API-Key': api_key
    }

    data = {
        'message': message
    }

    response = requests.post(url, json=data, headers=headers)

    if response.status_code == 200:
        print("✅ Message sent successfully!")
    else:
        print(f"❌ Failed: {response.text}")

# Example usage:
send_text_message("Hello from MessageGateBot!")
send_text_message("Bold and italic text")
send_text_message("Visit: Example")

🔗 cURL Example (Webhooks, Monitoring, Shell Scripts)

cURL curl_example.sh
# Method 1: Using X-API-Key header (Recommended)
curl -X POST https://t69.me \
  -H "X-API-Key: your-api-key-here" \
  -H "Content-Type: application/json" \
  -d '{"message": "🚨 Alert: CPU usage is 95%"}'

# Method 2: Using Authorization Bearer header (Also recommended)
curl -X POST https://t69.me \
  -H "Authorization: Bearer your-api-key-here" \
  -H "Content-Type: application/json" \
  -d '{"message": "✅ Deployment successful!"}'

📸 Send Photo

Python send_photo.py
import requests

def send_photo(image_path: str, caption: str = "") -> None:
    url = 'https://t69.me'
    api_key = "your-api-key-here"

    # Recommended: Use X-API-Key header
    headers = {
        'X-API-Key': api_key
    }

    with open(image_path, 'rb') as photo:
        files = {'file': photo}
        data = {
            'message': caption,
            'file_type': 'photo'
        }

        response = requests.post(url, data=data, files=files, headers=headers)

        if response.status_code == 200:
            print("✅ Photo sent successfully!")
        else:
            print(f"❌ Failed: {response.text}")

# Example usage:
send_photo('screenshot.png', 'Check this out!')
send_photo('chart.jpg', 'Q4 Report\nRevenue: $1.2M')

📄 Send Document

Python send_document.py
import requests

def send_document(file_path: str, caption: str = "") -> None:
    url = 'https://t69.me'
    api_key = "your-api-key-here"

    # Recommended: Use X-API-Key header
    headers = {
        'X-API-Key': api_key
    }

    with open(file_path, 'rb') as document:
        files = {'file': document}
        data = {
            'message': caption,
            'file_type': 'document'
        }

        response = requests.post(url, data=data, files=files, headers=headers)

        if response.status_code == 200:
            print("✅ Document sent successfully!")
        else:
            print(f"❌ Failed: {response.text}")

# Example usage:
send_document('report.pdf', 'Monthly Report - Dec 2024')
send_document('data.csv', 'Sales Data\nQ4 2024')
send_document('backup.zip', 'Backup completed')

🎨 HTML Formatting Guide

Create beautiful, formatted messages with HTML tags

<b>bold</b> or <strong>bold</strong>
Result: bold text
<i>italic</i> or <em>italic</em>
Result: italic text
<u>underlined</u> or <ins>underlined</ins>
Result: underlined text
<s>strikethrough</s> or <del>strikethrough</del>
Result: strikethrough text
<code>inline code</code>
Result: inline code
<pre>code block</pre>
For multi-line code blocks
<a href="url">link text</a>
Result: clickable link
📖 Full Documentation: For complete HTML formatting reference, visit
https://core.telegram.org/bots/api#html-style

🔥 Real-World Example

Python advanced_message.py
message = """
<b>Server Alert</b> 🚨

<u>Server Status:</u> <code>CRITICAL</code>
<u>Instance:</u> <i>web-server-01</i>

<b>Resource Usage:</b>
• CPU: <b>95%</b> ⚠️
• Memory: <b>87%</b> ⚠️
• Disk: <s>78%</s> → <b>92%</b> 🔴

<b>Action Required:</b>
Review the <a href="https://monitoring.example.com">monitoring dashboard</a>

<pre>
Error Log:
disk space critical
swap usage high
</pre>
"""

send_text_message(message)

🔗 API Reference

Complete API documentation

Endpoint

POST https://t69.me/

Authentication Methods

The API supports three methods for passing your API key (in priority order):

1️⃣ Header: X-API-Key
X-API-Key: your-api-key-here
Recommended for webhooks (Grafana, monitoring tools)
2️⃣ Header: Authorization Bearer
Authorization: Bearer your-api-key-here
Standard OAuth-style authentication
3️⃣ Form/JSON Parameter
api_key: your-api-key-here
Traditional form-data or JSON body parameter

Parameters

Parameter Type Required Description
api_key String ✅ Yes Your API key from @MessageGateBot (via header or body)
message String ✅ Yes Message text or caption (HTML supported)
file File ❌ No File to upload (photo/document)
file_type String ⚠️ If file "photo" or "document"

Response

JSON Success Response
{
  "status": "success"
}

🎯 Ready to Get Started?

Join thousands of developers using MessageGateBot