Skip to main content
Glama

Write a draft's file

write_file
DestructiveIdempotent

Create or replace a draft's 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": {
      "app": "<app>",
      "path": "<path>",
      "content": "<content>"
    },
    "name": "write_file"
  }
}

Input Schema

NameRequiredDescriptionDefault
appYesThe app, as list_apps names it, such as sam/budget.
pathYesapp.py, instructions.md, tests/<name>.py, migrate.py or data/<name>.
contentYes

Schema Changelog

Changes observed during successful MCP inspections.

No schema history has been recorded yet.

TDQS

B3.1/5.0
Behavior3/5

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

The annotations already declare destructiveHint=true, idempotentHint=true, and readOnlyHint=false, so the safety profile is fully covered by structured data. The description's only behavioral contribution is the word "replace", which corroborates that existing file content is overwritten rather than appended — useful but largely redundant with the annotations. Nothing is said about permission requirements, whether a published app is affected, or how drafts relate to deploys.

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?

A single short sentence with the verb and resource front-loaded and no filler. It is efficient, though the brevity tips into under-specification rather than disciplined conciseness.

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

Completeness2/5

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

This is a destructive, non-open-world write tool with no output schema and an undefined central concept ("draft"), yet the description never explains what a draft is, whether it must already exist, or what happens to a previously published version. For a mutation tool in a catalog dense with file-related siblings, this leaves real gaps an agent must guess through.

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 coverage is 67%: app and path both carry format examples (including the allowed path shapes), while content is an undocumented required string. The description adds no parameter meaning beyond that — it does not say that content is the full file body, its encoding, or any size limits. With the schema doing most of the work, the baseline 3 is appropriate.

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?

"Create or replace a draft's file" gives a clear compound verb (create/replace) and a specific resource (a draft's file), which lets an agent distinguish it from pure edit operations like edit_file. It stops short of naming which sibling to prefer, and the term "draft" is never defined, so an agent must infer what a draft is from the surrounding catalog.

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

Usage Guidelines2/5

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

There is no when-to-use guidance at all: nothing says whether to call this versus edit_file, write_app_data, upload_file, or upload_app_file, nor whether a draft must exist first or how this relates to publish_app. The only implied guidance is the word "draft" itself.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources