Command Palette

Search for a command to run...

UnylyUnyly
Весь каталог

Leonardo Ai Server

БесплатноНе проверен

Integrates Leonardo AI image generation capabilities into MCP-compatible clients like Cursor, Claude Desktop, and VS Code, allowing natural language commands to

GitHubEmbed

Описание

Integrates Leonardo AI image generation capabilities into MCP-compatible clients like Cursor, Claude Desktop, and VS Code, allowing natural language commands to generate, upscale, vary, and manage images.

README

A remote Model Context Protocol (MCP) server for Leonardo.ai, powered by Vercel.

Generate images, manage models, check generation status, upscale, create variations — all through MCP from Cursor, Claude Desktop, VS Code, or any MCP-compatible client.

✨ Features / Tools

Tool Description
generate_image Generate images with Leonardo AI. Supports model selection, dimensions, style presets, Alchemy, PhotoReal, and Ultra mode. Polls for completion automatically.
get_generation Get the status and results of a generation job by ID
list_models List all available Leonardo AI platform models with IDs, names and descriptions
get_user_generations Get recent generation jobs for a user
get_user_info Get the authenticated user's info (username, tokens, quota)
create_variation Create a variation, outpaint, inpaint, or unzoom of an existing image
upscale_image Upscale a generated image to higher resolution
delete_generation Permanently delete a generation and its images

🚀 Deploy to Vercel

One-Click Deploy

Deploy with Vercel

Manual Deploy

  1. Fork/clone this repository
  2. Import it in Vercel
  3. Set environment variable LEONARDO_API_KEY with your Leonardo AI API key
  4. Enable Fluid Compute in your Vercel project settings for optimal performance
  5. Deploy — your MCP server will be live at https://your-project.vercel.app/mcp

🔑 Get a Leonardo AI API Key

  1. Go to Leonardo.ai
  2. Sign up / log in
  3. Navigate to API Access in your settings
  4. Generate an API key

🔌 Connect Your MCP Client

Cursor

Add to your Cursor MCP settings (.cursor/mcp.json):

{
  "mcpServers": {
    "leonardo-ai": {
      "url": "https://your-project.vercel.app/mcp",
      "headers": {
        "x-leonardo-api-key": "YOUR_LEONARDO_API_KEY"
      }
    }
  }
}

Claude Desktop

Add to your Claude Desktop config (~/Library/Application Support/Claude/claude_desktop_config.json):

{
  "mcpServers": {
    "leonardo-ai": {
      "url": "https://your-project.vercel.app/mcp",
      "headers": {
        "x-leonardo-api-key": "YOUR_LEONARDO_API_KEY"
      }
    }
  }
}

VS Code (GitHub Copilot)

Add to your VS Code MCP settings:

{
  "mcp": {
    "servers": {
      "leonardo-ai": {
        "url": "https://your-project.vercel.app/mcp",
        "headers": {
          "x-leonardo-api-key": "YOUR_LEONARDO_API_KEY"
        }
      }
    }
  }
}

Note: You can also set LEONARDO_API_KEY as an environment variable on Vercel instead of passing it as a header. If the env var is set, the header is optional.

🛠 Local Development

# Install dependencies
pnpm install

# Set your API key
cp .env.example .env
# Edit .env and add your LEONARDO_API_KEY

# Start local dev server
pnpm dev

The MCP server will be available at http://localhost:3000/mcp.

📁 Project Structure

├── api/
│   ├── server.ts           # MCP server with all tool definitions
│   └── leonardo-client.ts  # Leonardo AI REST API client
├── public/
│   └── index.html          # Landing page
├── package.json
├── tsconfig.json
├── vercel.json             # Vercel deployment config
├── .env.example
└── README.md

📋 API Key Options

The server resolves the Leonardo API key in this order:

  1. x-leonardo-api-key header — passed by the MCP client (recommended for multi-user setups)
  2. LEONARDO_API_KEY env variable — set in Vercel project settings (simpler for single-user)

🧪 Example Usage

Once connected, you can use natural language in your MCP client:

  • "Generate an image of a sunset over mountains in cinematic style"
  • "List available Leonardo AI models"
  • "Show me my recent generations"
  • "Upscale the last generated image"
  • "Create a variation of image xyz"

📝 License

MIT

from github.com/superdwayne/leonardo-ai-mcp-server

Установка Leonardo Ai Server

У этого сервера нет опубликованного пакета — он собирается из исходников. Открой репозиторий и следуй инструкции в README.

▸ github.com/superdwayne/leonardo-ai-mcp-server

FAQ

Leonardo Ai Server MCP бесплатный?

Да, Leonardo Ai Server MCP бесплатный — установка в пару кликов через Unyly без оплаты.

Нужен ли API-ключ для Leonardo Ai Server?

Нет, Leonardo Ai Server работает без API-ключей и переменных окружения.

Leonardo Ai Server — hosted или self-hosted?

Доступен hosted-вариант: Unyly запускает сервер в облаке, локальная установка не обязательна.

Как установить Leonardo Ai Server в Claude Desktop, Claude Code или Cursor?

Открой Leonardo Ai Server на unyly.org, выбери вкладку своего клиента (Claude Desktop, Claude Code, Cursor) и нажми Install — конфиг сгенерируется автоматически, без правки JSON.

Похожие MCP

Compare Leonardo Ai Server with

Не уверен что выбрать?

Найди свой стек за 60 секунд

Автор?

Embed-бейдж для README

Похожее

Все в категории development