Skip to main content
Glama

Upload a local file

upload_file
Destructive

Transfers a local file into an Overleaf project, replacing any existing file at the same path.

Instructions

Uploads a file from this computer (e.g. a generated figure or .bib) into a project, replacing any file with the same path. For text you already have, write_file is simpler; download_file goes the other way.

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": {
      "localPath": "<localPath>"
    },
    "name": "upload_file"
  }
}

Input Schema

NameRequiredDescriptionDefault
pathNoDestination path in the project (default: the file name in the root folder)
projectNoProject name, id or Overleaf URL. May be omitted when exactly one project is pinned.
localPathYesAbsolute path of the file on this computer

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv2.1.1

TDQS

A4.4/5.0
Behavior4/5

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

Annotations already flag destructiveHint and openWorldHint; the description adds the concrete meaning of destruction — any file at the same destination path is replaced — which is real added context. It stops short of stating auth requirements (a sign_in sibling exists), size limits, or whether missing destination folders are created.

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, zero filler: the core action and its overwrite semantics come first, then the routing guidance. Every clause earns its place and nothing is repeated from the schema.

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 simple three-parameter upload with no output schema, the description covers action, overwrite behavior, and sibling routing, which is what an agent needs to call it. Minor omissions are failure behavior and directory-creation semantics, but the annotations and full schema coverage absorb most of that risk.

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 100%, so localPath, path, and project are all documented with defaults and pinning behavior in the schema itself. The description only echoes the localPath concept via "from this computer" and adds no format or syntax guidance. Baseline 3 is appropriate when the schema carries the parameter burden.

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?

States a specific verb (uploads), resource (a file from this computer into a project), and direction of transfer, plus a concrete example of content (generated figure, .bib). It also contrasts with both write_file and download_file, so an agent can place it among siblings without opening a schema.

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?

Explicitly names the alternative for text content ("write_file is simpler") and the reverse-direction tool ("download_file goes the other way"). It doesn't enumerate exclusions beyond that, but the positive selection rule for the nearest competing sibling is stated outright.

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