mcpField
M
mcp-image-compression

mcp-image-compression

Local
glama.aiMedia & Design34Updated 72w ago

About mcp-image-compression

mcp-image-compression is an image compression microservice built on MCP architecture that handles JPEG, PNG, WebP and AVIF files. It is aimed at developers who want to reduce image resource sizes for websites and applications.

Key features

  1. 01Supports JPEG, PNG, WebP and AVIF formats
  2. 02Adjustable compression quality from 0 to 100
  3. 03Automatic parameter selection based on image content
  4. 04Parallel compression of multiple images
  5. 05Stated to work offline without internet access

Use cases

  1. 01Reducing image sizes to improve website loading speed
  2. 02Batch compressing image assets for applications
  3. 03Calling an image compression tool from an MCP client

MCP support

This project is an MCP server that exposes an image_compression tool, which takes image URLs, quality and output format and returns URLs of the compressed images.

Configuration

Local server config is the same for every client. Copy it into your client’s MCP config file.

mcp.json · Universal config
{
"mcpServers": {
"image-compression": {
"command": "docker",
"args": [
"run",
"-i",
"--rm",
"build"
]
}
}
}
Run commanddocker run -i --rm build

Local servers need a runtime on your machine (e.g. Node.js 18+). Config file locations differ by client; see your client’s docs.

Packages
ocibuild

Tools

No tool list yet

Local servers expose tools only once running on your machine, and the maintainer has not provided a tool list.

Details

From the project README

MseeP.ai Security Assessment Badge

mcp-image-compression

Project Overview

mcp-image-compression is a high-performance image compression microservice based on MCP (Modal Context Protocol) architecture. This service focuses on providing fast and high-quality image compression capabilities to help developers optimize image resources for websites and applications, improving loading speed and user experience.

Features

  • Multi-format support: Compress mainstream image formats including JPEG, PNG, WebP, AVIF
  • Offline Usage: No need to connect to the internet to use
  • Smart compression: Automatically select optimal compression parameters based on image content
  • Batch processing: Support parallel compression of multiple images for improved efficiency
  • Quality control: Customizable compression quality to balance file size and visual quality

TOOLS

  1. image_compression
    • Image compression
    • Inputs:
      • urls (strings): URLs of images to compress
      • quality (int): Quality of compression (0-100)
      • format (string): Format of compressed image (e.g. "jpeg", "png", "webp", "avif")
    • Returns: Compressed images url

Setup

NPX
{
  "mcpServers": {
    "Image compression": {
      "command": "npx",
      "args": [
        "-y",
        "@inhiblab-core/mcp-image-compression"
      ],
      "env": {
        "IMAGE_COMPRESSION_DOWNLOAD_DIR": "<YOUR_DIR>"
      },
      "disabled": false,
      "autoApprove": []
    }
  }
}

Build

docker build -t mcp-image-compression .

License

This MCP server is licensed under the MIT License. This means you are free to use, modify, and distribute the software, subject to the terms and conditions of the MIT License. For more details, please see the LICENSE file in the project repository.

Comments

Markdown supported

New to MCP?

From what the protocol is to installing your first server, these answers cover most first questions.

An open protocol that defines how AI applications connect to external tools and data in a uniform way. Clients talk to the model; MCP servers provide tools, resources and prompt templates. They exchange standard messages, so one server can be reused by many clients.