MCP Video Generation with Veo2
Generación de vídeo MCP con Veo2
Este proyecto implementa un servidor de Protocolo de Contexto de Modelo (MCP) que expone las capacidades de generación de video de Veo2 de Google. Permite a los clientes generar videos a partir de indicaciones de texto o imágenes y acceder a ellos mediante recursos MCP.
Características
Generar vídeos a partir de indicaciones de texto
Generar vídeos a partir de imágenes
Acceda a los vídeos generados a través de los recursos de MCP
Plantillas de generación de videos de ejemplo
Compatibilidad con transportes stdio y SSE
Related MCP server: hyper-video-service
Imágenes de ejemplo
Ejemplo de imagen a vídeo
Imagen a video: del cachorro generado por Grok
Imagen a vídeo - de un gato real
Prerrequisitos
Node.js 18 o superior
Clave API de Google con acceso a la API de Gemini y al modelo Veo2 (= ¡Necesitas configurar una tarjeta de crédito con tu clave API! -> Ve a aistudio.google.com )
Instalación
Instalación en FLUJO
Haga clic en Agregar servidor
Copie y pegue la URL de Github en FLUJO
Haga clic en Analizar, Clonar, Instalar, Compilar y Guardar.
Instalación mediante herrería
Para instalar mcp-video-generation-veo2 para Claude Desktop automáticamente a través de Smithery :
npx -y @smithery/cli install @mario-andreschak/mcp-veo2 --client claudeInstalación manual
Clonar el repositorio:
git clone https://github.com/yourusername/mcp-video-generation-veo2.git cd mcp-video-generation-veo2Instalar dependencias:
npm installCrea un archivo
.envcon tu clave API de Google:cp .env.example .env # Edit .env and add your Google API keyEl archivo
.envadmite las siguientes variables:GOOGLE_API_KEY: Su clave API de Google (obligatoria)PORT: Puerto del servidor (predeterminado: 3000)STORAGE_DIR: Directorio para almacenar los vídeos generados (predeterminado: ./generated-videos)LOG_LEVEL: Nivel de registro (predeterminado: fatal)Niveles disponibles: detallado, depuración, información, advertencia, error, fatal, ninguno
Para el desarrollo, configúrelo en
debugoinfopara obtener registros más detallados.Para producción, manténgalo como
fatalpara minimizar la salida de la consola.
Construir el proyecto:
npm run build
Uso
Iniciando el servidor
Puede iniciar el servidor con el transporte stdio o SSE:
Transporte stdio (predeterminado)
npm start
# or
npm start stdioTransporte SSE
npm start sseEsto iniciará el servidor en el puerto 3000 (o el puerto especificado en su archivo .env ).
Herramientas MCP
El servidor expone las siguientes herramientas MCP:
generarVideoDesdeTexto
Genera un vídeo a partir de un mensaje de texto.
Parámetros:
prompt(cadena): El texto que indica la generación del videoconfig(objeto, opcional): Opciones de configuraciónaspectRatio(cadena, opcional): "16:9" o "9:16"personGeneration(cadena, opcional): "dont_allow" o "allow_adult"numberOfVideos(número, opcional): 1 o 2durationSeconds(número, opcional): Entre 5 y 8enhancePrompt(booleano, opcional): si se debe mejorar el mensajenegativePrompt(cadena, opcional): Texto que describe lo que no se debe generar
Ejemplo:
{
"prompt": "Panning wide shot of a serene forest with sunlight filtering through the trees, cinematic quality",
"config": {
"aspectRatio": "16:9",
"personGeneration": "dont_allow",
"durationSeconds": 8
}
}generarVideoDesdeImagen
Genera un vídeo a partir de una imagen.
Parámetros:
image(cadena): datos de imagen codificados en Base64prompt(cadena, opcional): mensaje de texto para guiar la generación del videoconfig(objeto, opcional): Opciones de configuración (igual que la anterior, pero personGeneration solo admite "dont_allow")
lista de vídeos generados
Enumera todos los vídeos generados.
Recursos de MCP
El servidor expone los siguientes recursos MCP:
vídeos://{id}
Acceda a un vídeo generado por su ID.
videos://plantillas
Acceda a plantillas de generación de videos de ejemplo.
Desarrollo
Estructura del proyecto
src/: Código fuenteindex.ts: Punto de entrada principalserver.ts: configuración del servidor MCPconfig.ts: Manejo de configuracióntools/: Implementaciones de herramientas MCPresources/: Implementaciones de recursos MCPservices/: Integraciones de servicios externosutils/: Funciones de utilidad
Edificio
npm run buildModo de desarrollo
npm run devLicencia
Instituto Tecnológico de Massachusetts (MIT)
Available Tools
7 toolsgenerateImageC
Generate an image from a text prompt using Google Imagen
| Name | Required | Description | Default |
|---|---|---|---|
| prompt | Yes | ||
| numberOfImages | No | ||
| includeFullData | No |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations are provided, so the description must disclose behavioral traits. It does not mention side effects, authentication needs, rate limits, or whether the image is stored or returned directly.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single sentence, which is concise. However, it sacrifices valuable information for brevity. Not every sentence earns its place when it omits critical details.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given 3 parameters, no output schema, and no annotations, the description is severely incomplete. It does not explain return values or parameter behavior, leaving the agent without enough context to use the tool effectively.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 0%. The description adds no meaning beyond the parameter names and types in the input schema. It fails to explain prompt constraints, the number of images, or the includeFullData field.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the verb ('Generate'), the resource ('an image'), and the input ('from a text prompt using Google Imagen'). It effectively distinguishes from sibling tools focused on video generation or listing.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
No guidance on when to use this tool versus alternatives like getImage or listGeneratedImages. The description does not mention prerequisites, exclusions, or context for invocation.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
generateVideoFromGeneratedImageC
Generate a video from a generated image (one-step process)
| Name | Required | Description | Default |
|---|---|---|---|
| prompt | Yes | ||
| aspectRatio | No | 16:9 | |
| videoPrompt | No | ||
| autoDownload | No | ||
| enhancePrompt | No | ||
| negativePrompt | No | ||
| numberOfImages | No | ||
| numberOfVideos | No | ||
| durationSeconds | No | ||
| includeFullData | No | ||
| personGeneration | No | dont_allow |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations are present, and the description only mentions 'one-step process'. Important behavioral traits such as cost, async behavior, output format, and side effects are not disclosed. The description fails to compensate for the lack of annotations.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single sentence, which is too brief given the tool's complexity (11 parameters). It is under-specified and does not effectively convey necessary information despite being concise.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
The description is minimal given the large parameter count and lack of output schema. It does not explain the overall workflow (e.g., whether the image is generated first or input is needed) or how the tool fits with siblings. Important context like return values and constraints is missing.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
With 0% schema description coverage, the description must explain parameters but does not. None of the 11 parameters are described in the description, and the schema itself lacks descriptions. The agent cannot understand what parameters like 'autoDownload' or 'personGeneration' do.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description states the action (generate video) and the source (generated image). However, it does not differentiate from the sibling tool 'generateVideoFromImage', which could lead to confusion about when to use this tool vs that one.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
No guidance is provided on when to use this tool versus alternatives like generateVideoFromImage or generateVideoFromText. There is no explanation of prerequisites or exclusions.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
generateVideoFromImageC
Generate a video from an image
| Name | Required | Description | Default |
|---|---|---|---|
| image | Yes | ||
| prompt | No | Generate a video from this image | |
| aspectRatio | No | 16:9 | |
| autoDownload | No | ||
| enhancePrompt | No | ||
| negativePrompt | No | ||
| numberOfVideos | No | ||
| durationSeconds | No | ||
| includeFullData | No | ||
| personGeneration | No | dont_allow |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations are provided, and the description only states the basic operation. It does not disclose any behavioral traits such as processing time, image format requirements, or potential limitations, leaving the agent without important context.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single sentence, which is under-specified for a tool with 10 parameters. It lacks structure and important details, making it minimally informative.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the complexity (10 parameters, no output schema, no annotations), the description is grossly incomplete. It fails to provide context for the output, parameter behavior, or usage scenarios.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The input schema has zero description coverage for parameters, and the description adds no meaning about any of the 10 parameters. Parameters like 'prompt', 'aspectRatio', 'durationSeconds' are not explained, so the agent cannot infer their purpose from the description.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool generates a video from an image, using a specific verb and resource. However, it does not differentiate from sibling tool 'generateVideoFromGeneratedImage', which has a similar purpose.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description implies usage when you have an image to convert to a video, but provides no explicit guidance on when to use this tool versus alternatives like 'generateVideoFromText' or 'generateVideoFromGeneratedImage'. No exclusions or context are given.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
generateVideoFromTextC
Generate a video from a text prompt
| Name | Required | Description | Default |
|---|---|---|---|
| prompt | Yes | ||
| aspectRatio | No | 16:9 | |
| autoDownload | No | ||
| enhancePrompt | No | ||
| negativePrompt | No | ||
| numberOfVideos | No | ||
| durationSeconds | No | ||
| includeFullData | No | ||
| personGeneration | No | dont_allow |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations, the description bears full burden for behavioral transparency. It only states the basic function without disclosing any behavioral traits such as generation time, cost, success/failure handling, or return format. This is insufficient for responsible agent use.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is very concise at one sentence, but given the tool's complexity (9 parameters), it is too brief. While front-loaded with the core action, it sacrifices necessary detail for brevity.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Considering the tool's complexity (9 parameters, no output schema, no annotations), the description is critically incomplete. It lacks details on output, behavior, parameter effects, and usage context, making it inadequate for correct agent selection and invocation.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 0%, yet the description adds no value by explaining parameters like enhancePrompt, autoDownload, includeFullData, or personGeneration. Agents must infer meaning from names alone, risking misuse. At minimum, key parameters should be explained.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description 'Generate a video from a text prompt' clearly states the verb (Generate) and resource (video from text), distinguishing it from siblings like generateImage (image from text) and generateVideoFromImage (video from existing image). It's specific and unambiguous.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description provides no guidance on when to use this tool vs alternatives. It doesn't mention scenarios, prerequisites, or exclusions, leaving the agent without context for appropriate usage.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
getImageB
Get a specific image by ID
| Name | Required | Description | Default |
|---|---|---|---|
| id | Yes | ||
| includeFullData | No |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
The description does not disclose behavioral traits beyond the basic operation. It lacks details about error handling, response format, or side effects. With no annotations, the description carries the full burden but provides minimal insight.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single, front-loaded sentence. Every word is necessary and there is no wasted information.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the absence of an output schema, no parameter descriptions in the schema, and no annotations, the description is insufficient. It does not explain return values, error states, or the effect of optional parameters, leaving significant gaps for the agent.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The description only hints at the 'id' parameter through the phrase 'by ID', but does not explain the 'includeFullData' parameter. Schema description coverage is 0%, so the description should compensate but does not.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description 'Get a specific image by ID' clearly states the verb (Get), resource (specific image), and method (by ID). It effectively distinguishes from sibling tools like generateImage, which are generative in nature.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
No guidance is provided on when to use this tool versus alternatives. For example, it does not clarify that this tool is for retrieving existing images, while siblings handle generation or listing.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
listGeneratedImagesB
List all generated images
| Name | Required | Description | Default |
|---|---|---|---|
No parameters | |||
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations provided; description does not disclose read-only nature, auth requirements, or any side effects. Simply states 'list all', offering no behavioral context.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Extremely concise at one sentence, no wasted words. Could be slightly improved by front-loading key info, but currently adequate.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Simple list tool with no params or output schema; however, lacks any mention of pagination or ordering, which may be necessary for completeness.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Tool has zero parameters; schema coverage is 100%. Description adds no parameter info, but none is needed. Baseline 4 is appropriate for no-param tool.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
Description clearly states verb (list) and resource (generated images), distinguishing from siblings like getImage (single) and generateImage.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
No guidance on when to use this tool vs alternatives; no mention of filtering, pagination, or context such as if the list is all images or scoped to a user.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
listGeneratedVideosB
List all generated videos
| Name | Required | Description | Default |
|---|---|---|---|
No parameters | |||
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations provided, and the description merely repeats the tool name without disclosing any behavioral traits (e.g., pagination, scope of 'all', or read-only nature).
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Single, efficient sentence with no extraneous words. Appropriate for a simple list tool with no parameters.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a zero-parameter list tool, the description is acceptable but lacks details like result format, sorting, or limits. Could be improved with a note on scope or output structure.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
No parameters exist (schema is empty), so the description has no parameter semantics to add. Baseline 4 applies as the schema already covers 100% of parameters.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description 'List all generated videos' clearly states the verb (List) and resource (generated videos), distinguishing it from siblings like generateImage, generateVideoFromText, and listGeneratedImages.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
No guidance on when to use this tool versus alternatives such as getImage or generateVideoFromText. The description does not specify context, prerequisites, or exclusions.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
7 tool updates
v1.0.0- First observed
generateImage - First observed
generateVideoFromGeneratedImage - First observed
generateVideoFromImage - First observed
generateVideoFromText - First observed
getImage - First observed
listGeneratedImages - First observed
listGeneratedVideos
TDQS
Scored across 7 tools
Most tools have distinct purposes, but generateVideoFromGeneratedImage and generateVideoFromImage overlap in functionality; one is described as 'one-step process' but the distinction is not immediately clear from names alone.
Tool names follow a verb_noun pattern, but there is inconsistency: 'generateImage' uses a direct object while video tools use 'from' prepositional phrases. Also, 'getImage' differs from 'listGeneratedImages/listGeneratedVideos' in tense.
With 7 tools, the set is well-scoped for an image/video generation server, covering creation and listing without being overly numerous.
The tool surface includes generation and listing but lacks retrieval of individual videos (no getVideo), update, and delete operations, leaving notable gaps in lifecycle management.
Maintenance
Related MCP Connectors
MCP server for Google Veo AI video generation
MCP server for Kling AI video generation
MCP server for Hailuo (MiniMax) AI video generation
MCP server for Wan AI video generation
Related MCP Servers
- AlicenseNot gradedqualityDmaintenanceAn async video generation MCP server with multi-provider support. Currently in skeleton phase with stub implementations, it will eventually enable video generation through providers like Veo 3.1, Grok Imagine Video, and Sora 2 Pro.MIT
- FlicenseNot gradedqualityDmaintenanceMCP server for programmatic video generation. Send a prompt, get an MP4.-
- AlicenseNot gradedqualityAmaintenanceMCP server for generating images and videos using Google Gemini and VEO models, with support for multiple AI models and credential modes.1Apache 2.0
- FlicenseBqualityDmaintenanceA production-ready MCP server that enables Claude and other LLMs to generate images and videos using Google's Gemini AI models (Gemini 2.0 Flash and Veo 2.0).32-