Memes Bot

A personal Telegram inline bot to store and search media (photos, GIFs, videos, voice) by keywords.

فارسی


Requirements

Setup

1. Create the bot in BotFather

  • /newbot → get your token
  • /setinline → enable inline mode, set a placeholder (e.g. Search memes...)

2. Find your Telegram user ID

You need your numeric Telegram user ID to whitelist yourself.

  • Easiest: forward any message to @userinfobot — it replies with your ID
  • Alternative: open Telegram Web, click your profile, the number in the URL is your ID
  • For multiple users: repeat for each person and separate IDs with commas

3. Clone and configure

git clone https://git.goyban.com/goyban/memes_bot
cd memes_bot
cp .env.example .env

Edit .env:

BOT_TOKEN=your_telegram_bot_token_here
ALLOWED_USERS=123456789,987654321

4. Run

docker compose up -d --build

The database will be saved in ./bot_db/media.db.

Usage

Adding media — send the bot a photo, GIF, video, or voice message, then type keywords when prompted (comma-separated or one per message), then /done.

Searching inline — in any chat type @yourbotusername keyword to search and send.

Commands

Command Description
/list Show all saved media
/delete <id> Remove an entry (get ID from /list)
/cancel Cancel current add operation

Moving to another server

The only files you need to transfer are:

  • .env
  • bot_db/media.db
S
Description
No description provided
Readme 32 KiB
Languages
Python 96.6%
Shell 2%
Dockerfile 1.4%