MCP Server for LLM Automation

WinSysClean ships with an MCP (Model Context Protocol) server that lets a large-language-model host — such as LM Studio, Claude Desktop, or Cursor — scan and clean your computer for you. The LLM can ask WinSysClean to run a scan, show you what it found, change which options are enabled, and fix the problems.

How it works

The MCP server is a small bridge program, WinSysCleanMCP.exe, that speaks the standard MCP stdio protocol. When the LLM calls a tool, the bridge starts WinSysClean.exe in a special background worker mode, performs the operation, returns the result, and keeps the worker running so the next call reuses it.

The first tool call after a restart asks for a UAC elevation prompt. Accept it once — the elevated worker then stays alive and later calls do not prompt again.

Default installation folder

The MCP files are installed together with WinSysClean:

  • PRO edition: C:\Program Files\WinSysClean X13 PRO
  • FREE edition: C:\Program Files\WinSysClean X13 FREE

The two files you need are:

File Purpose
WinSysCleanMCP.exe The MCP server (bridge).
WinSysClean.exe The worker that actually performs scans and fixes.

Keep both files in the same folder. The bridge starts the worker beside itself, so do not move one without the other.

Registering the server in LM Studio

  1. In LM Studio, open Settings → Tools (or Developer → MCP servers).
  2. Add a new stdio server named winsysclean.
  3. Set the command to the full path of WinSysCleanMCP.exe, for example: C:\Program Files\WinSysClean X13 PRO\WinSysCleanMCP.exe
  4. Save and start the server. Wait until LM Studio shows it as connected.
  5. Open a chat with an agent model, and the winsysclean tools become available.

The server also supports the Content-Length framing used by other MCP clients, not only the newline-delimited framing LM Studio uses.

Sample configuration

Here is a complete .mcp.json you can drop into your project or client configuration folder:

{
  "mcpServers": {
    "winsysclean": {
      "type": "stdio",
      "command": "C:\\Program Files\\WinSysClean X13 PRO\\WinSysCleanMCP.exe",
      "args": []
    }
  }
}

For the free edition, change the path to C:\Program Files\WinSysClean X13 FREE\WinSysCleanMCP.exe.

Available tools

The MCP server exposes seven tools:

Tool Arguments What it does
scan none Enumerates all enabled cleaning problems (registry entries and junk files) without deleting anything. Returns registryProblems and junkFiles counts. Run this before fix.
fix none Deletes the problems recorded by the most recent scan. Returns registryRemoved and filesRemoved counts.
list_options none Returns the current enabled/disabled state of every cleaning option (keys such as Items.EmptyRecycleBin, RegistryItems.DelRegInvalidOLE).
set_options options (object) Enables or disables one or more cleaning options, e.g. {"Items.EmptyRecycleBin": true, "RegistryItems.DelRegInvalidOLE": false}. Persisted in the registry.
get_scan_log type (optional string) Returns the full per-problem list from the most recent scan. Set type to "registry" or "files" to filter.
list_apps none Returns all installed apps the App Cleaner can clean, with id, name, category, description, selection state, and safe-to-clean flag.
set_apps apps (object) Selects or deselects App Cleaner apps by id, e.g. {"12": true, "34": false}. Persisted to the app database.

Example conversation

A typical flow for an assistant:

  1. list_options → find the current settings.
  2. set_options → enable exactly the cleaning options you want.
  3. scan → find out how much junk exists (nothing is removed).
  4. get_scan_log → review what was found before touching anything.
  5. fix → delete the recorded problems.

Safety notes

  • scan never deletes anything — it only reports what it found.
  • fix deletes only what the most recent scan recorded.
  • set_options and set_apps change persisted settings, so they affect future scans and fixes — verify with list_options or list_apps if you are unsure.
  • Cleaning operations require elevated rights. Accept the UAC prompt on the first call so the worker can run with administrator privileges.