Skip to content
This repository has been archived by the owner on Apr 21, 2018. It is now read-only.

lkd70/the-engine

Repository files navigation

The Engine

A mattata-esque Telegram bot written in Node.js

This bot is currently out of fuel, maybe one day development will continue.

Powered by...

The Engine couldn't work without a few projects:

Installation

The Engine requires Node.js in order to run. Download the project from our git & install dependencies:

$ git clone https://github.com/lkd70/the-engine.git
$ cd the-engine
$ npm install
$ node bot

Configuration

In order to use The Engine, you must first configure the bot. Configuration is handled by the config.json file.

Example config.json:

{
    "auth_token": "YOUR_API_TOKEN",
    "db": {},
    "plugins": [
        { "path": "./plugins/plugins", "essential": true },
        { "path": "./plugins/sayhi" },
        { "path": "./plugins/ping"  },
        { "path": "./plugins/help"  },
        { "path": "./plugins/quote" },
        { "path": "./plugins/id"    },
        { "path": "./plugins/trigger"  },
        { "path": "./plugins/unformat" },
        { "path": "./plugins/demojify" },
        { "path": "./plugins/echo"     }
    ]
}
Element Example Data Description
auth_token 123456789:a1B2c3D4e5F6g7H8i9JkLmNoPqRsTuVwXyZ Your bots token as provided by @BotFather
db {} DB settings, following the ioredis format
plugins { "path": "./plugins/plugins", "essential": true },
{ "path": "./plugins/sayhi" },
{ "path": "./plugins/getid" }
Plugins you wish the bot to load

Plugins

Listed below are the official plugins that are maintained by the The Engine team. To learn more about the plugins, read their corresponding README files.

Plugins README
demojify demojify.js
echo echo.js
help help.js
id id.js
jsondump jsondump.js
ping ping.js
plugins plugins.js
quote quote.js
sayhi sayhi.js
trigger trigger.js
unformat unformat.js

Commands

These are the stock commands provided by the official plugins

Command Plugin Description
/demojify demojify Returns the word representation of the given Emoji(s)
/echo echo Returns the given text with additional formatting
/help help Returns help information about the given /command
/id id Returns the ID of a given @username
/jsondump jsondump Returns a JSON formatted object dump of the message
/ping ping Returns "PONG!" (with any luck...)
/plugins plugins Returns a list of available plugins and their active status
/enable plugins Enables the named plugin(s)
/disable plugins Disables the named plugin(s)
/commands plugins Lists all available /commands
/savequote quote Saves the replied to message, can be called upon using /quote
/quote quote Returns a random quite from the replied to user
/sayhi sayhi Returns a 'hi' message through all methods available
/trigger trigger Creates a #trigger allowing custom responses to specified hash-tags
/tomd /unformat unformat Unformats the given markdown message
/tohtml unformat Unformats the given markdown to HTML
/chatid getid Returns the ID of the current chat
/myid getid Returns your user ID

License

BSD 3-Clause License

The Team

The Engine consists of several skilled developers (and Matt), all working together efficiently.

Name Telegram Role
GingerPlusPlus @GingerPlusPlus Developer & innovator
Kuvam @snarkie Developer & innovator
LKD70 @LKD70 Documenter & innovator
Matt @wrxck0 Leech
nyuszika7h @nyuszika7h Developer & innovator