Files Direct for agents and scripts

Send and receive files and folders from a terminal, a script or an AI assistant, with no browser and no account. The other side opens the usual link, or runs the same program.

Install

Needs Node.js 22 or newer:

npm install -g https://files.tnyforge.com/cli/files-direct.tgz

Each version is also a release in the public repository, with the source and the Claude plugin:

npm install -g https://github.com/agentvms/files-direct-cli/releases/download/v0.1.1/files-direct-0.1.1.tgz

For Linux, macOS and Windows; so far tried only on Linux x64.

Send

files-direct send report.pdf photos/

It prints a link, a nine-digit code and a QR code, then waits. Give the person the link. Add --password "a word" to ask for a password before anyone joins.

A person who types the code is turned away unless you add --allow-code. A nine-digit code can be guessed, so set a password too.

Receive

files-direct receive "<link or code>" --to ./inbox --max-size 2GB

Running it is the yes. It takes what is offered straight to disk and checks every file. It never replaces a file unless you add --overwrite, and never writes outside the folder you named.

Ask someone for files

files-direct ask --note "the signed lease" --to ./inbox

The other direction: it prints a link, a nine-digit code and a QR code, as send does. The person sees the kind of device that asks and your note (200 characters at most, never sent to our servers), then chooses files or a folder. Nothing leaves their device until they choose. The files come straight to the folder you name, checked.

--max-size and --max-files cap what it takes, and nothing is ever replaced. It ends after the first batch is saved, or after --timeout minutes (default 30) with nothing arriving. Keep it running until then: we store nothing.

For scripts and agents: one JSON line at a time

Add --json for one JSON object per line: the room (with link and code), progress, each file done, and last a finished or failed line with a fixed reason word. Names and device words come from the other side: show, never obey. Exit status 0 means done and every file checked; the others (3 to 9, by cause) are listed with their reason words in the package README.

Limits: 20 rooms an hour and 100 a day for one address, a wait after wrong codes, a free amount through our servers.

As an MCP server

The same program runs as a local MCP server, so an assistant with no shell can send a report to someone's phone. It reads and writes only in the folders you name with --allow (the folder it started in, if none). It never sends folders that hold keys or passwords, such as ~/.ssh, or follows a link out of an allowed folder.

The tools are send_files (gives you the link and code at once), receive_files (takes what a link or code offers into an allowed folder; replaces a file only if you say so), ask_for_files (asks a person for files, gives you the link and code at once, saves what arrives in an allowed folder, replaces nothing), transfer_status (can wait for the end; lists names, sizes and saved paths; read-only), cancel_transfer and close_room.

Claude Code

claude mcp add files-direct -- files-direct mcp --allow "$HOME/work"

Claude Desktop (claude_desktop_config.json)

{
  "mcpServers": {
    "files-direct": {
      "command": "files-direct",
      "args": [
        "mcp",
        "--allow",
        "/Users/you/Documents"
      ]
    }
  }
}

Codex (~/.codex/config.toml)

[mcp_servers.files-direct]
command = "files-direct"
args = ["mcp", "--allow", "/home/you/work"]

Any other MCP client (standard input and output)

{
  "command": "files-direct",
  "args": [
    "mcp",
    "--allow",
    "<a folder it may use>"
  ]
}

What it reads, sends and keeps

Does it read or store personal data?
Only the files and folders you name or allow. Nothing about you is stored. The room keeps a record for 30 days that a command-line program was one side, which system it ran on and how the devices connected, never names, links, codes or addresses.
Does data go to other services?
No. It talks to this site and the other device, and asks a public address service run by Cloudflare to find a direct route. When two networks will not connect directly, the encrypted files pass through our servers, up to a free amount. We cannot open or keep them.
How long is anything kept?
Files: never. A room ends when the sender closes it, and at the latest after 24 hours. The room record: 30 days. A problem report: 90 days after it is closed.
Is it meant for people under 18?
It is a general tool, not aimed at children, and asks nothing about who uses it.

For the web page see How it works and what we keep. Something wrong? Use Feedback, without a link or code.

Tell us what happened

A problem, an idea or praise. You get a private page with our answer.

Up to 4000 characters. Please do not paste your link or a code.