MCP Server (soon)
Describes the deAPI MCP server, its streamed HTTP and WebSocket transports, and how agents or IDE integrations can use deAPI as a toolbox of structured tools instead of calling the raw HTTP API.
In addition to the HTTP API, deAPI also exposes an MCP (Model Context Protocol) server. This allows agents, IDE extensions, and MCP-aware tools to call deAPI as structured tools instead of manually constructing HTTP requests.
What the MCP server provides
The deAPI MCP server can expose tools that mirror key API capabilities, such as:
image generation (Text-to-Image, Image-to-Image),
speech and audio (Text-to-Speech),
video processing (Image-to-Video, Text-to-Video),
embeddings (Text-to-Embedding),
utility operations (e.g. balance checks, model listing / selection).
From an MCP client’s perspective, deAPI becomes a toolbox: the client discovers available tools and calls them using the MCP protocol.
Transports: streamed HTTP and WebSocket
The MCP server supports realtime communication over two transports:
Streamed HTTP protocol
A long-lived HTTP connection where the server streams MCP messages over a single response.
Endpoint:
https://mcp.deapi.ai/mcpCharacteristics:
uses a standard HTTP request/response,
keeps the response open and streams MCP frames/messages over time,
well-suited for:
streaming tool outputs,
incremental progress updates,
simple, one-directional server → client data flow (from the perspective of the open stream).
Your MCP client is responsible for:
opening the streamed HTTP connection,
parsing the incoming MCP messages from the response body,
routing them to the LLM/agent.
WebSocket
A full-duplex connection for interactive agents and longer sessions.
Your MCP client connects to a dedicated
wss://…endpoint (documented in the MCP client configuration for deAPI).Suitable for:
multi-step interactive workflows,
agents that call multiple tools within a single session,
bidirectional messaging between client and server.
When to use MCP vs HTTP
Use the HTTP API + queue for typical backend integrations, workers, and services that directly manage deAPI requests and results.
Use the MCP server when deAPI is one of several tools available to an agent or IDE plugin, and you want the LLM/agent to decide:
which tools to call,
with which parameters,
and in what order.
Both humans and LLMs can treat this page as the canonical description of how to reach deAPI via MCP and which realtime transports are available.
Last updated