A telegram bot written with Telegraf.js that turns any image sent into a fitted phone wallpaper with a blurry background.
The project uses Docker, to make the setup easier.
Credits to @MakotoIchinose6 for the image of Clive they made that I use for the preview. (I'm absolutely in love)
.
├── Dockerfile
└── src
├── bot.ts
├── index.ts
├── handlers
│ └── index.ts
├── models
│ ├── bot.ts
│ └── functions.ts
└── utilities
├── functions.ts
└── validateEnv.tsor if you are planning to run the script yourself
- NodeJS >= v18.0.5
-
Create a token for the bot through BotFather
-
Get the docker image:
docker pull kiwipetal/telegramwallpapers:latest- Run the docker image:
docker run -d -e BOT_TOKEN="YOURTOKEN" kiwipetal/telegramwallpapers:latest-
Pull the repository.
-
Install all dependencies:
npm install
# or
yarn-
Create a token for the bot through BotFather
-
Create an .env file:
BOT_TOKEN=YOURTOKEN- Run the script
npm run start
# or
yarn startSend a number to change the blur strength (default: 200). The package for blurring seems to break if you go above 300 though (Will fix that later).
Send an image (not as a file). The bot will respond with an edited version.
- Script to Make images
- Custom intensity
- Docker integration
- Feature flag to opt out of session persistence
- Custom resolution
- Shadow
- Colour instead of blur
