Skip to main content
Glama

xae_links_import

Destructive

Preview and apply a TwinCAT variable-link mapping table via ConsumeMappingInfo, adding or replacing all project links, with dry-run diff, backup, and restore guidance.

Instructions

Import a mapping table (, as ProduceMappingInfo writes it) through ConsumeMappingInfo, which replaces ALL links of the project. mode='add': its links are added to the table as it is (nothing removed); 'replace': it is the whole new table. dry_run (default): what would be added / removed / changed — nothing done; its confirm_target is the token target the apply needs. dry_run=false: the table as it is goes to a new backup file first (~/.twincat_mcp/backups/links/), then ConsumeMappingInfo once, then the table is read again and compared; a failure says what the table holds then and how to restore it. xml text or file (on this PC, UTF-8 or UTF-16). Refused while the table has a link with a TwinSAFE end (ConsumeMappingInfo rewrites every link). Destructive-class: tc_request_confirmation(action='xae_links_import', args={xml|file, mode}) — the target is the dry run's confirm_target, ': over (+ -)' (a table changed since: refused).

Input Schema

NameRequiredDescriptionDefault
xmlNo
fileNo
modeNoadd
dry_runNo
confirm_tokenNo

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv0.8.19

TDQS

A4.3/5.0
Behavior5/5

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

Annotations already declare destructiveHint=true and idempotentHint=false, but the description still adds substantial unique detail: a backup is written to ~/.twincat_mcp/backups/links/ before the single ConsumeMappingInfo call, the table is re-read and compared afterwards, and failures report the post-state plus how to restore. The confirmation-token semantics and the staleness refusal are also behavior an agent could not infer from annotations.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness3/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Nearly every clause carries real information, but the prose is telegraphic and run-on, with deeply nested parentheticals (the token format string in particular) that make it hard to parse linearly. The purpose is front-loaded, yet the mode and safety details are interleaved rather than ordered into a readable sequence.

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 destructive, non-idempotent tool over a zero-coverage schema, the description supplies the safety workflow, rollback story, refusal conditions and mode semantics that matter. Minor omissions remain: which project/solution the table belongs to and whether an empty table is a valid starting point, but the output schema covers the return shape.

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 0%, so the description must carry all five parameters, and it largely does: mode's two values with their exact semantics, dry_run's two states, xml vs file with encoding constraints (UTF-8/UTF-16, path on this PC), and the confirmation token. It loses a point for calling the token 'confirm_target' while the schema property is 'confirm_token', and for never stating that at least one of xml/file must be supplied.

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?

States a concrete verb and resource: import a <VarLinks> mapping table through ConsumeMappingInfo, and makes clear that it replaces ALL links of the project. That scope phrase implicitly separates it from the per-link siblings (xae_link, xae_unlink, xae_links), but no sibling is named, so the agent has to infer the routing itself.

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?

Gives the when: dry_run default for preview, dry_run=false to apply; distinguishes mode='add' (merge, nothing removed) from 'replace' (whole new table). Gives the when-not: refused while the table contains a TwinSAFE-ended link, and refused if the table changed since the dry run. Also names the prerequisite step (tc_request_confirmation with the dry run's confirm_target) and the value it must carry.

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