Skip to content

spalen0/bad-debt-alert

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

31 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Bad Debt Alert

Alerting Telegram bot for bad debt data from Risk DAO. It's a simple Python script that is triggered by GitHub actions every hour. It checks bad debt data for a given protocol and if the value is above a given threshold it will send Telegram message to a defined chat.

Add new alert

  • Add new workflow to .github/workflows
  • In GitHub repository settings add secrets:
    • TELEGRAM_TOKEN - generate token for your bot.
    • TELEGRAM_CHAT_ID - open the link in a browser and change {TELEGRAM_TOKEN} to your token. Find your chat id in the JSON response. It's possible to set multiple chat ids separated by comma.
  • Set remaining env variables:
    • PROTOCOL name of the protocol you want to monitor.
    • DEBT_THRESHOLD in dollars after which an alert will be sent to Telegram chat. Optional value.
    • DEBT_THRESHOLD_RATIO in percent after which an alert will be sent to Telegram chat. Default value is 100%.
    • DATA_URL link to the data source in JSON format. Link to all RiskDAO data sources. Example data URL for Sonne Finance.

About

Alerting for debt debt

Resources

Stars

Watchers

Forks

Languages