Skip to main content
Glama

save_response_to_file

Send an API request and save its response body directly to a file, so you can download PDFs, CSVs, images, and other resources without manual copying.

Instructions

Send a request and save the response body directly to a file on disk. Useful for downloading files from APIs (PDFs, CSVs, images, etc.).

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": {
      "request_id": "<request_id>",
      "output_path": "<output_path>"
    },
    "name": "save_response_to_file"
  }
}

Input Schema

NameRequiredDescriptionDefault
confirmedNoSet to true to confirm sending to an external URL after reviewing it
request_idYes
output_pathYesAbsolute file path to save the response body to
environment_idNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.6-beta

TDQS

B3/5.0
Behavior2/5

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

No annotations are supplied, so the description carries the full behavioral burden. It discloses that a network request is made and a file is written, but says nothing about overwrite behavior on an existing path, whether the `confirmed` flag gates external URLs, permission or size constraints, or what happens on a failed request. The one behavioral hint present (`confirmed` for external URLs) comes only from the schema, not the description.

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 short sentences, front-loaded with the core action and followed by concrete use cases. Every sentence earns its place with no filler or redundancy.

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?

With four parameters, no annotations, no output schema, and only half the parameters documented, the description leaves too much unspecified for an operation that performs an external network call and writes to disk. Key facts an agent needs -- what request_id identifies, the purpose of environment_id, and the confirmation flow -- are absent.

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

Parameters2/5

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

Schema description coverage is only 50%: `request_id` and `environment_id` have no documentation anywhere, and the description never explains what a request_id refers to or how environment_id selects context. It adds nothing about parameter meaning beyond loosely implying that the response of the identified request lands at `output_path`.

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?

The description gives a specific verb and resource: send a request and persist the response body to a file on disk. That clearly separates it from read-only siblings like inspect_response or get_response_history, which inspect rather than persist. It stops short of naming any sibling as an alternative, so it is clear but not fully differentiated.

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 second sentence gives a genuine usage context ('downloading files from APIs (PDFs, CSVs, images)'), which is more than a bare restatement. However, it offers no when-not guidance and never explains the confirmation prerequisite implied by the `confirmed` parameter, so an agent could call it and hit an unexpected gate.

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