Skip to main content
Glama

ssh_write_file

Write text content to a remote file via SSH. Creates parent directories if needed, uses atomic write to prevent partial writes.

Instructions

Write content to a file on the remote server.

Uses atomic write (temp file + mv) to prevent partial writes. Overwrites the file if it exists, creates it if it doesn't.

Args: path: Absolute or relative path on the remote. content: Text content to write. create_dirs: If true, create parent directories if they don't exist. host: SSH host alias from config. Uses default if omitted.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
pathYes
contentYes
create_dirsNo
hostNo
Behavior4/5

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

The description discloses atomic write (temp file + mv) and overwrite/create behavior, adding value beyond the schema. No annotations exist, so the description carries the full burden. It does not cover error handling or auth requirements, but the provided details are helpful.

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 description is concise: one sentence for purpose, one for behavior, then a clear bullet list for parameters. No unnecessary words.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

The description covers the core behavior and parameter meanings, but lacks details on return value (no output schema), error handling, or idempotency. For a 4-param tool with no annotations, it is minimally adequate.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The input schema has no descriptions (0% coverage), but the description explains each parameter: path (absolute/relative), content (text), create_dirs (create parent dirs), and host (SSH alias). This adds critical meaning that the schema lacks.

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 writes content to a file on a remote server, with atomic write behavior. It distinguishes from siblings like ssh_append_file or ssh_read_file by specifying overwrite/create behavior.

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?

The description implies usage for writing file content but does not explicitly state when to use this over alternatives like ssh_append_file or when not to use it (e.g., for small vs large files, or when partial writes might be acceptable).

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/mkavinkumar1/ssh-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server