botrelay-cli
Command-line client for BotRelay. Humans sign up and manage vaults. Agents read secrets with an API key and a vault key that stay on this machine.
Decrypts locally. The API stores ciphertext only. The vault key is never sent to the API.
Install
Python 3.11 or newer. Install the CLI on its own. botrelay-mcp is deprecated (the local daemon was removed) and is not required:
python3 -m venv ~/.venvs/botrelay
source ~/.venvs/botrelay/bin/activate
python -m pip install --upgrade pip
python -m pip install botrelay-cli
From a monorepo checkout:
python -m pip install -e packages/sdk-python
python -m pip install -e apps/cli
botrelay-cli 0.1.2 is the release the deprecated botrelay-mcp package depends on (botrelay-cli>=0.1.1,<0.2). Maintainer commands are at the bottom of this file. This change does not publish to PyPI.
Agent onboarding
botrelay agent configure
On a TTY this prompts for the API URL (default https://api.botrelay.ai), then the API key and vault key with hidden input. It writes:
~/.config/botrelay/agent.env
or $BOTRELAY_HOME/agent.env when BOTRELAY_HOME is set. The file is mode 0600. Secrets are not printed.
# BotRelay agent credentials. Do not commit.
BOTRELAY_API_URL='https://api.botrelay.ai'
BOTRELAY_API_KEY='brt_live_...'
BOTRELAY_VAULT_KEY='...'
That is KEY=VALUE (optional export, # comments, single quotes) so both of these work:
set -a; source ~/.config/botrelay/agent.env; set +a
and a normal dotenv parse. The CLI reads BOTRELAY_API_URL, BOTRELAY_API_KEY, and BOTRELAY_VAULT_KEY. It does not execute the file.
Precedence for botrelay agent commands: explicit flags (--api-url, --api-key, --vault-key), then agent.env, then the process environment. A value set in the file wins over the process environment. The process environment is used only for a key the file omits. Human commands do not read agent.env. A manual source follows normal shell rules and will assign over current variables. Hosted MCP does not read this file; it uses the agent API key on the request. The vault key stays local.
Non-interactive (CI or scripts; no TTY):
botrelay agent configure \
--api-url https://api.botrelay.ai \
--api-key "$BOTRELAY_API_KEY" \
--vault-key "$BOTRELAY_VAULT_KEY"
--yes skips the overwrite prompt on a TTY. Without a TTY, a complete set of values overwrites an existing file.
--check calls the same vault-metadata read as botrelay agent vault and prints id, name, and labels only. It does not print secrets. botrelay agent configure --check with no new values verifies the current file or environment without rewriting it.
botrelay agent vault
botrelay agent list
botrelay agent get github
botrelay agent get still fetches one secret by label and opens it locally. Its flags and output are unchanged. Credential loading is the shared rule above (file wins over the process environment).
botrelay agent decrypt
Opens a sealed secret on this machine. It does not call the API. It reads JSON from stdin, or from a file path (- is stdin):
botrelay agent decrypt < secret.json
botrelay agent decrypt secret.json
Pipe hosted MCP get_secret output straight in. The command accepts:
- the sealed row (
id,vault_id,label,secret_type,ciphertext,nonce, …) - an MCP tool result (
structuredContent, orcontent[0].textcontaining that JSON) - a JSON-RPC envelope whose
resultis one of those
Stdout is the same typed JSON botrelay agent get prints:
- password:
username,password,label,secret_type - api_key:
key,id,label,secret_type - contact: the contact fields, plus
labelandsecret_type
The vault key comes from --vault-key, otherwise agent.env, otherwise BOTRELAY_VAULT_KEY. A missing key, a key that is not 32-byte standard base64, malformed JSON, a row missing ciphertext fields, or a failed open prints {"error": "..."} on stderr and exits non-zero. A vault_key field inside the JSON is ignored.
Human commands still default to http://localhost:8000 (or BOTRELAY_API_URL). They do not read agent.env.
Publish
From a checkout, after tests pass. This uploads to PyPI; do it from a maintainer machine that already has credentials. Do not commit tokens.
python -m pip install --upgrade build twine
python -m build apps/cli
twine check dist/botrelay_cli-0.1.2*
twine upload dist/botrelay_cli-0.1.2*
botrelay-mcp 0.3.0 is a deprecated tombstone (daemon removed). Do not publish it as a supported server. If a maintainer still uploads the tombstone so old installs resolve:
python -m build apps/mcp
twine check dist/botrelay_mcp-0.3.0*
twine upload dist/botrelay_mcp-0.3.0*
There is no publish job in CI.
Metadata
Release files for botrelay-cli 0.1.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| botrelay_cli-0.1.2.tar.gz | 19.0 kB | Without provenance | Details for botrelay_cli-0.1.2.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| botrelay_cli-0.1.2-py3-none-any.whl | Python 3 | none | any | Details for botrelay_cli-0.1.2-py3-none-any.whl |
Total release size: 34.7 kB
Release files / botrelay_cli-0.1.2.tar.gz
| Download URL | botrelay_cli-0.1.2.tar.gz |
|---|---|
| Size | 19.0 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
057fb4f8a8c4e09ea1ba610ef8c27208faa8f1cee0ee6061ec17a613c828a0f9
|
|
BLAKE2b-256 checksum How to use checksums |
5c557167ea24fcfb0b433db488d702119e93da1a6bf786c756ae18d1fea7c2e2
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.14.7
|
Release files / botrelay_cli-0.1.2-py3-none-any.whl
| Download URL | botrelay_cli-0.1.2-py3-none-any.whl |
|---|---|
| Size | 15.7 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
7c3545299eb3f4ce11f72337f20998ab9222fafe2aac222612660b77422adf58
|
|
BLAKE2b-256 checksum How to use checksums |
ef44cc6a401813b234aa4cdfebe7146b0ea674e120494ea756ee5342d6c5d882
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.14.7
|
Security for botrelay-cli 0.1.2
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.