revolt-bot/README.md
2021-10-05 23:04:40 +02:00

37 lines
813 B
Markdown
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# Revolt-Bot
Projet de bot en *Bash* pour *Revolt*.
…Un peu de *Python* aussi.
Si `revolt_bot.sh` est exécutable laide est disponible comme suit :
```bash
revolt_bot.sh --help
```
## Dépendances
Ce petit bot en *Bash* dépend de deux outils :
### *cURL*
*cURL* permet de communiquer avec lAPI de *Revolt* (un serveur *Revolt Delta*) via le HTTP.
Pour linstaller via `apt` :
```bash
sudo apt install curl
```
### *Py-ULID*
*Py-ULID* permet de générer des codes de type ULID sous forme de 26 caractères.
Pour linstaller via `pip` :
```bash
pip install py-ulid
```
## Usage
Pour envoyer un message `MESSAGE` via son bot le jeton didentification `BOT_TOKEN` et lidentifiant du salon `CHANNEL_ID` sont nécessaires.
```bash
revolt_bot.sh -t $BOT_TOKEN -c $CHANNEL_ID -m $MESSAGE
```