这是一个用于与 Placid.app API 集成的 MCP 服务器实现。该服务器通过模型上下文协议提供了列出模板以及生成图像和视频的工具。
node --version npm --version
最简单的入门方法是使用 Smithery,它会自动为您配置一切:
npx -y @smithery/cli install @felores/placid-mcp-server --client claude
如果您更喜欢手动配置,请将以下内容添加到您的 Claude Desktop 或 Cline 设置中:
{
"mcpServers": {
"placid": {
"command": "npx",
"args": ["@felores/placid-mcp-server"],
"env": {
"PLACID_API_TOKEN": "your-api-token"
}
}
}
}

# Run in development mode with hot reload
npm run dev
# Run tests
npm test

列出带有过滤选项的可用 Placid 模板。每个模板都包含其标题、ID、预览图片 URL、可用图层和标签。
collection_id
(可选): 按集合 ID 过滤模板custom_data
(可选): 按自定义参考数据过滤tags
(可选): 用于过滤模板的标签数组返回一个模板数组,每个模板包含:
uuid
: 模板的唯一标识符title
: 模板名称thumbnail
: 预览图片 URL(如果可用)layers
: 包含名称和类型的可用图层数组tags
: 模板标签数组通过结合 Placid 模板与动态内容如视频、图像和文本生成视频。对于较长的视频(>60 秒处理时间),您将收到一个作业 ID,在您的 Placid 仪表板中检查状态。
template_id
(required): 要使用的模板的 UUIDlayers
(required): 包含模板层动态内容的对象
{ "layerName": { "video": "https://video-url.com" } }
{ "layerName": { "image": "https://image-url.com" } }
{ "layerName": { "text": "您的内容" } }
audio
(optional): mp3 音频文件的 URLaudio_duration
(optional): 设置为 'auto' 以将音频裁剪至视频长度audio_trim_start
(optional): 裁剪起始时间戳(例如 '00:00:45' 或 '00:00:45.25')audio_trim_end
(optional): 裁剪结束时间戳(例如 '00:00:55' 或 '00:00:55.25')返回一个对象,包含:
status
: 当前状态("finished"、"queued" 或 "error")video_url
: 生成视频的下载链接(当状态为 "finished" 时)job_id
: 在 Placid 仪表板中检查状态的 ID(用于较长的视频){
"template_id": "template-uuid",
"layers": {
"MEDIA": { "video": "https://example.com/video.mp4" },
"PHOTO": { "image": "https://example.com/photo.jpg" },
"LOGO": { "image": "https://example.com/logo.png" },
"HEADLINE": { "text": "My Video Title" }
},
"audio": "https://example.com/background.mp3",
"audio_duration": "auto"
}

通过结合 Placid 模板与动态内容(如文本和图像)来生成静态图片。
template_id
(required): 要使用的模板的 UUIDlayers
(required): 包含模板层动态内容的对象
{ "layerName": { "text": "您的内容" } }
{ "layerName": { "image": "https://image-url.com" } }
返回一个对象,包含:
status
: 完成时为 "finished"image_url
: 生成图片的下载链接{
"template_id": "template-uuid",
"layers": {
"headline": { "text": "Welcome to My App" },
"background": { "image": "https://example.com/bg.jpg" }
}
}

有关 Placid API 的更详细信息,请访问 Placid API Documentation。
MIT