Skip to main content
Glama

read_file_as_text

Read-only

Read a Google Drive file's content as text, one chunk at a time. Supports Google-native files and PDFs with paging metadata.

Instructions

Read a file's content as text, one bounded chunk at a time.

Google-native files are exported; PDFs are text-extracted. Returns the requested chunk
(0-based) in `content` plus name, mime_type, and paging metadata (total_chunks,
total_chars, has_more) — page through by incrementing chunk. Set max_chars<=0 for the
whole document.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
itemYes
chunkNo
max_charsNo
Behavior4/5

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

Annotations already indicate readOnly and openWorld. Description adds value beyond annotations by explaining chunking behavior, return paging metadata, and special handling for file types.

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, front-loaded with primary action. No wasted words.

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?

Given complexity (chunked reading, export/extraction) and no output schema, description covers return fields (content, name, mime_type, paging metadata) and paging mechanism. Completeness is high but could mention output structure more explicitly.

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 has 0% description coverage. Description explains all three parameters: item (required), chunk (0-based, default 0), max_chars (default 8000, set <=0 for whole document). Adds meaning beyond 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?

Description clearly states verb (Read), resource (file's content as text), and operation (one bounded chunk at a time). It distinguishes from siblings like read_document by focusing on arbitrary files with chunking and export/extraction.

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?

Description explains when to use (for text content of any file) and gives context about file types (Google-native exported, PDFs text-extracted). However, no explicit guidance on when not to use or alternatives, though context is clear.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/shivankj11/gdrive-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server