Image Resize API - width, height or percent
image_resizeResize 1-30 images by width, height (aspect kept) or percent, Lanczos quality; exact=true stretches to width x height. GPS/EXIF removed. Runs on our server, files are deleted right after the call, nothing stored. Free: 25 calls/day per IP. Paid: $0.003 per call via x402 at https://radarbg.com/x402/image-resize.
Example tool call
This call uses example arguments supplied in the tool’s input schema.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"width": 60,
"fileName": "sample.png",
"fileContent": "iVBORw0KGgoAAAANSUhEUgAAAHgAAABQCAIAAABd+SbeAAAA6klEQVR4nO3cQQ2DABAAwdKgg1cFVQIykIOEyqiIisFDKdsQZv6XXDb3vmFa3jeOd//3AlchdEToiNARoSNCR4SOCB0ROiJ0ROiI0BGhI0JHhI4IHRE6InRE6Mi4Z/jznH+0xmk8Xut3gy46InRE6IjQEaEjQkeEjggdEToidEToiNARoSNCR4SOCB0ROiJ0ROiI0BGhI0JHhI4IHRE6InRE6IjQEaEjQkeEjggdEToidEToiNARoSNCR4SOCB0ZPIFtuOiI0BGhI0JHhI4IHRE6InRE6IjQEaEjQkeEjggdEToidEToiNCRDexBBl0OjJSaAAAAAElFTkSuQmCC"
},
"name": "image_resize"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| exact | No | Use exactly width x height | |
| files | No | Or several files: [{fileName, fileContent (base64)}] | |
| width | No | Width in px (max 10000) | |
| height | No | Height in px (max 10000) | |
| percent | No | Or scale in percent (1-400) | |
| fileName | No | File name with extension, e.g. report.pdf | |
| fileContent | No | The file as base64 (a data: URI is fine) |