Skip to main content

ssmtree

CI PyPI Python 3.11+ License: MIT

Render AWS SSM Parameter Store as a colorized terminal tree. Browse, diff, and copy parameters across namespaces.

Features

  • Tree view — Visualize SSM parameters as a rich, colorized tree in your terminal
  • Diff — Compare parameters between two namespaces side by side
  • Copy — Copy parameters from one namespace to another with dry-run support
  • Glob filtering — Filter parameters with glob patterns to focus on what matters
  • JSON output — Export parameter trees or diffs as JSON for scripting and automation
  • Decrypt support — Decrypt SecureString parameters inline with optional KMS key re-encryption
  • SecureString safety — SecureString values shown as [redacted] by default; use --decrypt to reveal them
  • Leaf parameter support — Query a single leaf parameter directly (e.g. ssmtree /app/db/password)

Installation

pip install ssmtree

For development:

git clone https://github.com/Specter099/ssmtree.git
cd ssmtree
python -m venv .venv
source .venv/bin/activate
pip install -e ".[dev]"

Quick Start

# Browse all parameters under a prefix
ssmtree /app/prod

# Query a single leaf parameter
ssmtree /app/prod/db/password

# Decrypt SecureString values (shown as [redacted] by default)
ssmtree --decrypt /app/prod

# Hide all values entirely
ssmtree --hide-values /app/prod

# Filter with a glob pattern
ssmtree --filter "*db*" /app

# JSON output (SecureStrings redacted by default)
ssmtree --output json /app/prod

# JSON output with SecureString values included
ssmtree --decrypt --output json --include-secrets /app/prod

Commands

diff

Compare parameters between two namespaces:

# Table diff (default)
ssmtree diff /app/prod /app/staging

# With decryption
ssmtree diff --decrypt /app/prod /app/staging

# JSON diff output
ssmtree diff --output json /app/prod /app/staging

# JSON diff with SecureString values included
ssmtree diff --decrypt --output json --include-secrets /app/prod /app/staging

copy

Copy parameters from one namespace to another:

# Preview what would be copied
ssmtree copy --dry-run /app/prod /app/staging

# Copy (prompts for confirmation)
ssmtree copy /app/prod /app/staging

# Copy with overwrite, skip confirmation
ssmtree copy --yes --overwrite /app/prod /app/staging

# Copying SecureStrings requires --decrypt (see "Secret handling" below)
ssmtree copy --decrypt /app/prod /app/staging

# Copy with decryption and re-encryption under a new KMS key
ssmtree copy --decrypt --kms-key-id alias/my-key /app/prod /app/staging

Note: copy refuses to copy SecureString parameters unless --decrypt is given. Without it, the source value is still-encrypted KMS ciphertext, and writing that back would silently corrupt the destination secret.

Options

Option Commands Description
--decrypt / -d all Decrypt SecureString values
--profile all AWS named profile to use
--region all AWS region override
--endpoint-url all Custom SSM endpoint URL (e.g. localstack)
--show-values / --hide-values main, diff Show or hide parameter values (default: show)
--filter PATTERN / -f main Glob filter on parameter paths
--output main, diff Output format: tree/table (default) or json
--include-secrets main, diff Include SecureString values in JSON output
--overwrite / --no-overwrite copy Overwrite existing destination parameters
--dry-run copy Show what would be copied without writing
--kms-key-id copy KMS key for SecureString parameters at destination
--yes / -y copy Skip confirmation prompt

Secret handling

SecureString values are protected by default and revealed only when you opt in:

  • Human-readable output (tree, diff table): SecureStrings show as [redacted] unless you pass --decrypt.
  • JSON output (--output json): SecureStrings show as ***REDACTED*** unless you pass --include-secrets (which also prints a warning to stderr).
  • copy: requires --decrypt to copy SecureStrings at all, so the real plaintext (not KMS ciphertext) is written to the destination.

A SecureString diff without --decrypt always shows as changed because KMS ciphertext is non-deterministic; decrypt to compare real values.

Development

pytest          # run tests
ruff check .    # lint

License

MIT — see LICENSE

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

ssmtree-0.4.0.tar.gz (31.1 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

ssmtree-0.4.0-py3-none-any.whl (20.3 kB view details)

Uploaded Python 3

File details

Details for the file ssmtree-0.4.0.tar.gz.

File metadata

  • Download URL: ssmtree-0.4.0.tar.gz
  • Upload date:
  • Size: 31.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.13

File hashes

Hashes for ssmtree-0.4.0.tar.gz
Algorithm Hash digest
SHA256 6aec4d644745a0155f24089ff4cbe4f6da42710738743b984b72188d54859d4c
MD5 91b8340e9360d702422c5ac6c4663d03
BLAKE2b-256 b50fc5b785c9997941afb94427490bfaecb6f9f81e1774ab257d8646e2d318f4

See more details on using hashes here.

Provenance

The following attestation bundles were made for ssmtree-0.4.0.tar.gz:

Publisher: publish.yml on Specter099/ssmtree

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file ssmtree-0.4.0-py3-none-any.whl.

File metadata

  • Download URL: ssmtree-0.4.0-py3-none-any.whl
  • Upload date:
  • Size: 20.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.13

File hashes

Hashes for ssmtree-0.4.0-py3-none-any.whl
Algorithm Hash digest
SHA256 5968b4d5e3fa40966f8a213f0495772b452bd95f493fb43e02c41944604e858c
MD5 81052e7a16474d877654e3971007b74e
BLAKE2b-256 ecc2ee9af6f0f169c34b7ebe5ed57ed7010c76d25aa065c87ba2ea3ea96c46ca

See more details on using hashes here.

Provenance

The following attestation bundles were made for ssmtree-0.4.0-py3-none-any.whl:

Publisher: publish.yml on Specter099/ssmtree

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Release history Release notifications | RSS feed

This release

0.4.0 This release

2 files

0.3.2

2 files

0.3.1

2 files

0.3.0

2 files

0.2.0

2 files

0.1.0

2 files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page