Skip to main content
Glama

Server Configuration

Describes the environment variables required to run the server.

NameRequiredDescriptionDefault
TERMUX_MCP_CONFIGNoPath to the configuration file, overriding the default `~/.config/termux-mcp/config.json`.

Instructions

Guidance the server publishes about itself, which clients place ahead of the tool catalog so the model reads it before choosing anything.

This server publishes no instructions, or was last inspected before Glama recorded them.

Capabilities

Features and capabilities supported by this server

Protocol revision2025-11-25

CapabilityDetails
tools
{
  "listChanged": true
}
logging
{}
prompts
{
  "listChanged": true
}
resources
{
  "subscribe": false,
  "listChanged": true
}

Tools

Functions exposed to the LLM to take actions

NameDescription
run_commandA

Run a command with bash -c as the Termux user and return exit code, stdout, stderr, duration and truncation flags. Use cwd for the working directory and timeout_sec for long jobs. There is no command allow list: the command runs with the full permissions of the Termux user. A non-zero exit code is returned as data, not as a tool failure. For long-running or interactive work use the task_* or terminal_* tools.

read_fileA

Read a file from an allowed directory (home, shared storage or Termux tmp) as text. Supports line offsets and line numbering. Binary files must be read with encoding="base64". Large reads are limited by security.maxReadBytes.

write_fileA

Create, overwrite or append to a text file inside an allowed directory. Writes are atomic for overwrite mode. Parent directories can be created automatically. Content is returned as a small JSON summary.

edit_fileA

Replace an exact string in a UTF-8 text file. By default old_string must occur exactly once; use replace_all to replace every occurrence. The file is written atomically.

list_dirA

List files and subdirectories with type, size, modification time and permissions. Symlinks are reported but not followed. Hidden entries are skipped unless show_hidden=true.

stat_pathA

Return stat information for a file, directory or symlink, including size, permissions, timestamps and the resolved real path.

mkdirB

Create a directory. Parent directories are created by default.

copy_pathA

Copy a file or directory to another path. Directories are copied recursively; existing destinations require overwrite=true.

move_pathA

Move or rename a file or directory. Existing destinations require overwrite=true. Cross-filesystem moves fall back to copy + delete.

delete_pathA

Delete a file, symlink or directory. Destructive: first call with dry_run=true to inspect the target, then call again with confirm="DELETE". The filesystem root / is always refused; all other paths are allowed subject to the Termux user's Android permissions.

search_filesA

Recursively search below a root for files matching a glob and optionally a regular expression in their contents. Symlinks are skipped. Returns up to max_results matches.

system_infoA

Return device model, Android version, Termux paths, CPU/memory/load, storage usage, network interfaces and availability of common tools (node, python, git, tmux, Termux:API).

clipboard_getA

Return the current Android clipboard text via Termux:API. Requires the termux-api package and Termux:API app.

clipboard_setA

Set the Android clipboard text via Termux:API. Requires the termux-api package and Termux:API app.

notifyA

Create an Android notification via Termux:API. Requires the Termux:API app and notification permission. Use a stable id to update an existing notification.

toastB

Show a short toast message on the device via Termux:API.

vibrateB

Vibrate the device for the given duration via Termux:API.

openA

Open an http(s) URL in the default browser, or open a local file with Android via Termux:API. Local paths are resolved on the device; Android permissions still apply.

battery_statusA

Return battery percentage, charging state, temperature and related fields via Termux:API.

tts_speakC

Speak text aloud using the Android text-to-speech engine via Termux:API.

termux_apiA

Advanced escape hatch: run any termux-* command directly (for example command="wifi-connectioninfo", args=["-i"]). No shell is involved, but the command still has the full permissions granted to Termux:API. Privacy-sensitive commands such as SMS, calls, contacts, location, camera and microphone are available if the Termux:API app has been granted those Android permissions; every call is written to the audit log.

terminal_createA

Create a persistent interactive shell in tmux. Sessions survive termux-mcp restarts and can run REPLs, SSH, TUI programs and prompts. The shell defaults to $SHELL (Termux bash if unset); when bash is selected, startup files are skipped by default because a custom .bashrc can break Enter handling. Set use_rc=true or terminal.useShellRc in the config to load them. Use terminal_write to type and terminal_read to capture output.

terminal_writeA

Send literal text, special key names, and/or Enter to a terminal session. Multi-line or large text is pasted through a tmux buffer by default; set paste=false to force literal send-keys. Key names use tmux notation: Enter, Tab, Escape, Up, Down, Left, Right, C-c, C-d, M-x, F1, etc. Set wait_ms to return a capture in the same call.

terminal_readA

Capture the visible screen and recent scrollback of a terminal session. Use expect with a regex to wait until a prompt or marker appears; if it does not match within timeout_ms, the result has expect_matched=false and timed_out=true. ANSI escapes are stripped by default. full_history=true captures the whole tmux history.

terminal_listA

List tmux-backed terminal sessions with size, current command, PID, alive/dead state and a command for attaching from a Termux terminal.

terminal_resizeA

Resize the tmux window/PTY used by a terminal session. Useful before launching TUI programs.

terminal_killA

Kill one terminal session by name, or every session with all=true. Killing a session terminates its shell and any programs running in that pane.

terminal_attach_infoA

Return the tmux attach command for a session. Run it from a Termux terminal for direct human interaction; external Android apps should keep using terminal_read/terminal_write.

task_startA

Start a detached background shell command and return immediately with a task id, PID and log path. The task keeps running if termux-mcp restarts, and its exit code is persisted in a status file. Use task_output to read incremental output and task_stop to terminate it. Background tasks are non-interactive; use terminal_create for prompts and TUI programs.

task_listA

List background tasks with state, PID, exit code, log size and paths. Reads persisted metadata, so tasks started before a termux-mcp restart are included.

task_outputA

Read a task log, either the last N lines (default) or an incremental byte range via offset. Use wait_ms to wait for new output. The result includes next_offset for cheap incremental polling.

task_stopA

Send a signal to the task process group, wait for the grace period, then force SIGKILL if it is still alive. Defaults to SIGTERM.

task_removeA

Delete the metadata, log, status and script files of a task that is no longer running.

Prompts

Interactive templates invoked by user choice

NameDescription
termux_operatorPlan and execute a task on the Android device using termux-mcp tools.

Resources

Contextual data attached and managed by the client

NameDescription
system-infoLive device, Termux, storage and network information.
configThe merged effective config.
audit-recentThe last 50 audit log entries, with sensitive argument values redacted.
tasksCurrently known background tasks and their status.
terminalsCurrently known tmux terminal sessions and their status.
helpTool overview and security notes.

TDQS

A3.6/5.0

Scored across 33 tools

Disambiguation4/5

Descriptions do a strong job of routing between overlapping entry points: run_command vs terminal_* vs task_* is explicitly explained, and termux_api is framed as an escape hatch for the specific termux-api wrappers. Minor overlaps remain (terminal_attach_info duplicates the attach command already returned by terminal_list, and termux_api can do everything the specific Android tools do), but they are deliberate conveniences rather than confusion.

Naming Consistency4/5

Strong grouping via prefixes (terminal_*, task_*, clipboard_*) and mostly verb_noun naming (read_file, list_dir, task_start, move_path). Deviations: clipboard_get/set use noun_verb ordering while the majority use verb_noun, and a handful are bare verbs (open, toast, notify, vibrate, mkdir) with no consistent noun.

Tool Count3/5

33 tools is at the high end; however the surface is genuinely broad, spanning filesystem CRUD, tmux terminals, background tasks, Android Termux:API, and system info, and the tools are cleanly clustered by subsystem. Each group earns its tools, but an agent must scan a large menu and the count exceeds the comfortable 3-15 range.

Completeness5/5

Lifecycle coverage is thorough in every subsystem: filesystem has read/write/edit/delete/mkdir/copy/move/list/stat/search; terminals have create/write/read/list/resize/kill/attach; tasks have start/list/output/stop/remove; Android has clipboard, notifications, toast, vibrate, open, battery, TTS plus an escape hatch. No obvious dead ends, with run_command and termux_api filling residual gaps.

Maintenance

ActivityMaintained
ResponsivenessNo issues