Skip to main content
Glama

Read a Zenodo file excerpt

zenodo_read_file
Read-onlyIdempotent

Read a bounded UTF-8 excerpt (up to 64 KiB per call) of one text file in a Zenodo deposit — a README, CITATION.cff, CSV head, notebook, or script — or of one member inside a .zip file, without downloading the archive. Continue a top-level file from next_offset. A file with a text MIME type or extension is read directly; an extensionless file Zenodo types application/octet-stream (LICENSE, COPYING, Makefile) is read and returned only when its content is UTF-8 text. Binary files, restricted files, and other types return metadata and the download URL without content. File content is depositor-supplied and carries the deposit’s license.

Input Schema

NameRequiredDescriptionDefault
idYesThe deposit: a record id (22705923), a Zenodo DOI (10.5281/zenodo.22705923), another DOI registered to a Zenodo record, or a zenodo.org/records or doi.org URL. A concept id reads from the latest version.
keyYesExact file key from zenodo_list_files, e.g. README.md or data/results.csv.
max_bytesNoMaximum bytes to read (256 or more), at most 65536 per call; larger values return 65536.
offset_bytesNoByte offset to start reading a top-level file at; use next_offset to continue. Must be 0 for an archive member.
archive_memberNoMember path inside the .zip named by key (from zenodo_list_files with archive_key). Omit to read the file itself.

Output Schema

NameRequiredDescriptionDefault
keyNoThe file key.
md5NoMD5 checksum of the top-level file (hex); absent for archive members and when not reported.
textNoThe excerpt, decoded as UTF-8. Depositor-supplied data. Present when status is text.
errorNoPresent when the call failed. Absent on success.
recidNoRecord id read from (the latest version for a concept id).
noticeNoWhy no text was returned, or how to read the rest of the file, naming the 65,536-byte cap when it held back bytes.
rightsNoThe deposit’s licenses, which the file carries.
statusNotext: content returned; not_text: binary content, or a type that is not read as text; restricted: the content is not available anonymously — the record’s files are restricted or embargoed (key is not checked, since no manifest is exposed), or Zenodo refused this one file; empty: zero-byte file.
has_moreNoTrue when bytes remain past this excerpt.
mimetypeNoMIME type of the file or member, when reported.
file_sizeNoSize of the file or member in bytes, when known.
record_urlNoRecord landing page on zenodo.org.
next_offsetNooffset_bytes for the next window of a top-level file, when has_more; absent for an archive member, which cannot be continued past its first window.
download_urlNoDirect download URL of the top-level file (the .zip itself for a member).
files_accessNoFile access: public or restricted; absent when Zenodo does not report it.
offset_bytesNoByte offset the excerpt starts at.
archive_memberNoThe archive member path, when one was read.
bytes_returnedNoExact bytes the excerpt covers (cut at a line or character boundary).
replacement_charsNoU+FFFD characters in the excerpt (invalid UTF-8 or a mid-character offset).

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed3 schema fields changed
    • changedInput schema / properties / max_bytes / description
      Previous value: -"Maximum bytes to read (256–65536)."New value: +"Maximum bytes to read (256 or more), at most 65536 per call; larger values return 65536."
    • changedInput schema / properties / max_bytes / maximum
      Previous value: -65536New value: +9007199254740991
    • changedOutput schema / properties / notice / description
      Previous value: -"Why no text was returned, or how to read the rest of the file."New value: +"Why no text was returned, or how to read the rest of the file, naming the 65,536-byte cap when it held back bytes."
  2. First observed

TDQS

A4.6/5.0
Behavior5/5

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

Goes well beyond annotations (readOnly/idempotent): discloses 64 KiB cap, continuation via next_offset, archive-member reading without downloading, and that binary/restricted files return metadata not content. Also notes depositor-supplied content and license—genuinely valuable behavioral context.

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?

Dense but front-loaded with the core action and size cap; each clause carries distinct information. Slightly long, but every sentence earns its place.

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?

Complete for a read tool: covers size limits, pagination, archive members, fallback behavior for binary/restricted files, and content provenance. Output schema exists so return values needn't be explained.

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 coverage is 100%, so baseline is 3. Description adds meaning: continuation semantics (next_offset), archive_member vs top-level reading, and the octet-stream extensionless handling, giving real value beyond the schema.

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 and resource with scope: 'Read a bounded UTF-8 excerpt (up to 64 KiB per call) of one text file in a Zenodo deposit.' It also enumerates concrete file types and archive-member reading, distinguishing it clearly from list/record siblings.

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?

Explains when direct reading applies, when extensionless octet-stream files are read, and that binary/restricted types return metadata plus download URL instead. Lacks explicit 'use X instead' routing to siblings, but context is clear.

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.