Automated Watermark & AI Text Refinement Bot for Telegram Channels
Watermark Bot helps Telegram channel owners automatically add watermarks to media files and refine text using AI (Gemini API) before posting.
It stores your preferences using Prisma ORM + Neon PostgreSQL — smooth, fast, and persistent.
- Adds watermarks to photos , videos & texts
- Save your default watermark (one per user)
Choose your style:
- Grammar Correction ✍️
- Professional Rewrite 💼
- Funnier Text 📝
- Emoji-Friendly Caption 😎✨
- Powered by Neon PostgreSQL + Prisma ORM
- Saves:
- Default watermark URL
- Preferred text style
- Forward media → bot adds watermark → returns ready-to-post version
- Forward text → bot refines with AI → get polished caption
- Fast. Simple. Reliable.
| Layer | Technology |
|---|---|
| Bot Engine | Node.js + Telegraf |
| AI Processing | Google Gemini API |
| Database | Neon PostgreSQL |
| ORM | Prisma |
| Media Processing | FFmpeg |
| Runtime | Node.js 18+ |
# 1. Clone
git clone https://github.com/Natnsis/Watermark-bot.git
cd Watermark-bot
# 2. Install
npm install
# 3. Create .env
cp .env.example .env
# Then edit .env with your keys
BOT_TOKEN=your_telegram_bot_token
GEMINI_API_KEY=your_gemini_api_key
DATABASE_URL="postgresql://user:pass@ep-cool-name.us-east-2.aws.neon.tech/db?sslmode=require"
DIRECT_URL="postgresql://user:pass@ep-cool-name.us-east-2.aws.neon.tech/db?sslmode=require"
# 4. Install FFmpeg
# Linux
sudo apt install ffmpeg
# Windows: Download from https://ffmpeg.org and add to PATH
# 5. Prisma setup
npx prisma migrate deploy
npx prisma generate
# 6. Run
npm start
- Send anything containig image on your channel for post
- The bot instantly applies your default watermark
- Send or forward any text/caption
- Choose one of the styles from the menu:
• Grammar Correction ✍️
• Professional Rewrite 💼
• Funnier Version 📝 - Get a perfectly polished caption in seconds!
- Forward a post from the channel so that the bot can pick your channel
- Send the water mark to be added on posts (bot must be admin in your chanel with edit permisson for it to wor)
→ Saved in the database and used automatically from now on.
- Only Grammar by default
- The bot remembers it for all future text refinements
→ No need to choose every time!
| Command | Description |
|---|---|
/start |
Show welcome message & quick guide |
/help |
List all features & commands |
/watermark |
Set default watermark to be sent on the channel |
/post |
Send text that you want to be refined |
/preferences |
Apply preferred refinement method |
That’s it — no complicated menus, no extra apps.
Just forward → get perfect content → post to your channel. Fast & effortless! 🚀
