This is a Telegram bot that helps to calculate sleep phases.
Available at: https://t.me/wake_me_bot
To run this bot locally, you should get your own BOT_TOKEN
, using BotFather.
There are two ways to get updates from this bot
- get updates from a chan
- get updates via API call, by setting up a webhook
- Modify
compose.env
file, to store yours validBOT_TOKEN
- Run the following command to start datastore emulator and bot automatically:
docker compose -f chan-compose.yml up --build
- Try to use your bot from a telegram client
-
Install ngrok
-
Set up a tunnel from
:8080
port using the following command:ngrok http 8080
As the result you will see something similar to this message:
ngrok by @inconshreveable (Ctrl+C to quit) Session Status online Account ____________ (Plan: Free) Update update available (version 2.3.40, Ctrl-U to update) Version 2.3.35 Region United States (us) Web Interface http://127.0.0.1:4040 Forwarding http://ab88-134-17-149-60.ngrok.io -> http://localhost:8080 Forwarding https://ab88-134-17-149-60.ngrok.io -> http://localhost:8080 Connections ttl opn rt1 rt5 p50
-
Copy a forwarding URL from the ngrok result screen. Choose the one, that starts with
https://
. Paste it intocompose.env
file as aWEBHOOK_URL
. -
Modify
compose.env
file, to store yours validBOT_TOKEN
. -
Run the following command to start datastore emulator and bot automatically.
docker compose -f webhook-compose.yml up --build
-
Try to use your bot from a telegram client
We use Trello board as a public issues tracker. To leave an issue to the project, please open a new github issue, we will migrate it to trello, then you will be able to track a progress on it.
https://trello.com/b/iycB60bT/wakebot
Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.