All our programs (S#.Designer
), as well as those custom-built on S#.API
, can send messages to Telegram channels and groups, both public and private.
Telegram is a leading messenger, making it an ideal communication tool for interacting with a trading robot (receiving notifications). For managing robots, we offer another service - S#.Telegram robots
(please refer to the service where the Telegram bot authorization process is described).
To configure notifications in Telegram:
- Go through the bot authorization process as described in the S#.Telegram robots service.
- Create a channel or group (private or public).
- Add the StockSharpBot to your channel or group.
- Make the bot an administrator.
- Provide the necessary permissions for proper functionality.
- Write a special word activate in the channel or group.
- If successful, you will receive a response.
The created channel is now available for your strategies and trading robots:
- In the case of using S#.Designer, click on the list of channels in the top panel:
In the appeared window, you will see the lists of all channels and groups where you have activated the bot:
By clicking the button with the Telegram icon, a test message will be sent. If you receive it, it means that everything is done correctly.
In the free tariff, a line mentioning the StockSharp website is added. This line is removed in paid tariffs.
If you have multiple output channels in Telegram and you want to send different strategies to different channels, you can specify specific channels for each strategy in the properties:
- In other programs, the settings are similar to S#.Designer. For example, in the S#.Data program, you can configure error logging for market data downloading if S#.Data is located on a server, and you need to receive prompt information about a failed connection.
- In the case of S#.Shell or S#.API, you can look at the code that integrates your strategies with the Telegram service.