Skip to main content
Glama

Stream Vessel

Measure a bucket

measure_bucket
Read-only

Counts a bounded piece of a bucket and hands back a position to continue from. To total the bucket, call this again with that position as continuationToken, and keep going until no position comes back - that is the end of the bucket, however few objects the last chunk counted. A true restarted means the position you gave was refused: drop whatever you had accumulated from earlier calls, because the count began again from the start. The numbers cover only what this connection's grant can see, never more. This counts current objects only - it does not include old versions, delete markers, or the parts of an unfinished multipart upload.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
bucketYesBucket name.
prefixNoKey prefix to count under. Empty counts the whole bucket.
connectionIdYesConnection id from list_connections.
continuationTokenNonextToken from a previous call, to keep counting from where it left off. Omit to start from the beginning.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.3/5.0
Behavior4/5

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

Annotations already declare readOnlyHint=true, idempotentHint=false, and destructiveHint=false. The description adds useful behavioral context: the count is bounded by the connection's grant, it excludes old versions, delete markers, and multipart parts, and that a true restart means the position was refused. It doesn't describe rate limits or error handling, but the key operational traits are covered.

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 description is three sentences, front-loaded with the core action and then details. It is fairly compact but the third sentence about what is counted could be slightly more concise; overall it earns its place without excess.

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 complexity (bounded counting with continuation) and the absence of an output schema, the description covers how to handle the return value (continuation token), what happens on restart, and what objects are included. It is complete enough for an agent to use correctly.

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 description coverage is 100%, so the schema already defines each parameter. The description adds meaning about continuationToken: it's the 'position to continue from' and that a true restart signals the token was refused, which goes beyond the schema's basic description. This extra nuance earns a score above the baseline 3.

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 states a clear verb and resource: it counts a piece of a bucket and returns a continuation position. It distinguishes itself from siblings like stat_prefix or list_objects by focusing on counting with continuation, but it doesn't explicitly name an alternative for related tasks.

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?

It gives explicit step-by-step guidance on when and how to use the tool, including how to continue until the end and how to interpret a 'true restart'. It also clarifies that it counts current objects only, implicitly contrasting with tools that handle old versions or multipart uploads.

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