Skip to main content
Glama

get_video_info

Extract detailed video metadata including duration, frame rate, and codec from a specified file path using the FFmpeg-MCP server’s processing capabilities.

Instructions

获取视频信息,包括时长,帧率,codec等

参数:
video_path (str): 输入视频文件路径
返回:
视频详细信息

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
video_pathYes

Implementation Reference

  • The core handler function that runs ffprobe to retrieve video stream information including duration, framerate, codec etc. in JSON format.
    def get_video_info(video_path: str):
        cmd = f" -v error -show_streams -of json -i {video_path}"
        return ffmpeg.run_ffprobe(cmd, timeout=60)
  • Registers the 'get_video_info' tool with the MCP server using @mcp.tool() decorator. Includes input parameter description in docstring and delegates execution to cut_video.get_video_info.
    @mcp.tool()
    def get_video_info(video_path: str):
        """
        获取视频信息,包括时长,帧率,codec等
        
        参数:
        video_path (str): 输入视频文件路径
        返回:
        视频详细信息
        """
        return cut_video.get_video_info(video_path)
Behavior2/5

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

No annotations are provided, so the description carries the full burden of behavioral disclosure. It states the tool retrieves information (implying a read-only operation) but doesn't clarify whether it requires specific permissions, has rate limits, returns structured data, or handles errors. For a tool with zero annotation coverage, this leaves significant gaps in understanding its behavior.

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

Conciseness3/5

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

The description is concise with three short sentences, but it's not optimally structured. The purpose statement is clear, but the parameter and return sections are brief and lack depth. While there's no wasted text, it could be more front-loaded with critical details given the lack of annotations and output schema.

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

Completeness2/5

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

Given the complexity (a tool with one parameter but no annotations or output schema), the description is incomplete. It doesn't explain the return format ('视频详细信息' - video detailed information is vague), error handling, or behavioral constraints. With no structured fields to rely on, the description should provide more context to guide the agent effectively.

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

Parameters3/5

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

The description adds minimal parameter semantics: it lists 'video_path (str): 输入视频文件路径' (input video file path), which matches the schema's single parameter. However, schema description coverage is 0%, so the schema provides no additional details. The description doesn't elaborate on path formats, supported video types, or validation rules, offering only basic clarification beyond the schema.

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

Purpose4/5

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

The description clearly states the tool's purpose: '获取视频信息,包括时长,帧率,codec等' (Get video information, including duration, frame rate, codec, etc.). It specifies the verb ('获取' - get) and resource ('视频信息' - video information) with concrete examples of what information is retrieved. However, it doesn't explicitly differentiate from sibling tools like 'find_video_path' which might also retrieve video metadata.

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. It doesn't mention any prerequisites, context for usage, or comparisons to sibling tools like 'find_video_path' (which might find paths) or 'extract_frames_from_video' (which might provide frame details). The agent must infer usage solely from the purpose statement.

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

Related 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/video-creator/ffmpeg-mcp'

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