Skip to main content

Production CLI for Relay — query, sync, and manage organisational memory.

Project description

relay-cli

Production CLI for Relay. One command (relay) wraps the full HTTP surface: query the memory layer, pull the daily brief, manage atoms / conflicts / drift, upload meetings, manage API tokens, sync published skills, inspect retrieval traces.

The legacy relay-sync console script is preserved as an alias for relay skills sync so existing automation keeps working.

Install

pipx install ./cli            # recommended — isolated, on $PATH
# or
pip install -e ./cli          # editable, for hacking on the CLI

Optional extras:

pip install -e "./cli[yaml]"  # adds --output yaml support
pip install -e "./cli[dev]"   # adds pytest, pyyaml

First run

relay profile set prod --api-base https://api.relay.example --org acme --default
relay login --email you@acme.com
relay doctor

Environment variables (handy in CI):

Var Purpose
RELAY_PROFILE Override active profile
RELAY_API_BASE Override API base (skills-sync only)
RELAY_TOKEN Bypass the keyring
RELAY_CONFIG_DIR Override ~/.config/relay

Commands

relay login [--email --password|-] | [--with-token <jwt>]
relay logout
relay whoami

relay query ask "what is our refund SLA?"
relay query drift <query_log_id>

relay brief [--must-know N --must-do N --waiting N]

relay atoms list [--type --domain --search --limit --offset --include-inactive]
relay atoms list --all [--max 10000]   # auto-paginate every page
relay atoms get <atom_id>

relay conflicts list [--status]
relay conflicts resolve <id> --winner <atom_id> [--note "..."]

relay drift list [--status]
relay drift recompute

relay meetings list | get <id> | upload <file> [--title]

relay integrations status
relay integrations disconnect <kind>

relay export mine | create --kind atoms --format json | download <id> --out file

relay trace list | get <id>

relay tokens create --name ci --scope atoms:read --scope query:run
relay tokens list | revoke <id>

relay skills sync --org <slug> --target <dir> [--prune] [--dry-run]

relay profile list | set <name> | default <name> | show
relay welcome   # show the Relay banner (profile, API, auth state)
relay doctor
relay --version

Output formats

Every read command supports --output text|json|yaml|table. Default is text on a TTY, json on a pipe, so relay atoms list | jq just works.

Security notes

  • Tokens live in the OS keyring (Keychain / Credential Manager / Secret Service). Fallback: ~/.config/relay/tokens/<profile> mode 0600 with a warning.
  • Authorization is never echoed in -vv logs (httpx pinned to INFO).
  • Skills-sync cache rejects any ETag that isn't hex-64 SHA-256.
  • Writes are atomic via tmp + rename.

Tests

cd cli
python -m pytest

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

try_relay-0.3.1.tar.gz (41.0 kB view details)

Uploaded Source

Built Distribution

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

try_relay-0.3.1-py3-none-any.whl (50.9 kB view details)

Uploaded Python 3

File details

Details for the file try_relay-0.3.1.tar.gz.

File metadata

  • Download URL: try_relay-0.3.1.tar.gz
  • Upload date:
  • Size: 41.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.11

File hashes

Hashes for try_relay-0.3.1.tar.gz
Algorithm Hash digest
SHA256 f095c911360d6817d23f6a3bcf0f60d59f0b584857b72335ab650f60f6f8762e
MD5 7f906fda6029f7220d7e54de763411ae
BLAKE2b-256 450fef801c4d7920428cdba8b31fe5b54aa498ffbbd0a0f61c3a0234e7c87777

See more details on using hashes here.

File details

Details for the file try_relay-0.3.1-py3-none-any.whl.

File metadata

  • Download URL: try_relay-0.3.1-py3-none-any.whl
  • Upload date:
  • Size: 50.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.11

File hashes

Hashes for try_relay-0.3.1-py3-none-any.whl
Algorithm Hash digest
SHA256 22fd37577cad388bb6ae1f3bbb67a82b4cc275de274ae89c34d6cb9ab3e7d78b
MD5 91f9417b98a8d153bf8efa02434b1328
BLAKE2b-256 e73c213b3cf915ae01b90c3ebab5a491e47c36df8375235cbd8a68fd43496346

See more details on using hashes here.

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