Administration with an AI assistant - MCP Server

The MCP Server lets an AI assistant such as Claude administer your CompleteFTP server. Instead of clicking through CompleteFTP Manager or remembering command-line syntax, you describe what you want in plain English. For example, you might type "add a user called fred and give him a home folder", and the assistant carries it out by calling CompleteFTP for you.

MCP (Model Context Protocol) is simply the open standard that lets AI assistants use external tools. CompleteFTP's MCP server exposes every command-line (CLI) command as a tool that the assistant can call, plus some built-in tools for looking up documentation. You don't need to understand the protocol to use it. You just connect your assistant to CompleteFTP and start asking.

The MCP server is available in all editions of CompleteFTP from version 26.1.0 onwards.

What you can do with it

Every CompleteFTP command-line command is available to the assistant as a tool (over 100 in total, covering users, folders, groups, sites, triggers, extensions, notifications, licensing and monitoring). In other words, anything you can configure from the command line, which is almost the entire server, you can now ask for in plain language. Some examples of what you might say to your assistant:

The assistant works out which CompleteFTP commands to run, runs them, and tells you what it did. It can also explain your existing configuration, which makes it useful even if you only ever let it read (see Read-only mode).

What you'll need

A word on safety. When not in read-only mode, the assistant can change your server's configuration: it can add and remove users, change folders and permissions, and modify site settings. It runs with the privileges of whoever started it. Treat access to it as you would administrator access to CompleteFTP itself, and start in read-only mode while you get a feel for it.

Getting started

There are four steps: enable the administration channel, point your assistant at CompleteFTP, run the assistant as administrator (on Windows), and confirm the connection.

Step 1: Enable the administration channel

The MCP server talks to CompleteFTP through its local administration channel (the same channel the CLI uses). This channel must be running first.

On Linux, the administration channel is enabled by default, so there is nothing to do; skip to Step 2.

On Windows, it is not enabled by default. Enable it by adding the --enable-admin-cli argument to the CompleteFTP Windows service and restarting the service. In an administrator Command Prompt or PowerShell (adjust the path if you installed CompleteFTP elsewhere):

sc config CompleteFTP binpath= "\"C:\Program Files\Complete FTP\Server\CompleteFTPService.exe\" --enable-admin-cli"
sc stop CompleteFTP
sc start CompleteFTP

Note the space after binpath=; it is required. Then verify the channel is working:

"C:\Program Files\Complete FTP\Server\completeftp.exe" user list

If this prints a list of users (rather than an error about connecting to the admin channel), the channel is enabled and you are ready for Step 2. For more detail, see Windows Command-Line Interface (CLI) under Enabling the CLI.

This Windows step is temporary. A future release will have the administration channel enabled by default, or allow it to be turned on from CompleteFTP Manager, so that editing the service arguments will no longer be necessary.

Step 2: Point your assistant at CompleteFTP

You connect an assistant by telling it the command to run for the MCP server. You do not start the MCP server yourself; the assistant launches it in the background when it needs it. Each assistant has its own configuration file, so follow the section for the one you use.

In both cases, set command to the full path of completeftp.exe in your CompleteFTP installation. On a default Windows installation this is the Server folder shown below; if you installed elsewhere, adjust it to match. Use double backslashes (\\) in the path, as shown. The --read-only argument starts in read-only mode, which is the recommended way to begin; later, when you are comfortable, remove it to let the assistant make changes.

Claude Code

Claude Code reads MCP servers from an .mcp.json file. Add a completeftp entry under mcpServers. A complete file looks like this:

{
	"mcpServers": {
		"completeftp": {
			"command": "C:\\Program Files\\Complete FTP\\Server\\completeftp.exe",
			"args": ["mcp", "--read-only"]
		}
	}
}

If the file already has an mcpServers section, add just the "completeftp" entry inside it (separated from any existing entries with a comma). There should only ever be one mcpServers section.

Codex

Codex reads MCP servers from %USERPROFILE%\.codex\config.toml (create the file if it doesn't exist). Add the following section:

[mcp_servers.completeftp]
command = "C:\\Program Files\\Complete FTP\\Server\\completeftp.exe"
args = ["mcp", "--read-only"]

Save the file when you're done.

Step 3: Start your assistant from an administrator terminal

On Windows, completeftp.exe requires elevation (it runs "as administrator"). Your assistant launches the MCP server itself, so the assistant must also be running with administrator privileges. Open a terminal as administrator (right-click Command Prompt, Windows Terminal or PowerShell and choose Run as administrator), then start your assistant from it: run claude for Claude Code, or codex for Codex.

This step is temporary. A future release will not require elevation for the mcp command, so starting the assistant from an administrator terminal will no longer be necessary. If you skip this step, you will see an error such as spawn ... EACCES or Cannot connect to admin channel 'CompleteFTP_config' when the assistant tries to use CompleteFTP.

Step 4: Confirm the connection

Check that the assistant has loaded the CompleteFTP MCP server. In Claude Code, run /mcp; in Codex, run /mcp (or codex mcp list from the command line). You should see completeftp listed.

To check that everything is working end-to-end, ask the assistant something harmless, such as:

If the assistant replies with your server's version, edition and licensing, you're connected and ready to go.

A worked example

Once connected, you work entirely in plain language. A typical exchange looks like this:

You:
Add a user called fred with a home folder, then turn off FTP for him so he can only use SFTP.
Assistant:
I've added the user fred with a home folder at /Home/fred and disabled FTP, so he can connect via SFTP only.

Behind the scenes, the assistant carried out the same operations as the equivalent CLI commands (completeftp user add fred and completeftp user set fred ftpEnabled=false), but you never had to type them or look up the property names.

Tip: keep CompleteFTP Manager open while you work with the assistant to watch changes appear live. For example, when the assistant adds a user, the new user shows up in CompleteFTP Manager within a couple of seconds. This is a reassuring way to confirm that the assistant is doing exactly what you asked.

Read-only mode

Read-only mode is the safe way to explore the feature, because it hides every tool that could change your configuration. With --read-only set, the assistant can still:

It cannot add, change or remove anything. This is ideal for letting an assistant audit or explain your configuration, and for building confidence before you give it the ability to make changes. To allow changes, remove the --read-only argument from your assistant's configuration and restart it.

Reference

The completeftp mcp command

The MCP server is the mcp sub-command of the completeftp program. As noted above, you don't normally run it yourself; your assistant runs it for you. It accepts the following options, which you can include in the args list of your assistant's configuration:

--read-only
Only expose tools that read configuration (the show, list and listall commands, plus the documentation and status tools). All tools that would change the configuration are hidden. See Read-only mode. Defaults to off.
--uds-path
The path to the administration channel the MCP server uses to talk to CompleteFTP. The default is correct for a standard installation, so this rarely needs to be set.
--docs-db
The path to the bundled documentation archive (mcp-docs.zip) used by the documentation tools. It is auto-detected for a standard installation, so this rarely needs to be set. If it can't be found, the server still runs, but the documentation lookup tools are unavailable.
If you run completeftp mcp directly in a terminal, it will appear to hang. That is normal: it is waiting for an MCP client to send it messages on its standard input. Press Ctrl+C to stop it.

A summary of the command and its options is also available with the -h option:

completeftp mcp -h

How it works

Your assistant launches completeftp mcp as a background process and exchanges messages with it over the process's standard input and output, using the JSON-RPC 2.0 protocol. When you ask the assistant to do something, it chooses the appropriate tool, calls it through the MCP server, and the MCP server carries it out against CompleteFTP via the local administration channel. No new network ports are opened.

The documentation tools

Besides the configuration commands, the assistant has a few built-in tools that let it look up CompleteFTP's own documentation so that its answers and the commands it chooses stay accurate. You never call these yourself; the assistant uses them in the background. They cover CLI help, this User Guide, the JSS (server-side JavaScript) API reference, and server status.

Troubleshooting

The assistant doesn't list CompleteFTP among its tools
Check that the command path in the configuration points to completeftp.exe in your CompleteFTP installation directory, that the first entry in args is mcp, and that you restarted the assistant after editing its configuration.
You see spawn ... EACCES
The assistant is not running as administrator, so Windows won't let it start completeftp.exe (which currently requires elevation). Start the assistant from an administrator terminal, as described in Step 3.
You see Cannot connect to admin channel 'CompleteFTP_config'
The MCP server started, but it could not reach CompleteFTP through the administration channel. This has two common causes, in order of likelihood:
  1. The administration channel is not enabled. On Windows it is off by default. Complete Step 1 and confirm it with the user list check shown there before trying again.
  2. The assistant is not running as administrator, so it can't access the channel. Start it from an administrator terminal, as described in Step 3.
Also make sure the CompleteFTP service is actually running on the same machine.
The assistant can read settings but can't change anything
It is running in read-only mode. Remove the --read-only argument and restart the assistant to allow changes.
The assistant's answers seem out of date or it can't look things up
The documentation archive (mcp-docs.zip) could not be found. It ships with a standard installation; if you've moved it, point to it with the --docs-db option.

See also