Skip to main content
Glama

download_attachment

Download uploaded files from GitLab projects using project ID, secret, and filename to retrieve attachments locally.

Instructions

Download an uploaded file from a GitLab project by secret and filename

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
project_idYesProject ID or URL-encoded path of the project
secretYesThe 32-character secret of the upload
filenameYesThe filename of the upload
local_pathNoLocal path to save the file (optional, defaults to current directory)

Implementation Reference

  • Input schema definition for the 'download_attachment' MCP tool, defining parameters for downloading GitLab uploads/attachments using project ID, secret, filename, and optional local save path.
    export const DownloadAttachmentSchema = z.object({
      project_id: z.string().describe("Project ID or URL-encoded path of the project"),
      secret: z.string().describe("The 32-character secret of the upload"),
      filename: z.string().describe("The filename of the upload"),
      local_path: z.string().optional().describe("Local path to save the file (optional, defaults to current directory)"),
    });
Behavior2/5

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

No annotations are provided, so the description carries the full burden. It states the tool downloads a file but doesn't disclose behavioral traits like authentication requirements, rate limits, error handling, or what happens if the file doesn't exist. It mentions saving to a local path but doesn't specify default behavior or permissions needed.

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?

The description is a single, efficient sentence with zero waste. It's front-loaded with the core purpose and includes key identifiers. Every word earns its place without redundancy.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given no annotations and no output schema, the description is minimally complete for a download tool but lacks details on authentication, errors, or return values. It covers the basic purpose and parameters but doesn't fully address the complexity of file operations in GitLab, leaving gaps for the agent to infer behavior.

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 the schema already documents all parameters thoroughly. The description adds minimal value by mentioning 'secret and filename' as identifiers, but doesn't provide additional context beyond what's in the schema descriptions. Baseline 3 is appropriate when schema does the heavy lifting.

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 clearly states the action ('Download'), the resource ('an uploaded file'), and the context ('from a GitLab project'), with specific identifiers ('by secret and filename'). It distinguishes from sibling tools like 'download_release_asset' by specifying it's for uploaded files accessed via secret, not release assets.

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 description implies usage when you have a secret and filename for an uploaded file in a GitLab project, but it doesn't explicitly state when to use this versus alternatives like 'download_release_asset' or 'get_file_contents'. No exclusions or prerequisites are mentioned.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/zereight/gitlab-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server