Skip to content

Latest commit

 

History

History
68 lines (54 loc) · 2.01 KB

File metadata and controls

68 lines (54 loc) · 2.01 KB

Get Started

Clone repository

git clone git@github.com:xsubject/telegram-channel-signature-bot.git

Create Bot Token

Open telegram and find BotFather and create a new bot using hints, after copy your telegram bot key

image

image

Put your token to your env

If using local folder

Creates .env file based on .env.example

cp .env.example .env
BOT_TOKEN=5708152915:AAE92GLKORIRcU4qZyrOP9HCQt4Jx43lN7o
CHAT_ID=
ADMIN_ID=

If using docker compose

Creates docker-compose.yml file based on docker-compose-example.yml

// ...
  app:
    // ...
    environment:
      - BOT_TOKEN=5622128701:AAHWDbgaJE2cV74wmBEvf56_fhPQKBaKlTs
      - ADMIN_ID=
      - CHAT_ID=-
    // ...

Build and start bot

if using local folder

npm install
npm run start

if using docker compose

docker-compose up

Now if you send any message to the bot, it will show your ID to put in ADMIN_ID image

Also add your bot to your channel with permission: edit messages, invite users, and and when you send a message to the channel, you will see the channel ID in the terminal log image

update your environment variables and reload your app

if using docker compose

Now you can add -d flag to run bot as deamon

docker-compose up -d

Now you just have to write a message to your bot, which will contain the desired signature

signature (5)