Skip to main content
Glama
bitscorp-mcp

MCP FFmpeg Video Processor

by bitscorp-mcp

get-ffmpeg-version

Check the installed FFmpeg version to verify compatibility for video processing tasks like resizing and audio extraction.

Instructions

Get the version of FFmpeg installed on the system

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • Inline handler function for the get-ffmpeg-version tool. Executes 'ffmpeg -version', parses the version with regex, returns formatted text response with version or error if FFmpeg not found.
    server.tool(
      "get-ffmpeg-version",
      "Get the version of FFmpeg installed on the system",
      {},
      async () => {
        try {
          const { stdout, stderr } = await execAsync('ffmpeg -version');
    
          // Extract the version from the output
          const versionMatch = stdout.match(/ffmpeg version (\S+)/);
          const version = versionMatch ? versionMatch[1] : 'Unknown';
    
          return {
            content: [{
              type: "text" as const,
              text: `FFmpeg Version: ${version}\n\nFull version info:\n${stdout}`
            }]
          };
        } catch (error) {
          const errorMessage = error instanceof Error ? error.message : String(error);
          return {
            isError: true,
            content: [{
              type: "text" as const,
              text: `Error getting FFmpeg version: ${errorMessage}\n\nMake sure FFmpeg is installed and in your PATH.`
            }]
          };
        }
      }
    );
  • Registers the get-ffmpeg-version tool on the MCP server with empty input schema and the inline handler function.
    server.tool(
      "get-ffmpeg-version",
      "Get the version of FFmpeg installed on the system",
      {},
      async () => {
        try {
          const { stdout, stderr } = await execAsync('ffmpeg -version');
    
          // Extract the version from the output
          const versionMatch = stdout.match(/ffmpeg version (\S+)/);
          const version = versionMatch ? versionMatch[1] : 'Unknown';
    
          return {
            content: [{
              type: "text" as const,
              text: `FFmpeg Version: ${version}\n\nFull version info:\n${stdout}`
            }]
          };
        } catch (error) {
          const errorMessage = error instanceof Error ? error.message : String(error);
          return {
            isError: true,
            content: [{
              type: "text" as const,
              text: `Error getting FFmpeg version: ${errorMessage}\n\nMake sure FFmpeg is installed and in your PATH.`
            }]
          };
        }
      }
    );
  • Promisified exec function used by the get-ffmpeg-version handler to run the ffmpeg command asynchronously.
    const execAsync = promisify(exec);
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations provided, the description carries the full burden of behavioral disclosure. It states the tool retrieves version information, implying a read-only operation, but does not disclose potential side effects, error conditions, permissions required, or output format. This leaves significant gaps in understanding how the tool behaves beyond its basic function.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single, clear sentence that directly states the tool's purpose without any unnecessary words or structural fluff. It is front-loaded and efficiently communicates the essential information, making it highly concise and well-structured.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool's simplicity (0 parameters, no output schema, no annotations), the description is adequate for a basic read operation but incomplete for practical use. It lacks details on output format (e.g., string, object), error handling, or system dependencies, which are important for an agent to invoke it correctly in varied contexts.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The input schema has 0 parameters with 100% coverage, so the schema fully documents the lack of inputs. The description appropriately does not mention parameters, aligning with the schema. Since there are no parameters to explain, this meets the baseline for tools without inputs, though it doesn't add extra semantic context.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the specific action ('Get') and resource ('version of FFmpeg installed on the system'), distinguishing it from sibling tools like 'extract-audio' or 'resize-video' which perform different operations. It precisely defines what the tool does without being vague or tautological.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

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 versus alternatives like 'get-video-info' (which might include version information) or other system-check tools. It lacks explicit context, prerequisites, or exclusions, offering only a basic statement of purpose without usage instructions.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

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/bitscorp-mcp/mcp-ffmpeg'

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