{"_id":"@boomlinkai/image-resize-mcp","_rev":"2-e4af276faa860871fba569a3d61d46ee","name":"@boomlinkai/image-resize-mcp","dist-tags":{"latest":"0.0.1"},"versions":{"0.0.0":{"name":"@boomlinkai/image-resize-mcp","version":"0.0.0","keywords":["MCP","Sharp","Image Resize"],"author":{"name":"Vuong Ngo @ https://boomlink.ai"},"license":"MIT","_id":"@boomlinkai/image-resize-mcp@0.0.0","maintainers":[{"name":"boomlinkai","email":"admin@boomlink.ai"}],"bin":{"image-resize-mcp":"bin/image-resize-mcp.mjs"},"dist":{"shasum":"c9ee442f7b99c99234df4838764dcd11cebea6b4","tarball":"https://registry.npmjs.org/@boomlinkai/image-resize-mcp/-/image-resize-mcp-0.0.0.tgz","fileCount":6,"integrity":"sha512-whBJanCEbLD7a/euAXBj8wBJVhSHNuTE4W9DkliCiuS27uIsGDiqXNKI3QxfUT7xzY3QPUXNz1FTvA3WKwadFQ==","signatures":[{"sig":"MEYCIQCHRWqo6L4MaQkUBdSDYGdn+junpmtW5phiBDOZpP6WdgIhALb1m930T4u7ZUlVh/BWEAdqC8H8yN8Ym+ri0inBtNT9","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":20297},"gitHead":"033ab4379e5ede968ca321d409bc6b82389e8fec","scripts":{},"_npmUser":{"name":"boomlinkai","email":"admin@boomlink.ai"},"_npmVersion":"10.9.2","description":"MCP server for image resizing","directories":{},"_nodeVersion":"23.9.0","dependencies":{"zod":"^3.22.4","chalk":"5.3.0","sharp":"0.34.1","commander":"12.0.0","@modelcontextprotocol/sdk":"1.11.4"},"_hasShrinkwrap":false,"peerDependencies":{},"_npmOperationalInternal":{"tmp":"tmp/image-resize-mcp_0.0.0_1747655904528_0.5049296891800037","host":"s3://npm-registry-packages-npm-production"}},"0.0.1":{"name":"@boomlinkai/image-resize-mcp","version":"0.0.1","description":"MCP server for image resizing","bin":{"image-resize-mcp":"bin/image-resize-mcp.mjs"},"peerDependencies":{},"dependencies":{"@modelcontextprotocol/sdk":"1.11.4","chalk":"5.3.0","commander":"12.0.0","node-fetch":"^3.3.2","sharp":"0.34.1","zod":"^3.22.4"},"scripts":{},"author":{"name":"Vuong Ngo @ https://boomlink.ai"},"license":"MIT","keywords":["MCP","Sharp","Image Resize"],"_id":"@boomlinkai/image-resize-mcp@0.0.1","gitHead":"408f7ece19b7590a427cb091d3f880f03906fc60","_nodeVersion":"23.9.0","_npmVersion":"10.9.2","dist":{"integrity":"sha512-G9HD7o+YhW9baXi2qbVZi2sIELvXCOt8L62FxiIrQDNWkJGt2as8/PrG+znqUVg3wqPye3OR8azqPYtASUzAGA==","shasum":"ea184f37a285928c73cf6237d63eb564d7289f48","tarball":"https://registry.npmjs.org/@boomlinkai/image-resize-mcp/-/image-resize-mcp-0.0.1.tgz","fileCount":6,"unpackedSize":29873,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEUCIQC1Lde9mFhnAb0TtqDQQgwpcK+hkZLEjiQRV6COzMQeVAIgd0MDMXTBLkGZTJM+BM6h1sZbDXK1cnHTqVPpbypuXBA="}]},"_npmUser":{"name":"boomlinkai","email":"admin@boomlink.ai"},"directories":{},"maintainers":[{"name":"boomlinkai","email":"admin@boomlink.ai"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/image-resize-mcp_0.0.1_1747658201673_0.4187793529418973"},"_hasShrinkwrap":false}},"time":{"created":"2025-05-19T11:58:24.458Z","modified":"2025-05-19T12:36:42.059Z","0.0.0":"2025-05-19T11:58:24.797Z","0.0.1":"2025-05-19T12:36:41.855Z"},"author":{"name":"Vuong Ngo @ https://boomlink.ai"},"license":"MIT","keywords":["MCP","Sharp","Image Resize"],"description":"MCP server for image resizing","maintainers":[{"name":"boomlinkai","email":"admin@boomlink.ai"}],"readme":"# @boomlinkai/image-resize-mcp\n\nA command-line tool that provides an MCP server for image resizing.\n\n## Installation\n\nYou can install the Image Resize MCP CLI globally to use it across projects:\n\n```sh\n# Using npm\nnpm install -g @boomlinkai/image-resize-mcp\n\n# Using yarn\nyarn global add @boomlinkai/image-resize-mcp\n\n# Using pnpm\npnpm add -g @boomlinkai/image-resize-mcp\n```\n\nOr use it directly with npx/pnpm dlx/yarn dlx:\n\n```sh\nnpx @boomlinkai/image-resize-mcp\n```\n\n## Features\n\n- Resize images to different dimensions\n- Convert images between formats (JPEG, PNG, WebP, AVIF)\n- Optimize images for web use\n- Apply basic transformations (rotate, flip, etc.)\n\n## Usage\n\nThe package provides an MCP server that can be executed via stdio, allowing it to be used as a tool by AI assistants.\n\n### MCP Server Configuration\n\nTo use this as an MCP server, add it to your MCP settings configuration:\n\n```json\n{\n  \"mcpServers\": {\n    \"image-resize\": {\n      \"command\": \"npx\",\n      \"args\": [\"-y\", \"@boomlinkai/image-resize-mcp\"]\n    }\n  }\n}\n```\n## Supported Options\n\nThe `resize_image` tool, provided by this MCP server, accepts the following arguments. These are based on the `sharp` image processing library.\n\n**Input Image (at least one required):**\n\n*   `imagePath` (string, optional): Filesystem path to the input image.\n    *   Example: `/path/to/your/image.jpg`\n*   `imageUrl` (string, optional): URL of the input image.\n    *   Example: `https://example.com/image.png`\n*   `base64Image` (string, optional): Base64-encoded image data. Can include a data URL prefix (e.g., `data:image/jpeg;base64,...`) or be raw base64.\n    *   Example: `data:image/jpeg;base64,/9j/4AAQSkZJRgABAQEAYABgAAD...`\n\n**Output Options:**\n\n*   `format` (enum, optional): Desired output image format.\n    *   Supported values: `jpeg`, `jpg`, `png`, `webp`, `avif`.\n    *   If not specified, the input format is used if supported, otherwise defaults to a common format.\n*   `quality` (number, optional): Quality for lossy formats like JPEG, WebP, AVIF (1-100).\n    *   Defaults to a pre-configured value (typically around 80).\n*   `outputPath` (string, optional): Filesystem path to save the processed image.\n    *   If not provided, the image is returned as base64 data in the response.\n    *   Example: `/path/to/save/resized_image.webp`\n\n**Resizing and Dimensions:**\n\n*   `width` (number, optional): Target width in pixels (1-10000).\n    *   If only `width` is provided, `height` is adjusted to maintain aspect ratio.\n    *   If neither `width` nor `height` is specified, defaults to a pre-configured value (e.g., 1024).\n*   `height` (number, optional): Target height in pixels (1-10000).\n    *   If only `height` is provided, `width` is adjusted to maintain aspect ratio.\n    *   If neither `width` nor `height` is specified, defaults to a pre-configured value (e.g., 1024).\n*   `fit` (enum, optional): How the image should be resized to fit the specified `width` and `height`.\n    *   Values: `cover`, `contain`, `fill`, `inside`, `outside`.\n    *   Defaults to `contain` if both `width` and `height` are specified but `fit` is not.\n*   `position` (enum, optional): Position to use when `fit` is `cover` or `contain`.\n    *   Values: `centre`, `center`, `north`, `east`, `south`, `west`, `northeast`, `southeast`, `southwest`, `northwest`.\n*   `background` (string, optional): Background color to use when `fit` results in empty areas (e.g., for `contain`).\n    *   Format: CSS color string (e.g., `#RRGGBB`, `rgba(r,g,b,a)`).\n    *   Example: `#FFFFFF`, `rgba(0,0,0,0.5)`\n*   `withoutEnlargement` (boolean, optional): If true, do not enlarge the image if its original dimensions are smaller than the target `width`/`height`.\n*   `withoutReduction` (boolean, optional): If true, do not reduce the image if its original dimensions are larger than the target `width`/`height`.\n*   `trim` (boolean, optional): Trim \"boring\" pixels from all edges based on the top-left pixel color.\n\n**Transformations & Effects:**\n\n*   `rotate` (number, optional): Angle of rotation (e.g., 90, 180, 270).\n*   `flip` (boolean, optional): Flip the image vertically.\n*   `flop` (boolean, optional): Flop (mirror) the image horizontally.\n*   `grayscale` (boolean, optional): Convert the image to grayscale.\n*   `blur` (number, optional): Apply a Gaussian blur. Sigma value between 0.3 and 1000.\n*   `sharpen` (number, optional): Apply a sharpening effect. Sigma value between 0.3 and 1000.\n*   `gamma` (number, optional): Apply gamma correction. Value between 1.0 and 3.0.\n*   `negate` (boolean, optional): Produce a negative of the image.\n*   `normalize` (boolean, optional): Enhance image contrast by stretching its intensity levels (histogram normalization).\n*   `threshold` (number, optional): Apply a threshold to the image, converting it to black and white based on luminance. Value between 0 and 255.\n\n## Requirements\n\n- Node.js 18.x or higher\n- Sharp image processing library (automatically installed as a dependency)\n\n## License\n\nMIT\n\n## Author\n\nVuong Ngo @ https://boomlink.ai\n","readmeFilename":"README.md"}