Skip to main content
Glama

creatify-mcp

by TSavo

🎬 创建 MCP 服务器

用于 AI 视频生成的终极 MCP 服务器- 将Creatify AI强大的视频创作功能带给 MCP 生态系统中的每个 AI 助手。

🌟 概述

Creatify MCP 服务器是一款功能全面的模型上下文协议 (MCP) 服务器,它将 Creatify AI 视频生成平台的全部功能开放给 AI 助手、聊天机器人和自动化工具。该服务器基于强大的@tsavo/creatify-api-ts TypeScript 客户端库构建,可将复杂的视频创建工作流程转化为简单的自然语言交互。

🎨高级 MCP 功能:

  • 📝 Prompts - 可重复使用的视频创建模板和工作流程
  • 📊 日志记录- 具有多个严重性级别的结构化日志记录
  • 🔍 进度跟踪- 视频生成过程中的实时更新
  • 🤖 AI 自助- how_to_use AI 助手理解参数的工具
  • 📊 通知- 实时状态更新和进度通知

🎯 这项技术能带来什么

想象一下,你告诉 Claude Desktop: “创建一个 16:9 的 Anna 头像视频,视频中安娜说着‘欢迎观看我们的产品演示’,然后等待它完成。” —— 而这一切真的发生了。这就是 MCP 服务器的强大之处。

🏗️ 内置

特征

🛠️ MCP 工具(12 个强大的操作)

  • create_avatar_video - 创建具有唇形同步的 AI 头像视频
  • create_url_to_video - 将网站转换为专业视频
  • generate_text_to_speech - 从文本生成自然语音
  • create_multi_avatar_conversation - 创建包含多个头像对话的视频
  • create_custom_template_video - 使用自定义模板生成视频
  • create_ai_edited_video - 自动编辑和增强视频
  • create_ai_shorts - 制作短视频(适用于 TikTok、Instagram Reels)
  • generate_ai_script - 为视频生成 AI 脚本
  • create_custom_avatar - 设计和创建您自己的自定义头像(DYOA)
  • manage_music - 上传、管理和使用背景音乐
  • create_advanced_lipsync - 具有情绪和手势控制的高级唇形同步
  • how_to_use - 获取任何工具的详细使用信息
  • get_video_status - 检查视频生成任务的状态

📚 MCP 资源(6 个数据源)

  • creatify://avatars - 可用 AI 头像列表
  • creatify://voices - 可用于文本转语音的声音列表
  • creatify://templates - 可用的自定义视频模板
  • creatify://music - 可用的背景音乐库
  • creatify://credits - 剩余 API 积分
  • creatify://avatar/{avatarId} - 特定头像的详细信息

🏆为什么选择 Creatify MCP 服务器?

🚀完整的 API 覆盖

  • **12 个 MCP 工具,**涵盖 100% 的 Creatify API 功能
  • 6 个 MCP 资源,提供全面的数据访问
  • 5 个常见视频创作场景的工作流程提示
  • **企业级日志记录,**具有 8 个严重级别

🤖 AI 优先设计

  • ✅ 使用how_to_use工具为 AI 助手提供自我文档
  • 智能参数验证和错误处理
  • ✅ 视频生成过程中实时进度更新
  • ✅ 具有自动发布的语义版本控制

🎨高级功能

  • ✅ 高级唇形同步中的情绪和手势控制
  • 自定义头像创建(DYOA - 设计您自己的头像)
  • ✅ 适用于任何视频类型的AI 脚本生成
  • ✅ TikTok/Instagram/YouTube 的短视频优化
  • 背景音乐管理和集成

💼生产就绪

  • TypeScript提供类型安全性和更好的 IDE 支持
  • ✅ 具有详细上下文的全面错误处理
  • ✅ 用于监控和调试的专业日志记录
  • 自动化测试和持续集成
  • 语义版本控制,实现可靠更新

📝 MCP 提示(5 个工作流模板)

  • create-product-demo - 专业产品演示工作流程
  • create-social-content - 参与社交媒体内容创作
  • create-educational-video - 教育和教程视频工作流程
  • create-marketing-campaign - 营销活动视频制作
  • analyze-video-performance - 视频性能分析和优化

先决条件

  • Node.js 18 或更高版本
  • Createfy API 凭证(专业版或更高版本)

安装

来自 npm(推荐)

npm install -g @tsavo/creatify-mcp

从源头

git clone https://github.com/TSavo/creatify-mcp.git cd creatify-mcp npm install npm run build npm link

🎬现场演示示例

创建AI头像视频

User: "Create a professional avatar video with Anna saying 'Welcome to our company!' in 16:9 format" Claude: I'll create a professional avatar video for you using the Creatify MCP Server. [Uses create_avatar_video tool with: - text: "Welcome to our company!" - avatarId: "anna_costume1_cameraA" - aspectRatio: "16:9" - voiceId: "en-US-AriaNeural"] Your professional avatar video has been created! Anna delivers your message with natural lip-sync and professional presentation.

生成TikTok风格的短视频

User: "Make a 30-second TikTok video about coffee brewing tips" Claude: I'll create an engaging short-form video perfect for TikTok! [Uses create_ai_shorts tool with: - prompt: "Quick coffee brewing tips with energetic presentation" - aspectRatio: "9:16" - duration: 30 - style: "energetic"] Your TikTok-ready short video is being generated with optimal 9:16 aspect ratio and engaging content!

将网站转换为视频

User: "Turn my product landing page into a marketing video" Claude: I'll convert your website into a compelling marketing video. [Uses create_url_to_video tool with: - url: "https://yourproduct.com" - aspectRatio: "16:9" - style: "marketing"] Your landing page has been transformed into a professional marketing video showcasing your product!

人工智能脚本生成

User: "Generate a script for a 60-second product demo video" Claude: I'll create a compelling script for your product demo. [Uses generate_ai_script tool with: - topic: "Product demonstration video" - scriptType: "commercial" - duration: 60 - tone: "professional"] Your script is ready! It includes engaging hooks, clear value propositions, and a strong call-to-action optimized for 60-second format.

配置

将您的 Createfy API 凭据设置为环境变量:

export CREATIFY_API_ID="your-api-id" export CREATIFY_API_KEY="your-api-key"

或者创建一个.env文件:

CREATIFY_API_ID=your-api-id CREATIFY_API_KEY=your-api-key

用法

使用 Claude Desktop

添加到您的 Claude Desktop 配置(在 macOS 上为~/Library/Application Support/Claude/claude_desktop_config.json ):

{ "mcpServers": { "creatify": { "command": "creatify-mcp", "env": { "CREATIFY_API_ID": "your-api-id", "CREATIFY_API_KEY": "your-api-key" } } } }

🎨高级 MCP 功能

📝使用提示(工作流模板)

AI 助手现在可以使用预定义的工作流模板来处理常见的视频创作场景:

示例:产品演示工作流程

User: "Use the create-product-demo prompt for 'Amazing Widget' with features 'fast, reliable, easy to use' targeting small business owners" Claude: I'll use the product demo workflow template to create a professional demonstration video. [Claude automatically follows the complete workflow: 1. Generates an engaging script using generate_ai_script 2. Creates avatar video using create_avatar_video 3. Optimizes for the target audience 4. Includes clear call-to-action]

可用的提示模板:

  • create-product-demo - 专业产品演示
  • create-social-content - TikTok/Instagram/YouTube 内容
  • create-educational-video - 教程和教育内容
  • create-marketing-campaign - 营销和宣传视频
  • analyze-video-performance - 视频优化和分析
📊实时记录和进度

服务器提供具有多个严重程度级别的结构化日志记录:

[INFO] Creatify MCP Server initialized [INFO] Creating avatar video {avatarId: "anna_costume1_cameraA", aspectRatio: "16:9"} [INFO] Waiting for avatar video completion... [INFO] Avatar video completed {videoId: "video_abc123"}

日志级别: debuginfonoticewarningerrorcriticalalertemergency

🤖 AI自助系统

AI 助手现在可以使用how_to_use工具更好地理解工具参数:

