Skip to content

archive

Create and extract zip / tar / tar.gz archives, sandboxed to the directories passed as args. Same sandbox semantics as filesystem — every input and output path is validated against the allowed roots, with symlink resolution.

Usage

bash
native-mcp archive PATH [PATH...]

Each PATH must be an existing directory. The server can read from and write into any of them, but never outside.

Tools

create_zip

FieldTypeRequiredDescription
outputstringyesPath of the zip to create.
inputsarray<string>yesFiles or directories to include (walked recursively).

extract_zip

FieldTypeRequiredDescription
archivestringyesZip file to read.
dest_dirstringyesOutput directory (created if missing).

Entries that try to escape the sandbox via absolute paths or .. traversal are rejected.

create_tar

FieldTypeRequiredDescription
outputstringyesPath of the tar/tar.gz to create.
inputsarray<string>yesFiles or directories to include.
gzipboolnoIf true, wrap the tar in gzip → produces .tar.gz.

extract_tar

Auto-detects gzip via magic bytes. Skips symlinks and special device entries for safety.

FieldTypeRequiredDescription
archivestringyesTar or tar.gz file.
dest_dirstringyesOutput directory.

list_allowed_paths

Returns the sandbox roots, one per line.

Register in Claude Code

bash
claude mcp add native-archive native-mcp archive /tmp /home/you/projects

Released under the MIT License.