Skip to content

Asrothear/Telegram-Bot

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Telegram-Bot Example

API winston node Telegraf

This is a simple Telegram-Bot based on JS and the Telegraf package.

  • Fast Setup
  • Custom Commands
  • Basic mysql example Inclued

Tech

This Bot uses open source software:

  • node.js - Node.js® is a JavaScript runtime built on Chrome's V8 JavaScript engine.
  • Telegraf - Modern Telegram BotFramework for Node.js
  • mysql - awesome mysql driver
  • winston - awsome logger library

Installation

Requirements:

To install node v12 run the following commands:

$ sudo apt update
$ sudo apt -y install curl dirmngr apt-transport-https lsb-release ca-certificates
$ curl -sL https://deb.nodesource.com/setup_12.x | sudo -E bash -
$ sudo apt -y install nodejs

Install the dependencies fast with the npm installer:

$ cd telegram-Bot
$ npm install

add your Bot-Token and if needed your Databe login in the config.mjs

to run this Bot simply use

$ node bot.mjs

Recommendation

It will be usefull to run this Bot via a screen session.

Development

Want to contribute? Great! Just Create a Pull requests

Todos

  • Write MORE Examples
  • Add general mysql functionality

License

GNU GENERAL PUBLIC LICENSE v3+

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published