Skip to main content
Glama
mcp-curl-downloader

mcp-curl-downloader

by mutoukenji

mcp-curl-downloader

npm version npm downloads node license

MCP server for downloading files via HTTP/HTTPS — like curl but integrated with AI assistants (Claude Desktop, VS Code, Cursor, etc.).

Quick Start

npx -y mcp-curl-downloader

No installation needed. The server starts on stdio and speaks the Model Context Protocol (MCP).

Related MCP server: MCP File Downloader

Claude Desktop Configuration

Add to your claude_desktop_config.json:

{
  "mcpServers": {
    "curl-downloader": {
      "command": "npx",
      "args": ["-y", "mcp-curl-downloader"]
    }
  }
}

Config file location:

  • macOS: ~/Library/Application Support/Claude/claude_desktop_config.json

  • Windows: %APPDATA%\Claude\claude_desktop_config.json

Tool: download_file

Downloads a file from a URL to any local directory or file path.

Parameters

Parameter

Type

Required

Default

Description

url

string

yes

—

File URL (http/https only)

dest_path

string

yes

—

Destination directory or full file path

filename

string

no

auto-detected

Custom filename (only when dest_path is a directory)

headers

object

no

{}

HTTP headers as key-value pairs

overwrite

boolean

no

false

Overwrite existing file

Examples

Download to a directory (filename auto-detected from URL):

{
  "url": "https://example.com/report.pdf",
  "dest_path": "/home/user/downloads"
}

Download with custom filename:

{
  "url": "https://example.com/data.csv",
  "dest_path": "/tmp",
  "filename": "my_data.csv"
}

Download with auth headers:

{
  "url": "https://api.example.com/export",
  "dest_path": "./output.json",
  "headers": { "Authorization": "Bearer token123" }
}

Overwrite existing file:

{
  "url": "https://example.com/latest.zip",
  "dest_path": "/home/user/archive.zip",
  "overwrite": true
}

Response

Success:

{
  "success": true,
  "file_path": "/home/user/downloads/report.pdf",
  "file_size": 1048576,
  "content_type": "application/pdf",
  "message": "Successfully downloaded: /home/user/downloads/report.pdf (1.00 MB)"
}

Failure:

{
  "success": false,
  "error": "File already exists: \"/home/user/downloads/report.pdf\". Set overwrite=true to replace.",
  "url": "https://example.com/report.pdf",
  "dest_path": "/home/user/downloads"
}

Security

  • Protocol whitelist: Only http: and https: are allowed

  • URL validation: Malformed URLs are rejected

  • Path traversal protection: Filenames are sanitized (../, Windows-illegal characters, control characters removed)

  • File size limit: 500 MB default (configurable via CONFIG.MAX_FILE_SIZE)

  • Overwrite protection: Existing files are not overwritten unless overwrite: true

  • Timeout: 5 minutes per download (configurable via CONFIG.TIMEOUT_MS)

Development

# Install dependencies
npm install

# Build
npm run build

# Watch mode
npm run dev

# Test with MCP Inspector
npx @modelcontextprotocol/inspector node dist/index.js

Requirements

  • Node.js >= 18 (uses built-in fetch and stream/promises)

License

MIT

Available Tools

1 tool
download_fileA

Download a file from a URL to a local directory or file path.

Features:

  • Supports HTTP and HTTPS protocols

  • Streams large files efficiently (no memory pressure)

  • Auto-detects filename from URL or Content-Disposition header

  • Creates parent directories automatically

  • Configurable timeout (300s) and size limit (500MB)

  • Safe filename sanitization (removes dangerous characters)

Examples:

Inputs: url (required), dest_path (required), headers, filename, +1 more.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    A4.1/5.0

    Scored across 1 tool

    Disambiguation5/5

    There is only one tool, so there is zero ambiguity between tools. The tool has a single, clearly defined purpose: downloading files from a URL.

    Naming Consistency3/5

    With only one tool, there is no pattern to evaluate for consistency. The name 'download_file' uses a reasonable verb_noun convention, but a single tool doesn't demonstrate any naming system.

    Tool Count2/5

    A single tool feels thin for a downloader server. The downloader domain could reasonably include tools like list_directory, delete_file, or check_file_status to provide a more complete surface, though a minimalist download-only server is defensible.

    Completeness2/5

    The tool covers download functionality well, but represents a dead-end surface. There is no way to check whether a download succeeded (no status/history), no way to remove downloaded files, or resolve/validate URLs before downloading. Agents hit a hard wall after invoking download_file.

    Maintenance

    ActivityInactive
    ResponsivenessNo recent community issues

    Related MCP Connectors

    Related MCP Servers