Skip to main content
Glama

Preview a component

preview_component
Read-onlyIdempotent

Look at a contact sheet of one custom component on its own, without placing it in the film: the component alone at the film's size and its own place, on a plain background, from startSeconds to endSeconds of its own time. Use after replace_component, patch_component or scaffold_component to watch it enter, move and leave; pass params to try other input values. The answer is laid out as preview_range's: its previewId, each tile's time (the component's own seconds) and the image; read the pixels. region, grid, annotate, overlays and loupes work as in preview_range. Changes nothing.

Input Schema

NameRequiredDescriptionDefault
gridYesDraw a labelled grid and edge rulers to read coordinates off the picture: in source pixels (of the front video or image clip), film pixels (centre origin) or film_norm. null or none draws none.
nameYesThe custom component's class name, as replace_component names it, or its Asset ID.
detailYesHow much the answer says: brief is one line per result with its ids; normal (null) adds the transform; full adds every matrix of the chain.
loupesYesA magnified inset around a point with a crosshair, for checking a corner to the pixel. The point may be in any space (type point).
paramsYesThe component's inputs for this preview, each as name and value. Inputs left out keep their defaults. null (or leaving it out) draws every input at its default.
regionYesThe part of the frame to draw, as [x0, y0, x1, y1]: its top left and bottom right corners as fractions of the frame from the frame's top left (0 to 1, at least 0.02 apart). Example: [0.5, 0, 1, 0.5] is the top right quarter. The scene draws only this region, at the image's full size and a higher resolution, so small text, logos, thin lines and edges show real detail instead of an enlarged frame. The image has the region's shape. With space, the corners are in that space instead (preview pixels with previewId, film pixels, a clip's source pixels with clipId) and the region is the box around them on the frame. null (or leaving it out) draws the whole frame.
annotateYesYour own points, boxes, quads, lines or polygons drawn on the frame in any space, to check them before you commit: e.g. the four corners you think a sign has, in source pixels. null draws none.
gridStepYesGrid spacing in the grid's own units. null picks a step that keeps the labels legible (see gridDensity).
overlaysYesWhat to outline on every frame: tracks (each object track on screen, a plane's corners numbered 0 to 3), pins (each <pin>'s corners), follows (each <follow>'s anchor), regions (each region's box), safeAreas (TikTok, Reels and Shorts safe areas), clipBounds (each clip's picture after fit, with its id), crop (what a cover fit cuts off), occluders (the box of what passes in front of each tracked surface, from track_occluders). null outlines nothing.
projectIdYesThe project this call runs on without changing the open project. null (or leaving it out) uses the open project. wait_for_jobs takes the projectId of the calls that started the jobs.
backgroundYesCSS colour behind the component, such as #00ff00 or white. null (or leaving it out) uses the film's background.
endSecondsYesThe last second of the component's own time to draw, after startSeconds. The component is drawn as a clip of this length: atTime's duration is endSeconds.
gridDensityYesHow close the grid lines are when gridStep is null: sparse, normal (null) or dense.
startSecondsYesThe first second of the component's own time to draw: atTime's time, 0 where its clip starts.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4.3/5.0
Behavior4/5

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

Annotations already declare readOnly/idempotent/non-destructive, and 'Changes nothing' is consistent with them rather than contradicting. Beyond that it discloses the return shape (previewId, per-tile component-own seconds, images, 'read the pixels'), which a readOnly flag alone would not tell an agent, though latency/cost of rendering a range is unmentioned.

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 what it is and when to use it, then the return shape, then the delegated parameters, then the safety note. Some clauses are dense ('the component alone at the film's size and its own place, on a plain background, from startSeconds to endSeconds of its own time'), but nothing is filler.

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?

With 14 required parameters, no output schema, and only readOnly-style annotations, the description carries the load well: it explains the answer's layout and how to read it, the default behavior of params and background, and delegates the shared rendering options. It stops short of stating resolution/tile-count limits or failure modes for a bad component name.

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 the baseline is 3, but the description adds real meaning: startSeconds/endSeconds are the component's OWN time (not timeline seconds), params override defaults for other input values, and region/grid/annotate/overlays/loupes are delegated to preview_range semantics instead of being re-explained. That own-time framing is the kind of ambiguity the schema alone would leave.

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?

Opens with a specific verb and resource: look at a contact sheet of one custom component on its own, without placing it in the film, and specifies the framing (film's size, own place, plain background, own time range). It separates itself from preview_range (whose layout it borrows) and from the mutation siblings named in the usage sentence.

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?

Gives an explicit trigger: 'Use after replace_component, patch_component or scaffold_component to watch it enter, move and leave; pass params to try other input values.' That is a clear when, but there is no explicit when-not or a statement of which sibling to pick when you want the component in the film context versus alone.

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.