Skip to main content
Glama

Media Upload, Auto-Fit Video & Clip Pipeline

media_pipeline
Idempotent

Execute media ingestion, zero-egress storage uploads, automatic multi-aspect-ratio video reframing (9:16, 16:9, 1:1, 4:5), viral short clip extraction with burned-in captions, and AI visual asset generation (media_generate). Use this tool before posts_publish whenever a campaign requires uploading video/image files or converting a single landscape video into vertical Reels, TikToks, and YouTube Shorts. Returns presigned PUT upload URLs, zero-egress CDN URLs, transcoded aspect-ratio variant maps, or extracted clip URLs.

Input Schema

NameRequiredDescriptionDefault
actionYesMedia pipeline operation: 'presign_upload' creates a signed direct PUT upload URL (no Authorization header needed, single use, 15 min), 'upload_base64' uploads a file inline (fileName, mimeType/contentType, dataBase64; max 20 MB), 'auto_fit_video' reframes video into target aspect ratios with -14 LUFS audio normalization, 'extract_clips' cuts viral vertical highlights, 'media_generate' renders social visuals from a prompt, and 'check_status' polls transcode progress.
promptNoCreative prompt or visual template instructions when running `action: 'media_generate'` (e.g. 'Minimalist B2B architecture diagram for MCP server launch').
fileNameNoOriginal file name with extension (e.g. 'keynote-demo.mp4' or 'launch-carousel.png') when requesting a presigned upload URL.
mimeTypeNoMIME type of the media asset being uploaded or generated (e.g. 'video/mp4', 'image/png', 'image/jpeg', 'image/svg+xml').video/mp4
clipCountNoNumber of short highlight clips (1 to 10) to extract from a long-form source video when `action` is 'extract_clips'.
profileIdNoBrand profile identifier (`prof_...`) that owns the media asset.prof_allometrik
sizeBytesNoFile size in bytes used to validate upload quotas and allocate storage buffers.
dataBase64NoBase64-encoded file bytes for 'upload_base64' (max 20 MB decoded).
contentTypeNoMIME type for 'upload_base64' (alias of mimeType), e.g. 'image/jpeg'.
mediaAssetIdNoExisting media asset identifier (`med_...`) to reframe, extract clips from, or inspect status.
targetAspectRatiosNoTarget aspect ratios for automatic video/image reframing: '9:16' (Reels/TikTok/Shorts), '16:9' (X/LinkedIn/YouTube), '1:1' (Square), '4:5' (Portrait Feed).

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed4 schema fields changed
    • changedInput schema / properties / action / description
      Previous value: -"Media pipeline operation: 'presign_upload' creates a direct PUT upload URL, 'auto_fit_video' reframes video into target aspect ratios with -14 LUFS audio normalization, 'extract_clips' cuts viral vertical highlights, 'media_generate' renders social visuals from a prompt, and 'check_status' polls transcode progress."New value: +"Media pipeline operation: 'presign_upload' creates a signed direct PUT upload URL (no Authorization header needed, single use, 15 min), 'upload_base64' uploads a file inline (fileName, mimeType/contentType, dataBase64; max 20 MB), 'auto_fit_video' reframes video into target aspect ratios with -14 LUFS audio normalization, 'extract_clips' cuts viral vertical highlights, 'media_generate' renders social visuals from a prompt, and 'check_status' polls transcode progress."
    • changedInput schema / properties / action / enum
      Previous value: -[
      -  "presign_upload",
      -  "auto_fit_video",
      -  "extract_clips",
      -  "media_generate",
      -  "check_status"
      -]New value: +[
      +  "presign_upload",
      +  "upload_base64",
      +  "auto_fit_video",
      +  "extract_clips",
      +  "media_generate",
      +  "check_status"
      +]
    • addedInput schema / properties / contentType
      Added value: +{
      +  "description": "MIME type for 'upload_base64' (alias of mimeType), e.g. 'image/jpeg'.",
      +  "type": "string"
      +}
    • addedInput schema / properties / dataBase64
      Added value: +{
      +  "description": "Base64-encoded file bytes for 'upload_base64' (max 20 MB decoded).",
      +  "type": "string"
      +}
  2. Changed15 schema fields changed
    • addedInput schema / additionalProperties
      Added value: +false
    • addedInput schema / properties / action / description
      Added value: +"Media pipeline operation: 'presign_upload' creates a direct PUT upload URL, 'auto_fit_video' reframes video into target aspect ratios with -14 LUFS audio normalization, 'extract_clips' cuts viral vertical highlights, 'media_generate' renders social visuals from a prompt, and 'check_status' polls transcode progress."
    • addedInput schema / properties / clipCount / default
      Added value: +3
    • addedInput schema / properties / clipCount / description
      Added value: +"Number of short highlight clips (1 to 10) to extract from a long-form source video when `action` is 'extract_clips'."
    • addedInput schema / properties / fileName / description
      Added value: +"Original file name with extension (e.g. 'keynote-demo.mp4' or 'launch-carousel.png') when requesting a presigned upload URL."
    • addedInput schema / properties / mediaAssetId / description
      Added value: +"Existing media asset identifier (`med_...`) to reframe, extract clips from, or inspect status."
    • addedInput schema / properties / mimeType / default
      Added value: +"video/mp4"
    • addedInput schema / properties / mimeType / description
      Added value: +"MIME type of the media asset being uploaded or generated (e.g. 'video/mp4', 'image/png', 'image/jpeg', 'image/svg+xml')."
    • addedInput schema / properties / profileId / default
      Added value: +"prof_allometrik"
    • addedInput schema / properties / profileId / description
      Added value: +"Brand profile identifier (`prof_...`) that owns the media asset."
    • changedInput schema / properties / prompt / description
      Previous value: -"Prompt or template spec for media_generate add-on"New value: +"Creative prompt or visual template instructions when running `action: 'media_generate'` (e.g. 'Minimalist B2B architecture diagram for MCP server launch')."
    • addedInput schema / properties / sizeBytes / default
      Added value: +10485760
    • addedInput schema / properties / sizeBytes / description
      Added value: +"File size in bytes used to validate upload quotas and allocate storage buffers."
    • addedInput schema / properties / targetAspectRatios / default
      Added value: +[
      +  "9:16",
      +  "16:9"
      +]
    • addedInput schema / properties / targetAspectRatios / description
      Added value: +"Target aspect ratios for automatic video/image reframing: '9:16' (Reels/TikTok/Shorts), '16:9' (X/LinkedIn/YouTube), '1:1' (Square), '4:5' (Portrait Feed)."
  3. First observed

