Skip to main content
Glama

prepare-document-upload

Step 1 of document upload. Call before uploading bytes. Returns a presigned POST target with form fields and uploadToken; submit the returned form fields, include Content-MD5/checksum fields exactly when present, append the file last, then call complete-document-upload. Never send contentBase64, arbitrary upload headers, or file bytes to MCP.

Input Schema

NameRequiredDescriptionDefault
checksumYes32-character MD5 hex digest
filenameYesOriginal filename, including extension
companyIdYesCompany ID
sizeBytesYesFile size in bytes, max 50 MB
contentTypeYesMIME type for the file

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.7/5.0
Behavior4/5

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

Annotations cover the safety profile (readOnlyHint=false, destructiveHint=false, openWorldHint=false), and the description adds substantial behavior beyond them: the return shape (presigned target, form fields, uploadToken) and the prohibition on sending bytes/headers/contentBase64 to MCP. It stops short of disclosing token expiry, auth requirements, or re-call behavior, so a 4 rather than a 5.

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?

Three tight sentences, front-loaded with 'Step 1', and every sentence carries a distinct directive (precondition, return shape, upload mechanics, next call, prohibitions). No filler.

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?

With no output schema, the description correctly explains the return value (presigned POST target, form fields, uploadToken) and the full two-step flow, which is exactly what an agent needs to invoke this correctly within the upload pipeline.

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%, so the baseline is 3, but the description adds real meaning by tying the checksum parameter to the upload step ('include Content-MD5/checksum fields exactly when present') and explaining how the returned form fields must be submitted. That mapping is not evident from the schema's '32-character MD5 hex digest' alone.

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?

It states a specific verb+resource ('Step 1 of document upload') and precisely what it produces: a presigned POST target with form fields and an uploadToken. It clearly distinguishes itself from the sibling complete-document-upload, which it names as the next step.

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?

Explicit sequencing: 'Call before uploading bytes' and 'then call complete-document-upload' name the alternative and the condition that selects it. It also gives exclusions ('Never send contentBase64, arbitrary upload headers, or file bytes to MCP'), so nothing is left to inference.

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