Skip to main content

Python bindings for murk — encrypted secrets manager

Project description

murk-secrets

PyPI

Python bindings for murk — an encrypted secrets manager for developers.

murk stores encrypted secrets in a single .murk file safe to commit to git. This package lets Python apps read those secrets at runtime.

Prerequisites

You need the murk CLI to create and manage vaults. This package only reads them.

# Install the CLI first
brew tap iicky/murk && brew install murk

# Initialize a vault and add secrets
murk init
murk add DATABASE_URL
murk add API_KEY

Then add the Python package to your project:

pip install murk-secrets

Quick start

# Load your key (created by murk init)
source .env
import murk

# Load the vault (reads MURK_KEY from environment)
vault = murk.load()

# Get a single secret
db_url = vault.get("DATABASE_URL")

# Get all secrets as a dict
secrets = vault.export()

# Dict-style access
api_key = vault["API_KEY"]

API

murk.load(vault_path=".murk") -> Vault

Load and decrypt a murk vault. Reads MURK_KEY or MURK_KEY_FILE from the environment.

murk.get(key, vault_path=".murk") -> str | None

One-liner: load the vault and get a single value.

murk.export_all(vault_path=".murk") -> dict[str, str]

One-liner: load the vault and export all secrets as a dict.

murk.has_key() -> bool

Check if a MURK_KEY is available in the environment.

Vault

Method Returns Description
vault.get(key) str | None Get a single decrypted value
vault.export() dict[str, str] All secrets as a dict
vault.keys() list[str] List of key names
vault[key] str Dict-style access (raises on missing key)
key in vault bool Check if a key exists
len(vault) int Number of secrets

Scoped (per-user) overrides are applied automatically — if you have a scoped value for a key, it takes priority over the shared value.

Environment

Set one of:

  • MURK_KEY — your age secret key directly
  • MURK_KEY_FILE — path to your key file (created by murk init)

The easiest setup is source .env in your project directory after running murk init.

Requirements

  • Python >= 3.9
  • murk CLI installed (to create and manage vaults)
  • A .murk vault file in your project (created with murk init)
  • MURK_KEY or MURK_KEY_FILE in the environment (created by murk init, loaded via source .env)

License

MIT OR Apache-2.0

Project details


Download files

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

Source Distribution

murk_secrets-0.5.6.tar.gz (5.1 MB view details)

Uploaded Source

Built Distributions

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

murk_secrets-0.5.6-cp312-cp312-win_amd64.whl (926.0 kB view details)

Uploaded CPython 3.12Windows x86-64

murk_secrets-0.5.6-cp312-cp312-manylinux_2_28_aarch64.whl (861.5 kB view details)

Uploaded CPython 3.12manylinux: glibc 2.28+ ARM64

murk_secrets-0.5.6-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (913.0 kB view details)

Uploaded CPython 3.12manylinux: glibc 2.17+ x86-64

murk_secrets-0.5.6-cp312-cp312-macosx_11_0_arm64.whl (787.6 kB view details)

Uploaded CPython 3.12macOS 11.0+ ARM64

murk_secrets-0.5.6-cp312-cp312-macosx_10_12_x86_64.whl (844.9 kB view details)

Uploaded CPython 3.12macOS 10.12+ x86-64

File details

Details for the file murk_secrets-0.5.6.tar.gz.

File metadata

  • Download URL: murk_secrets-0.5.6.tar.gz
  • Upload date:
  • Size: 5.1 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for murk_secrets-0.5.6.tar.gz
Algorithm Hash digest
SHA256 dbafbca3685e76b94666b3569451e63c951a1fd845629687fa223c64f017b541
MD5 99383cd980182e51bf46ef907984dbe2
BLAKE2b-256 5e449394cf63b88e2161fec0d0a523f2672ec8fabb1543dea7733c93a283513d

See more details on using hashes here.

Provenance

The following attestation bundles were made for murk_secrets-0.5.6.tar.gz:

Publisher: python.yaml on iicky/murk

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

File details

Details for the file murk_secrets-0.5.6-cp312-cp312-win_amd64.whl.

File metadata

File hashes

Hashes for murk_secrets-0.5.6-cp312-cp312-win_amd64.whl
Algorithm Hash digest
SHA256 288066bb1cd9cc82763226abbb90ada11c2292761e3874fa57c9f85369db1f8a
MD5 8d8011579035905739a816c31c064c4e
BLAKE2b-256 86d1be7e693f6c31a69baeb67bf3f76bd9a33970ba10592812663a370328a280

See more details on using hashes here.

Provenance

The following attestation bundles were made for murk_secrets-0.5.6-cp312-cp312-win_amd64.whl:

Publisher: python.yaml on iicky/murk

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

File details

Details for the file murk_secrets-0.5.6-cp312-cp312-manylinux_2_28_aarch64.whl.

File metadata

File hashes

Hashes for murk_secrets-0.5.6-cp312-cp312-manylinux_2_28_aarch64.whl
Algorithm Hash digest
SHA256 f6e8a7b71316dd5985d6ce118cc1eb91a0093094dae49ad42491e229e4cace41
MD5 4b5b4ba48aff2029a64bf37a188adf3d
BLAKE2b-256 1b894a79b0abcd7a437d44e47281ff7185b1218dc63a0a75d616c5c8030cb880

See more details on using hashes here.

Provenance

The following attestation bundles were made for murk_secrets-0.5.6-cp312-cp312-manylinux_2_28_aarch64.whl:

Publisher: python.yaml on iicky/murk

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

File details

Details for the file murk_secrets-0.5.6-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for murk_secrets-0.5.6-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 f8e2ded579506cd3207379150eb00e0acc244db150b5ad2407fa82b00a8e413c
MD5 5790aa668abc42e03b3dd41e8d457739
BLAKE2b-256 f0dca768a7f15b5d569be2eacd513bfc0819fa7adbe775643a801a2fb77c6d82

See more details on using hashes here.

Provenance

The following attestation bundles were made for murk_secrets-0.5.6-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl:

Publisher: python.yaml on iicky/murk

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

File details

Details for the file murk_secrets-0.5.6-cp312-cp312-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for murk_secrets-0.5.6-cp312-cp312-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 25a7d95549e1080ce14c4b76619333d9bf51ac3af6b1b541d3d20b0de5f5146d
MD5 e9b9d2e165b68647e3a610ae31ed0f9a
BLAKE2b-256 383786c82fa02073753d58311eaaaba9607b771a0c61c37c4cb6cbbfbec66230

See more details on using hashes here.

Provenance

The following attestation bundles were made for murk_secrets-0.5.6-cp312-cp312-macosx_11_0_arm64.whl:

Publisher: python.yaml on iicky/murk

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

File details

Details for the file murk_secrets-0.5.6-cp312-cp312-macosx_10_12_x86_64.whl.

File metadata

File hashes

Hashes for murk_secrets-0.5.6-cp312-cp312-macosx_10_12_x86_64.whl
Algorithm Hash digest
SHA256 df04837a5edce9437fd081437e398fb5ac2da9624b70363c92572f0d17b45a4f
MD5 20d31312bce8c4906a550482e75cb4ad
BLAKE2b-256 07cca38ee7125cd0130f7e0c40bbf1848409c6e3e24848611c759a66f8905915

See more details on using hashes here.

Provenance

The following attestation bundles were made for murk_secrets-0.5.6-cp312-cp312-macosx_10_12_x86_64.whl:

Publisher: python.yaml on iicky/murk

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

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page