Ffmpeg Mcp

io.github.PedroMarianoAlmeida由 GitHub 帳號 PedroMarianoAlmeida 發布v1.0.2更新於 Oct 24, 2026

FFmpeg video/audio tools: cut, convert, concat, remove silence, and raw commands.

已驗證STDIO僅桌面檔案與儲存媒體與設計

概覽

AI 產生的概覽

本機 MCP 伺服器,為助理提供 FFmpeg 工具,可在工作區內剪裁、轉檔、合併影音並移除靜音。

可以做什麼
  • 依起始時間與長度擷取影片片段,或將靜態圖片轉為固定長度影片
  • 將多段影片合併成一個檔案
  • 在 mp4、mp3、wav、mov 等格式間轉檔,包含從影片擷取音訊
  • 自動偵測並移除影片或播客音訊中的靜音片段
  • 以本機輸入、單一輸出路徑與少量編解碼及時間選項執行受限的 FFmpeg 指令
適用情境
適合讓助理對本機檔案做日常媒體處理,例如裁切片段、轉換格式、合併影片或去除靜音;由於內附 FFmpeg 執行檔,不需在系統中另外安裝。
執行需求
以本機程序執行,可透過 npm 套件 ffmpeg-mcp-server 安裝,或以 Node.js 從原始碼建置,已內附 FFmpeg 執行檔。可選擇設定 FFMPEG_MCP_WORKSPACE 指定媒體目錄,未設定時使用伺服器目前的工作目錄。執行工具前須先建立輸出目錄。
安裝前請注意
工具會寫入檔案,建議將 FFMPEG_MCP_WORKSPACE 指向專用媒體目錄;所有輸入與輸出都必須位於該目錄內,URL 協定、越界路徑與符號連結輸出會被拒絕。原始指令工具雖有限制(僅本機輸入、單一輸出與有限編解碼及時間選項),仍會在本機執行 FFmpeg。

安裝

在 SourceWeft 中

  1. 開啟 儀表板中的 Ffmpeg Mcp,將其新增到工作區。
  2. 為需要使用其工具的對話啟用該服務。

Desktop only,透過 STDIO。 STDIO 服務會啟動本機處理程序,因此需要 SourceWeft 桌面主機。

其他 MCP 客戶端

參照 儲存庫 中的啟動說明。

README

FFmpeg MCP Server

A Model Context Protocol (MCP) server that provides video and audio manipulation tools powered by FFmpeg. This server enables AI assistants to perform media operations like cutting videos, converting formats, removing silence, and more.

Features

  • Self-contained - Includes bundled FFmpeg binary via ffmpeg-static, no system installation required
  • Format conversion - Convert between audio/video formats (mp4, mp3, wav, mov, etc.)
  • Video editing - Cut segments, concatenate multiple videos, convert images to video
  • Audio processing - Detect and remove silent segments automatically
  • Local by default - Inputs and outputs stay inside a configured workspace

Available Tools

ToolDescription
cut_videoExtract a segment from a video using start time and duration
image_to_videoConvert a static image to a video with fixed duration
concat_videosJoin multiple videos into one
convertConvert between media formats (auto-detects from file extension)
remove_silenceDetect and remove silent segments from video
ffmpeg_rawRun a restricted local FFmpeg command

Installation

From npm (recommended)

bash
npm install -g ffmpeg-mcp-server

From source

bash
git clone https://github.com/PedroMarianoAlmeida/ffmpeg-mcpcd ffmpeg-mcpnpm installnpm run build

Configuration

Workspace and safety

Every input and output must be inside FFMPEG_MCP_WORKSPACE. If it is unset, the server's current working directory is used. The server resolves symlinks before reading and rejects URL schemes, traversal outside the workspace, and symlink outputs. Create output directories before running a tool.

ffmpeg_raw is deliberately restricted. It accepts local -i inputs, one final local output path, and a small set of codec and timing options. It does not accept filters, forced formats, or arbitrary FFmpeg flags because those options can load extra files or use network protocols.

For example, set a dedicated media directory in your MCP configuration:

json
{  "mcpServers": {    "ffmpeg": {      "command": "npx",      "args": ["ffmpeg-mcp-server"],      "env": {        "FFMPEG_MCP_WORKSPACE": "/absolute/path/to/media-workspace"      }    }  }}

Claude Desktop

Add to your claude_desktop_config.json:

json
{  "mcpServers": {    "ffmpeg": {      "command": "npx",      "args": ["ffmpeg-mcp-server"]    }  }}

Claude Code

Add to your Claude Code MCP settings:

json
{  "mcpServers": {    "ffmpeg": {      "command": "npx",      "args": ["ffmpeg-mcp-server"]    }  }}

Usage Examples

Cut a video segment

"Cut the first 30 seconds from video.mp4"→ Uses cut_video tool

Convert formats

"Convert video.mov to mp4""Extract audio from video.mp4 as mp3"→ Uses convert tool

Remove silence

"Remove silent parts from my podcast recording"→ Uses remove_silence tool (detects silence > 2s at -30dB by default)

Restricted raw operations

"Convert input.mp4 to output.mp4 using libx264"→ Uses ffmpeg_raw with local paths and supported codec options

Development

bash
# Install dependenciesnpm install
# Buildnpm run build
# Project structuresrc/  index.ts    # MCP server setup and tool registrations  lib.ts      # FFmpeg operations

License

MIT

來源:README.md,提交 518b13c

工具

0
SourceWeft 尚未在沙箱中啟動過該軟體包,因此其工具未知。

版本歷史

1
  1. v1.0.2最新Sep 16, 2026

評分

已滿足適用檢查項的 50%

該評分衡量此收錄條目的完整程度,依據註冊中心條目、端點與公開來源計算得出。它不是對伺服器本身的評價,也不表示伺服器安全或目前可用:可連通性是帶日期的檢查結果,評分也不包含安裝量或使用者評價。

  • 近 30 天內可連通25 分

    請保持端點能夠回應 MCP 握手;SourceWeft 每 30 天探測一次。

  • 已宣告認證方式10 分

    請在註冊中心條目中宣告憑證請求標頭,或保持端點能夠回應探測,以便判定其認證方式。

  • 已列出工具15 分

    請讓伺服器在無憑證時回應 tools/list,或發布可在沙箱中無憑證啟動的軟體包。

  • 描述必需15 分
  • 圖示10 分
  • 文件15 分
  • 授權條款10 分