Skip to content

Commit

Permalink
Merge pull request #50 from PowerLoom/feat/telegram-bot-update
Browse files Browse the repository at this point in the history
Telegram bot instructions update
  • Loading branch information
SwaroopH authored Sep 2, 2024
2 parents 9a7e7d2 + dbcd162 commit 1f08eac
Show file tree
Hide file tree
Showing 6 changed files with 27 additions and 21 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -190,6 +190,10 @@ After initiating the process, the terminal will prompt you to enter the followin

- `$SLOT_ID`: To assign your node to a specific slot, please provide the corresponding Slot ID or NFT ID. You can locate your NFT ID within your transaction details on PolygonScan.

- Optionally, you can provide to following values:

- `$TELEGRAM_CHAT_ID`: Can be provided if you would like to enable Telegram reporting for node issues. See our [Telegram Bot Setup](/docs/build-with-powerloom/snapshotter-node/lite-node/Telegram%20Bot%20Setup.md) page for instructions on how to get your Telegram Chat ID.

After entering these details, the node will start running the background processes.

If you want to exit your screen, type the command in the terminal:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,13 @@ This section will guide you through the process of Monitoring and Troubleshootin
## Steps to Confirm and Monitor Node Snapshotting Process

### Monitoring Node Activity with the Snapshotter Dashboard
Our Snapshotter Dashboard enables you to verify if your node slot is actively submitting snapshots.
- #### Snapshotter Dashboard
Our Snapshotter Dashboard enables you to verify if your node slot is actively submitting snapshots.

![Snapshotter-node-dashboard](/images/snapshot-lite-v2-daily-dashboard.png)
![Snapshotter-node-dashboard](/images/snapshot-lite-v2-daily-dashboard.png)

- #### Telegram Reporting Bot
Snapshotter Lite Nodes have the capability to send Telegram messages directly to you if any issues arise during the snapshotting process. See the [Telegram Bot Setup](/docs/build-with-powerloom/snapshotter-node/lite-node/Telegram%20Bot%20Setup.md) page for instructions on how to enable this feature.

### Terminal Status Check
- The primary method to verify node status is through the terminal, which displays log responses from the node.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,36 +1,34 @@
### Setting up your Telegram Bot | Node Health Monitoring


This guide provides instructions for setting up your Powerloom Telegram Bot to monitor the health of your node. The Snapshotter-lite nodes currently require manual monitoring to detect any issues.
The Snapshotter-lite nodes currently require manual monitoring to detect any issues.

Introducing the Powerloom Telegram Bot, ‘PowerloomReportingBot’. This bot service maintains an internal health state and reports any issues to operators, such as failed or missed snapshots.
Introducing the `PowerloomReportingBot`! This bot service maintains an internal health state and reports any issues to operators, such as failed or missed snapshots. This guide provides instructions for setting up your Powerloom Telegram Bot to monitor the health of your node.

### Follow the steps below to set up your Node Health Monitoring process using Telegram.
### Telegram Bot Setup Instructions:

- Step 1: Find the telegram bot by searching ‘PowerloomReportingBot’ on Telegram
- Step 2: Type ‘/start to activate the bot. This will provide you with a Chat ID.
- **Step 1**: Open a new conversation with [@PowerloomReportingBot](https://t.me/PowerloomReportingBot) in the Telegram App.
- **Step 2**: Start the bot by typing `/start` to activate the bot. This will provide you with a `Chat ID`.

![chatID-start](/images/chatID-start.png)
:::note
The PowerloomSnapshotterReportingService will <ins>never</ins> ask you for any personal information or private keys. Ensure that you have started a conversation with the correct bot, and do not provide any information besides the `/start` command under any circumstances.
:::

### If you are setting up the node for the first time,
Enter the ChatID when prompted on the terminal during the node setup.
![chatID-start](/images/chatID-start.png)

### If you have an existing installation,
Here's what you can do:
- **Step 3**: Provide the `Chat ID` to your Snapshotter Lite node:

A.
- Update your `.env` file with the generated ChatID & the Telegram Reporting URL, as seen in the image below.
- Run the build setup again
- If you are setting up the node for the first time, enter the `Chat ID` when prompted on the terminal during the node setup:

![updated-env-screenshot](/images/updated-env-screenshot.png)
![telegram-promp](/images/telegram-prompt.png)

OR
- If you have a running node and would like to add the Telegram reporting feature, there are two options that you can use:

B.
- Delete your existing `.env` file & Run the build setup again.
- Enter the ChatID when prompted on the terminal.
**Option 1**: Update your `.env` file with the generated `Chat ID` as seen in the image below. Once updated, run the `./build.sh` command again to restart the node.

![terminal-prompt](/images/terminal-prompt.png)
![updated-env-screenshot](/images/updated-env-screenshot.png)

**Option 2**: Delete your `.env` file, and then run the `./build.sh` command again to trigger a recreation of the `.env`. This will remove all values from the initial setup, so ensure that you have these available.

### To check if the Bot is successfully running, try these:

Expand Down
Binary file modified static/images/failed-snapshot.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added static/images/telegram-prompt.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified static/images/updated-env-screenshot.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 1f08eac

Please sign in to comment.