-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
add brief description in readme.md and rename Broker class
- Loading branch information
Showing
2 changed files
with
23 additions
and
2 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 +1,22 @@ | ||
# TelegramAlerts | ||
# TelegramAlerts | ||
|
||
Telegram bot created to get Alerts from Ensemble on your mobile phone | ||
|
||
## Steps to add to your Ensemble Production | ||
|
||
1. Create your bot using BotFatner (https://telegram.me/BotFatner) and get a token | ||
2. Create client SSL configuration in Management Portal | ||
3. Import classes (Telegram package) | ||
4. Create Lookup Table in your Ensemble namespace. Add one or more records. Use phone number (without "+" prefix) as a key. | ||
5. Add in your Production business operation TelegramOperation, in its settings, you must specify TelegramToken and SSLConfiguration | ||
|
||
For getting updates from Telegram do one of the following (6 or 7): | ||
6. Long polling. Add TelegramService business service to your Production and configure it. Specify TelegramToken, SSLConfiguration, TableName (Lookup table name). Set call interval. | ||
7. Webhook | ||
* Create web application and Specify Dispatch Class parameter as Telegram.RESTBroker.cls | ||
* Configure SSL on your Web server | ||
* Call method SetWebhook of class Telegram.API to set webhook. | ||
* Add TelegramService business service to your Production. Specify TableName (Lookup table name). Set "Pool Size"=0. | ||
|
||
8. Add AlertOperation.cls with the name Ens.Alert to the product and configure TelegramToken, SSLConfiguration, TableName | ||
9. Done! |
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,4 +1,4 @@ | ||
Class REST.Broker Extends %CSP.REST | ||
Class Telegram.RESTBroker Extends %CSP.REST | ||
{ | ||
XData UrlMap | ||
{ | ||
|