Skip to main content

An MCP server that provides video processing services

Project description

Video Service MCP

An MCP server that provides video processing services.

Features

  • Frame Extraction: Extract frames from a video, ensuring the first and last frames are included.
  • Video Concatenation: Concatenate multiple videos into a single video.

Installation

pip install -e .

Environment Variables

The following environment variables must be set for TOS (Tencent Object Storage) integration:

  • TOS_ACCESS_KEY: Your TOS access key
  • TOS_SECRET_KEY: Your TOS secret key
  • TOS_BUCKET_NAME: Your TOS bucket name
  • TOS_ENDPOINT (optional): TOS endpoint (default: "tos-cn-beijing.volces.com")
  • TOS_REGION (optional): TOS region (default: "cn-beijing")

Usage

Starting the Server

carey_mcp_video --transport sse

API

Extract Frames

Extracts frames from a video and uploads them to TOS.

extract_frames(video_url: str, num_frames: int = 10)

Parameters:

  • video_url: URL of the video to extract frames from.
  • num_frames: Number of frames to extract (minimum 2 for first and last frames).

Returns:

  • A dictionary containing:
    • success: Boolean indicating if the operation was successful
    • message: Human-readable message about the result
    • frames: List of frame URLs (on success)

Concatenate Videos

Concatenates multiple videos using FFmpeg and uploads the result to TOS.

concatenate_videos(video_urls: List[str])

Parameters:

  • video_urls: List of URLs of videos to concatenate.

Returns:

  • A dictionary containing:
    • success: Boolean indicating if the operation was successful
    • message: Human-readable message about the result
    • url: URL of the concatenated video (on success)

Dependencies

  • fastmcp
  • loguru
  • requests
  • opencv-python
  • tos
  • FFmpeg (system dependency)

License

MIT

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

carey_mcp_video-0.1.3.tar.gz (5.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

carey_mcp_video-0.1.3-py3-none-any.whl (7.3 kB view details)

Uploaded Python 3

File details

Details for the file carey_mcp_video-0.1.3.tar.gz.

File metadata

  • Download URL: carey_mcp_video-0.1.3.tar.gz
  • Upload date:
  • Size: 5.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.6.14

File hashes

Hashes for carey_mcp_video-0.1.3.tar.gz
Algorithm Hash digest
SHA256 a87b05404b79edf29f4695c33a3bbf3b4ab7c7899da357768cfe5fbdc132d8d6
MD5 d57d629a616ca827cd19bd97cac3d9bc
BLAKE2b-256 7a0ee6a8b697aabd9b88112795c78e3614b71f367de5ba26914e9d1e558842a9

See more details on using hashes here.

File details

Details for the file carey_mcp_video-0.1.3-py3-none-any.whl.

File metadata

File hashes

Hashes for carey_mcp_video-0.1.3-py3-none-any.whl
Algorithm Hash digest
SHA256 85aea914f90df0740066905f1b637afa23bb001a0e3d6d476aa5eaa11fd52179
MD5 aec6787db3254468339cb40ce99c242c
BLAKE2b-256 b15e73f9191b8a840a580cb186783f274774783736ea87ef0ad4766574770fa7

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page