Skip to main content
Glama
Mipiti
by Mipiti

Restore Entity

restore_entity

Restore a soft-deleted entity to its original ID and active state. Revives tombstoned relationships and un-orphans linked controls for assets, attackers, components, trust boundaries, and assumptions.

Instructions

Un-soft-delete a single entity of any core type, reversing a prior remove_entity. Mutating: creates a new model version. Only affects an entity that is currently soft-deleted.

Dispatches on entity_type. Per-type effect:

  • asset — revives the asset's tombstoned (asset × attacker) COs with their original IDs, un-orphaning any linked controls.

  • attacker — reinstates the attacker under its original ID, revives the COs tombstoned when it was removed, and un-orphans any controls that were anchored to it.

  • component — reinstates the component under its original ID, restoring its trust-boundary contribution to asset reachability.

  • trust_boundary — reinstates the boundary: the reachability it filtered re-narrows and its sealed/isolation claim is restored, so CO reachability verdicts past it can flip back toward unreachable.

  • assumption — returns the assumption to active status; controls whose assumption_groups referenced it keep their group structure intact. Re-attestation is required before it mitigates COs again.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
model_idYesID of the threat model.
entity_idYesID of the entity to restore.
entity_typeYesWhich entity to restore — one of ``asset``, ``attacker``, ``component``, ``trust_boundary``, ``assumption``.
server_versionYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv0.68.2

TDQS

A4.6/5.0
Behavior5/5

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

With zero annotations, the description carries the full burden and succeeds impressively. It discloses mutation ('creates a new model version'), ID preservation, tombstone resurrection mechanics, un-orphaning of controls, reachability verdict flips for trust_boundary, and the re-attestation requirement for assumptions — exactly the non-obvious side effects an agent needs to anticipate.

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 core purpose is front-loaded in the first sentence, and the per-type effects are organized into scannable bullets. Though long, the length is justified by genuine complexity — five dispatch branches each with distinct semantics — and no sentence is redundant or restates schema content.

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?

The description is unusually complete for a polymorphic mutation tool: it covers preconditions, versioning side effects, per-type outcomes, and downstream consequences like re-attestation and verdict flips. The only gaps are error behavior (what happens if the entity is not soft-deleted, or if entity_type/entity_id is invalid) and server_version semantics — minor omissions given the output schema covers return values.

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%, so the schema does most of the work. The description adds substantial meaning beyond the schema by explaining what each entity_type value actually does behaviorally (distinct effects for asset, attacker, component, trust_boundary, assumption) and clarifying that entity_id must reference a soft-deleted entity. However, server_version remains undocumented in both schema and description.

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 opening sentence names a specific verb ('Un-soft-delete'), a precise resource ('a single entity of any core type'), and ties it to its inverse operation ('reversing a prior remove_entity'). It further enumerates the five supported entity types. This fully differentiates it from the large sibling set, especially remove_entity and the various add/edit tools.

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?

The description gives a clear precondition ('Only affects an entity that is currently soft-deleted') and positions the tool as the reversal of remove_entity, which tells the agent when it applies. It does not, however, explicitly name alternatives or state when-not-to-use cases (e.g., that active entities should go through edit_* tools instead), so it falls just short of full routing 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