Connector · Messaging and email
Telegram, in every client’s workflows.
Send a message, send a photo, or start when a message is sent to the bot, with the client’s own Telegram account.
- Triggers
- 1start a workflow
- Actions
- 3steps in a workflow
Start a workflow when something happens in TelegramBeta
By webhook where Telegram sends one, by checking where it does not. A webhook is checked once a day to see it is still on, and if Telegram turns it off the alert carries a Reconnect button.
- A message is sent to the botWebhookA message to the bot, within seconds. A bot sends its messages to one place: one workflow per bot, and no other tool may use the same bot’s updates. In a group, the bot sees only commands, replies and mentions unless privacy mode is off (BotFather).
Do it in Telegram
A step with its own fields: values from the run go in by name, and what Telegram answers is there for the next step.
- Send a messageMessage a chat, group or channel the bot is in.
- Send a photoA picture from a web address (an earlier step’s link, a public URL), up to 4.5 MB, with an optional caption.
- Send a fileA file from a web address (a PDF, an invoice, a report), up to 4.5 MB, with an optional caption.
Connect the client’s Telegram
On the client’s page in Thrum: Add credential, type Telegram bot token.
In Telegram, message @BotFather → /newbot → copy the token. Add the bot to the client’s group, or have the client message it once.
The key is stored encrypted and bound to that client: another client’s workflow cannot use it, and no template or pack copies it.
Via HTTP
Or by web request: send a message to a chat
Owners who live in Telegram get the lead on their phone the moment it arrives. The web request step, filled in: paste it, swap in the client’s ids, add their key.
01
Add the client’s credential
On the client’s page in Thrum: Add credential, type API key. In Telegram, message @BotFather → /newbot → copy the token. Add the bot to the client’s group, or have the owner send it one message first.
{ "api_key": "123456789:AA…" }02
Add a web request step
Name it “Message the owner”, set it as here, and pick the credential. Values in double braces are read from the run: here, the lead the form brought in.
- CHAT_ID
- The chat’s number (a group’s starts with -100), or @channelname for a public channel. Send the bot a message, then open api.telegram.org/bot<token>/getUpdates and read chat.id.
{ "method": "POST", "url": "https://api.telegram.org/bot{{ credential.api_key }}/sendMessage", "body": { "chat_id": "CHAT_ID", "text": "New lead: {{ lead.name }}, {{ lead.phone }}. {{ lead.summary }}" } }03
What goes out, and what comes back
The token is part of the address; the engine keeps it out of the run’s record.
POST https://api.telegram.org/bot••••••••/sendMessage content-type: application/json { "chat_id": "CHAT_ID", "text": "New lead: Nadia Karim, +447700900222. Quote for a new bathroom, two basins and a shower" }200 { "ok": true, "result": { "message_id": 42, "chat": { "id": -1001234567890, "type": "supergroup" }, "date": 1790582700, "text": "New lead: Nadia Karim, +447700900222. Quote for a new bathroom, two basins and a shower" } }
Watched like everything else
When Telegram stops answering or refuses the client’s key, you hear about it, and your client does not.
- A failing request
- Tried 3 times, 5 seconds apart and doubling, only for errors a retry can fix
- A service that asks for a pause
- Given it, up to an hour
- Requests at once, per account
- 2, per worker; the rest wait their turn
- Timeout
- 15 seconds, unless the step sets its own
- Private and internal addresses
- Refused, on every redirect too
- The client’s key
- Encrypted, bound to the client, and kept out of every run record
- A step that keeps failing
- Marks the workflow Degraded and alerts you, not the client
Telegram and its logo are trademarks of their owner, used here only to say what Thrum works with; no endorsement is implied.
Thrum is cooking.
Get early access and you’ll be among the first in. Early members get a launch perk.