Usage: http://render.imoalert.com.br/resize
/output
/url
width
xheight
- stretch to exact dimensionswidth
xheight
[gravity
] - crop to dimensions with optional gravityc
(center). Options: c, n, ne, e, se, s, sw, w, nw
height
- scale proportional to height (e.g., h160)width
- scale proportional to width (e.g., w120)format
- Default is jpg
. Supported: jpg, png
jpg,quality
- Optional quality for JPEG (1-100, default: 80)Basic resize:http://render.imoalert.com.br/120x160/jpg/https://example.com/image.jpg
Crop with center gravity:http://render.imoalert.com.br/c300x300/jpg/https://example.com/image.jpg
Crop with north gravity:http://render.imoalert.com.br/c300x300n/jpg/https://example.com/image.jpg
Scale by height:http://render.imoalert.com.br/h300/jpg/https://example.com/image.jpg
Scale by width with quality:http://render.imoalert.com.br/w300/jpg,90/https://example.com/image.jpg
Use the getCacheName.js
utility to get cache filenames from routes:
Get cache name from route:node utils/getCacheName.js "/w100/jpg,50/https://example.com/image.jpg"
Returns the cache filename and full path information
Example output:
✅ Sucesso!
📄 Nome do arquivo: 04a22000d2c837920a49e555f55cb4dd676b0f49.jpg
📁 Caminho completo: /cache/04a22000d2c837920a49e555f55cb4dd676b0f49.jpg
This utility is helpful for: