Skip to main content

Movitera CLI: inject vault secrets as environment variables, generate TOTP codes

Project description

movitera CLI

Inject Movitera vault secrets as environment variables, render dotenv files, and generate TOTP codes from the terminal. Authenticates with a Movitera vault personal access token (PAT).

Install

pip install movitera-cli
# or install as an isolated CLI tool (recommended):
pipx install movitera-cli
# or with uv:
uv tool install movitera-cli
# or run without installing:
uvx --from movitera-cli movitera --help

Quick start

# 1. Sign in (opens your browser, click "Authorize", done — no copy/paste):
movitera login

# 2. Run any command with secrets injected as env vars:
movitera run --team <teamId> --credential myapp-prod -- npm start

# 3. Or dump as dotenv:
movitera secrets pull --team <teamId> --credential myapp-prod > .env

# 4. Or generate a TOTP code for a credential:
movitera totp --team <teamId> <credential-id>

How it works

movitera run -- cmd fetches the dotenv body from GET /vault/credentials/by-name/{name}/env, then execs the child process with those vars merged into its environment. The CLI never writes secrets to disk — they exist only in the child process's environ.

Tokens are stored in the OS keyring (Keychain on macOS, libsecret on Linux, Credential Manager on Windows) with a file fallback under ~/.config/movitera/token (mode 0o600) if no keyring backend is available.

Config

Env var Purpose Default
MOVITERA_API_URL API base URL https://api.movitera.com
MOVITERA_TOKEN PAT override (skips keyring lookup)
MOVITERA_TEAM Default team id (you can omit --team)

Commands

movitera login

Opens your default browser to the Movitera approval screen. Click "Authorize" and the CLI captures a freshly minted PAT via a one-time grant code (PKCE-protected), then stores it in the OS keyring. The PAT itself never appears in the URL or browser history.

Headless escape hatches — preserved for CI, SSH, and Docker where no browser is available:

# Paste a PAT directly:
movitera login --token mvt_pat_…

# Pipe a PAT from another tool (`pass`, `vault`, etc.):
pass show movitera/pat | movitera login --stdin

# Or skip `login` entirely by setting MOVITERA_TOKEN at runtime:
export MOVITERA_TOKEN=mvt_pat_…
movitera secrets pull --team <teamId> --credential myapp-prod

movitera logout

Removes the stored PAT.

movitera run --team T --credential N -- <cmd> [args...]

Fetches the ENV_BUNDLE credential named N and execs <cmd> with those vars in the environment.

movitera secrets pull --team T --credential N

Writes the dotenv body to stdout. Exits non-zero on resolution failures so you can chain movitera secrets pull ... > .env.

movitera totp --team T <credential-id>

Prints the current TOTP code for the credential's OTPAUTH_URI field.

movitera tokens list --team T / movitera tokens revoke <id>

Manage your own PATs from the CLI.

Security model

  • PATs have full 256-bit entropy and are stored as SHA-256 on the server, so a server compromise cannot recover the plaintext.
  • Every movitera run invocation is audited server-side, but PAT reads are coalesced per hour per token (see the backend's FETCHED_VIA_TOKEN aggregation) so a hot dev loop doesn't drown the log.
  • Group/team access is re-checked on every request: if your vault scope is revoked, your PAT immediately loses access — no token-cache divergence.

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

movitera_cli-0.2.0.tar.gz (47.7 kB view details)

Uploaded Source

Built Distribution

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

movitera_cli-0.2.0-py3-none-any.whl (18.9 kB view details)

Uploaded Python 3

File details

Details for the file movitera_cli-0.2.0.tar.gz.

File metadata

  • Download URL: movitera_cli-0.2.0.tar.gz
  • Upload date:
  • Size: 47.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for movitera_cli-0.2.0.tar.gz
Algorithm Hash digest
SHA256 a4b0dd25ca15f87a5bdd12225c2f5c5844ecbd16771de93801ab977d735521dd
MD5 066fbeee8c5eab21fa2b9100c9fdd848
BLAKE2b-256 bb61038751f3dcb21bb07b2362504ab594aabe1e9fa41b90444c8eb80fe31e03

See more details on using hashes here.

Provenance

The following attestation bundles were made for movitera_cli-0.2.0.tar.gz:

Publisher: publish.yml on joaoheusi/movitera-cli

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

File details

Details for the file movitera_cli-0.2.0-py3-none-any.whl.

File metadata

  • Download URL: movitera_cli-0.2.0-py3-none-any.whl
  • Upload date:
  • Size: 18.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for movitera_cli-0.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 4b5e6e00b0f3ab09cef056d61bc10c4aa4b5a8956a86383f6854387b29bdec75
MD5 2ad47e8c75e6d03396a106db54807910
BLAKE2b-256 c26849c058829b6b6943dc5ab9d3b0a6111003edba885cb11dbae644e7d9a3d2

See more details on using hashes here.

Provenance

The following attestation bundles were made for movitera_cli-0.2.0-py3-none-any.whl:

Publisher: publish.yml on joaoheusi/movitera-cli

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