Skip to main content
Glama

DERO MCP Server

tela_get_doc_content

Read-only

Composite: fetch the actual file content stored in a TELA-DOC-1 contract. A DOC's file (HTML/CSS/JS/...) lives inside a DVM-BASIC comment block in the contract code — NOT in a stored variable — so this tool fetches DERO.GetSC, confirms the SCID is a DOC, and extracts the file bytes. Gzip-compressed files (a .gz filename, the TELA-CLI default) are transparently base64-decoded + decompressed to plaintext. Large files paginate via offset.

When to call: when a user wants to READ or inspect the actual code/markup a TELA app file holds (e.g. "show me the HTML of this TELA DOC", "what does this app's app.js contain"). Get DOC SCIDs from tela_inspect on an INDEX first. PREFER this over dero_get_sc: that returns the raw DVM contract wrapper; this extracts just the embedded file content and reports docType, size, and signature presence.

Input Requirements:

  • scid is REQUIRED. Must be 64 hex chars and reference a TELA-DOC-1 contract (an INDEX or non-TELA SCID returns INVALID_INPUT with guidance).

  • offset is OPTIONAL. Byte offset into the extracted content; pass next_offset to read the next chunk of a large file.

  • topoheight is OPTIONAL. Omit for the latest committed state.

Output: { scid, topoheight, filename, doc_type, sub_dir, content_embedded, content, content_offset, content_length, content_truncated, next_offset, compressed, decompressed, stored_filename, signature, signature_note, note, narrative, related_docs }. content is the plaintext file (a 60000-char chunk; paginate via next_offset), or null when content is not embedded (DocShard/STATIC/external). compressed is true for .gz files; decompressed is true when this tool gunzipped them (filename then strips .gz; stored_filename keeps the on-chain name). The contract's author signature presence is reported but NOT cryptographically verified.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
scidYes64-char hex Smart Contract ID of a TELA-DOC-1 file contract
offsetNoByte offset into the extracted file content; use next_offset to paginate large files
topoheightNoOptional topo height; omit for latest committed state

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed5 schema fields changed
    • changedInput schema / $schema
      Previous value: -"http://json-schema.org/draft-07/schema#"New value: +"https://json-schema.org/draft/2020-12/schema"
    • removedInput schema / additionalProperties
      Removed value: -false
    • addedInput schema / properties / offset / maximum
      Added value: +9007199254740991
    • addedInput schema / properties / topoheight / maximum
      Added value: +9007199254740991
    • addedInput schema / properties / topoheight / minimum
      Added value: +-9007199254740991
  2. First observed

TDQS

A4.7/5.0
Behavior5/5

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

Annotations (readOnlyHint=true, destructiveHint=false) already establish safety; the description adds rich behavior: the composite DERO.GetSC fetch, base64-decode + gunzip decompression, 60000-char chunking with next_offset, null content for DocShard/STATIC/external, and the explicit caveat that signature presence is not cryptographically verified. It also discloses INVALID_INPUT behavior for non-DOC SCIDs.

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?

Well-structured with bolded sections: purpose, when to call, input requirements, output. The most important scoping and alternative routing are front-loaded, and the detailed output explanation is justified because there is no output schema. No filler sentences, despite the length.

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?

Given there is no output schema, the description thoroughly explains return fields like content, compressed, decompressed, stored_filename, next_offset, and the signature caveat. It covers pagination, compression, invalid-input behavior, and the relationship to tela_inspect and dero_get_sc. The tool's complexity is matched by the description's completeness.

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% — each parameter is documented with type, constraints, and purpose. The description echoes the schema for scid/offset/topoheight and adds only one extra semantic detail: that an INDEX or non-TELA SCID returns INVALID_INPUT with guidance. Per the high-coverage baseline, a 3 is appropriate.

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: fetches and extracts the actual file content from a TELA-DOC-1 contract. Explains the internal mechanism (scraping a DVM-BASIC comment block) and explicitly distinguishes itself from dero_get_sc, which returns the raw wrapper. This leaves no ambiguity about what the tool does.

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?

Includes an explicit 'When to call' section: read/inspect actual code/markup of a TELA app file, with concrete example queries. Tells the agent to get DOC SCIDs from tela_inspect first, and instructs to prefer this tool over dero_get_sc with the reason why. This is model 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.