Skip to content

A Serverless Telegram Bot to Create Permanent Shareable Links to a Single or Batch of Messages.

License

Notifications You must be signed in to change notification settings

Jisin0/TGMessageStore

Repository files navigation

TGMessageStore

telegram badge Go Report Card Go Build License: GPL v3

TGMessageStore is a serverless telegram bot to generate permanent shareable links to a single or batch of messages.

Commands

start - Check if the bot is alive.
batch - Create a new message batch.
genlink - Create a link for a single message.
about - Basic Information About the bot.
help - Short Guide on How to Use the Bot.
privacy - Read about the privacy policy.
id - Get user id or forwarded channel id.

Features

  • Batch Link
  • Single Link
  • Unlimited Force Subscribe
  • AutoDelete
  • Protect Content
  • Comaptible With CodeX Links
  • Disable Notification
  • Unlimited Bots
  • Easy Customization
  • Fully Serverless

Variables

Variables can also be loaded by creating a .env file at the root of the repository. See .env.sample to see the format to use.

  • BOT_TOKEN : Optional. On vercel, a list of bot tokens allowed to connect to the app or leave empty allow anyone to connect. On servers, a single bot token.
  • ADMINS : Optional. List of telegram IDs of users allowed to create links with the bot, seperated by spaces.
  • FSUB : Optional. List of IDs of channels the user must join to get content, seperated by spaces.
  • AUTO_DELETE: Optional. Number of minutes after which messages should be automatically deleted. (Does not work on vercel)
  • ALLOW_PUBLIC : Optional. Set this to true to allow anyone to create batch links.
  • PROTECT_CONTENT: Optional. Set this to true to prevent users from forwarding/copying content from the bot.
  • BATCH_SIZE_LIMIT: Optional. Maximum number of messages allowed in a batch.
  • DISABLE_NOTIFICATION: Optional. Set this to true to send messages without a notification.
  • LOG_CHANNEL: Optional. Channel to log details about new batch links created.
  • DISABLE_ADMIN_LOGS: Optional. Set to true to diasble logs for batch created by admins.
  • DB_CHANNEL : Database channel only used for backward compatibilty with codex links.

Deploy

Deploy your own TGMessageStore app to vercel

Deploy with Vercel

Deploy To Heroku


Deploy

Deploy To Scalingo


Deploy on Scalingo

Deploy To Render


deploy-to-render

Make sure to have the following options set :

Environment

Go

Build Command

go build .

Start Command

./TGMessageStore

Advanced >> Health Check Path

/

Deploy To Koyeb


deploy-to-koyeb

You must set the Run command to :

./bin/TGMessageStore

Deploy To Okteto


deploy-to-okteto

Deploy To Railway


deploy-to-railway

Run Locally/VPS

You must have the latest version of GO installed first

git clone https://github.com/Jisin0/TGMessageStore
cd TGMessageStore
go build .
./TGMessageStore

Formatting

All texts located in the /config/text.go file can be customized using the mention, user_id and name values. Example: Hey {mention} this is a start message!

Thanks

  • Thanks to Paul for his awesome Library

Disclaimer

GNU General Public License 3.0
Licensed under GNU GPL 3.0..

About

A Serverless Telegram Bot to Create Permanent Shareable Links to a Single or Batch of Messages.

Resources

License

Stars

Watchers

Forks

Languages