Skip to main content
Glama

Add article media (image or GIF)

add_article_media

Add a screenshot or GIF to the article. It goes right after the block holding the screenshot named in after ("start" for the top), in place of the screenshot named in replace, or else at the end of the article. Returns its screenshot_id (it appears in the article as <SCREENSHOT screenshot_id>) and the new article_version.

  • kind="image": one of timestamp (capture a frame from the project's base video), mcp_upload_id (an uploaded image: mup_… from upload_file, or a Clueso upload_id), source_url (an image URL, e.g. one generate_media returned) or prompt (generate an AI illustration for the article; optional style_id and aspect_ratio, default 16:9). A generated image costs AI credits like generate_media's and takes a few seconds; ask for little or no text in it, since generated text is often misspelled.

  • kind="gif": pass timestamp (start) and duration (seconds). Captures a short GIF clip from the base video. Requires the project to have a video clip. A GIF still rendering after ~20s returns status: "processing" and a job_id: it is added to the article when ready (follow it with get_media_job).

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "kind": "<kind>",
      "project_id": "<project_id>"
    },
    "name": "add_article_media"
  }
}

Input Schema

NameRequiredDescriptionDefault
kindYes'image' or 'gif'.
afterNoPut it right after the block holding this screenshot_id, or 'start' / 'end' (the default).
promptNokind='image' only: generate an AI illustration from this prompt instead of capturing or attaching one.
clip_idNoThe clip this screenshot belongs to (from get_article include_clips). Stamped on the image so the step is tied to its clip.
replaceNoPut it in place of this screenshot_id, wherever that sits; the old one is removed from the article.
durationNokind='gif' only: GIF duration in seconds.
style_idNokind='image' with prompt only: an image style pack ID from find(type='image_gen_style_packs').
timestampNokind='image': capture frame at this timestamp (seconds). kind='gif': GIF start time.
project_idYesProject ID.
source_urlNokind='image' only: an https image URL to download and attach.
aspect_ratioNokind='image' with prompt only: the illustration's shape. Default 16:9.
mcp_upload_idNokind='image' only: attach an uploaded image (mcp_upload_id from upload_file, or a Clueso upload_id) instead of capturing from video.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • addedInput schema / properties / clip_id
      Added value: +{
      +  "description": "The clip this screenshot belongs to (from get_article include_clips). Stamped on the image so the step is tied to its clip.",
      +  "minLength": 1,
      +  "type": "string"
      +}
  2. Changed5 schema fields changed
    • addedInput schema / properties / after
      Added value: +{
      +  "description": "Put it right after the block holding this screenshot_id, or 'start' / 'end' (the default).",
      +  "minLength": 1,
      +  "type": "string"
      +}
    • addedInput schema / properties / aspect_ratio
      Added value: +{
      +  "description": "kind='image' with prompt only: the illustration's shape. Default 16:9.",
      +  "enum": [
      +    "16:9",
      +    "1:1",
      +    "4:3",
      +    "3:4",
      +    "9:16",
      +    "21:9"
      +  ],
      +  "type": "string"
      +}
    • addedInput schema / properties / prompt
      Added value: +{
      +  "description": "kind='image' only: generate an AI illustration from this prompt instead of capturing or attaching one.",
      +  "minLength": 1,
      +  "type": "string"
      +}
    • addedInput schema / properties / replace
      Added value: +{
      +  "description": "Put it in place of this screenshot_id, wherever that sits; the old one is removed from the article.",
      +  "minLength": 1,
      +  "type": "string"
      +}
    • addedInput schema / properties / style_id
      Added value: +{
      +  "description": "kind='image' with prompt only: an image style pack ID from find(type='image_gen_style_packs').",
      +  "type": "string"
      +}
  3. Changed2 schema fields changed
    • changedInput schema / properties / mcp_upload_id / description
      Previous value: -"kind='image' only: attach an uploaded image (mcp_upload_id from the upload tool) instead of capturing from video."New value: +"kind='image' only: attach an uploaded image (mcp_upload_id from upload_file, or a Clueso upload_id) instead of capturing from video."
    • addedInput schema / properties / source_url
      Added value: +{
      +  "description": "kind='image' only: an https image URL to download and attach.",
      +  "format": "uri",
      +  "type": "string"
      +}
  4. Changed4 schema fields changed
    • removedInput schema / properties / context
      Removed value: -{
      -  "description": "Explain in 15-25 words, in third person, why this tool is called and how it supports the user's goal. For analytics only. You MUST describe only the abstract purpose of the tool call. NEVER include, repeat, paraphrase, or infer personal, sensitive, or identifying information from the user request or tool results, including names, emails, phone numbers, IPs, IDs, or credentials. You MUST generalize specific entities into roles such as \"a user\", \"the customer\", or \"an account\". Example: \"Retrieving a customer's recent orders to investigate a billing issue and help support determine the appropriate resolution.\"",
      -  "type": "string"
      -}
    • removedInput schema / properties / conversation_id
      Removed value: -{
      -  "description": "Echo the conversation_id from the server's previous response. The server provides it on the first call — never invent one, and do not issue parallel tool calls until you have it.",
      -  "type": "string"
      -}
    • removedInput schema / properties / llm_model
      Removed value: -{
      -  "description": "The exact model identifier you (the assistant) are running as, taken from your system prompt or environment (e.g. \"claude-opus-4-8\", \"gpt-5.2\"). Used for analytics only. If you do not know your model identifier with certainty, pass \"unknown\" — never guess.",
      -  "type": "string"
      -}
    • changedInput schema / required
      Previous value: -[
      -  "kind",
      -  "project_id",
      -  "context",
      -  "llm_model"
      -]New value: +[
      +  "kind",
      +  "project_id"
      +]
  5. Changed4 schema fields changed
    • addedInput schema / properties / context
      Added value: +{
      +  "description": "Explain in 15-25 words, in third person, why this tool is called and how it supports the user's goal. For analytics only. You MUST describe only the abstract purpose of the tool call. NEVER include, repeat, paraphrase, or infer personal, sensitive, or identifying information from the user request or tool results, including names, emails, phone numbers, IPs, IDs, or credentials. You MUST generalize specific entities into roles such as \"a user\", \"the customer\", or \"an account\". Example: \"Retrieving a customer's recent orders to investigate a billing issue and help support determine the appropriate resolution.\"",
      +  "type": "string"
      +}
    • addedInput schema / properties / conversation_id
      Added value: +{
      +  "description": "Echo the conversation_id from the server's previous response. The server provides it on the first call — never invent one, and do not issue parallel tool calls until you have it.",
      +  "type": "string"
      +}
    • addedInput schema / properties / llm_model
      Added value: +{
      +  "description": "The exact model identifier you (the assistant) are running as, taken from your system prompt or environment (e.g. \"claude-opus-4-8\", \"gpt-5.2\"). Used for analytics only. If you do not know your model identifier with certainty, pass \"unknown\" — never guess.",
      +  "type": "string"
      +}
    • changedInput schema / required
      Previous value: -[
      -  "kind",
      -  "project_id"
      -]New value: +[
      +  "kind",
      +  "project_id",
      +  "context",
      +  "llm_model"
      +]
  6. Changed2 schema fields changed
    • changedInput schema / $schema
      Previous value: -"http://json-schema.org/draft-07/schema#"New value: +"https://json-schema.org/draft/2020-12/schema"
    • removedInput schema / additionalProperties
      Removed value: -false
  7. First observed

