Provides image analysis from URLs or local file paths using GPT-4o-mini with URL validation and local file loading.
Configuration
View docs{
"mcpServers": {
"champierre-image-mcp-server": {
"command": "node",
"args": [
"/path/to/image-mcp-server/dist/index.js"
],
"env": {
"OPENAI_API_KEY": "your_openai_api_key"
}
}
}
}You set up Image MCP Server to analyze image content from either a URL or a local file path. It uses a GPT-4o-mini model for high-precision descriptions and can validate image URLs and handle local file loading or Base64 encoding as needed.
To analyze an image, run the MCP client tool you use with the image-analysis MCP server configured, then call the analyze_image tool with an image URL or the analyze_image_from_path tool with a local file path. The server will return a detailed description of the image content.
Prerequisites you need before installing this server:
- Node.js and npm installed on your machine.
Steps to install and prepare the server locally:
# Clone the repository
git clone https://github.com/champierre/image-mcp-server.git
cd image-mcp-server
# Install dependencies
npm install
# Compile TypeScript
npm run buildYou must provide an OpenAI API key to use this server. Set the environment variable OPENAI_API_KEY with your key.
OPENAI_API_KEY=your_openai_api_keyThe following configuration runs a local MCP server instance via node and loads the built index. This is intended for use with MCP clients that support stdio endpoints.
{
"type": "stdio",
"name": "image_analysis",
"command": "node",
"args": ["/path/to/image-mcp-server/dist/index.js"],
"env": {
"OPENAI_API_KEY": "your_openai_api_key"
}
}Analyzing from a URL: Please analyze this image URL: https://example.com/image.jpg
Analyzing from a local file path: Please analyze this image: /path/to/your/image.jpg
Receives an image URL and analyzes its content, returning a detailed description of the image features.
Receives a local file path and analyzes its content, returning a detailed description of the image features.