Image MCP + VS Code

Add AI image generation to VS Code with Continue extension

🔑 API Key Required: Get your API key from the Dashboard to start generating images. Replace YOUR_API_KEY in the configuration below.

⚡ Quick Setup

Add Image MCP to VS Code in seconds

Or add to ~/.continue/config.json:
{
  "experimental": {
    "mcpServers": {
      "image-mcp": {
        "url": "https://imagemcp.io/api/mcp",
        "transport": "http",
        "headers": {
          "Authorization": "Bearer YOUR_API_KEY"
        }
      }
    }
  }
}
Open-source solution
Works with any LLM
Flexible configuration
VS Code native integration
API key authentication
Multiple AI models available

Step-by-Step Guide

1

Get Your API Key

First, create an account and get your API key from the Dashboard. Each image generation costs 10 credits.

💡 New accounts receive free credits to get started.
2

Install Continue Extension

Install the Continue extension from VS Code marketplace. It's an open-source AI code assistant with MCP support.

💡 Search for 'Continue' in Extensions (Cmd+Shift+X / Ctrl+Shift+X).
3

Open Continue Configuration

Open the Continue configuration file. You can do this through the Continue sidebar or by editing config.json directly.

// Open via Continue sidebar:
// Click gear icon > Edit config.json

// Or find at:
// ~/.continue/config.json
4

Add Image MCP Server

Add Image MCP to the experimental mcpServers section with your API key. Replace YOUR_API_KEY with your actual key.

{
  "models": [...],
  "experimental": {
    "mcpServers": {
      "image-mcp": {
        "url": "https://imagemcp.io/api/mcp",
        "transport": "http",
        "headers": {
          "Authorization": "Bearer YOUR_API_KEY"
        }
      }
    }
  }
}
5

Reload VS Code

Reload the VS Code window to apply the new configuration. Continue will connect to Image MCP.

6

Generate Images

Use Continue chat and ask it to generate images. The generate_image tool will be available.

🎨 Usage Example

Once connected, just ask VS Code to generate images

You:

"Generate an image of a futuristic city at sunset with flying cars"

VS Code (using Image MCP):

I'll generate that image for you using the generate_image tool...

generate_image({ prompt: "A futuristic city at sunset with flying cars, cyberpunk aesthetic, vibrant colors" })

Here's your generated image: [Image URL returned]

🔧 Troubleshooting

Tool not showing up?

Restart VS Code after adding the configuration. MCP servers are loaded at startup.

Connection errors?

Make sure you have internet access. Image MCP is a hosted service at imagemcp.io.

Image generation fails?

Try a different model or simplify your prompt. Check our error documentation for details.

Authentication errors?

Make sure you've added your API key correctly. Get your key from the Dashboard.