Skip to main content
Glama

Apply layer template to clips

apply_layer_template
Destructive

Applies a layer template to selected or all clips in a project, fitting layers to each clip's length and setting its intro/outro; choose replace or add mode and optionally re-render now.

Instructions

Write a template onto clips of one project (up to 200 clipIds, or all): its layers fitted to each clip's length, and the intro / outro it sets as each clip's own. Not linked afterwards. mode replace (default) swaps the clips' layers, add keeps them and adds. rerender true re-renders finished clips now, else the next render shows them. update_project settings.layerTemplateId only affects clips created later. Returns { updated, rerendered, skipped: [{ clipId, reason }], layersSkipped, bumpers: slots set }

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": {
      "templateId": "<templateId>",
      "projectId": "<projectId>"
    },
    "name": "apply_layer_template"
  }
}

Input Schema

NameRequiredDescriptionDefault
modeNo"replace" (default) = the template becomes the clip's layers; "add" = its layers join the ones the clip already hasreplace
clipIdsNoClip ids of that project (get_project), 1-200; omitted = every clip of the project
rerenderNotrue = re-render the affected finished clips now; false = the layers show on their next render
projectIdYesProject the clips belong to (list_projects)
templateIdYesLayer template id (list_layer_templates)

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv0.51.1
    • changedInput schema / $schema
      Previous value: -"http://json-schema.org/draft-07/schema#"New value: +"https://json-schema.org/draft/2020-12/schema"
  2. Addedv0.23.0

TDQS

A4.5/5.0
Behavior4/5

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

With only destructiveHint=true supplied, the description carries real weight and delivers: it discloses that the applied data is 'not linked afterwards' (no ongoing sync), that replace swaps existing layers (the destructive act), and that rerender controls whether finished clips are reprocessed now. It does not cover permissions or rate/scale behavior, but the mutation surface is well described.

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?

Compact and front-loaded: the action and scope come first, then mode, then rerender, then the caveat about settings, then the return shape. Telegraphic phrasing ('Not linked afterwards.', 'else the next render shows them') is dense but each clause carries distinct information.

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?

For a 5-parameter mutation tool with no output schema, the description closes both gaps: it documents the return payload inline ({ updated, rerendered, skipped, layersSkipped, bumpers }) and covers side effects, linkage, and deferred rendering. Nothing an agent needs in order to call it correctly is 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; the description still adds value by spelling out the consequence of each switch (replace destroys existing layers, add preserves them; rerender now vs next render) and the 200-clip ceiling. Some of this echoes the schema, but the behavioral meaning of mode and rerender beyond the field text is a genuine addition.

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 and resource ('Write a template onto clips of one project'), gives the batch bound (up to 200 clipIds, or all), and clarifies the resulting artifacts (layers fitted to clip length, intro/outro as the clip's own). An agent can distinguish this from settings-level template assignment, which the description explicitly separates.

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?

Explains the operative switches: mode replace vs add, and rerender true vs deferring to the next render. It also flags the key routing rule that update_project settings.layerTemplateId only affects clips created later, which steers the agent to this tool for existing clips. It does not name a sibling alternative outright, but the conditions for use are clear.

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

Deploy Server

Other Tools