Skip to main content
Glama
remote-ssh-mcp
by RuiFG

ssh_write_file

Destructive

Writes UTF-8 text to a remote path over SFTP via a temporary file. Requires an existing parent directory and explicit overwrite:true to replace an existing file.

Instructions

Write remote UTF-8 text via SFTP using a temporary file. Requires an existing parent directory and explicit overwrite:true to replace a file.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "hostId": "<hostId>",
      "path": "<path>",
      "content": "<content>"
    },
    "name": "ssh_write_file"
  }
}

Input Schema

NameRequiredDescriptionDefault
pathYes
hostIdYesRequired stable host ID returned by ssh_list_hosts. Names are not accepted.
contentYes
overwriteNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.0

TDQS

A3.8/5.0
Behavior4/5

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

Annotations already declare destructive, non-idempotent, open-world behavior, so the bar is lower. The description still adds real value: it discloses the temporary-file write mechanism and the failure condition that the parent directory must already exist, which are not in the annotations or schema.

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?

Two sentences, no filler, with the write mechanism front-loaded and the preconditions grouped second. Every clause carries actionable meaning.

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?

A mutation tool with no output schema, covered by annotations for safety; the description supplies the key gotchas (parent dir, overwrite flag, temp file, UTF-8). It omits the content size limit and any statement of what a successful call yields, but is otherwise sufficient to invoke correctly.

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 only 25% (hostId only), so the description must compensate. It clarifies 'overwrite' semantics and the path precondition, but says nothing about the 4 MB content cap, path format, or required hostId (covered by schema). Partial compensation warrants a mid score.

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 specific verb and resource: writes remote UTF-8 text via SFTP. It implicitly distinguishes itself from binary transfer tools (ssh_upload_file) through the 'UTF-8 text' qualifier, though no sibling is named explicitly.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Gives clear preconditions (parent directory must exist, overwrite:true required to replace) which shape when the call will succeed. It does not say when to prefer this over ssh_upload_file for binary or bulk transfers, so guidance is implied rather than explicit.

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