Skip to main content

Documentation Index

Fetch the complete documentation index at: https://mintlify.com/XxYouDeaDPunKxX/chatgpt-local-agent-mcp/llms.txt

Use this file to discover all available pages before exploring further.

Process tools manage background processes, port visibility, and log streams on the local Windows machine. All seven tools require the mcp:process scope. The group divides naturally into read-only observation tools (process_list, port_list, tail_log), a diagnostic polling tool (wait_for_port), and mutative operate tools (start_process, stop_process, process_kill). The operate tools are additionally gated by the operate policy mode, and start_process is governed by GPT_FS_MCP_PROCESS_POLICY.

Tool reference

1. process_list

AttributeValue
Required scopemcp:process
Policy modeobserve
Risk tagsprocess-disclosure
Lists running operating-system processes. On Windows, queries Win32_Process via PowerShell. On Linux/macOS, runs ps -eo. Parameters
ParameterTypeDefaultDescription
includeCommandLinebooleanfalseWhether to include the full redacted command line for each process.
maxProcessesnumber500Maximum number of processes to return (max 2000). Truncation is indicated by truncated: true.
Response fields: processes (array of { pid, name, parentPid?, commandLine? }) and truncated boolean.

2. port_list

AttributeValue
Required scopemcp:process
Policy modeobserve
Risk tagsnetwork-disclosure
Lists listening TCP/UDP ports using netstat. Reveals which ports are open and which PIDs own them. This information may disclose internal service topology. Parameters
ParameterTypeDefaultDescription
protocol"tcp" | "udp" | "all""all"Filter output by protocol family.
Response fields: ports (array of { localAddress, localPort, pid, protocol, remoteAddress?, remotePort?, state? }).

3. tail_log

AttributeValue
Required scopemcp:process
Policy modeobserve
Risk tagslog-read
Reads the tail of a log file or the captured stdout/stderr of a managed process started by start_process. Prefer this over shell Get-Content -Tail, tail, or polling. You can address a log either by managed processId (which bypasses path checks since the server owns that file) or by an explicit path. Parameters
ParameterTypeDefaultDescription
processIdstring (UUID)ID returned by start_process. Use this to tail stdout/stderr without a file path.
pathstringLog file path to tail. Required if processId is not provided.
cwdstringBase directory for resolving a relative path.
stream"stdout" | "stderr""stdout"Which stream to read when using processId.
maxBytesnumber100000Maximum bytes to read from the tail (max 1,000,000).
Response fields: content (string), bytesRead, path (resolved absolute path), truncated.

4. wait_for_port

AttributeValue
Required scopemcp:process
Policy modediagnose
Risk tagsnetwork-probe
Polls a TCP host:port until it becomes reachable or the timeout elapses. By default only loopback addresses (localhost, 127.0.0.1, ::1) are allowed; pass allowRemote: true to reach non-loopback hosts. Parameters
ParameterTypeDefaultDescription
portnumber(required)TCP port number to probe (1–65535).
hoststring"127.0.0.1"Hostname or IP to connect to.
allowRemotebooleanfalseAllow non-loopback hosts. Required for anything other than localhost.
intervalMsnumber250Polling interval in milliseconds (max 10,000).
timeoutMsnumber30000Total wait timeout in milliseconds (max 120,000).
Response fields: reachable (boolean), host, port, elapsedMs. Returns isError: true if the port was not reached before timeout.

5. start_process

AttributeValue
Required scopemcp:process
Policy modeoperate
Risk tagsrce, process, long-running
Policy env varGPT_FS_MCP_PROCESS_POLICY
Starts a long-running background process — the preferred alternative to shell Start-Process, npm start, npm run dev, Vite, or any command that should keep running after the MCP request completes. Stdout and stderr are captured to managed log files that survive the MCP request boundary. The server tracks up to 100 concurrent managed processes. This tool defaults to dryRun: true. A dry run returns the resolved command, path hints, and any warnings without actually launching anything. Set dryRun: false and confirm: true to execute. Command policy Governed by GPT_FS_MCP_PROCESS_POLICY:
Policy valueBehavior
disabledAll start_process calls are rejected.
workspace_guardedPath tokens in the command and cwd are verified against workspace profile roots before launching.
fullNo workspace path restriction; the process runs wherever cwd points.
Parameters
ParameterTypeDefaultDescription
commandstring(required)The command to run as a background process.
cwdstring(required)Working directory for the process. Resolved and checked against workspace policy.
dryRunbooleantrueWhen true, validates and returns a preview without launching.
confirmbooleanfalseMust be true when dryRun is false.
maxLogBytesnumber1000000Per-stream log cap in bytes (max 50,000,000). Logs are truncated at this limit.
Response fields (live run): processId (UUID), pid, cwd, commandRedacted, stdoutPath, stderrPath, maxLogBytes, effectivePathHints, warnings.
Use the returned processId with tail_log, stop_process, and to identify the process in process_list output.

6. stop_process

AttributeValue
Required scopemcp:process
Policy modeoperate
Risk tagsprocess-kill
Gracefully stops a process that was started by start_process. On Windows, uses taskkill /PID … /T /F; on Linux/macOS, sends SIGTERM. Like start_process, defaults to dryRun: true. Parameters
ParameterTypeDefaultDescription
processIdstring (UUID)(required)The processId returned by start_process.
dryRunbooleantruePreview without stopping.
confirmbooleanfalseMust be true when dryRun is false.
Response fields: stopped, exited, pid, processId, code, stdout, stderr.

7. process_kill

AttributeValue
Required scopemcp:process
Policy modeoperate
Risk tagsprocess-kill
Force-kills any process by OS PID — not limited to managed processes. On Windows, uses taskkill /PID … /T /F (tree kill by default). Defaults to dryRun: true.
process_kill is irreversible. Killing the wrong PID can terminate user applications, editors, databases, or background services with no recovery path for unsaved state. Always perform a dry run first and verify name/commandLine in the response before setting confirm: true.
Parameters
ParameterTypeDefaultDescription
pidnumber(required)OS process ID to kill.
dryRunbooleantruePreview the kill target without executing.
confirmbooleanfalseMust be true when dryRun is false.
treebooleantrueKill the entire process tree (child processes included).
expectedNamestringGuard: reject if the process name doesn’t match.
expectedCommandSubstringstringGuard: reject if the command line doesn’t include this substring.
allowCriticalbooleanfalseAllow killing processes flagged as critical (e.g. cloudflared). Requires explicit opt-in.
Response fields: killed, pid, name, commandLine, code, stdout, stderr.

Practical workflow: start a dev server

A common pattern is to start a dev server, wait for its port to become available, then tail its log to verify startup.
// Step 1 — dry run to preview
{
  "tool": "start_process",
  "arguments": {
    "command": "npm run dev",
    "cwd": "C:\\Users\\dev\\projects\\my-app",
    "dryRun": true
  }
}

// Step 2 — confirm and launch
{
  "tool": "start_process",
  "arguments": {
    "command": "npm run dev",
    "cwd": "C:\\Users\\dev\\projects\\my-app",
    "dryRun": false,
    "confirm": true
  }
}

// Step 3 — wait for the server to be ready
{
  "tool": "wait_for_port",
  "arguments": {
    "port": 5173,
    "host": "127.0.0.1",
    "timeoutMs": 30000
  }
}

// Step 4 — tail the stdout log
{
  "tool": "tail_log",
  "arguments": {
    "processId": "<uuid from step 2>",
    "stream": "stdout",
    "maxBytes": 50000
  }
}

See also

  • Command Policies — reference for GPT_FS_MCP_PROCESS_POLICY and workspace path enforcement

Build docs developers (and LLMs) love