How do I add an MCP server to Gemini CLI to generate images and videos?
To generate images and videos in Gemini CLI, add the Wireflow MCP server to settings.json under mcpServers with httpUrl, then sign in with OAuth.
To generate images and videos from Gemini CLI, add the Wireflow MCP server to the mcpServers object in your settings.json with httpUrl set to https://www.wireflow.ai/api/mcp, sign in with your Wireflow account when Gemini CLI opens your browser, then ask for the image or clip in plain words. There is no API key to add. The models run on your Wireflow credits, and Gemini CLI gets the finished files back as links.
{
"mcpServers": {
"wireflow": {
"httpUrl": "https://www.wireflow.ai/api/mcp"
}
}
}
The Gemini CLI docs carry this notice: "Unpaid tier and Google One users: Gemini CLI was replaced by Antigravity CLI on June 18th, 2026." The steps on this page are for Gemini CLI. For other agents, start from How do I connect my AI agent to image and video generation tools?
Can Gemini CLI generate images?
Yes, through an MCP server that runs image models. With Wireflow added, Gemini CLI can run image models such as Nano Banana 2 and Seedream V4.5 and video models such as Kling Video and Wan 2.5, across 100+ models with one sign-in. Which models you can run depends on your Wireflow plan, so check the pricing page.
Where do I add the server in settings.json?
Add a wireflow entry to the mcpServers object, with the server URL in httpUrl, as in the example above. The entry can go in your user settings or in one project's settings:
| File | Scope |
|---|---|
~/.gemini/settings.json |
User |
.gemini/settings.json in a project folder |
Project |
Use httpUrl, not url: in Gemini CLI, httpUrl is the HTTP streaming endpoint URL and url is the SSE endpoint URL, and Wireflow's server is a Streamable HTTP endpoint. Leave out headers, because Wireflow uses no API key. Leave out OAuth settings too: Gemini CLI can discover them for servers that support OAuth discovery, and Wireflow needs no client setup.
How do I sign in with OAuth?
Let Gemini CLI run the sign-in. Its docs say that when a remote server requires OAuth, Gemini CLI discovers the OAuth endpoints, registers itself if the server supports it, and opens your browser. Wireflow's MCP connector page says clients self-register, so sign in there with your Wireflow account and approve the consent screen. Gemini CLI then stores the tokens in ~/.gemini/mcp-oauth-tokens.json and retries the connection.
To start or repeat the sign-in yourself, run /mcp auth to list the servers that need authentication, then /mcp auth wireflow. Run it again when the tokens expire. The browser step needs local browser access, so it doesn't work in headless environments, remote SSH sessions without X11 forwarding, or containers without browser support.
The consent screen lists exactly the permissions Gemini CLI asked for, and you can revoke access at any time from your Wireflow settings. Every permission and tool is listed on the MCP connector page.
How do I check that the server is connected?
Run /mcp in Gemini CLI: it shows each MCP server with its status and its tools, and wireflow should read CONNECTED. From your terminal, gemini mcp list shows each server's name, configuration details and connection status.
| Status | Meaning |
|---|---|
| CONNECTED | Server is connected and ready |
| CONNECTING | Connection attempt in progress |
| DISCONNECTED | Server is not connected or has errors |
Once wireflow is connected and its tools show, try a short clip. This prompt quotes the cost and waits for your yes before it spends credits:
Use Wireflow to make a short video of a hot air balloon drifting over a red canyon at sunrise with Kling Video. Tell me the credit cost and wait for my yes before you run it.
Resolution, length and quality change what Kling Video costs. Gemini CLI should look up the price with list_models, which spends nothing, and start the run only after your yes. It reads the finished video's link with get_execution.
What does "disconnected" mean, and how do I fix it?
DISCONNECTED means the server is not connected or has errors. Background connection errors are silent by default, so run /mcp or gemini mcp list for details, or start Gemini CLI with --debug for verbose output. Then check these points:
- The entry uses
httpUrl, noturl, with exactlyhttps://www.wireflow.ai/api/mcp. - You finished the sign-in. Run
/mcp authto see whetherwireflowstill needs authentication, then run/mcp auth wireflow. - Your session can open a local browser, which the sign-in needs.
- Your tokens haven't expired. If they have, run
/mcp auth wireflowagain.
The command, args and cwd checks in the Gemini CLI docs are for stdio servers that run on your machine. A URL entry like Wireflow's has none of them.