imgant-mcp
v0.1.0
Published
MCP server for ImgAnt image hosting — upload local images and get public URLs, designed for AI agents
Maintainers
Readme
imgant-mcp
MCP (Model Context Protocol) server for ImgAnt image hosting. Lets AI agents upload a local image file and get back a public URL ready to paste into Markdown, HTML, or a chat reply.
Looking for the command line tool that humans can run directly? See richcalls/imgant-cli — you can install it with
brew install richcalls/tap/imgant.
What it does
Exposes a single MCP tool:
upload_image— takes an absolute file path plus an optional output format (url|markdown|html), uploads the file to your ImgAnt account via theX-API-Keyendpoint, and returns the public URL.
Prerequisites
- An ImgAnt account (imgant.com)
- An API key — generate one in Account → API Keys
- Node.js 20 or newer (Claude Desktop ships its own, Cursor and Cline pick up your system node)
Configuration
Add the server to your MCP client's config. The server is distributed on
npm, so npx will download it on first run — no manual install needed.
Claude Desktop
Edit ~/Library/Application Support/Claude/claude_desktop_config.json
(macOS) or %APPDATA%\Claude\claude_desktop_config.json (Windows):
{
"mcpServers": {
"imgant": {
"command": "npx",
"args": ["-y", "imgant-mcp"],
"env": {
"IMGANT_API_KEY": "your_api_key_here"
}
}
}
}Cursor
Add to ~/.cursor/mcp.json:
{
"mcpServers": {
"imgant": {
"command": "npx",
"args": ["-y", "imgant-mcp"],
"env": {
"IMGANT_API_KEY": "your_api_key_here"
}
}
}
}Cline (VS Code extension)
Add to your Cline MCP settings file:
{
"mcpServers": {
"imgant": {
"command": "npx",
"args": ["-y", "imgant-mcp"],
"env": {
"IMGANT_API_KEY": "your_api_key_here"
}
}
}
}Custom endpoint (self-hosted)
If you are running ImgAnt against a non-production API, set
IMGANT_ENDPOINT in the same env block:
"env": {
"IMGANT_API_KEY": "your_api_key_here",
"IMGANT_ENDPOINT": "https://api.your-imgant.example.com"
}Usage
Once configured, just ask your AI assistant things like:
- "Upload
~/Desktop/screenshot.pngto my image host and give me a Markdown embed." - "Here's a chart at
/tmp/chart.svg— please upload it and paste the URL into this blog post draft."
The assistant will call the upload_image tool and receive back a public
URL rendered in the format you requested.
Local development
git clone https://github.com/richcalls/imgant-mcp.git
cd imgant-mcp
npm install
npm run buildSanity-check the server via MCP Inspector:
npm run inspectorOr with the tiny probe script bundled with this repo:
IMGANT_API_KEY=your_key ./scripts/probe-call.sh /path/to/real-image.pngEnvironment variables
| Variable | Default | Description |
|---|---|---|
| IMGANT_API_KEY | (required) | Your ImgAnt X-API-Key |
| IMGANT_ENDPOINT | https://api.imgant.com | Override the API base URL |
License
MIT — see LICENSE.
