ComfyUI Telegram Suite
Implement Telegram into your ComfyUI workflows.
Nodes (35)
The type adapter for audio-signal ordering
Relabel a signal so a flag port accepts it
The type adapter for text-encoder plumbing
The converter that feeds Telegram API params
A type bridge, not a number converter
Relabel a signal so an image port accepts it
The converter that restores a number after a trigger
The type adapter for latent-space ordering
Restore a model's type after a trigger
The type adapter you're most likely to actually use
The converter that just relabels
Call any Telegram Bot API method from your workflow
The legacy half of the audio converter pair
The converter the README says you no longer need
Cast a CLIP model to ANY without touching a single weight
Cast a dict to ANY so it can flow into any wildcard socket
Swap the audio on a Telegram message without posting a new one
Rewrite the caption on a Telegram message you already sent
Swap the image in a Telegram message without resending the whole thing
Rewrite a Telegram message instead of spamming a new one
Replace the video in a Telegram message after it's already sent
Cast a float to ANY β the two-second fix for stubborn sockets
Pass an IMAGE through as ANY without touching a pixel
Cast an int to ANY when ComfyUI's type checker won't let it through
Cast a latent to ANY without decoding a thing
Pure relabel, zero model math
Turn a JSON string into a real dict inside a ComfyUI graph
Send TTS and audio straight to Telegram β voice notes included
Show 'typingβ¦' in Telegram while your workflow grinds
Push your finished renders to Telegram β no more babysitting the queue
Send a text message to your phone when the render finishes
Ship your finished render straight to a Telegram chat
Cast a string to ANY so it stops fighting ComfyUI's type checker
The node that gives every other Telegram node a phone number
Cast a VAE to ANY without loading or decoding anything
ComfyUI Telegram Suite
Implement Telegram into your ComfyUI workflows.
Nodes
The main nodes:
<img src="https://github.com/SwissCore92/comfyui-telegram-suite/blob/master/screenshots/main_nodes.png" alt="screenshots/main_nodes.png">
You can configure it via: ComfyUI/user/default/telegram-suite/config.json
- If the
IMAGEinput contains multiple images andgroupis set toTrue, theyβll be sent as a media group. - If
groupis False, the images will be sent individually. - If
send_as_fileisTrue, the images will be sent as files instead of inline media.
</details> <details><summary>Send Video </summary> This node sends a video file.Note:
Only themessage(_id)of the last sent image will be returned to the output.
- The video input must be of type
VHS_FILENAMES(e.g., from theFilenamesoutput of the Video Combine node in the Video Helper Suite).
The video can be sent as a regular video, an animation, or a file.
</details> <details><summary>Send Audio </summary> This node sends an audio file.- Can be sent as an audio message, voice message, or file.
Additional nodes include message editing, experimental features, and various type converters (see Triggers).
Installation
Note: Requires
ffmpeg!
Step 1:
Install via ComfyUI Manager (and skip to Step 2) or execute the following commands:
β οΈ Ensure your ComfyUI virtual environment is activated and you're in the
ComfyUI/custom_nodesdirectory.
git clone https://github.com/SwissCore92/comfyui-telegram-suite.git
cd comfyui-telegram-suite
pip install -r requirements.txt
Step 2:
Restart ComfyUI.
Step 3:
Add your bot(s) and chat(s) to the config file.
- Open:
ComfyUI/user/default/telegram-suite/config.json. - Add your bot token(s) under
"bots". - Add your chat ID(s) under
"chats". - (Optional) Add your own telegram bot api url under
"api_url".
Example:
{
"bots": {
"MyCoolBot": "123456:ABC-DEF1234ghIkl-zyx57W2v1u123ew11",
"MyOtherCoolBot": "654321:CBA-DEF1234ghIkl-zyx57W2v1u123ew11"
},
"chats": {
"MyPrivateChat": 567891234,
"MyGroupChat": -1012345678
},
"api_url": "http://localhost:8081"
}
Use any string as the key for
"bots"and "chats"β I like to use the Telegram @usernamefor clarity.
Step 4:
Restart ComfyUI again β and you're good to go!
Triggers
The optional trigger inputs/outputs are used to enforce execution order in your workflow.
ComfyUI runs by evaluating output nodes and working backward to resolve dependencies. I like to think of it as the inputs "pulling" the values they need from connected outputs.
The trigger passthrough ensures a node executes at a specific point during the workflow. Here's an example using F5-TTS:
<img src="https://github.com/SwissCore92/comfyui-telegram-suite/blob/master/screenshots/trigger_example_tts.png" alt="screenshots/trigger_example_tts.png">This flow sends the recording_voice chat action before generating the audio with the F5-TTS node. Once audio is generated, it's sent to the chat.
The seed is required by the
F5-TTS Audionode, so theSend Chat Actionnode must execute first.
You can use almost any type as a trigger. However, since ComfyUI has strict type checking, you'll need to:
- ~~Convert the signal to ANY before feeding it into the trigger input.~~
This step is no longer required. You can feed the trigger signal directly into the node now. - Convert it back to the original type after the trigger output.
Yes, it's a bit clunky β but itβs the only reliable way Iβve found to control execution order. Thatβs also why the converter category has so many nodes.
If you have Ideas how to solve the problem in a more elegant way, feel free to open a PR.
To Do
-
[ ] Improve documentation
-
[x] Add
Edit Message Videonode -
[x] Add
Edit Message Audionode -
[x] Add Forum/Topics support
-
[x] Add tooltips and descriptions.
-
[ ] Add Rich Message support.
-
[ ] Wait for feedback to refine this list