Skip to main content
Glama

start_artifact_upload

Guarda un artefacto sin retipearlo: el archivo va del disco a Secondbrain sin pasar por el modelo.

Para cuando el archivo ya existe en disco. **Sólo artefactos LIVIANOS: hasta 20 KB.** Medí el archivo ANTES (`wc -c ARCHIVO`) y pasalo en `bytes`. Si pasa de 20 KB no lo intentes por ningún camino del MCP: decile al usuario que lo guarde con la extensión de Chrome de Secondbrain (pestaña «Artefactos» → «Sincronizar»).

Devuelve una upload_url. El PUT la termina: sube el archivo Y crea la versión de una. NO hay segundo llamado.

  curl -X PUT "<upload_url>" --data-binary @mi-artefacto.html

Con artifact_id agrega una versión nueva a uno que ya existe; sin él crea uno nuevo.

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": {
      "name": "<name>",
      "bytes": "<bytes>"
    },
    "name": "start_artifact_upload"
  }
}

Input Schema

NameRequiredDescriptionDefault
nameYesNombre del artefacto
tipoNoQué es el contenido del archivo (default: html)
bytesYesCuánto pesa el archivo, en bytes (`wc -c ARCHIVO`). Se valida ANTES de subir: arriba del tope no se guarda.
origenNo
artifact_idNoPara actualizar uno existente
document_idNoDocumento del que cuelga
workspace_idNoUUID del workspace, o su nombre tal como lo dice el usuario ('Acme', 'el personal'). Omitir si el token ya tiene workspace fijo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed2 schema fields changed
    • addedInput schema / properties / bytes
      Added value: +{
      +  "description": "Cuánto pesa el archivo, en bytes (`wc -c ARCHIVO`). Se valida ANTES de subir: arriba del tope no se guarda.",
      +  "minimum": 1,
      +  "type": "integer"
      +}
    • changedInput schema / required
      Previous value: -[
      -  "name"
      -]New value: +[
      +  "name",
      +  "bytes"
      +]
  2. First observed

TDQS

A4.4/5.0
Behavior5/5

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

Annotations only say this is a non-read-only, non-destructive, non-idempotent write; the description adds the operationally decisive facts: a 20 KB cap validated before upload, the two-phase flow, and that the PUT both uploads the file and creates the version in one shot with no second call. It also shows the literal curl invocation, which is the actual contract an agent must fulfill.

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 the purpose, then the size gate, then a runnable example, then the artifact_id rule — a sensible order. The 20 KB limit is stated twice (bold rule plus escalation path), which is deliberate emphasis rather than padding, but it does add length to an otherwise tight definition.

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 7-parameter mutation tool with no output schema, it covers the essentials: what comes back (upload_url), how to finish the operation, and the size precondition. It leaves failure modes (expired URL, rejected PUT, version conflicts) and the relationship to the finish_artifact_upload sibling unstated, though the 'NO hay segundo llamado' line preempts the worst confusion.

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 already 86%, so the baseline is 3. The description goes beyond it for the two parameters that carry real risk: bytes must be measured first with `wc -c ARCHIVO` and is validated server-side against the cap, and artifact_id switches the call from create to add-version. origen and document_id are left to the schema.

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?

States a specific verb and resource plus the defining mechanism: the file goes from disk to Secondbrain without passing through the model, and an upload_url is returned. That mechanism separates it from save_artifact, but the description never names a sibling, so an agent comparing it against start_document_upload gets no explicit disambiguation.

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 trigger ('Para cuando el archivo ya existe en disco'), an explicit hard exclusion with a redirect ('Si pasa de 20 KB no lo intentes por ningún camino del MCP' → Chrome extension, Artefactos → Sincronizar), and a decision rule for artifact_id (new version vs. new artifact). Nothing about when to reach for this tool 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