Memgen MCP Server
by sint-ai
The Memgen MCP Server generates memes from user input using OpenAI's image editing capabilities. It implements the Model Context Protocol (MCP) to provide meme generation functionality.
Last updated: N/A
tag : innovationlab
Memgen MCP Server
A Model Context Protocol server that generates memes from user input using OpenAI's image editing capabilities.
Overview
This server implements the Model Context Protocol (MCP) to provide meme generation functionality. It takes a text description as input, refines it using AI, and generates a meme image by editing a base template. The generated images are uploaded to MinIO S3-compatible storage and returned as URLs.
Features
- MCP-compliant server for seamless integration with MCP clients
- Prompt refinement using AI to optimize meme descriptions
- Image generation using OpenAI's GPT-image-1 model
- Automatic upload of generated images to MinIO S3 storage
Prerequisites
- Node.js >= 22.0.0
- MinIO S3-compatible storage
- OpenAI API key
Installation
-
Clone the repository:
git clone https://github.com/sint-ai/image_mcp_server.git cd image_mcp_server
-
Install dependencies:
npm install
-
Copy the example environment file and fill in your credentials:
cp .env.example .env
-
Edit
.env
with your configuration:PORT
: Server portOPENAI_API_KEY
: Your OpenAI API keyMINIO_ENDPOINT
: MinIO server endpointMINIO_PORT
: MinIO server portMINIO_USE_SSL
: Whether to use SSL for MinIO connectionMINIO_ACCESS_KEY
: MinIO access keyMINIO_SECRET_KEY
: MinIO secret keyMINIO_BUCKET_NAME
: MinIO bucket nameMINIO_BUCKET_URL
: Public URL for accessing the MinIO bucket
Usage
Start the server:
npm start
The server will start running on the configured port (default: 3000).
API Endpoints
POST /mcp
: Main MCP endpoint for processing requests
MCP Tooling
This server provides the following MCP tool:
create_meme
: Generates a meme from a text description- Input: String describing the desired meme
- Output: URLs to the generated images
Development
Check TypeScript types:
npm run check-types