Skip to main content
Glama

AssetLab

Upload file

upload_file

Upload a file to AssetLab storage by sending its bytes inline (base64). The AssetLab backend performs the storage upload server-side - use this tool when the client cannot PUT directly to Supabase Storage (e.g. Claude integrations whose outbound network blocks arbitrary supabase.co hosts). Returns { path, bucket, file_size, content_type }. After uploading, pass path to the appropriate record tool (update_asset image_url, create_asset_document file_path, update_work_order image_url, create_attachment file_path, create_project_document file_path, create_contract_document file_path). Server limit is ~10 MB decoded; MCP arg ceiling effectively caps file size around 700 KB-1 MB. For larger files, use create_upload_url instead. Requires upload_urls:write scope.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
bucketYesStorage bucket (required). Use "asset-images" for asset photos, "attachments" for work-order/PM attachments.
file_nameYesFile name including extension (required)
content_typeNoMIME type (e.g. image/jpeg, application/pdf). Defaults to application/octet-stream.
content_base64YesFile contents base64-encoded (required). Data URI prefixes like "data:image/png;base64," are stripped automatically.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.6/5.0
Behavior5/5

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

Annotations cover the safety profile (readOnly=false, destructive=false, idempotent=false, openWorld=false), and the description adds substantial context beyond them: an ~10 MB server cap, a practical 700 KB-1 MB MCP arg ceiling, the required upload_urls:write scope, and the exact response payload. That is well past the lower annotation-adjusted bar.

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?

Front-loaded with purpose, followed by mechanism, return shape, follow-up tools, limits, alternative, and scope. Every clause is operationally useful, though the six-tool consumer enumeration makes the single paragraph dense enough that it could be trimmed slightly.

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?

Despite having no output schema, the description specifies the return object shape, size limits, auth scope, and the downstream call needed after upload. An agent has everything required to invoke this correctly and chain the result.

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% and the schema already documents bucket enum guidance, content_type default, and the data-URI prefix stripping. The description restates the base64/inline nature of content_base64 but adds no format or constraint detail beyond the schema, 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 (upload), resource (file), destination (AssetLab storage) and mechanism (inline base64, server-side upload). It also explicitly distinguishes itself from the sibling create_upload_url, so an agent can pick between them without opening a schema.

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?

Gives an explicit use condition ('when the client cannot PUT directly to Supabase Storage'), a named alternative for the opposite case ('For larger files, use create_upload_url instead'), and the follow-up action chain (pass path to update_asset/create_asset_document/etc.). No inference required.

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