TDQS

A4.1/5.0
Behavior4/5

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

Annotations already declare readOnly=false, destructive=false, idempotent=true, openWorld=true, so the safety profile is covered. The description still adds real value by disclosing the shape of the outputs (presigned PUT URLs, zero-egress CDN URLs, variant maps, clip URLs) where no output schema exists, and by flagging the zero-egress storage trait; it stops short of permissions, quotas, or transcode latency.

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

Conciseness4/5

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

Three sentences ordered as capabilities, then when-to-use, then return values — front-loaded and purposeful. The first sentence is dense with marketing-flavored phrasing ('viral short clip extraction with burned-in captions') that could be trimmed, but nothing is genuinely wasted.

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

Completeness4/5

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

For a six-action, eleven-parameter mutation tool with no output schema, the description covers what it does, when to call it, and what comes back. Remaining gaps are per-action prerequisites and quota/rate behavior, though the action enum in the schema partially compensates.

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?

Schema description coverage is 100% and all 11 parameters (including the action enum and per-action requirements) are documented in the schema itself. The description only restates the aspect-ratio list and echoes `media_generate` as a prompt-driven action, adding essentially nothing beyond structured data, so the baseline 3 applies.

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?

Names specific verbs and resources: media ingestion, zero-egress storage uploads, multi-aspect-ratio video reframing, clip extraction, and AI visual asset generation, plus the concrete aspect ratios and the `media_generate` sub-action. An agent can tell this apart from posts_publish and the other siblings without opening the schema.

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

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Explicitly states the moment of use: 'before `posts_publish` whenever a campaign requires uploading video/image files or converting a single landscape video into vertical Reels, TikToks, and YouTube Shorts.' That gives a clear triggering condition and a relative ordering versus a named sibling, but there is no when-not guidance (e.g., what to do if the asset already exists or when to prefer another upload path).

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources