Skip to main content
Glama

Get selection

ae_get_selection
Read-onlyIdempotent

Retrieves the current selection in After Effects—project items, active comp layers, and selected properties with paths—so you can act on "this layer" or "the selected ones".

Instructions

What the user has selected right now: project items, and in the active comp the selected layers and selected properties (with paths usable by ae_set_property). Read-only. Use it when the user says "this layer" or "the selected ones". Lists are empty when nothing is selected, and comp is null when no comp is active. To change the selection use ae_select_layers (via ae_call).

Input Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.6/5.0
Behavior4/5

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

Annotations already declare readOnlyHint, idempotentHint and non-destructive, so the safety profile is covered; the description still adds value by declaring the empty-state semantics (empty lists when nothing is selected, comp null when no comp is active). It leaves the exact return structure undocumented, which with no output schema is a modest gap.

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?

Two dense sentences, front-loaded with what is returned, then when to reach for it, then the redirect to the mutation sibling. No filler and no repetition of annotation metadata beyond a brief 'Read-only' confirmation.

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 no-param read tool with no output schema, the description covers scope, empty-state edge cases, and cross-tool compatibility of returned paths. It could go slightly further on what a 'project item' entry contains, but an agent has everything needed to call it and interpret an empty result.

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?

The tool takes zero parameters, so there is nothing for the description to disambiguate and the baseline applies. The description correctly spends no words on parameter syntax.

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 names the exact resource and its three scopes: project items, selected layers in the active comp, and selected properties. It even states that returned property paths are consumable by ae_set_property, which separates it cleanly from siblings like ae_get_properties or ae_get_layer_info.

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?

It gives a concrete trigger ("when the user says 'this layer' or 'the selected ones'") and routes the inverse operation elsewhere ("To change the selection use ae_select_layers (via ae_call)"). Both when-to-use and what-not-to-use-it-for are explicit.

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