TDQS

A4.6/5.0
Behavior5/5

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

Beyond the annotations, the description discloses cost (generated images consume AI credits like generate_media), latency (a few seconds; GIFs may return status="processing" with a job_id after ~20s), a quality caveat about misspelled generated text, and the side effect that `replace` removes the old screenshot. These are the operational facts an agent needs before invoking a mutating call.

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?

Front-loaded with the core action, placement, and return value, then split into two clearly labeled bullets per kind. Dense but every clause carries information; only minor cost from deeply nested parentheticals and identifier examples.

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

Completeness5/5

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

With 12 parameters and no output schema, the description carries return-value information itself (screenshot_id, article_version, the `<SCREENSHOT screenshot_id>` rendering, and the processing/job_id path). Prerequisites, cost, and async behavior are all covered, leaving nothing material an agent would need missing.

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?

Schema coverage is 100%, so baseline would be 3, but the description adds the precedence rule among `after`, `replace`, and default end-of-article placement, plus the dual meaning of `timestamp` per kind, defaults for `aspect_ratio`, and GIF `duration` semantics. That interaction-level meaning is not derivable from the per-field schema text alone.

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 opens with a concrete verb+resource ("Add a screenshot or GIF to the article") and immediately specifies placement semantics and return values. It explicitly separates the two modes (kind="image" vs kind="gif"), so an agent knows exactly what operations this tool covers 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?

It gives per-mode usage rules: `timestamp`/`mcp_upload_id`/`source_url`/`prompt` for images, `timestamp`+`duration` for GIFs, and the prerequisite that GIFs require the project to have a video clip. It also routes the agent to upload_file for `mcp_upload_id`, find(type='image_gen_style_packs') for `style_id`, and get_media_job for polling. It stops short of stating when to prefer this tool over a sibling like update_article_media, so it is not a full when/when-not spec.

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.