Skip to main content
Glama

List OneDrive folder contents

files_list_children
Read-onlyIdempotent

List the immediate children of any OneDrive folder using its item ID or path. Returns file details like name, size, type, and modified time, with pagination for large folders.

Instructions

Lists the direct children of a folder in the signed-in user's OneDrive, returning id, name, kind (file or folder), size, mime type, child count, last-modified time and webUrl per entry, plus count and nextLink when more pages exist. Address the folder by itemId or by path; omit both for the drive root. Page size defaults to 50. This is not recursive: use files_search to look through the whole drive.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
topNoMaximum number of children to return in this page. Defaults to 50.
pathNoPath of the folder to list, e.g. "Documents/Reports". Path from the OneDrive root, e.g. "Documents/Reports/q3.docx". Leading slashes are ignored. Mutually exclusive with itemId. Omit both to list the drive root.
itemIdNoId of the folder to list. Drive item id, as returned by any files_* listing tool. Mutually exclusive with path. Omit both to list the drive root.
orderbyNoSort order for the children. Graph defaults to name ascending. OneDrive for Business (SharePoint-backed) drives silently ignore some sorts, notably by size.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.5/5.0
Behavior4/5

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

Annotations already declare readOnlyHint=true, idempotentHint=true, and destructiveHint=false, covering safety and idempotency. The description adds valuable behavioral context: non-recursive nature, pagination via nextLink, default page size, and the fact that it returns multiple entries. It also notes that SharePoint-backed drives may ignore some sorts, which is a useful caveat. The only minor gap is lack of detail on error handling or rate limits, but with strong annotations, this is above baseline.

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 two sentences: the first is information-dense, covering return fields, addressing, and pagination; the second clarifies non-recursion and points to the alternative. It is concise, front-loaded with the primary purpose, and every sentence earns its place without redundancy.

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 the tool's moderate complexity (4 params, no required params, decisive annotations), the description is complete: it explains return fields, pagination, default page size, non-recursion, and alternate addressing. No output schema exists, but the description lists all return fields, making it self-sufficient. There is no missing guidance for an agent to call this correctly.

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 all parameters are fully described in the schema. The description adds context by explicitly mentioning the mutual exclusivity of itemId and path, and the omission for root, which reinforces but does not extend the schema. Since coverage is high, baseline 3 is appropriate; no significant added meaning.

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 clearly states it lists direct children of a folder in OneDrive, enumerates the exact fields returned, and distinguishes it from recursive search by naming files_search as the non-recursive alternative. This is a specific verb+resource with sufficient detail to differentiate from siblings.

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?

The description explicitly states when to use this tool (list direct children) and when not to (use files_search for whole-drive search). It also clarifies how to address the folder (by itemId, by path, or omit for root), which serves as usage guidance. No exclusions are needed beyond that.

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