MCP server

Boot a built-in MCP server on stdio that exposes every CLI command as a tool, with provider and credentials bound at startup.

files ... mcp boots an MCP server on stdio that exposes every CLI command as a tool — upload, download, head, exists, delete, copy, move, list, url, sign-upload, and transfer. The provider and credentials are bound at server startup; the agent only passes operation arguments, never secrets.

The tools mirror the CLI surface: upload accepts multipart, download accepts a byte range, head/exists/delete take arrays of keys plus concurrency/stopOnError, list accepts all to walk every page, and transfer takes a destination provider config (to) to copy objects across backends.

# Start the MCP server on stdio
files --provider s3 --bucket uploads mcp
// Wire it into Claude Code (~/.claude.json or .claude/mcp.json)
{
  "mcpServers": {
    "files-sdk": {
      "command": "files",
      "args": ["--provider", "s3", "--bucket", "uploads", "mcp"],
      "env": {
        "AWS_ACCESS_KEY_ID": "...",
        "AWS_SECRET_ACCESS_KEY": "...",
      },
    },
  },
}

Binary payloads are roundtripped as base64 over MCP, so binary downloads (download) and uploads (upload with a base64 body) survive intact.