Skip to main content
Glama

Make component

make_component
Destructive

Make a component shared between screens. ids[0] becomes the main component (or already is one); the other elements, with the same structure (typically the same header, nav or footer copied into other screens), become its instances: what differs between them becomes props. Returns a summary (name, id, instances, props, element count, named layers); html: true adds the component's HTML.

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": {
      "fileId": "<fileId>",
      "ids": "<ids>"
    },
    "name": "make_component"
  }
}

Input Schema

NameRequiredDescriptionDefault
idsYesMain component first, then its copies.
htmlNoAlso return the component's HTML with its data-ids, which did not change: ids returned earlier still apply.
nameNoComponent name, e.g. "AppHeader" (derived by default).
fileIdYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.3/5.0
Behavior4/5

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

Annotations flag this as a mutating, destructive, non-open-world operation, and the description adds real substance beyond that: it explains the restructure into a main component plus instances, that differing attributes become props, and what the returned summary contains. It still leaves open whether the operation is reversible and what happens to the original elements' identities.

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?

The definition front-loads the core action and packs the id-ordering rule, prop behavior, and return shape into a compact block with no filler. It is dense—one long sentence carries most of the mechanics—but every clause carries information.

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 no output schema, the description helpfully enumerates the returned summary fields (name, id, instances, props, element count, named layers). Only fileId is left unexplained, a minor gap for an otherwise self-contained definition of a moderately complex mutation.

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 75% and the schema already states 'Main component first, then its copies', so the ordering rule is partly redundant. The description nonetheless adds meaning about the consequences of that ordering (main vs instances, prop extraction) and clarifies what html:true returns, exceeding the baseline for high-coverage schemas.

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 first sentence gives a specific verb+resource ('Make a component shared between screens') and the rest explains the exact transformation: ids[0] becomes the main component, the remaining ids become instances, and differences become props. That mechanism distinguishes it from mutation siblings like detach_instance or make_template without needing to inspect the schema.

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?

It supplies a clear usage cue: the elements should share structure, 'typically the same header, nav or footer copied into other screens'. It stops short of naming an alternative or stating when not to use it, so there are no explicit exclusions.

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.