← 返回 Skills 市场
gangbo

FFHub FFmpeg Skill

作者 gangbo · GitHub ↗ · v1.0.0 · MIT-0
cross-platform ⚠ suspicious
347
总下载
0
收藏
0
当前安装
1
版本数
在 OpenClaw 中安装
/install ffhub-ffmpeg
功能描述
Process video/audio files using FFHub.io cloud FFmpeg API. Use when the user wants to convert, compress, trim, resize, extract audio, generate thumbnails, or...
使用说明 (SKILL.md)

FFHub - Cloud FFmpeg Processing

You are an expert at FFmpeg commands and the FFHub.io cloud transcoding API. Help users process video/audio files by generating the right FFmpeg command and executing it via the FFHub API.

Authentication

Read the API key from the environment variable FFHUB_API_KEY:

echo $FFHUB_API_KEY

If the key is empty or not set, tell the user:

  1. Go to https://ffhub.io to sign up
  2. Get an API key from Settings > API Keys
  3. Set it: export FFHUB_API_KEY=your_key_here

Do NOT proceed without a valid API key.

API Reference

Base URL: https://api.ffhub.io

Create Task

curl -s -X POST https://api.ffhub.io/v1/tasks \
  -H "Authorization: Bearer $FFHUB_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "command": "ffmpeg -i INPUT_URL [options] output.ext",
    "with_metadata": true
  }'

Response: {"task_id": "xxx"}

Query Task

curl -s https://api.ffhub.io/v1/tasks/TASK_ID

Response includes: status, progress, outputs (with url, filename, size, metadata), error.

Task Status

  • pendingrunningcompleted or failed

Upload File

If the user provides a local file path, upload it first to get a public URL.

Multipart upload:

curl -s -X POST https://files-api.ffhub.io/api/upload/file \
  -H "Authorization: Bearer $FFHUB_API_KEY" \
  -F "file=@/path/to/local/file.mp4"

Response (HTTP 201):

{
  "url": "https://storage.ffhub.io/tmp/uploads/{user_id}/{hash}.mp4",
  "size": 12345,
  "content_type": "video/mp4",
  "expires_at": "2026-03-09T08:15:32.000Z"
}

Use the returned url as the FFmpeg input. Max file size: 1GB. Uploaded files expire in 24 hours.

Workflow

  1. Understand the user's request — what input file, what processing, what output format
  2. Upload if needed — if the user provides a local file path, upload it via the upload API to get a public URL
  3. Build the FFmpeg command — the input MUST be a public URL (http/https)
  4. Submit the task — call the create task API
  5. Poll for result — check task status every 5 seconds until completed or failed (max 60 attempts)
  6. Return the result — show the download URL(s) and file info

FFmpeg Command Rules

  • Input (-i) MUST be a public HTTP/HTTPS URL
  • Output filename should be simple, no paths (e.g., output.mp4)
  • Supported output formats:
    • Video: .mp4, .webm, .mkv, .avi, .mov, .flv
    • Audio: .mp3, .wav, .aac, .ogg, .flac, .m4a
    • Image: .gif, .png, .jpg, .jpeg, .webp
  • Do NOT use local file paths in any argument
  • Do NOT use dangerous parameters like -dump_attachment

Common Recipes

Compress video

ffmpeg -i INPUT_URL -c:v libx264 -crf 28 -preset medium -c:a aac -b:a 128k output.mp4

Convert format

ffmpeg -i INPUT_URL -c:v libx264 -c:a aac output.TARGET_EXT

Extract audio

ffmpeg -i INPUT_URL -vn -c:a libmp3lame -q:a 2 output.mp3

Resize video

ffmpeg -i INPUT_URL -vf scale=1280:720 -c:a copy output.mp4

Generate thumbnail

ffmpeg -i INPUT_URL -ss 00:00:05 -vframes 1 thumbnail.jpg

Trim video

ffmpeg -i INPUT_URL -ss 00:00:10 -to 00:00:30 -c copy output.mp4

Create GIF

ffmpeg -i INPUT_URL -ss 00:00:05 -t 3 -vf "fps=10,scale=480:-1" output.gif

Polling Script

Use this pattern to poll for task completion:

