Skip to main content
Glama

typst_upload_asset

Upload or replace binary assets such as images, PDFs, and fonts in a Typst project from a local file path or base64 data.

Instructions

Upload or replace a binary asset (PNG, JPG, SVG, PDF, font, etc.) in a https://typst.app project from a local file path or base64 data.

Input Schema

NameRequiredDescriptionDefault
convertNoWhether typst.app should convert the uploaded file
fileNameYesDestination path inside the Typst project (e.g. 'figures/plot.png')
projectIdYesThe Typst project ID
base64DataNoBase64-encoded binary payload (used if localFilePath is not provided)
localFilePathNoLocal filesystem path to read binary asset bytes from

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.2

TDQS

A3.8/5.0
Behavior3/5

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

With no annotations, the description carries the full behavioral burden. It usefully discloses that the tool can overwrite an existing asset ('replace') and accepts either a local path or base64 payload, but it omits authentication requirements, overwrite/destructive semantics, size limits, and how conversion interacts with the upload.

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?

A single, front-loaded sentence that names the action, resource, formats, destination, and source options without filler. Every clause contributes useful information.

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?

For a 5-parameter upload tool with no output schema, the description covers purpose, asset types, destination, and source methods adequately, and the rich input schema fills in parameter details. The main gap is the lack of any auth or overwrite-safety context, which matters because annotations are absent.

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 100%, so the schema already documents all five parameters in detail. The description reinforces that source data can come from a local path or base64, but it adds no meaningful semantics beyond the schema, especially for the undocumented-in-description 'convert' parameter.

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 uses a specific verb pair ('Upload or replace') and a precise resource ('binary asset') with concrete examples (PNG, JPG, SVG, PDF, font). It distinguishes itself from text-file siblings such as typst_write_file by explicitly framing the tool around binary assets and local file/base64 sourcing.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The binary-asset framing implies when this tool applies, and the source options (local path vs base64) are clear. However, it does not explicitly say when to use this over siblings like typst_write_file or typst_edit_file, nor does it state exclusions or prerequisites.

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