From 55ab9c774a5e60c7b691d878c20c44fb1744e474 Mon Sep 17 00:00:00 2001 From: Lili Date: Mon, 12 Sep 2022 09:43:51 +0200 Subject: [PATCH] fix wording, add config --- README.md | 23 ++++++++++++++++------- 1 file changed, 16 insertions(+), 7 deletions(-) diff --git a/README.md b/README.md index a4a9734..cdadf60 100644 --- a/README.md +++ b/README.md @@ -38,7 +38,7 @@ Create a `tlapbot/config.py` file and fill it in as needed. Default values are included in `tlapbot/default_config`, and values in `config.py` overwrite them. -Some recommendations: +Tlapbot will probably not work if you don't overwrite these: ```bash SECRET_KEY # get one from running `python -c 'import secrets; print(secrets.token_hex())'` OWNCAST_ACCESS_TOKEN # get one from owncast instance @@ -52,7 +52,7 @@ In Access Tokens, generate an Access Token to put in `tlapbot/config.py`. At the moment, the only permission the Access Token needs is sending messages, the bot doesn't perform any administrative actions. #### Webhook -In webhooks, you create a Webhook, and point it at your bot's URL with +In webhooks, create a Webhook, and point it at your bot's URL with `/owncastWebhook` added. In debug, this will be something like `localhost:5000/owncastWebhook`, @@ -60,16 +60,16 @@ or, if you're not running the debug Owncast instance and bot on the same machine you can use a tool like [ngrok](https://ngrok.com/) to redirect the Owncast traffic to your `localhost`. #### External Action -In External Actions, you point the external action to your bot's URL with `/dashboard` added. +In External Actions, point the external action to your bot's URL with `/dashboard` added. In debug, this might be something like `localhost:5000/dashboard`, or you can use a tool like ngrok again. -Example: - +**Example:** +``` URL: MyTlapbotServer.com/dashboard - Action Title: Redeems Dashboard +``` ### Running in debug: Set the FLASK_APP variable: @@ -85,4 +85,13 @@ Run the app (in debug mode): python -m flask --debug run ``` ### Running in prod: -To be added when I actually run a prod version of the bot. \ No newline at end of file +To be added when I actually run a prod version of the bot. +## Config +Values you can include in `tlapbot/config.py` to change how the bot behaves. +### Channel points interval and amount +`POINTS_CYCLE_TIME` decides how often channel points are given to users in chat, +in seconds. + +`POINTS_AMOUNT_GIVEN` decides how many channel points users receive. + +By default, everyone receives 10 points every 600 seconds (10 minutes).