|
1 | 1 | --- |
2 | 2 | title: Telegram |
3 | | -description: Send messages through Telegram or trigger workflows from Telegram events |
| 3 | +description: Interact with Telegram |
4 | 4 | --- |
5 | 5 |
|
6 | 6 | import { BlockInfoCard } from "@/components/ui/block-info-card" |
@@ -67,7 +67,7 @@ In Sim, the Telegram integration enables your agents to leverage these powerful |
67 | 67 |
|
68 | 68 | ## Usage Instructions |
69 | 69 |
|
70 | | -Integrate Telegram into the workflow. Can send messages. Can be used in trigger mode to trigger a workflow when a message is sent to a chat. |
| 70 | +Integrate Telegram into the workflow. Can send and delete messages. Can be used in trigger mode to trigger a workflow when a message is sent to a chat. |
71 | 71 |
|
72 | 72 |
|
73 | 73 |
|
@@ -96,6 +96,105 @@ Send messages to Telegram channels or users through the Telegram Bot API. Enable |
96 | 96 | | `timestamp` | number | Unix timestamp when message was sent | |
97 | 97 | | `from` | object | Information about the bot that sent the message | |
98 | 98 |
|
| 99 | +### `telegram_delete_message` |
| 100 | + |
| 101 | +Delete messages in Telegram channels or chats through the Telegram Bot API. Requires the message ID of the message to delete. |
| 102 | + |
| 103 | +#### Input |
| 104 | + |
| 105 | +| Parameter | Type | Required | Description | |
| 106 | +| --------- | ---- | -------- | ----------- | |
| 107 | +| `botToken` | string | Yes | Your Telegram Bot API Token | |
| 108 | +| `chatId` | string | Yes | Target Telegram chat ID | |
| 109 | +| `messageId` | string | Yes | Message ID to delete | |
| 110 | + |
| 111 | +#### Output |
| 112 | + |
| 113 | +| Parameter | Type | Description | |
| 114 | +| --------- | ---- | ----------- | |
| 115 | +| `message` | string | Success or error message | |
| 116 | +| `data` | object | Delete operation result | |
| 117 | + |
| 118 | +### `telegram_send_photo` |
| 119 | + |
| 120 | +Send photos to Telegram channels or users through the Telegram Bot API. |
| 121 | + |
| 122 | +#### Input |
| 123 | + |
| 124 | +| Parameter | Type | Required | Description | |
| 125 | +| --------- | ---- | -------- | ----------- | |
| 126 | +| `botToken` | string | Yes | Your Telegram Bot API Token | |
| 127 | +| `chatId` | string | Yes | Target Telegram chat ID | |
| 128 | +| `photo` | string | Yes | Photo to send. Pass a file_id or HTTP URL | |
| 129 | +| `caption` | string | No | Photo caption \(optional\) | |
| 130 | + |
| 131 | +#### Output |
| 132 | + |
| 133 | +| Parameter | Type | Description | |
| 134 | +| --------- | ---- | ----------- | |
| 135 | +| `message` | string | Success or error message | |
| 136 | +| `data` | object | Telegram message data including optional photo\(s\) | |
| 137 | + |
| 138 | +### `telegram_send_video` |
| 139 | + |
| 140 | +Send videos to Telegram channels or users through the Telegram Bot API. |
| 141 | + |
| 142 | +#### Input |
| 143 | + |
| 144 | +| Parameter | Type | Required | Description | |
| 145 | +| --------- | ---- | -------- | ----------- | |
| 146 | +| `botToken` | string | Yes | Your Telegram Bot API Token | |
| 147 | +| `chatId` | string | Yes | Target Telegram chat ID | |
| 148 | +| `video` | string | Yes | Video to send. Pass a file_id or HTTP URL | |
| 149 | +| `caption` | string | No | Video caption \(optional\) | |
| 150 | + |
| 151 | +#### Output |
| 152 | + |
| 153 | +| Parameter | Type | Description | |
| 154 | +| --------- | ---- | ----------- | |
| 155 | +| `message` | string | Success or error message | |
| 156 | +| `data` | object | Telegram message data including optional media | |
| 157 | + |
| 158 | +### `telegram_send_audio` |
| 159 | + |
| 160 | +Send audio files to Telegram channels or users through the Telegram Bot API. |
| 161 | + |
| 162 | +#### Input |
| 163 | + |
| 164 | +| Parameter | Type | Required | Description | |
| 165 | +| --------- | ---- | -------- | ----------- | |
| 166 | +| `botToken` | string | Yes | Your Telegram Bot API Token | |
| 167 | +| `chatId` | string | Yes | Target Telegram chat ID | |
| 168 | +| `audio` | string | Yes | Audio file to send. Pass a file_id or HTTP URL | |
| 169 | +| `caption` | string | No | Audio caption \(optional\) | |
| 170 | + |
| 171 | +#### Output |
| 172 | + |
| 173 | +| Parameter | Type | Description | |
| 174 | +| --------- | ---- | ----------- | |
| 175 | +| `message` | string | Success or error message | |
| 176 | +| `data` | object | Telegram message data including voice/audio information | |
| 177 | + |
| 178 | +### `telegram_send_animation` |
| 179 | + |
| 180 | +Send animations (GIFs) to Telegram channels or users through the Telegram Bot API. |
| 181 | + |
| 182 | +#### Input |
| 183 | + |
| 184 | +| Parameter | Type | Required | Description | |
| 185 | +| --------- | ---- | -------- | ----------- | |
| 186 | +| `botToken` | string | Yes | Your Telegram Bot API Token | |
| 187 | +| `chatId` | string | Yes | Target Telegram chat ID | |
| 188 | +| `animation` | string | Yes | Animation to send. Pass a file_id or HTTP URL | |
| 189 | +| `caption` | string | No | Animation caption \(optional\) | |
| 190 | + |
| 191 | +#### Output |
| 192 | + |
| 193 | +| Parameter | Type | Description | |
| 194 | +| --------- | ---- | ----------- | |
| 195 | +| `message` | string | Success or error message | |
| 196 | +| `data` | object | Telegram message data including optional media | |
| 197 | + |
99 | 198 |
|
100 | 199 |
|
101 | 200 | ## Notes |
|
0 commit comments