Skip to content

RGB-Tools/rln-telegram-bot

Repository files navigation

RGB Lightning Node Telegram Bot

Telegram bot to test RGB payments on the Lightning Network.

It requires a running instance of rgb-lightning-node (RLN).

Build and run

First, clone the project:

git clone https://github.com/RGB-Tools/rln-telegram-bot

Then obtain an API token that is necessary to create the Telegram bot. The token can be obtained by contacting @BotFather on Telegram, issuing the /newbot command and following the steps.

Once you obtained the token you can copy the sample config file (cp config.ini.sample config.ini) and set the API_TOKEN key to its value.

Then, issue an asset on your RGB LN node, set the ASSET_ID key of the config file to its ID, set the LN_NODE_URL so the bot can call the RGN LN node APIs, set the LN_ANNOUNCEMENT_ADDR to the public LN endpoint of the RGN LN node and optionally set the other keys to suit your needs. The RLN LN node needs to be reachable at the provided URL and unlocked for the bot to work.

Finally, provided you have poetry installed, you can install and run the bot executing:

poetry install
poetry run bot

Develop

When developing, you can run the following utilities:

# lint code
poetry run pylint rgb_ln_telegram_bot

# format code
poetry run black rgb_ln_telegram_bot

# sort imports
poetry run isort --profile black rgb_ln_telegram_bot

# find unused code
poetry run vulture rgb_ln_telegram_bot

# check compliance with docstring conventions
poetry run flake8 rgb_ln_telegram_bot

# check for known vulnerabilities
poetry run pip-audit

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 3

  •  
  •  
  •