Skip to main content
Glama

files_has_data

Read-onlyIdempotent

Checks whether an A1 range is already occupied — cell values, code/table output, or merged cells (each can cause a spill). Use before placing a table or code cell to avoid spill errors. Returns { has_data: true/false }. Read-only; reflects the file's latest live state. Signature: files_has_data(file_uuid, range, sheet?).

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "file_uuid": "<file_uuid>",
      "range": "<range>"
    },
    "name": "files_has_data"
  }
}

Input Schema

NameRequiredDescriptionDefault
rangeYesA1 range to check, e.g. 'A1:D10'.
sheetNoSheet name (defaults to the first sheet).
file_uuidYes

Output Schema

NameRequiredDescriptionDefault
rangeYes
has_dataYes
file_uuidYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.1/5.0
Behavior4/5

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

Annotations already declare readOnlyHint and idempotentHint, so the description's 'Read-only' restatement adds little. However, it does add real behavioral context beyond annotations: the check reflects the file's latest live state, and the result reveals pre-existing occupancy that would cause spill errors — exactly the nuance an agent needs before a write.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The purpose, rationale, and return shape are front-loaded in the first two sentences with no wasted clauses. The appended 'Signature: files_has_data(...)' line is redundant with the schema and slightly dilutes the tightness.

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?

Output schema exists, yet the description still helpfully states the return shape, and it covers the pre-write use case, freshness, and safety profile. For a simple 3-parameter predicate tool this is nearly complete; only the sheet-default behavior is left entirely to the schema.

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 coverage is 67%, with range and sheet already documented in the schema. The trailing signature line just restates the parameter names and adds no format or constraint detail beyond the schema's 'A1 range, e.g. A1:D10' example, so the baseline 3 applies.

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?

States a specific verb and resource ('checks whether an A1 range is already occupied') and enumerates what counts as data (cell values, code/table output, merged cells), which distinguishes it from siblings like files_read or files_write. An agent can tell exactly what question this tool answers without opening the schema.

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?

'Use before placing a table or code cell to avoid spill errors' gives a concrete prerequisite-timing rule, which is stronger than implied usage. It stops short of naming explicit alternatives (e.g., just calling files_read) or when a check is unnecessary, so it is clear but not fully routing.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources