Skip to main content
Glama

gemini_listFiles

List previously uploaded files with pagination support on the MCP Gemini Server. Retrieve file metadata and a token for the next page using optional page size and token parameters.

Instructions

Lists files previously uploaded to the Gemini API. Supports pagination to handle large numbers of files. NOTE: This API is not supported on Vertex AI clients. It only works with Google AI Studio API keys. Returns a list of file metadata objects and potentially a token for the next page.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
pageSizeNoOptional. The maximum number of files to return per page. Defaults to 100 if not specified by the API, max 1000.
pageTokenNoOptional. A token received from a previous listFiles call to retrieve the next page of results.
Behavior4/5

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

With no annotations provided, the description carries full burden and adds valuable behavioral context: it discloses pagination support, API compatibility constraints (not supported on Vertex AI, only Google AI Studio), and return format (list of metadata objects with potential next page token). This goes beyond the input schema, though it could detail error handling or rate limits.

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 front-loaded with the core purpose, followed by supporting details in clear, efficient sentences. Each sentence adds value: pagination support, API constraints, and return information. There is no wasted text, making it highly concise and well-structured.

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 no annotations and no output schema, the description compensates well by explaining return values (list of metadata objects with next page token) and behavioral constraints. It covers key aspects for a list operation, though it could improve by detailing error cases or authentication needs, keeping it from a perfect score.

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 description coverage is 100%, so the input schema fully documents parameters. The description does not add meaning beyond the schema, as it mentions pagination generally but not specific parameter roles. Baseline score of 3 is appropriate since the schema handles parameter documentation adequately.

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 clearly states the action ('Lists files') and resource ('previously uploaded to the Gemini API'), making the purpose immediately understandable. It distinguishes from siblings like gemini_getFile (retrieves specific file) and gemini_uploadFile (uploads new files), though not explicitly named. The description lacks explicit sibling differentiation, preventing a perfect score.

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 implies usage for listing uploaded files and mentions pagination for large datasets, providing some context. However, it does not explicitly state when to use this tool versus alternatives like gemini_listCaches or gemini_getFile, nor does it provide exclusions or prerequisites beyond the Vertex AI note. This leaves gaps in guidance.

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

Related 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/bsmi021/mcp-gemini-server'

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