Claude: Let me check how to use the avatar video tool... [Calls how_to_use tool with toolName: "create_avatar_video"] [Gets comprehensive documentation with: - Required parameters with descriptions - Optional parameters with usage notes - Real code examples - Tips and best practices] Now I understand exactly how to create your avatar video!

使用自定义 MCP 客户端

import { Client } from "@modelcontextprotocol/sdk/client/index.js"; import { StdioClientTransport } from "@modelcontextprotocol/sdk/client/stdio.js"; const transport = new StdioClientTransport({ command: "creatify-mcp", env: { CREATIFY_API_ID: "your-api-id", CREATIFY_API_KEY: "your-api-key" } }); const client = new Client({ name: "my-client", version: "1.0.0" }); await client.connect(transport); // List available tools const tools = await client.listTools(); console.log("Available tools:", tools.tools.map(t => t.name)); // Create an avatar video const result = await client.callTool({ name: "create_avatar_video", arguments: { text: "Hello, world! This is an AI-generated video.", avatarId: "anna_costume1_cameraA", aspectRatio: "16:9", waitForCompletion: true } });

独立服务器

# Set environment variables export CREATIFY_API_ID="your-api-id" export CREATIFY_API_KEY="your-api-key" # Run the server creatify-mcp

人工智能助手的示例提示

一旦配置了 Claude Desktop 或其他 MCP 客户端,您就可以使用自然语言提示,例如:

  • “创建一个 16:9 的安娜头像视频,视频中安娜说‘欢迎参加我们的产品演示’,然后等待它完成”
  • “将网站https://example.com转换为宣传视频”
  • “使用专业声音为‘Hello world’生成文本转语音音频”
  • “显示所有可用的头像及其详细信息”
  • “查看我剩余的 Creatify 积分”
  • “创建两个角色之间的对话来讨论我们的新产品”

API 参考

工具

create_avatar_video

创建具有唇形同步语音的 AI 头像视频。

参数:

  • text (字符串,必需) - 要朗读的文本
  • avatarId (字符串,必需) - 要使用的头像 ID
  • aspectRatio (“16:9”|“9:16”|“1:1”,必需) - 视频宽高比
  • voiceId (字符串,可选) - 头像的语音 ID
  • waitForCompletion (boolean,可选) - 等待视频完成
create_url_to_video

将网站 URL 转换为专业视频。

参数:

  • url (字符串,必需) - 要转换的 URL
  • visualStyle (字符串,可选) - 视觉样式模板
  • scriptStyle (字符串,可选) - 脚本编写风格
  • aspectRatio (“16:9”|“9:16”|“1:1”,可选) - 视频宽高比
  • waitForCompletion (布尔值,可选)-等待视频完成
generate_text_to_speech

从文本生成自然的语音。

参数:

  • text (字符串,必需) - 要转换为语音的文本
  • voiceId (字符串,必需) - 要使用的语音 ID
  • waitForCompletion (布尔值,可选)-等待音频完成
get_video_status

检查视频生成任务的状态。

参数:

  • videoId (字符串,必需) - 要检查的视频/任务 ID
  • videoType (字符串,必需) - 任务类型(“lipsync”、“url-to-video”等)

资源

creatify://avatars

返回所有可用 AI 头像及其 ID、名称和元数据的 JSON 列表。

creatify://voices

返回可用于文本转语音生成的所有可用声音的 JSON 列表。

creatify://templates

返回可用自定义视频模板的 JSON 列表。

creatify://credits

返回当前帐户信用余额和使用情况信息。

发展

# Install dependencies npm install # Build the project npm run build # Run in development mode with auto-reload npm run dev # Run tests npm test # Lint and format code npm run check

