Skip to main content
Glama

register_relationship_type

Register a relationship type after discovering the vocabulary with list_relationship_types. Requires an active grant with register_relationship_type and relationship_types permission; global scope additionally needs explicit global…

Instructions

Register a relationship type after discovering the vocabulary with list_relationship_types. Requires an active grant with register_relationship_type and relationship_types permission; global scope additionally needs explicit global permission. Defaults to user scope. Refresh cached tool definitions after registration, then write the edge and read it back.

Input Schema

NameRequiredDescriptionDefault
scopeNoDefaults to "user" — the safe branch. This deliberately inverts register_schema, whose user_specific defaults to false and whose default branch is therefore both the widest blast radius and the one that records no identity.user
acyclicNoENFORCED. When true, create_relationship refuses an edge of this type that would close a loop among edges OF THIS TYPE within this tenant. Opt-in: a type whose semantics permit cycles should leave this unset.
inverseNoAdvisory only. Name of the inverse edge.
symmetricNoAdvisory only. Whether the edge reads the same both ways.
descriptionNo
relationship_typeYesIdentifier-shaped name, 1-64 characters, matching ^[A-Za-z][A-Za-z0-9_]*$. Casing-agnostic. A new name that differs from an existing active type only by case is rejected; the pre-existing PART_OF/part_of and DEPENDS_ON/depends_on pairs are grandfathered.
source_entity_typesNoAdvisory only. Not enforced at write time.
target_entity_typesNoAdvisory only. Not enforced at write time.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv0.25.0

TDQS

A4.1/5.0
Behavior4/5

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

With no annotations, the description carries the full burden and does well: it discloses required grant permissions, scope-dependent global permission, the user-scope default, and the side effect that cached tool definitions must be refreshed afterward. It stops short of describing idempotency or what happens on a name collision.

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?

Front-loads the core purpose and sequencing tightly in three dense sentences. The final clause ('then write the edge and read it back') is useful but reads as slightly run-on; otherwise little waste.

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 mutation tool with no annotations or output schema, the description covers permissions, scope default, and the cache-refresh consequence an agent must know. Reasonably complete, though collision/error behavior is left undocumented.

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

Parameters3/5

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

Schema description coverage is 88%, so the seven optional parameters are already richly documented in the schema, and the description's mention of the user-scope default merely restates it. Baseline 3 is appropriate since the schema does the heavy lifting.

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?

States a specific verb+resource ('Register a relationship type') and distinguishes the operation from siblings like register_schema and create_relationship by naming itself as the vocabulary-definition step. An agent can tell what this does without opening 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?

Gives a clear prerequisite workflow: discover vocabulary via list_relationship_types, then register, then refresh cached definitions, then write/read the edge. It also names the required grants. It does not state when NOT to use it (e.g. when the type already exists), so it falls short of a 5.

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