-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
12d6ec0
commit 8758f8c
Showing
2 changed files
with
21 additions
and
21 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,21 +1,27 @@ | ||
# serverless-freshping-telegram | ||
Serverless solution for freshping-telegram integration. Creates a telegram bot that notifies a group when the server status changes (Available/ Not Responding) that is hosted with AWS Lambda. | ||
|
||
### Working Telegram Bot | ||
1. Add @esm_wonderful_bot to the telegram group | ||
2. Get group chat ID by adding @getidsbot | ||
3. Go to Freshping > Setting > Integrations > Webhook | ||
serverless-freshping-telegram | ||
====== | ||
![GitHub](https://img.shields.io/github/license/yarkhinephyo/serverless-freshping-telegram?style=flat-square) | ||
|
||
Serverless solution for freshping-telegram integration. Creates a telegram bot that notifies a group when the server status changes (Available/ Not Responding) that is hosted with AWS Lambda. | ||
|
||
### Integrate In Four Steps | ||
1. Add `@esm_wonderful_bot` to the telegram group | ||
2. Add `@getidsbot` to the telegram group to get group chat ID | ||
3. Go to Freshping Dashboard > Setting > Integrations > Webhook | ||
4. Paste `https://irrb74more.execute-api.ap-southeast-1.amazonaws.com/dev/{chat_id}` | ||
(Example: If group chat ID is -100123456, paste `https://irrb74more.execute-api.ap-southeast-1.amazonaws.com/dev/-100123456`) | ||
|
||
### Custom Deployment | ||
Example: If group chat ID is -100123456, paste | ||
`https://irrb74more.execute-api.ap-southeast-1.amazonaws.com/dev/-100123456` | ||
|
||
<hr/> | ||
|
||
### Custom Setup | ||
|
||
1. Ensure you have a [Freshping account](https://www.freshworks.com/website-monitoring/) | ||
2. [Create a Telegram Bot](https://core.telegram.org/bots#6-botfather) with @BotFather and save the bot token | ||
2. [Create a Telegram Bot](https://core.telegram.org/bots#6-botfather) with @BotFather and save the bot token | ||
3. Ensure [AWS credentials](https://docs.aws.amazon.com/cli/latest/userguide/cli-configure-files.html) are set up on your computer for Serverless to work | ||
4. Clone this repo: `git clone https://github.com/yarkhinephyo/serverless-freshping-telegram.git` | ||
5. Install Dependencies: `npm i` | ||
6. Deploy the webhook: `sls deploy --botToken <Telegram bot token>` | ||
(URL will look like: https://xxxxxxxxxx.execute-api.ap-southeast-1.amazonaws.com/dev/{chat_id}) | ||
7. Add webhook URL on Freshping | ||
Freshping > Setting > Integrations > Webhook | ||
Paste the URL while replacing {chat_id} with telegram group's chat id | ||
6. Deploy the webhook and receive a URL: `sls deploy --botToken <Telegram bot token>` | ||
7. Refer to the integration guide above |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters