Skip to main content
Glama

chmod permission converter

chmod_convert
Read-onlyIdempotent

Convert Unix permissions between octal (755, 4755), symbolic (rwxr-xr-x) and ls -l strings, or apply a chmod expression such as 'go-w,u+x' to a starting mode. Explains each class, setuid/setgid/sticky bits and risky modes, and gives umask defaults.

Returns: JSON { octal, symbolic, ls, description[], warnings[], command, symbolicArg, umaskDefaults{ umask, newFile, newDirectory } }. Example input: {"mode":"rwxr-x---"} On error, includes hint: Use 1-4 octal digits, nine rwx characters (optionally with a leading file type), or a symbolic expression like u+x,go-w.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "mode": "<mode>"
    },
    "name": "chmod_convert"
  }
}

Input Schema

NameRequiredDescriptionDefault
modeYesOctal (644), symbolic or ls -l (-rwsr-xr-x), or a chmod expression (u+x, a=rX) applied to start.
startNoStarting octal mode for expressions. Default 644 for files, 755 for directories.
umaskNoumask in octal, used for expressions without u/g/o/a and for new-file defaults. Default 022.
isDirectoryNoTreat the target as a directory (affects X and the ls -l type). Default false.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.4/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already declare readOnly/idempotent/closed-world, and the description goes further by disclosing that it emits warnings for risky modes, explains setuid/setgid/sticky classes, and returns umask defaults. It also documents the error path with a concrete hint, which is valuable behavior an agent would otherwise only discover at runtime.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Front-loaded with the core purpose, then a compact Returns line, one example, and an error hint. Every line carries information, though the Returns block is dense and slightly harder to scan than the opening sentence.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

There is no output schema, so the description compensates by naming every returned field, including warnings and umaskDefaults. Combined with the example input and error-format hint, an agent has everything needed to call it and interpret the result correctly.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so the baseline is 3, but the description adds meaning beyond it: it shows a worked example input and clarifies that a symbolic expression is applied 'to a starting mode,' which explains the relationship between mode and start. It adds modest but real value on top of an already-complete schema.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb+resource ('Convert Unix permissions') and enumerates the three representations it handles (octal, symbolic, ls -l) plus the expression-application mode. No sibling tool overlaps this domain, so an agent can select it unambiguously.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description makes clear which input shapes trigger which behavior (conversion vs. expression applied to a starting mode) and spells out the accepted formats in the error hint. It stops short of naming when not to use it, but no sibling competes for the same task, so there is little to disambiguate.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources