Skip to main content
Glama

app_save_all

Persist all modified design documents to disk after in-memory edits; check still_dirty to confirm writes succeeded before DRC or closing.

Instructions

Flush every dirty Altium document to disk.

Mutation tools (pcb_place_tracks, move_component, modify_objects, ...) now mark documents as modified in-memory only. Changes stay fast because they skip per-operation disk writes. Call save_all at logical checkpoints, after a routing pass, before running DRC, or before closing, to persist everything.

Detach also triggers save_all automatically, so you don't need this as the very last step.

CHECK still_dirty, DO NOT ASSUME. Altium refuses to save while a command is active in the editor and asks a human whether to write a copy instead; DoFileSave does not raise when it declines. MEASURED: this returned saved:true while every single save was being refused. It now counts what is still modified afterwards, and saved is false when anything is. If that happens, run app_exit_active_command and retry.

Returns: Dict with saved, still_dirty, and a reason when documents remain unsaved.

Input Schema

NameRequiredDescriptionDefault

No arguments

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.6.1

TDQS

A4.5/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 does so: it explains that mutation tools now write in-memory only, that Altium silently refuses saves while a command is active, that saved:true was previously misleading, and that saved is now false when anything remains dirty. The remediation (run app_exit_active_command and retry) is a level of operational detail rarely seen.

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 purpose is front-loaded in the first sentence and the material is well organized into purpose, when-to-call, caveat, remedy, and returns. It runs long and the "MEASURED" anecdote about the past bug is slightly padded, though it does justify the still_dirty warning.

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?

Everything an agent needs to call this correctly is present: trigger points, the silent-failure mode, how to detect it, and how to recover. The output schema covers return shape, and the description still summarizes it, so no gap remains.

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?

The tool takes no parameters, so the baseline is 4 and there is nothing for the description to disambiguate. It additionally names the return keys (saved, still_dirty, reason), which is bonus context even though an output schema exists.

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?

"Flush every dirty Altium document to disk" gives a specific verb plus resource and scope (all documents, dirty only). It implies the distinction from the sibling app_save_document via "every," but never names that sibling explicitly, leaving a small inference step.

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?

Explicit invocation points are listed: logical checkpoints, after a routing pass, before DRC, before closing. It also states when NOT to rely on it ("Detach also triggers save_all automatically, so you don't need this as the very last step") and gives a retry procedure when saves are refused.

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