Skip to main content
Glama

Passage Data — cited environmental limits

Add a document to a site

add_document
Idempotent

One file held on a site and read, as a file dropped on the site's page is: its text layer page by page, its summary and, for a laboratory table, its result rows, all kept in the account and searched by ask_site. Give the file as content_base64, or a text as text. The same bytes added twice are one document. The answer gives the document's id, its state (read, or refused with a code and why), its pages, and not_done: each step of the read not made in this call. At most 8 MiB a file here; a larger one goes on the site's page (up to 200 MiB).

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": {
      "site": "<site>",
      "filename": "<filename>"
    },
    "name": "add_document"
  }
}

Input Schema

NameRequiredDescriptionDefault
siteYesThe site: its id (from list_sites), or a part of its name that names one site only.
textNoThe document as text, kept as a UTF-8 file under `filename`. Give this or `content_base64`.
filenameYesThe file's name with its extension (permit.pdf, results.xlsx, notes.txt): it says what kind of file it is.
content_base64NoThe file's bytes, base64. Give this or `text`.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4.3/5.0
Behavior5/5

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

Beyond the annotations (which already state write, idempotent, non-destructive), the description discloses that identical bytes collapse into one document, that the response includes a state which can be 'refused with a code and why', and that `not_done` lists read steps not completed in this call – i.e. partial/async processing. It also caps input size. These are substantive behavioral facts an agent could not get from the annotations alone.

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?

Roughly five dense sentences, each carrying distinct information (content model, input alternatives, idempotency, return shape, size limits) with no filler. The opening clause is grammatically convoluted ('as a file dropped on the site's page is'), which slightly slows parsing, but nothing is wasted.

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

Completeness5/5

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

There is no output schema, so the description correctly carries the return contract (id, state, pages, not_done) as well as input modes, size limits and idempotency. For a 4-parameter write tool with no output schema, this covers everything an agent needs to call it correctly.

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

Parameters4/5

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

Schema description coverage is 100%, so the baseline is 3, but the description adds parameter-relevant meaning not in the schema: the 8 MiB ceiling on `content_base64` and the fact that `text` is stored as a UTF-8 file under `filename`. It largely mirrors the schema's `this or that` wording for the two content parameters.

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 conveys the resource (a file held on a site, read into text layers, summary and result rows) and its downstream use via ask_site, which distinguishes it from the read-side siblings. However, the action itself is only implied ('One file held on a site and read') rather than stated with a clear verb like 'adds'; the agent must infer the write from the tool name and title.

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

Usage Guidelines4/5

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

It gives concrete conditions: use `content_base64` for bytes or `text` for text, and files up to 8 MiB go here while larger ones (up to 200 MiB) go on the site's page. It also signals that ask_site is the retrieval path. It stops short of explicitly contrasting with other siblings such as fetch or search, but the input-mode and size routing is clear guidance.

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.