贡献

  1. 分叉存储库
  2. 创建功能分支( git checkout -b feature/amazing-feature
  3. 提交您的更改( git commit -m 'Add amazing feature'
  4. 推送到分支( git push origin feature/amazing-feature
  5. 打开拉取请求

执照

MIT 许可证 - 详情请参阅LICENSE文件。

相关项目

📚 全面的文档

🎬 视频教程

即将推出 - 展示真实使用场景的综合视频教程

📖 API 参考

详细API文档请参见:

🔧 高级配置

环境变量
多变的必需的描述例子
CREATIFY_API_ID您的 Createfy API IDyour-api-id-here
CREATIFY_API_KEY您的 Createfy API 密钥your-api-key-here
MCP_LOG_LEVEL日志级别debuginfowarnerror
Claude Desktop高级配置
{ "mcpServers": { "creatify": { "command": "creatify-mcp", "env": { "CREATIFY_API_ID": "your-api-id", "CREATIFY_API_KEY": "your-api-key", "MCP_LOG_LEVEL": "info" }, "args": ["--verbose"] } } }

🚀 性能优化

批量操作

对于多个视频创作,请考虑使用批处理功能:

// Example: Create multiple videos efficiently const videos = await Promise.all([ client.callTool({ name: "create_avatar_video", arguments: { text: "Video 1", avatarId: "anna", aspectRatio: "16:9" } }), client.callTool({ name: "create_avatar_video", arguments: { text: "Video 2", avatarId: "john", aspectRatio: "16:9" } }) ]);
缓存策略
  • 头像/语音列表:缓存 1 小时(很少改变)
  • 视频状态:每 5-10 秒轮询一次活动任务
  • 模板:缓存 24 小时

🔐 安全最佳实践

  1. 切勿将 API 密钥提交到版本控制
  2. 对所有敏感数据使用环境变量
  3. 定期轮换 API 密钥
  4. 监控 API 使用情况以检测未经授权的访问
  5. 对所有 webhook URL使用 HTTPS

🐛 故障排除

常见问题

“未找到 API 凭证”

# Solution: Set environment variables export CREATIFY_API_ID="your-api-id" export CREATIFY_API_KEY="your-api-key"

“视频创建失败”

  • 检查您的 Createfy 帐户积分
  • 验证头像/语音 ID 是否存在
  • 确保文本不为空
  • 检查纵横比是否有效

“MCP 连接失败”

  • 验证服务器是否正在运行
  • 检查 Claude Desktop 配置
  • 确保 Node.js 版本 >= 18
调试模式
# Run with debug logging MCP_LOG_LEVEL=debug creatify-mcp

📊 监控与分析

使用情况追踪

监控您的 Createfy API 使用情况:

// Check remaining credits const credits = await client.readResource({ uri: "creatify://credits" }); console.log(`Remaining credits: ${JSON.parse(credits.contents[0].text).remaining_credits}`);
绩效指标
  • 视频制作时间:通常为 2-5 分钟
  • API 响应时间:通常<2秒
  • 成功率:监控失败的请求

🤝 贡献

欢迎大家投稿!以下是参与方式:

🛠️ 开发设置

# Clone the repository git clone https://github.com/TSavo/creatify-mcp.git cd creatify-mcp # Install dependencies npm install # Set up environment variables cp .env.example .env # Edit .env with your API credentials # Run tests npm test # Build the project npm run build # Run in development mode npm run dev

🧪 测试

# Run all tests npm test # Run tests in watch mode npm run test:watch # Run type checking npm run type-check # Run linting npm run lint

📝 代码风格

我们使用:

  • ESLint用于代码检查
  • Prettier用于代码格式化
  • TypeScript类型安全
  • 提交消息的常规提交

🔄 拉取请求流程

  1. 分叉存储库
  2. 创建功能分支( git checkout -b feature/amazing-feature
  3. 进行更改
  4. 添加新功能测试
  5. 确保所有测试通过( npm test
  6. 运行 linting( npm run lint:fix
  7. 提交您的更改( git commit -m 'feat: add amazing feature'
  8. 推送到分支( git push origin feature/amazing-feature
  9. 打开拉取请求

📄 许可证

该项目根据 MIT 许可证获得许可 - 有关详细信息,请参阅LICENSE文件。

🙏 致谢

📞 支持


T Savo用❤️创作

🌐**地平线城市**——开启人工智能革命,加速人类灭绝

让每个开发人员和人工智能助手都能生成人工智能视频——距离人类淘汰更近一步

Related MCP Servers

View all related MCP servers

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/TSavo/creatify-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server