Skip to main content
Glama

get_macro_block

Read-onlyIdempotent

Retrieve one section of a compiled macro block blueprint by ID or content hash, then follow cursor links for full results. Use designId to pin aliases to a session registry.

Instructions

Retrieve one section of a compiled macro block blueprint (manifest, structure, slots, ports, rules, dependencies, provenance). Follow next cursors until complete. Optional designId pins aliases to that session registry.

Input Schema

NameRequiredDescriptionDefault
idNoAlternative block identifier alias matching idOrRef.
nameNoAlternative block identifier alias matching idOrRef.
cursorNoPagination cursor for large section reads exceeding packet limits.
idOrRefNoCanonical macro block ID or SHA-256 content reference hash.
sectionNoSpecific block section to retrieve: "all", "manifest", "structure", "slots", "ports", "rules", "dependencies", or "provenance". Defaults to "all".
designIdNoActive design session ID to retrieve session-bound block variants.
componentIdNoAlternative block identifier alias matching idOrRef.
environmentNoTarget environment (defaults to html).

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed9 schema fields changedv1.8.0
    • addedInput schema / properties / componentId
      Added value: +{
      +  "description": "Alternative block identifier alias matching idOrRef.",
      +  "maxLength": 80,
      +  "minLength": 1,
      +  "type": "string"
      +}
    • addedInput schema / properties / cursor / description
      Added value: +"Pagination cursor for large section reads exceeding packet limits."
    • addedInput schema / properties / designId / description
      Added value: +"Active design session ID to retrieve session-bound block variants."
    • addedInput schema / properties / environment
      Added value: +{
      +  "description": "Target environment (defaults to html).",
      +  "enum": [
      +    "html",
      +    "astro",
      +    "react",
      +    "vue",
      +    "svelte"
      +  ],
      +  "type": "string"
      +}
    • addedInput schema / properties / id / description
      Added value: +"Alternative block identifier alias matching idOrRef."
    • addedInput schema / properties / idOrRef / description
      Added value: +"Canonical macro block ID or SHA-256 content reference hash."
    • addedInput schema / properties / name
      Added value: +{
      +  "description": "Alternative block identifier alias matching idOrRef.",
      +  "maxLength": 80,
      +  "minLength": 1,
      +  "type": "string"
      +}
    • addedInput schema / properties / section / description
      Added value: +"Specific block section to retrieve: \"all\", \"manifest\", \"structure\", \"slots\", \"ports\", \"rules\", \"dependencies\", or \"provenance\". Defaults to \"all\"."
    • changedInput schema / properties / section / enum
      Previous value: -[
      -  "manifest",
      -  "structure",
      -  "slots",
      -  "ports",
      -  "rules",
      -  "dependencies",
      -  "provenance"
      -]New value: +[
      +  "all",
      +  "manifest",
      +  "structure",
      +  "slots",
      +  "ports",
      +  "rules",
      +  "dependencies",
      +  "provenance"
      +]
  2. Changed2 schema fields changedv1.6.2
    • addedInput schema / properties / id
      Added value: +{
      +  "maxLength": 80,
      +  "minLength": 1,
      +  "type": "string"
      +}
    • removedInput schema / required
      Removed value: -[
      -  "idOrRef",
      -  "section"
      -]
  3. Addedv1.4.0

TDQS

A3.9/5.0
Behavior4/5

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

Annotations already declare readOnly/idempotent/non-destructive/openWorld=false, so the safety profile is covered. The description adds real behavioral context beyond that: pagination requires cursor iteration to completion, and designId pins alias resolution to a session registry. It stops short of describing return shape or the alias-resolution rules without designId.

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?

Three tight sentences with zero filler, front-loading the core action and resource before the pagination and session nuances. Nothing is repeated from the schema and every sentence carries distinct 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?

There is no output schema, so the description must carry return expectations, and it does by naming the sections and the cursor-following requirement. It does not clarify that id/name/componentId are mutually exclusive aliases of idOrRef, but the schema attests to that, leaving only a minor gap for an 8-param, 0-required tool.

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?

With 100% schema coverage the baseline is 3, but the description adds meaning beyond the schema: it explains that designId pins aliases to that specific session registry, clarifying the interaction between the alias params and the session param, and frames cursor usage as an iterative loop rather than a one-shot field.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb (Retrieve) and resource (one section of a compiled macro block blueprint), and enumerates the sections so an agent knows the granularity of the read. It does not explicitly name sibling tools like search_macro_blocks or list_blocks, so it is distinguishable but without direct sibling routing.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Provides operational guidance for pagination ('Follow next cursors until complete') and notes the optional designId behavior, but never states when to choose this over search_macro_blocks or list_blocks, or when a single read is preferred over a search. Usage is implied rather than scoped.

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