Enhance & expand Telegram images to 3:2 with CodeFormer & LightX AI
Ready for 3.0Ready for 3.0. This template uses no nodes that n8n 3.0 removes. No removed nodes, versions or helpers found. Static check, last run 2026-10-19.
What this workflow does
This workflow has 26 nodes and runs on Telegram events. Along the way it connects Telegram and AWS S3.
How it runs
Trigger: On Telegram events.
- Check If Photo Exists (If): checks a condition and branches into true / false
- Set Input URL for AI Model (Edit Fields (Set)): sets or maps fields
- Generate Input File Name (.jpeg) (Edit Fields (Set)): sets or maps fields
- Generate Output File Name (.png) (Edit Fields (Set)): sets or maps fields
- Upload Original Photo to S (AWS S3): uses AWS S3
- AI Upscale Image via Replicate (HTTP Request): calls an HTTP API
- Generate Public URL for Original Image (Edit Fields (Set)): sets or maps fields
- Wait: pauses before continuing
- Download Upscaled Image from Replicate (HTTP Request): calls an HTTP API
- Calculate Padding for 3:2 Ratio (Code): runs custom JavaScript code
…plus 15 more steps. See the full node list below.
Services it uses
Before you upgrade to n8n 3.0
Nothing in this workflow is removed in n8n 3.0, so it should import and run after the upgrade.
Nodes used (10)
- Telegram
n8n-nodes-base.telegram - Edit Fields (Set)
n8n-nodes-base.set - AWS S3
n8n-nodes-base.awsS3 - HTTP Request
n8n-nodes-base.httpRequest - If
n8n-nodes-base.if - Wait
n8n-nodes-base.wait - Loop Over Items (Split in Batches)
n8n-nodes-base.splitInBatches - Merge
n8n-nodes-base.merge - Code
n8n-nodes-base.code - Telegram Trigger
n8n-nodes-base.telegramTrigger
From the author
🚀 Automatically enhance and expand Telegram images with AI This n8n workflow turns your Telegram bot into a powerful AI photo enhancer! Whether users send a photo or a link, it processes the image by: 1. 📥 Receiving the input (photo or link) 2. 🧠 Upscaling…