
Security News
MCP Steering Committee Launches Official MCP Registry in Preview
The MCP Steering Committee has launched the official MCP Registry in preview, a central hub for discovering and publishing MCP servers.
image-tools-mcp-server
Advanced tools
MCP server for image optimization, thumbnail generation, and format conversion using ImageMagick
A Model Context Protocol (MCP) server that provides powerful image processing capabilities using ImageMagick. This server enables AI assistants to perform image optimization, thumbnail generation, format conversion, and batch processing operations.
# Install globally
npm install -g image-tools-mcp-server
# Or run directly without installing (recommended)
npx image-tools-mcp-server
Then add to your Q CLI MCP configuration:
{
"mcpServers": {
"image-tools": {
"command": "npx",
"args": ["image-tools-mcp-server"],
"env": {}
}
}
}
Or if installed globally:
{
"mcpServers": {
"image-tools": {
"command": "image-tools-mcp-server",
"args": [],
"env": {}
}
}
}
Note: The MCP server runs via stdio - Q CLI launches the server process and communicates with it through standard input/output.
This server requires ImageMagick to be installed on your system.
# Using Homebrew
brew install imagemagick
# Using MacPorts
sudo port install ImageMagick
sudo apt-get update
sudo apt-get install imagemagick
Download and install from: https://imagemagick.org/script/download.php#windows
magick -version
Requires Node.js 18.0.0 or higher.
# Install globally
npm install -g image-tools-mcp-server
# Or run directly with npx (no installation required)
npx image-tools-mcp-server
git clone https://github.com/jon-the-dev/image-tools-mcp-server.git
cd image-tools-mcp-server
npm install
npm start
To use this MCP server with Amazon Q CLI, add it to your MCP configuration:
{
"mcpServers": {
"image-tools": {
"command": "npx",
"args": ["image-tools-mcp-server"],
"env": {}
}
}
}
{
"mcpServers": {
"image-tools": {
"command": "image-tools-mcp-server",
"args": [],
"env": {}
}
}
}
{
"mcpServers": {
"image-tools": {
"command": "node",
"args": ["/path/to/image-tools-mcp-server/src/index.js"],
"env": {}
}
}
}
No environment variables are required for basic operation.
Optimize an image to reduce file size while maintaining quality.
Parameters:
inputPath
(required): Path to the input image fileoutputPath
(required): Path for the optimized output imagequality
(optional): Quality level (1-100, default: 85)maxWidth
(optional): Maximum width in pixelsmaxHeight
(optional): Maximum height in pixelsExample:
{
"inputPath": "/path/to/image.jpg",
"outputPath": "/path/to/optimized.jpg",
"quality": 80,
"maxWidth": 1920,
"maxHeight": 1080
}
Create a thumbnail from an image with specified dimensions.
Parameters:
inputPath
(required): Path to the input image fileoutputPath
(required): Path for the thumbnail outputwidth
(required): Thumbnail width in pixelsheight
(required): Thumbnail height in pixelsmaintainAspectRatio
(optional): Whether to maintain aspect ratio (default: true)cropToFit
(optional): Whether to crop to fit exact dimensions (default: false)Example:
{
"inputPath": "/path/to/image.jpg",
"outputPath": "/path/to/thumbnail.jpg",
"width": 300,
"height": 200,
"maintainAspectRatio": true,
"cropToFit": false
}
Create icons in standard sizes from an image.
Parameters:
inputPath
(required): Path to the input image fileoutputDir
(required): Directory to save icon filessizes
(optional): Array of icon sizes to generate (default: [16, 32, 64, 128, 256])format
(optional): Output format (png, ico, default: png)Example:
{
"inputPath": "/path/to/logo.png",
"outputDir": "/path/to/icons/",
"sizes": [16, 32, 64, 128, 256],
"format": "png"
}
Convert an image from one format to another.
Parameters:
inputPath
(required): Path to the input image fileoutputPath
(required): Path for the converted output imageformat
(required): Target format (jpg, png, webp, gif, bmp, tiff)quality
(optional): Quality level for lossy formats (1-100, default: 90)Example:
{
"inputPath": "/path/to/image.png",
"outputPath": "/path/to/image.webp",
"format": "webp",
"quality": 85
}
Get detailed information about an image file.
Parameters:
imagePath
(required): Path to the image fileExample:
{
"imagePath": "/path/to/image.jpg"
}
Optimize multiple images in a directory.
Parameters:
inputDir
(required): Directory containing images to optimizeoutputDir
(required): Directory to save optimized imagesquality
(optional): Quality level (1-100, default: 85)maxWidth
(optional): Maximum width in pixelsmaxHeight
(optional): Maximum height in pixelsextensions
(optional): File extensions to process (default: [jpg, jpeg, png, webp])Example:
{
"inputDir": "/path/to/input/images/",
"outputDir": "/path/to/output/images/",
"quality": 80,
"maxWidth": 1920,
"extensions": ["jpg", "jpeg", "png", "webp"]
}
# After installing and configuring with Q CLI
q chat "Optimize the image at /Users/jon/photos/vacation.jpg and save it to /Users/jon/photos/vacation-optimized.jpg with 80% quality"
q chat "Create a 300x200 thumbnail from /Users/jon/photos/landscape.jpg and save it to /Users/jon/photos/landscape-thumb.jpg"
q chat "Optimize all images in /Users/jon/photos/raw/ and save them to /Users/jon/photos/optimized/ with 85% quality"
npm install -g image-tools-mcp-server
q chat "Get image info for any image file"
npm run dev
image-tools-mcp-server/
├── src/
│ ├── index.js # Main MCP server
│ └── imageProcessor.js # ImageMagick wrapper
├── docs/ # Documentation
├── package.json
├── README.md
└── .gitignore
src/index.js
src/imageProcessor.js
The server includes comprehensive error handling for:
Input formats: JPG, JPEG, PNG, WebP, GIF, BMP, TIFF, ICO Output formats: JPG, JPEG, PNG, WebP, GIF, BMP, TIFF, ICO
MIT License - see LICENSE file for details.
For issues and feature requests, please create an issue in the GitHub repository.
FAQs
MCP server for image optimization, thumbnail generation, and format conversion using ImageMagick
We found that image-tools-mcp-server demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
The MCP Steering Committee has launched the official MCP Registry in preview, a central hub for discovering and publishing MCP servers.
Product
Socket’s new Pull Request Stories give security teams clear visibility into dependency risks and outcomes across scanned pull requests.
Research
/Security News
npm author Qix’s account was compromised, with malicious versions of popular packages like chalk-template, color-convert, and strip-ansi published.