@dreamlayer/mcp
Enables MCP-compatible AI clients to generate and edit images via the DreamLayer Agent API, including text-to-image, image-to-image, background removal, and upscaling, with support for uploading images and managing execution streams.
README
@dreamlayer/mcp
Image generation and editing tools for MCP-compatible AI clients, backed by the DreamLayer Agent API.
Nothing to clone, nothing to build.
Install
Add it to your client. Claude Code:
claude mcp add dreamlayer --env DREAMLAYER_API_KEY=dlr_live_your_key -- npx -y @dreamlayer/mcp
Codex:
codex mcp add dreamlayer --env DREAMLAYER_API_KEY=dlr_live_your_key -- npx -y @dreamlayer/mcp
Cursor, or any other stdio MCP client:
{
"mcpServers": {
"dreamlayer": {
"command": "npx",
"args": ["-y", "@dreamlayer/mcp"],
"env": { "DREAMLAYER_API_KEY": "dlr_live_your_key" }
}
}
}
The key must be in the server's own environment. MCP clients spawn this as a subprocess, so a key exported in your shell does not reach it. That is the most common setup failure, and the server exits with an explanation rather than starting up broken.
Get a key at platform.dreamlayer.io. A new account starts at zero credits, and each finished image costs one.
Tools
| Tool | What it does |
|---|---|
dreamlayer_capabilities |
Read the contract and the operations this key may run. Spends nothing. |
dreamlayer_upload_image |
Upload PNG, JPEG, WebP, or camera RAW (up to 200 MB) and get an input_asset_id. |
dreamlayer_generate |
Generate or edit. Returns the event stream. |
dreamlayer_execution |
Read canonical state for one execution. |
dreamlayer_events |
Resume a stream after a drop, from a last event id. |
dreamlayer_cancel |
Cancel before dispatch. |
Operations
Omit operation and DreamLayer reads the prompt, which may come back asking a
clarifying question. Name it and that inference is skipped entirely.
operation |
Needs an image | Result |
|---|---|---|
text_to_image |
No | A new image from the prompt |
image_to_image |
Yes | The reference, edited as described |
background_remove |
Yes | The subject on transparency |
upscale |
Yes | Twice the width and height |
upscale doubles each side and finished images are capped at 4096 per side, so the
longest side of your input must be 2048 or less. A larger one is refused before it
costs a credit.
Behaviour worth knowing
A question is not a failure. An ambiguous prompt returns a question event ending
in needs_input. Answer it by calling dreamlayer_generate again with respond and
the conversation_id.
Retries are safe if you reuse the key. An idempotency_key is generated for you.
Pass the same one back to retry after an uncertain response and the original result
replays rather than paying twice.
Long runs are truncated, not lost. A stream over 256 events returns what it has,
marks truncated, and gives you the execution_id and last event id to resume from.
Requirements
Node.js 22.12 or later.
License
MIT. See LICENSE and NOTICE.
Recommended Servers
playwright-mcp
A Model Context Protocol server that enables LLMs to interact with web pages through structured accessibility snapshots without requiring vision models or screenshots.
Magic Component Platform (MCP)
An AI-powered tool that generates modern UI components from natural language descriptions, integrating with popular IDEs to streamline UI development workflow.
Audiense Insights MCP Server
Enables interaction with Audiense Insights accounts via the Model Context Protocol, facilitating the extraction and analysis of marketing insights and audience data including demographics, behavior, and influencer engagement.
VeyraX MCP
Single MCP tool to connect all your favorite tools: Gmail, Calendar and 40 more.
graphlit-mcp-server
The Model Context Protocol (MCP) Server enables integration between MCP clients and the Graphlit service. Ingest anything from Slack to Gmail to podcast feeds, in addition to web crawling, into a Graphlit project - and then retrieve relevant contents from the MCP client.
Kagi MCP Server
An MCP server that integrates Kagi search capabilities with Claude AI, enabling Claude to perform real-time web searches when answering questions that require up-to-date information.
E2B
Using MCP to run code via e2b.
Neon Database
MCP server for interacting with Neon Management API and databases
Exa Search
A Model Context Protocol (MCP) server lets AI assistants like Claude use the Exa AI Search API for web searches. This setup allows AI models to get real-time web information in a safe and controlled way.
Qdrant Server
This repository is an example of how to create a MCP server for Qdrant, a vector search engine.