Skip to main content
Glama
tecspda

listmonk-mcp-ts

upload_media_file

Upload a file from the configured sandbox directory to the Listmonk media library and get its ID and public URL for use in campaign bodies.

Instructions

Upload a file from LISTMONK_MCP_FILES_DIR to the Listmonk media library and return its ID and public URL for use in campaign bodies. Fails if LISTMONK_MCP_FILES_DIR is not set or the path is outside it. Image types (jpg, png, gif, webp, svg) get the right MIME type; other types upload as generic binary and Listmonk may reject them.

Input Schema

NameRequiredDescriptionDefault
titleNoDisplay title in the media library; defaults to the filename
file_pathYesPath to the media file inside LISTMONK_MCP_FILES_DIR (absolute or relative to it)

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv0.1.1
    • changedInput schema / properties / title / description
      Previous value: -"Title"New value: +"Display title in the media library; defaults to the filename"
  2. First observed

TDQS

A4.3/5.0
Behavior4/5

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

Beyond the annotations (mutation, non-idempotent, non-destructive), it discloses real behavioral traits: a filesystem sandbox constraint, the failure mode when the path escapes it, and MIME-type handling with the caveat that non-image types are sent as generic binary and may be rejected by Listmonk. It does not address what happens on repeat uploads of the same path (duplicate vs. overwrite), which is the main remaining gap.

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 dense sentences with zero filler: purpose and returns first, constraints second, type-handling caveat last. Every clause carries actionable information.

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?

For a 2-parameter tool with full schema coverage and no output schema, the description covers purpose, return values (ID and public URL), the directory precondition, and the file-type limitation an agent needs to avoid a failed upload. Nothing material is missing.

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%, so both parameters are already documented, giving a baseline of 3. The description reinforces the sandbox constraint on file_path but never mentions the title parameter or its filename default, adding only marginal meaning over the schema.

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 and resource ("Upload a file ... to the Listmonk media library") and names the concrete outputs (ID and public URL) plus the downstream use (campaign bodies). It is clearly distinguishable from siblings like get_media_list, rename_media, and delete_media_file.

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

Usage Guidelines4/5

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

Establishes the operating context: the file must live under LISTMONK_MCP_FILES_DIR, and it fails if that variable is unset or the path escapes the directory. It does not name an alternative sibling or state when not to use this versus another upload path, so it stops short of explicit routing.

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