Mac Camera
FreeNot checkedMCP server for macOS that enables photo capture and video recording using the system camera via imagesnap and ffmpeg.
About
MCP server for macOS that enables photo capture and video recording using the system camera via imagesnap and ffmpeg.
README
Mac-Camera-MCP (Model Context Protocol) 服务,提供拍照和录像功能。
功能特性
- 📷 拍照功能 - 使用摄像头拍摄照片并保存为 JPG 格式
- 🎥 录像功能 - 录制视频并保存为 MP4 格式
系统要求
- Node.js >= 18.0.0
- macOS 系统
- 摄像头设备
依赖安装
安装系统依赖
推荐使用 Homebrew 安装以下工具:
# 安装 imagesnap(用于快速拍照)
brew install imagesnap
# 安装 ffmpeg(用于拍照和录像)
brew install ffmpeg
注意: 至少需要安装其中一个工具才能使用拍照功能。录像功能需要 ffmpeg。
使用方法
{
"mcpServers": {
"Mac-Camera-MCP": {
"command": "npx",
"args": [
"-y",
"mac-camera-mcp"
]
}
}
}
可用工具
1. take_photo - 拍照
{
"name": "take_photo",
"arguments": {
"outputDir": "./output",
"filename": "my-photo.jpg",
"cameraIndex": 0,
"width": 1920,
"height": 1080
}
}
参数说明:
outputDir: 输出目录路径(可选,默认 ./output)filename: 输出文件名(可选,默认使用时间戳)cameraIndex: 摄像头索引(可选,默认 0)width: 图片宽度(可选,默认 1920)height: 图片高度(可选,默认 1080)
返回示例:
{
"success": true,
"path": "/path/to/output/2024-01-01T12-00-00.jpg",
"filename": "2024-01-01T12-00-00.jpg",
"message": "拍照成功",
"method": "imagesnap"
}
2. record_video - 录像
{
"name": "record_video",
"arguments": {
"outputDir": "./output",
"filename": "my-video.mp4",
"cameraIndex": 0,
"duration": 10,
"fps": 30,
"quality": "medium"
}
}
参数说明:
outputDir: 输出目录路径(可选,默认 ./output)filename: 输出文件名(可选,默认使用时间戳)cameraIndex: 摄像头索引(可选,默认 0)duration: 录制时长(秒),0 表示需要外部控制停止fps: 帧率(可选,默认 30)quality: 视频质量预设(ultrafast/fast/medium/slow,默认 medium)
返回示例:
{
"success": true,
"path": "/path/to/output/2024-01-01T12-00-00.mp4",
"filename": "2024-01-01T12-00-00.mp4",
"message": "录制 10 秒视频成功",
"duration": 10,
"method": "ffmpeg"
}
权限说明
在 macOS 上首次使用摄像头时,系统会弹出权限请求对话框。请确保:
- 允许终端/Node.js 访问摄像头
- 在「系统设置」>「隐私与安全性」>「相机」中检查权限
故障排除
问题:找不到摄像头
解决方案:
- 运行
list_cameras工具检查可用摄像头 - 确保已授予摄像头权限
- 检查是否有其他应用正在使用摄像头
问题:拍照/录像失败
解决方案:
- 运行
check_dependencies检查依赖是否已安装 - 确保 imagesnap 或 ffmpeg 已正确安装
- 检查输出目录是否有写入权限
问题:录像文件损坏
解决方案:
- 确保录制时长足够长(至少 1 秒)
- 尝试降低视频质量预设
- 检查磁盘空间是否充足
许可证
MIT License
Install Mac Camera in Claude Desktop, Claude Code & Cursor
unyly install mac-camera-mcpInstalls into Claude Desktop, Claude Code, Cursor & VS Code — handles npx, uvx and build-from-source repos for you.
First time? Get the CLI: curl -fsSL https://unyly.org/install | sh
Or configure manually
Run in your terminal:
claude mcp add mac-camera-mcp -- npx -y mac-camera-mcpFAQ
Is Mac Camera MCP free?
Yes, Mac Camera MCP is free — one-click install via Unyly at no cost.
Does Mac Camera need an API key?
No, Mac Camera runs without API keys or environment variables.
Is Mac Camera hosted or self-hosted?
Self-hosted: the server runs locally on your machine via the install command above.
How do I install Mac Camera in Claude Desktop, Claude Code or Cursor?
Open Mac Camera on unyly.org, pick your client tab (Claude Desktop, Claude Code, Cursor) and press Install — the config is generated automatically, no JSON editing.
Related MCPs
Omni Video
An MCP server that transforms LLM-enabled IDEs into professional video editors by pre-processing footage into text proxies, generating motion graphics via HTML/
by buildwithtazaARA
Generate images, video and audio from any AI agent — one connector.
by ARAYouTube
Transcripts, channel stats, search
by YouTubeEverArt
AI image generation using various models.
by modelcontextprotocolCompare Mac Camera with
Not sure what to pick?
Find your stack in 60 seconds
Author?
Embed badge for your README
Browse similar
All media MCPs
