Telegram Notification Node
The Telegram Notification node sends messages to Telegram users, groups, and channels through a bot you create. Use it to get instant trading alerts, execution summaries, and portfolio updates delivered straight to your phone.
Configuration
Telegram Bot Credentials
Message Content
Advanced Options
Configuration
| Field | Description |
|---|---|
| Bot Token Credential | Your Telegram bot token, stored as an encrypted credential. Create a bot via @BotFather ↗ to get one. |
| Chat ID | The target recipient: a user ID (e.g., 123456789), group ID (e.g., -1001234567890), or channel username (e.g., @mychannel). Supports interpolation. |
| Message Text | The message body. Supports Markdown formatting and {{edgeLabel.field}} interpolation for dynamic data. Maximum 4,096 characters (auto-truncated if longer). |
| Parse Mode | How Telegram renders your message: Markdown (default), MarkdownV2, or HTML. |
| Disable Web Preview | When enabled, links in your message won't generate preview cards. Default: off. |
| Silent Notification | When enabled, the recipient's device won't vibrate or make a sound. Default: off. |
Bot Setup
Before you can send messages, you need a Telegram bot and a chat ID. Follow these steps:
Step 1: Create a Bot
- Open Telegram and search for @BotFather (or tap this link ↗).
- Send the
/newbotcommand. - Choose a display name for your bot (e.g., "My Trading Alerts").
- Choose a username ending in
bot(e.g.,my_trading_alerts_bot). - BotFather will reply with your bot token -- it looks like
123456789:ABCdefGHIjklMNOpqrsTUVwxyz-1234567890. Copy it.
Step 2: Save the Token in NickAI
- Go to Credentials in NickAI.
- Click Add Credential and select Telegram.
- Paste your bot token and give the credential a name (e.g., "My Trading Bot").
- Click Save. The token is encrypted at rest.
Step 3: Get Your Chat ID
You need the numeric chat ID for the recipient. Here is how to find it:
For your personal account:
- Open Telegram and search for @userinfobot.
- Send it any message -- it will reply with your user ID (a number like
123456789).
For a group:
- Add your bot to the group.
- Send a message in the group.
- Open
https://api.telegram.org/bot<YOUR_TOKEN>/getUpdatesin a browser. - Find the
"chat"object -- the"id"field is your group chat ID (it starts with-100).
For a channel:
- Add your bot as an admin of the channel.
- Use the channel's
@usernameas the chat ID (e.g.,@mychannel), or use the numeric ID from thegetUpdatesmethod above.
Step 4: Start a Conversation with Your Bot
- Search for your bot by its username in Telegram.
- Tap Start or send any message (e.g.,
/start). - Your bot can now send you messages.
Template Interpolation
Use double curly braces to inject live data from upstream nodes into your message text and chat ID fields.
Trading Alert Example
*BTC/USD Alert*
Price: ${{price_data.data.prices[0].current}}
24h Change: {{price_data.data.prices[0].changePercent24h}}%
RSI: {{price_data.data.prices[0].indicators.rsi}}
Signal: {{llm.output}}
Order Confirmation Example
*Order Executed*
Action: {{exchange.side}}
Symbol: {{exchange.symbol}}
Quantity: {{exchange.quantity}}
Price: ${{exchange.price}}
Status: {{exchange.status}}
Portfolio Summary Example
*Daily Portfolio Update*
Total Value: ${{portfolio.netWorth}}
Cash: ${{portfolio.cashBalance}}
Positions: {{portfolio.positionCount}}
Top Holding: {{portfolio.positions[0].symbol}} ({{portfolio.positions[0].percentage}}%)
Workflow Example
A common pattern is to run analysis, check a condition, and send a Telegram alert when something noteworthy happens:
In this workflow:
- Price Data fetches live BTC/USD market data.
- LLM analyzes the price, volume, and indicators to produce a signal with a confidence score.
- Conditional checks if confidence exceeds 80%.
- Telegram Notification sends the alert to your phone -- only when the signal is strong.
You can also place Telegram at the end of both branches to send different messages for true and false conditions:
Output
After execution, the node produces the following data that downstream nodes can reference:
| Path | Description |
|---|---|
| {telegram.success} | true if the message was sent, false if it failed. |
| {telegram.message} | A status string -- "Telegram message sent successfully" on success, or an error description on failure. |
| {telegram.messageId} | The numeric Telegram message ID (only present on success). Useful for tracking or referencing specific messages. |
telegram with your node's edge label. If the edge connecting this node to the next is labeled alert, use {alert.success}.Parse Mode Reference
Telegram supports three formatting modes. Choose the one that fits your message style:
| Mode | Bold | Italic | Code | Link |
|---|---|---|---|---|
| Markdown | *bold* | _italic_ | `code` | [text](url) |
| MarkdownV2 | *bold* | _italic_ | `code` | [text](url) -- must escape special chars with \ |
| HTML | <b>bold</b> | <i>italic</i> | <code>code</code> | <a href="url">text</a> |
Next Steps
- Email Notification Node -- Send alerts via email as a backup channel.
- Discord Notification Node -- Post alerts to Discord servers.
- Slack Notification Node -- Send alerts to Slack channels.
- Conditional Node -- Route workflows based on conditions before sending notifications.
- Credentials -- Manage your Telegram bot token and other API keys.