json2video MCP Server
以下摘录自该仓库的 README(片段) · 在 GitHub 读完整 README →
A Model Context Protocol (MCP) server implementation for programmatically generating videos using the json2video API. This server exposes powerful video generation and status-checking tools for use with LLMs, agents, or any MCP-compatible client.
---
Features
- Generate videos with rich scene and element support (text, image, video, audio, components, subtitles, etc.)
- Asynchronous video rendering with status polling
- Flexible, extensible JSON schema for video projects
- Designed for easy integration with LLMs, automation agents, and MCP-compatible tools
- API key authentication (env or per-request)
- Comprehensive error handling and logging
---
Installation
Running with npx
Manual Installation
Windows Users
If you are on Windows and encounter issues, try:
---
Running on Cursor
Cursor v0.48.6+
1. Open Cursor Settings
2. Go to Features > MCP Servers
3. Click "+ Add New MCP Server"
4. Enter the following:
- Name: "json2video-mcp" (or your preferred name)
- Type: "command"
- Command: env JSON2VIDEO_API_KEY=your_api_key_here npx -y @omerrgocmen/json2video-mcp
Cursor v0.48.6+
1. Open Cursor Settings
2. Go to Features > MCP Servers
3. Click "+ Add new global MCP server"
4. Enter the following code:
Replace your_api_key_here with your json2video API key. You can get an API key from json2video.com.
After adding, refresh the MCP server list to see the new tools. Your agent or LLM will automatically use json2video MCP when appropriate, or you can explicitly request it by describing your video generation needs.
---
MCP Integration Example
Add this to your mcp.json or similar config:
- Replace your_api_key_here with your actual json2video API key.
- This configuration allows your agent or LLM to start and communicate with the json2video MCP server automatically.
- The server will expose the generate_video and get_video_status tools for use in your workflows.
---
Configuration
Environment Variables
- JSON2VIDEO_API_KEY (required): Your json2video API key. Can be set as an environment variable or provided per request.
---
> **Note:** If you encounter a client closed error, run the following command in your terminal:
>
>
---
Usage
Available Tools
1. Generate Video (generate_video)
Create a customizable video project with scenes and elements.
**Description:**
Creates a video project using the json2video API. Each project can contain multiple scenes, and each scene can contain various elements such as text, images, video, audio, components, HTML, voice, audiogram, and subtitles. Video generation is asynchronous; use the returned project ID to check status. See https://json2video.com/docs/api/ for full schema and more examples.
**Input Schema:**
**Element Types & Examples:**
- **Text Element:**
- **Image Element:**
- **Video Element:**
- **Component Element:**
- **HTML Element:**
- **Audio Element:**
- **Voice Element:**
- **Audiogram Element:**
- **Subtitles Element:**
**Example Input:**
**Notes for Users:**