Skip to main content
Glama
Mipiti
by Mipiti

Add Component

add_component

Add a component to a threat model to map trust boundaries to repository code, enabling scoped security controls and asset-boundary derivation.

Instructions

Add a component to a threat model.

Components bridge security architecture to code organization. They map trust boundaries to repos so controls can be scoped to the codebase that implements them. They also drive the deterministic reachability composer's asset-boundary derivation: an asset's trust-boundary footprint is the union of its components' trust_boundary_ids.

Generation reads no components, so add or edit them after generate_threat_model, not before.

A component with empty repo_url is either speculative (your own code, not linked to a repo yet) or external (e.g. a third-party service, the customer's IdP, or other external infrastructure you call but don't own). The component's trust boundary tells them apart: bind an internal-zone component to its repo via edit_component; leave an external-zone component unbound — its component_unbound finding is a permanent external-dependency marker, not a gap to close. Binding by "some client code touches it" is wrong: client code for external dependencies lives in your repo too.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
nameYesComponent name (e.g., "Backend API", "Auth Worker").
pathNoPath within repo for monorepos (e.g., "services/auth").
model_idYesID of the threat model.
repo_urlNoRepository URL (e.g., "github.com/org/backend"). Empty string is valid for speculative components — pass a real URL once you've identified the codebase.
server_versionYes
trust_boundary_idsNoComma-separated trust boundary IDs that this component spans (its deployment zone). Drives reach decisions for any asset scoped to this component.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv0.62.2
  2. Removedv0.62.1
  3. First observedv0.57.0

TDQS

A4.5/5.0
Behavior4/5

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

No annotations are provided, so the description carries the full burden. It discloses important behavioral traits: the tool's relationship to generation (must be called after generate_threat_model), the meaning of empty repo_url, and the permanent external-dependency marker behavior of component_unbound findings. It doesn't explicitly state side effects like whether it overwrites existing components or requires specific permissions, but the disclosed context is substantial.

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 description is moderately long but every sentence earns its place. It front-loads the core purpose, then provides essential context about components, generation ordering, and the repo_url/trust boundary semantics. The structure is logical, though the final warning about client code could be seen as slightly tangential.

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?

Given the tool's complexity (6 params, output schema present, many siblings), the description is quite complete. It covers the tool's role, when to use it, key parameter semantics, and common pitfalls. It doesn't describe the return value, but an output schema exists, so that's not required. It could mention prerequisites like needing a valid model_id, but that's likely implied by the schema.

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 description coverage is 83%, so the schema already documents most parameters well. The description adds meaning beyond the schema by explaining the semantic distinction between speculative and external components (empty repo_url) and how trust_boundary_ids drive reach decisions. It doesn't add detail for every parameter, but the schema covers them adequately.

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: 'Add a component to a threat model.' It goes beyond a simple definition by explaining what components are, how they relate to trust boundaries and repos, and how they drive the reachability composer. This distinguishes it from sibling tools like edit_component and add_trust_boundary.

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?

The description provides explicit usage guidance: 'Generation reads no components, so add or edit them after generate_threat_model, not before.' It also explains when a component with empty repo_url is speculative vs external, and explicitly warns against a common mistake ('Binding by "some client code touches it" is wrong'). This is strong, actionable guidance.

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

Deploy Server

Other Tools