Giter Site home page Giter Site logo

grmobiles's Introduction

tg-group

Shelf hosting , long polling telegram nodejs\telegraf admin bot.

this is not a ready to use bot. its a number of example comands and templates that needs to be edited by you to be functional. everything is explained in the comments inside the code. read the code, read the commnets.

Build locally and deploy.

Minimum requirements

pkg install node or (https://nodejs.org/en/download/package-manager/#debian-and-ubuntu-based-linux-distributions-enterprise-linux-fedora-and-snap-packages)

npm install telegraf

npm install ms

npm install axios

npm install quickchart-js

a bot token . go to @BotFather in telegram , type /newbot and follow instruction . after creating type /mybots , select your bot and hit api token .

It can welcome new members in groups. Mute them until a custom answers is given to a custom question. Ban or kick them if no correct answer is given our just keep them muted

Has basic admin commands like mute,unmute,promote\demote admin User id,chat id,ban,unban,notes(hardcoded must be created in src/memo.js), Hushtags(hardcoded must be created in src/hashtag.js), pin,unpin,insult,slap .

Read the comments on bot.js and src files to make the bot suit your needs.

to deploy to heroku Procfile is needed . This is a file called exactly “Procfile” in your node directory with a single line

make a heroku acount

install heroku cli with sudo snap install --classic heroku

Go to your dashboard

Select “Create new app” (top right)

Name your app something (only letters, numbers, and dashes)

Click “Create App”

open terminal inside your root bot folder

heroku login

git init

heroku git:remote -a your-app-name

git add .

git commit -am "commiting the code"

git push heroku master

grmobiles's People

Contributors

ippocratis avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.