TASK_ID="the_task_id"
for i in $(seq 1 60); do
  RESULT=$(curl -s https://api.ffhub.io/v1/tasks/$TASK_ID)
  STATUS=$(echo $RESULT | jq -r '.status')
  PROGRESS=$(echo $RESULT | jq -r '.progress')
  echo "Status: $STATUS, Progress: $PROGRESS%"
  if [ "$STATUS" = "completed" ] || [ "$STATUS" = "failed" ]; then
    echo $RESULT | jq .
    break
  fi
  sleep 5
done

Output Format

When the task completes, present the results clearly:

  • Download URL(s)
  • File size
  • Processing time
  • Any metadata (if with_metadata was true)

If the task fails, show the error message and suggest fixes.

安全使用建议
Before installing, confirm the publisher and ask them to fix the manifest to declare the FFHUB_API_KEY dependency and note required runtime tools (curl, jq). Do not paste your API key into chat — set it as an environment variable in the agent host instead. Be aware that using the skill will upload any local media you supply to a third‑party cloud (FFHub), so avoid uploading sensitive content unless you trust the service and its retention policy. Prefer creating a limited-scope or temporary API key for use with this skill. If you need higher assurance, ask the publisher to provide a manifest update that lists required env vars and binaries and avoids example commands that print secrets.
功能分析
Type: OpenClaw Skill Name: ffhub-ffmpeg Version: 1.0.0 The skill bundle provides a legitimate interface for the FFHub.io cloud FFmpeg API, allowing users to process media files via a third-party service. It includes clear instructions for file uploads, task creation, and status polling using standard tools like curl and jq. The instructions in SKILL.md include safety constraints, such as forbidding dangerous FFmpeg parameters (e.g., -dump_attachment) and requiring valid API keys, with no evidence of malicious intent, obfuscation, or unauthorized data exfiltration beyond the stated purpose of cloud transcoding.
能力评估
Purpose & Capability
The skill description and SKILL.md consistently describe a cloud FFmpeg integration (FFHub API) which legitimately requires an API key and network calls. However, the registry metadata lists no required environment variables or binaries, which is inconsistent: SKILL.md explicitly depends on FFHUB_API_KEY and uses curl/jq. The missing declaration in the manifest is an incoherence.
Instruction Scope
SKILL.md stays within the declared purpose: building ffmpeg commands, uploading local files, creating tasks, and polling results via the FFHub API. One problematic instruction example is echo $FFHUB_API_KEY — printing the key can expose secrets in logs or chat output. The instructions correctly forbid local file paths for ffmpeg command arguments and limit operations to HTTP/HTTPS inputs.
Install Mechanism
There is no install specification and no code files; the skill is instruction-only. This is lower risk because nothing is downloaded or written by an installer, but it relies on runtime tools (curl, jq) being available.
Credentials
SKILL.md requires a sensitive environment variable FFHUB_API_KEY (used for Authorization) but the skill metadata does not declare any required env vars or a primary credential. That omission is a significant mismatch. The skill only needs that single API key for its stated purpose, which would be proportionate if declared and handled safely; however, the example to echo the key increases accidental-exfiltration risk.
Persistence & Privilege
The skill does not request always:true and has no install or config path changes. It does not request persistent system privileges or modify other skills' configurations.
如何使用
  1. 确保已安装 OpenClaw(本地或 Docker 部署)
  2. 在对话框中输入安装命令:/install ffhub-ffmpeg
  3. 安装完成后,直接呼叫该 Skill 的名称或使用 /ffhub-ffmpeg 触发
  4. 根据 Skill 的参数说明提供必要输入,即可获得结构化输出
版本历史
v1.0.0
Initial release: cloud FFmpeg processing via FFHub.io API
元数据
Slug ffhub-ffmpeg
版本 1.0.0
许可证 MIT-0
累计安装 0
当前安装数 0
历史版本数 1
常见问题

FFHub FFmpeg Skill 是什么?

Process video/audio files using FFHub.io cloud FFmpeg API. Use when the user wants to convert, compress, trim, resize, extract audio, generate thumbnails, or... 它是一个面向 Claude Code / OpenClaw 的 AI Agent Skill 插件,目前累计下载 347 次。

如何安装 FFHub FFmpeg Skill?

在 OpenClaw 或 Claude Code 对话框中运行命令「/install ffhub-ffmpeg」即可一键安装,无需额外配置。

FFHub FFmpeg Skill 是免费的吗?

是的,FFHub FFmpeg Skill 完全免费,采用 MIT-0 许可证,可自由下载、安装和使用。

FFHub FFmpeg Skill 支持哪些平台?

FFHub FFmpeg Skill 跨平台运行,可在任意部署了 OpenClaw / Claude Code 的环境中使用(cross-platform)。

谁开发了 FFHub FFmpeg Skill?

由 gangbo(@gangbo)开发并维护,当前版本 v1.0.0。

💬 留言讨论