Added README.md
This commit is contained in:
parent
7a6f0d738c
commit
33b73f048c
80
README.md
Normal file
80
README.md
Normal file
@ -0,0 +1,80 @@
|
|||||||
|
# Matrix Bot
|
||||||
|
|
||||||
|
Matrix Bot is a Python-based chat bot designed to work with Matrix, an open network for secure, decentralized communication. This bot is built using the `simplematrixbotlib` library and provides various commands and functionalities for interacting with Matrix rooms.
|
||||||
|
|
||||||
|
## Features
|
||||||
|
|
||||||
|
- Modular architecture: Commands are implemented as separate plugins, making it easy to add or modify functionality.
|
||||||
|
- Command handling: The bot listens for specific commands prefixed with `!` and responds accordingly.
|
||||||
|
- Plugin system: Each command is implemented as a separate plugin module, allowing for easy customization and extension.
|
||||||
|
- Extensible: Users can add new commands by creating additional plugin modules.
|
||||||
|
|
||||||
|
## Installation
|
||||||
|
|
||||||
|
1. Clone the repository:
|
||||||
|
`git clone https://github.com/example/matrix-bot.git`
|
||||||
|
|
||||||
|
2. Install dependencies:
|
||||||
|
`pip install -r requirements.txt`
|
||||||
|
|
||||||
|
3. Set up environment variables:
|
||||||
|
Create a `.env` file in the root directory of the bot and add the following variables:
|
||||||
|
|
||||||
|
```
|
||||||
|
MATRIX_URL="https://matrix.org" (or another homeserver)
|
||||||
|
MATRIX_USER=""
|
||||||
|
MATRIX_PASS=""
|
||||||
|
```
|
||||||
|
|
||||||
|
4. Run the bot:
|
||||||
|
|
||||||
|
1. `python funguy.py`, or
|
||||||
|
2. `chmod +x funguy.py`
|
||||||
|
`./bot.py`
|
||||||
|
|
||||||
|
|
||||||
|
## Usage
|
||||||
|
|
||||||
|
To use the bot, invite it to a Matrix room and interact with it by sending commands prefixed with `!`. For example:
|
||||||
|
|
||||||
|
- `!date`: Display the current date and time.
|
||||||
|
- `!fortune`: Get a random fortune message.
|
||||||
|
- `!proxy`: Retrieve and test random SOCKS5 and HTTP proxies.
|
||||||
|
- `!isup <domain/ip>`: Check if the specified domain or IP address is reachable.
|
||||||
|
- `!karma <user>`: View or modify karma points for a user.
|
||||||
|
|
||||||
|
For a complete list of available commands and their descriptions, use the `!commands` command.
|
||||||
|
|
||||||
|
# 🍄 Funguy Bot Commands 🍄
|
||||||
|
|
||||||
|
🃏 **!fortune**
|
||||||
|
Returns a random fortune message.
|
||||||
|
Executes the `/usr/games/fortune` utility and sends the output as a message to the chat room.
|
||||||
|
|
||||||
|
⏰ **!date**
|
||||||
|
Displays the current date and time.
|
||||||
|
Fetches the current date and time using Python's `datetime` module and sends it in a formatted message to the chat room.
|
||||||
|
|
||||||
|
💻 **!proxy**
|
||||||
|
Retrieves a tested/working random SOCKS5 proxy.
|
||||||
|
Fetches a list of SOCKS5 proxies, tests their availability, and sends the first working proxy to the chat room.
|
||||||
|
|
||||||
|
📶 **!isup <domain/ip>**
|
||||||
|
Checks if the specified domain or IP address is reachable.
|
||||||
|
Checks if the specified domain or IP address is reachable by attempting to ping it. If DNS resolution is successful, it checks HTTP and HTTPS service availability by sending requests to the domain.
|
||||||
|
|
||||||
|
☯ **!karma <user>**
|
||||||
|
Retrieves the karma points for the specified user.
|
||||||
|
Retrieves the karma points for the specified user from a database and sends them as a message to the chat room.
|
||||||
|
|
||||||
|
⇧ **!karma <user> up**
|
||||||
|
Increases the karma points for the specified user by 1.
|
||||||
|
Increases the karma points for the specified user by 1 in the database and sends the updated points as a message to the chat room.
|
||||||
|
|
||||||
|
⇩ **!karma <user> down**
|
||||||
|
Decreases the karma points for the specified user by 1.
|
||||||
|
Decreases the karma points for the specified user by 1 in the database and sends the updated points as a message to the chat room.
|
||||||
|
|
||||||
|
# 🌟 Funguy Bot Credits 🌟
|
||||||
|
|
||||||
|
🧙♂️ Creator & Developer: Hash Borgir (HB): Hash Borgir, with a background in computer science and cybersecurity, is the author of 🍄Funguy Bot🍄.
|
Loading…
Reference in New Issue
Block a user