Skip to main content
Glama

get_selection

Read-only

Get the current selection on the active Figma page, returning page ID/name and selected nodes with their full properties. Use it to identify what the user is looking at before deeper node context.

Instructions

Return the current selection on the active Figma page: { pageId, pageName, nodes }, where each node is a full flat serialization — geometry, fills/strokes/effects, text properties, style/variable ids, mainComponent — without children. The zero-argument "what is the user looking at" call: use it to identify the selected node ids (and page), then walk deeper with get_design_context or get_node. An empty nodes array means nothing is selected.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Behavior4/5

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

The readOnlyHint annotation already signals safety, but the description adds valuable behavioral context: the return structure, that nodes are full flat serializations without children, and the meaning of an empty array. This goes beyond what the annotation alone provides, though it does not describe potential error conditions or pagination, which are less relevant for a selection getter.

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 well-structured and concise: it opens with the core action, then explains the return format and node content, and closes with usage guidance and edge-case semantics. Every sentence contributes meaningful information without redundancy.

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 simple, parameterless, read-only tool with no output schema, the description is complete: it explains the output shape, the level of detail in nodes, the workflow relationship to other tools, and the empty-selection case. There is no missing information that would prevent an agent from using it correctly.

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 has zero parameters, so the baseline is 4. The description reinforces this by calling it 'zero-argument' and provides no parameter details, which is appropriate since there are no parameters to document. The schema already fully covers the empty parameter set.

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 clearly states the tool's function: 'Return the current selection on the active Figma page' and specifies the exact output shape ({ pageId, pageName, nodes }). It distinguishes itself from siblings by noting it is the zero-argument 'what is the user looking at' call and explicitly points to get_design_context/get_node for deeper traversal.

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 provides explicit usage guidance: 'use it to identify the selected node ids (and page), then walk deeper with get_design_context or get_node.' This explains when to use this tool versus alternatives, and also clarifies the empty nodes array case, giving clear context for invocation.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/awdr74100/figwright'

If you have feedback or need assistance with the MCP directory API, please join our Discord server