Skip to main content
Glama

get-excel-used-range

Read-only

Retrieve the smallest cell range containing data or formatting on a worksheet to determine populated bounds before reading or appending data.

Instructions

Invoke function usedRange

💡 TIP: Get the smallest range that encompasses any cells with values or formatting on the worksheet. Returns address, values, formulas, numberFormat, rowCount, columnCount. Use this to discover the populated bounds of a sheet before reading or appending — avoids guessing how far data extends. Optional $select to trim the response.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
driveIdYesPath parameter: driveId
driveItemIdYesPath parameter: driveItemId
workbookWorksheetIdYesPath parameter: workbookWorksheetId
fetchAllPagesNoFollow @odata.nextLink and merge up to 100 pages into one response. Can return enormous payloads—only when the user explicitly needs a full export. Prefer a small $top first, then paginate or narrow with $filter/$search.
includeHeadersNoInclude response headers (including ETag) in the response metadata
excludeResponseNoExclude the full response body and only return success or failure indication
Behavior4/5

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

Annotations declare readOnlyHint=true and destructiveHint=false, indicating safe read. The description adds behavioral details such as the return of address, values, formulas, numberFormat, rowCount, columnCount, and mentions optional $select. No contradictions.

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 very concise: a single sentence plus a tip, front-loaded with the function name. Every word adds value, no fluff.

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 annotations and complete schema, the description fully informs about the tool's purpose, return values, and typical use case. No output schema exists, but the description compensates by listing returned fields.

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 coverage is 100%, providing descriptions for all parameters. The description adds extra context about $select trimming the response, which is not in the schema, and the tip implies how parameters relate to usage.

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 that the tool gets the smallest range encompassing cells with values or formatting on a worksheet. It specifies the returned data (address, values, formulas, etc.) and provides a tip that distinguishes it from other operations like reading or appending.

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?

The description explicitly advises using this tool to discover populated bounds before reading or appending, avoiding guesswork. It does not directly compare to sibling tools, but the context is sufficient for basic usage 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

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/Softeria/ms-365-mcp-server'

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