Skip to main content
Glama
sharafutdinovdi

Revit Model MCP

List Relations

revit_list_relations
Read-onlyIdempotent

Query Revit model dependencies by relation type—level-rooms, area-scheme-elements, view-template-dependents, group-elements, or nested-family—and get associated elements with IDs, names, categories, families, and types.

Instructions

Read model object membership or dependencies.

Returns data with relation, source and elements containing IDs, names, categories, families and types; no related objects return elements=[]. relation is required: level-rooms, area-scheme-elements or view-template-dependents with source_name, or group-elements or nested-family with source_id. Obtain source names from revit_list_catalog and IDs from element queries. An invalid relation, missing or wrong source, missing document, read failure or timeout raises an error; partial data is not returned.

If more than one Revit instance is running, document is required; otherwise any instance may respond.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
documentNoCase-insensitive substring of the target active document title or file name; default null leaves requests unaddressed, so any instance may respond. Use a unique substring with multiple instances; revit_list_instances instead returns all matching instances, or all instances when omitted.
relationYes
source_idNoPositive integer Revit ID of the source group for group-elements or family instance for nested-family. Default null is valid for name-based relations; these two ID-based relations require a value.
source_nameNoExact, case-insensitive source name: a level for level-rooms, area scheme for area-scheme-elements, or view template for view-template-dependents. Default null is valid for ID-based relations; name-based relations require a value from the catalog.
timeout_secondsNoPositive integer seconds to wait for a result after pickup (120 when omitted); HTTP uses this as its response budget. Expiry raises an error, and increasing it does not override the add-in's execution limits.
pickup_timeout_secondsNoPositive integer seconds to wait for the add-in to pick up a local or SSH job (300 when omitted); ignored over HTTP. A pickup timeout raises an error but the pending job may still execute later.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed5 schema fields changedv0.1.1
    • addedInput schema / properties / document / description
      Added value: +"Case-insensitive substring of the target active document title or file name; default null leaves requests unaddressed, so any instance may respond. Use a unique substring with multiple instances; revit_list_instances instead returns all matching instances, or all instances when omitted."
    • addedInput schema / properties / pickup_timeout_seconds / description
      Added value: +"Positive integer seconds to wait for the add-in to pick up a local or SSH job (300 when omitted); ignored over HTTP. A pickup timeout raises an error but the pending job may still execute later."
    • addedInput schema / properties / source_id / description
      Added value: +"Positive integer Revit ID of the source group for group-elements or family instance for nested-family. Default null is valid for name-based relations; these two ID-based relations require a value."
    • addedInput schema / properties / source_name / description
      Added value: +"Exact, case-insensitive source name: a level for level-rooms, area scheme for area-scheme-elements, or view template for view-template-dependents. Default null is valid for ID-based relations; name-based relations require a value from the catalog."
    • addedInput schema / properties / timeout_seconds / description
      Added value: +"Positive integer seconds to wait for a result after pickup (120 when omitted); HTTP uses this as its response budget. Expiry raises an error, and increasing it does not override the add-in's execution limits."
  2. First observed

TDQS

A5/5.0
Behavior5/5

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

Beyond the readOnlyHint/idempotentHint annotations, the description discloses empty-result behavior (elements=[]), strict error conditions for invalid relation/source/document/read failure/timeout, and promises no partial data. It also reveals the multi-instance routing behavior, adding meaningful context that annotations alone do not provide.

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-organized, front-loads the core purpose, and every sentence adds information: return format, required relation choices, source lookup guidance, error behavior, and multi-instance caveats. Despite covering many details, it remains compact and scannable.

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?

Given the tool's moderate complexity, an output schema, and rich parameter descriptions, the definition covers all necessary invocation details: valid relations, source requirements, timeouts, document routing, return shape, and failure semantics. Nothing an agent needs to call this correctly is missing.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The input schema leaves relation as a plain string, but the description defines the valid relation values and pairs each with the required source parameter (source_name or source_id). It also clarifies that source names come from revit_list_catalog and IDs from element queries, adding substantial meaning beyond the schema's property descriptions.

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 opens with a specific operation (read model object membership or dependencies) and enumerates the exact relation types (level-rooms, area-scheme-elements, view-template-dependents, group-elements, nested-family), which clearly separates it from sibling query tools. It also describes the returned data shape, leaving no doubt about what the tool does.

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 explicit direction on when to use name-based versus ID-based relations, instructs where to obtain source names (revit_list_catalog) and IDs (element queries), and explains the document parameter's role with multiple instances, even pointing to revit_list_instances as an alternative. This is actionable guidance that helps an agent select and invoke the tool correctly.

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