=== Mail forwarder to Telegram ===
Contributors: guruteam
Tags: mail to telegram, email telegram, mail log
Requires at least: 5.8
Tested up to: 6.9
Requires PHP: 7.4
Stable tag: 1.0.0
License: GPLv2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html

Forward WordPress emails to Telegram bot automatically.

== Description ==

# Mail forwarder to Telegram is a WordPress plugin that automatically forwards WordPress emails to your Telegram account in real-time. Monitor important emails, notifications, and messages from your WordPress site directly in Telegram with full HTML formatting and attachment support.

- ✅ **Real-time email forwarding** to Telegram
- ✅ **HTML formatting** support (Telegram-safe HTML tags)
- ✅ **Attachment support** - files sent as documents to Telegram
- ✅ Forward all emails or only specific ones
- ✅ Email ignore list (blacklist)
- ✅ Beautiful message formatting with emojis
- ✅ Easy-to-use admin settings page
- ✅ Automatic HTML tag filtering for Telegram compatibility
- ✅ Email validation and character counter
- ✅ Error logging and debugging support


== External services ==

This plugin relies on the Telegram Bot API, a third-party service provided by Telegram Messenger Inc., to send email notifications to Telegram.

**Service Information:**
- **Service:** Telegram Bot API
- **Provider:** Telegram Messenger Inc.
- **API Endpoint:** https://api.telegram.org/
- **Purpose:** Sending email notifications from WordPress to your Telegram account

**Data Transmission:**
When an email is sent from your WordPress site, the following data may be transmitted to Telegram servers:
- Email subject
- Email message content
- Email recipient addresses
- File attachments (if any)

**Important Links:**
- Telegram Terms of Service: https://telegram.org/tos
- Telegram Privacy Policy: https://telegram.org/privacy
- Telegram Bot API Documentation: https://core.telegram.org/bots/api

By using this plugin, you acknowledge that data will be transmitted to Telegram's servers and you agree to comply with Telegram's Terms of Service and Privacy Policy.


== Configuration ==

== 1. Get Telegram Bot Token ==

1. Open Telegram and search for `@BotFather`
2. Send `/newbot` command
3. Follow the instructions to create your bot
4. Copy the bot token (format: `123456789:ABCdefGHIjklMNOpqrsTUVwxyz`)

== 2. Get Chat ID ==

1. Start a chat with your newly created bot
2. Search for `@userinfobot` on Telegram
3. Start the bot and it will show your Chat ID
4. Copy your Chat ID (format: `123456789`)

== 3. Configure Plugin Settings ==

Go to **WordPress Admin → Mail Forwarder for Telegram** and configure:

== Telegram Settings ==

- **Telegram Bot Token**: Enter your bot token from BotFather
- **Telegram Chat ID**: Enter your Chat ID

== Forwarding Settings ==

- **Forward Mode**:
  - `Forward all emails` - All WordPress emails will be forwarded to Telegram
  - `Forward only specific emails` - Only emails sent to specific addresses will be forwarded

- **Forward Specific Emails** (shown only if "Forward only specific emails" is selected):
  - Enter email addresses separated by commas
  - Example: `admin@example.com, contact@example.com`

- **Ignore Emails**:
  - Enter email addresses that should NOT be forwarded to Telegram
  - Separated by commas
  - Example: `noreply@example.com, spam@example.com`
