Skip to main content
Glama

Get Drive File Content

get_drive_file_content
Read-onlyIdempotent

Get the contents of any Google Drive file using its file ID. Native Google files, Office documents, PDFs, images, and more are converted to readable text, CSV, or base64.

Instructions

Retrieves the content of a specific Google Drive file by ID, supporting files in shared drives.

• Native Google Docs, Sheets, Slides → exported as text / CSV. • Office files (.docx, .xlsx, .pptx) → unzipped & parsed with std-lib to extract readable text. • PDFs → text extracted with pypdf when possible; scanned/image-only PDFs fall back to a download hint. • Images → returned as base64 with MIME metadata for multimodal clients. • Any other file → downloaded; tries UTF-8 decode, else notes binary.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
file_idYesDrive file ID.
user_google_emailYesThe user’s Google email address.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Install Server

TDQS

A4.3/5.0
Behavior5/5

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

Annotations already provide readOnlyHint, idempotentHint, and destructiveHint, but the description adds substantial behavioral detail beyond them: per-format export/parsing strategies, PDF fallback behavior, base64/MIME for images, and a binary-note fallback for unknown file types. This is rich disclosure of how the tool behaves in various scenarios.

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?

The description is compact and well-structured: a single lead sentence followed by a scannable bullet list where each item covers a distinct file category. No sentence is wasted, and the most important usage information (retrieves content by ID, supports shared drives) is front-loaded.

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?

The tool has an output schema, so return-value details are already structured. The description covers all likely input file types, fallback behaviors, and edge cases such as binary files, making it sufficient for an agent to understand what will happen for any file. Combined with the annotations and schema, the description is contextually complete.

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?

Input schema coverage is 100% and both parameters already have reasonable descriptions. The tool description adds little beyond the schema: it mentions 'by ID' and the fact that shared drives are supported, but it does not deepen the meaning of user_google_email or provide guidance on acquiring a file_id. This matches the baseline of 3 for high schema coverage.

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?

The description opens with a precise verb+resource statement: 'Retrieves the content of a specific Google Drive file by ID,' which clearly defines what the tool does. The bulletized format-specific breakdown further distinguishes it from related siblings like get_drive_file_download_url or get_doc_content by showing it returns extracted text/content rather than a URL or a Docs-specific artifact.

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

Usage Guidelines3/5

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

The description clearly implies when to use the tool: whenever you need the content of a Google Drive file, including shared drives. However, it never explicitly names alternatives such as get_drive_file_download_url or get_doc_content, nor does it state when to prefer one over the other; the guidance is inferred from the format-handling bullets rather than stated.

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

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/WorldCentralKitchen/google_workspace_mcp'

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