Skip to main content
Glama

Add image layer

add_image_layer

Add an image layer. The asset must already be uploaded (the editor's drag-drop, upload_image, create_upload_link, or POST /api/upload-asset/ with the raw bytes and an X-Upload-Name header). Every upload returns { filename, name }: pass filename (the stored file's id) here, and name as the layer's label. To duplicate an existing layer, reuse its filename — the editor auto-assigns a fresh id.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
xYesCentre x in 1080-wide base coords.
yYesCentre y in 1920-tall base coords.
nameNoOptional label people see in the Inspector and Timeline: pass the upload's returned `name`. Without it the layer is labelled by an older project's own filename, or by kind; never by a stored id.
blockNoOPTIONAL timeline window — {start, duration} in composition frames. OMIT IT (the default) and the layer is ALWAYS PRESENT: a persistent overlay that holds for the whole composition, which is what an agent-placed watermark / lower-third almost always wants. Pass it to place a bounded CLIP instead (what the editor's own add does: 5 s at the playhead). Keyframes on a blocked layer are sampled RELATIVE to `start`.
widthYesWidth in px (must be > 0).
heightYesHeight in px (must be > 0).
filenameYesThe stored filename an upload returned (an id such as 3f2a9c1e-….png, or an older project's own name).
projectIdYesOpaque project id (a v4 UUID, from list_projects/create_project). Selects which existing project this call mutates.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
okYesWhether the call succeeded.
dataNoThe payload, shaped by the tool.
noteNoWhat to do next when not ready.
errorNoWhy it failed.
statusNoFor cache-backed readers: whether the answer was ready.
editorUrlNoOpens this project in the editor.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed2 schema fields changed
    • changedInput schema / properties / filename / description
      Previous value: -"Asset filename in the project's assets bucket, e.g. star.png."New value: +"The stored filename an upload returned (an id such as 3f2a9c1e-….png, or an older project's own name)."
    • addedInput schema / properties / name
      Added value: +{
      +  "description": "Optional label people see in the Inspector and Timeline: pass the upload's returned `name`. Without it the layer is labelled by an older project's own filename, or by kind; never by a stored id.",
      +  "type": "string"
      +}
  2. Changed2 schema fields changed
    • removedInput schema / properties / anonymousToken
      Removed value: -{
      -  "description": "The token create_anonymous_account returned. This connection has no Morpha key, so every call carries it.",
      -  "type": "string"
      -}
    • changedInput schema / required
      Previous value: -[
      -  "filename",
      -  "x",
      -  "y",
      -  "width",
      -  "height",
      -  "projectId",
      -  "anonymousToken"
      -]New value: +[
      +  "filename",
      +  "x",
      +  "y",
      +  "width",
      +  "height",
      +  "projectId"
      +]
  3. Changed1 schema field changed
    • changedOutput schema / (root)
      Previous value: -nullNew value: +{
      +  "description": "The result envelope every Morpha tool returns.",
      +  "properties": {
      +    "data": {
      +      "description": "The payload, shaped by the tool.",
      +      "type": [
      +        "object",
      +        "array",
      +        "string",
      +        "number",
      +        "boolean",
      +        "null"
      +      ]
      +    },
      +    "editorUrl": {
      +      "description": "Opens this project in the editor.",
      +      "type": "string"
      +    },
      +    "error": {
      +      "description": "Why it failed.",
      +      "type": "string"
      +    },
      +    "note": {
      +      "description": "What to do next when not ready.",
      +      "type": "string"
      +    },
      +    "ok": {
      +      "description": "Whether the call succeeded.",
      +      "type": "boolean"
      +    },
      +    "status": {
      +      "description": "For cache-backed readers: whether the answer was ready.",
      +      "enum": [
      +        "ready",
      +        "not-ready"
      +      ],
      +      "type": "string"
      +    }
      +  },
      +  "required": [
      +    "ok"
      +  ],
      +  "type": "object"
      +}
  4. Changed2 schema fields changed
    • addedInput schema / properties / anonymousToken
      Added value: +{
      +  "description": "The token create_anonymous_account returned. This connection has no Morpha key, so every call carries it.",
      +  "type": "string"
      +}
    • changedInput schema / required
      Previous value: -[
      -  "filename",
      -  "x",
      -  "y",
      -  "width",
      -  "height",
      -  "projectId"
      -]New value: +[
      +  "filename",
      +  "x",
      +  "y",
      +  "width",
      +  "height",
      +  "projectId",
      +  "anonymousToken"
      +]
  5. First observed

TDQS

A5/5.0
Behavior5/5

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

Annotations indicate readOnlyHint=false and destructiveHint=false, so the description adds value by detailing the mutation: it adds a layer. It explains the behavioral difference between omitting the block parameter (persistent overlay) and passing it (bounded clip), and notes keyframe sampling relative to start. No contradiction with annotations.

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

Conciseness5/5

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

The description is detailed but every sentence adds value. It front-loads the core action, then provides necessary upload context and behavioral options. No redundancy or fluff.

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?

Given the tool's complexity (8 parameters, nested block object, upload prerequisite), the description covers all essential context: how to obtain the asset, how to map upload returns to parameters, and the behavioral choice of persistent vs. bounded layer. An output schema exists, so return values need not be in the description.

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

Parameters5/5

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

Schema coverage is 100%, but the description goes beyond schema by linking `filename` to the upload's returned id and `name` to the label, and explaining the block parameter's default behavior and its impact on keyframes. This adds meaningful context not present in the schema 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?

States a specific verb ('Add') and resource ('image layer'), clearly distinguishing it from sibling tools like add_video_layer and add_text_layer. It also explains the required precondition (uploaded asset), which sharpens the tool's purpose.

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

Usage Guidelines5/5

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

Explicitly explains when to use this tool: after an asset is uploaded, and lists the available upload methods (drag-drop, upload_image, create_upload_link, or API endpoint). It also explains how to duplicate an existing layer by reusing its filename, giving concrete usage scenarios. No confusion with other add tools.

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