Media
Convert multiple image files between different formats like JPG, PNG, WebP, AVIF, TIFF, GIF with quality settings and batch processing
Call this tool from your code in three languages.
# 1) Upload each file first → returns { filePath }
curl -X POST 'https://api.elysiatools.com/upload/image-batch-convert' \
-F 'file=@/path/to/imageFiles.ext'
# 2) Call the tool with the returned filePath values
curl -X POST 'https://api.elysiatools.com/en/api/tools/image-batch-convert' \
-F 'imageFiles=photo.jpg' \
-F 'outputFormat=webp' \
-F 'quality=85' \
-F 'resizeWidth=0' \
-F 'resizeHeight=0' \
-F 'maintainAspect=true' \
-F 'backgroundColor=white' \
-F 'keepMetadata=true' \
-F 'keepOriginalNames=true'Send a POST request with your inputs as JSON. File parameters require a separate upload first.
POST https://api.elysiatools.com/en/api/tools/image-batch-convert| Name | Type | Required | Description |
|---|---|---|---|
| imageFiles | fileupload required | Yes | — |
| outputFormat | select | Yes | — |
| quality | range | No | Output image quality (1-100) |
| resizeWidth | number | No | Target width in pixels (leave empty to keep original) |
| resizeHeight | number | No | Target height in pixels (leave empty to keep original) |
| maintainAspect | checkbox | No | — |
| backgroundColor | select | No | Used for formats that don't support transparency (JPG) |
| keepMetadata | checkbox | No | — |
| keepOriginalNames | checkbox | No | — |
File result
{
"filePath": "/public/processing/randomid.ext",
"fileName": "output.ext",
"contentType": "application/octet-stream",
"size": 1024,
"metadata": {
"key": "value"
},
"error": "Error message (optional)",
"message": "Notification message (optional)"
}Add this tool to your Model Context Protocol server so AI agents can list and call it.
Add this block to your MCP client configuration:
{
"mcpServers": {
"elysiatools-image-batch-convert": {
"name": "image-batch-convert",
"description": "Convert multiple image files between different formats like JPG, PNG, WebP, AVIF, TIFF, GIF with quality settings and batch processing",
"baseUrl": "https://api.elysiatools.com/mcp/sse?toolId=image-batch-convert",
"command": "",
"args": [],
"env": {},
"isActive": true,
"type": "sse"
}
}
}After connecting to the SSE endpoint, list the exposed tools:
{
"jsonrpc": "2.0",
"id": 1,
"method": "tools/list"
}Invoke the tool by its id, passing arguments built from its parameters:
{
"jsonrpc": "2.0",
"id": 2,
"method": "tools/call",
"params": {
"name": "image-batch-convert",
"arguments": {
"imageFiles": [
"photo.jpg"
],
"outputFormat": "webp",
"quality": 85,
"resizeWidth": 0,
"resizeHeight": 0,
"maintainAspect": true,
"backgroundColor": "white",
"keepMetadata": true,
"keepOriginalNames": true
}
}
}Questions or issues? Contact [email protected]