Skip to main content

yoru-cli

The Claude Code hook installer for Yoru. One command installs a PostToolUse hook that forwards every tool call, file edit, and red-flag event to a Yoru backend. Your next session shows up in the dashboard automatically.

PyPI License: MIT

Install

pipx install yoru-cli                       # or: uv tool install yoru-cli
yoru init --server https://yoru.acme.com

Use pipx/uv — a bare pip install yoru-cli fails on Homebrew/Debian Python with error: externally-managed-environment (PEP 668). No pipx? A venv works too: python3 -m venv .venv && .venv/bin/pip install yoru-cli.

Yoru is self-hosted — point the CLI at your own backend with --server. yoru init opens a pairing URL in your browser, writes ~/.claude/hooks/yoru.sh, and registers the hook in ~/.claude/settings.json. Don't have a server yet? Stand one updocker-compose up.

Requires Python 3.10+. One runtime dep: httpx.

Usage

yoru init --server https://yoru.acme.com       # pair against your server (--server required)
yoru init --server https://yoru.acme.com --token yoru_xxx --force   # non-interactive (CI / scripted rotation)

yoru tail < events.jsonl                # post a batch of events (debug)

yoru --version
yoru --help

Exit codes: 0 ok · 1 already installed (use --force) · 2 auth failed · 3 4xx · 4 5xx/network.

How the hook works

The installed script is ~20 lines of Bash that POSTs one JSON event per Claude Code tool call:

{"session_id": "…", "user": "…", "kind": "tool_use", "tool": "Bash", "content": "…"}

It uses curl --max-time 2 || true so a Yoru outage never stalls your terminal — Claude Code doesn't notice the hook is even there.

Multiple devs, multiple identities

Each paired identity (server + token) gets its own local slot under ~/.config/yoru/identities/. The shared tailer and every hook event attribute to whichever identity is active — there is no per-process attribution.

  • One dev per machine (the normal case): no ambiguity — one OS user, one identity, all activity is unambiguously yours.
  • Same OS login, multiple identities paired (e.g. you re-paired against a second org, or a shared machine): only one identity is active at a time. Concurrent work under that same login attributes to whichever identity is active regardless of who actually ran it — this is an explicit, documented limit, not a bug. Switch identities first with yoru use <label>.

Run yoru doctor any time to see the active identity and get warned if other paired identities exist unused on this machine.

Self-host the server

The CLI is MIT. The server (backend + dashboard) is AGPL-3.0 and lives at github.com/TsukumoHQ/yoru. docker-compose up, then yoru init --server https://your-host — done. There is no hosted Yoru; you run it.

License

MIT · Copyright (c) 2026 Yoru authors. Issues and PRs welcome at github.com/TsukumoHQ/cli-yoru.

Release files for yoru-cli 0.3.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for yoru-cli 0.3.0
File Size Uploaded
yoru_cli-0.3.0.tar.gz 119.2 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for yoru-cli 0.3.0
File Interpreter ABI Platform
yoru_cli-0.3.0-py3-none-any.whl Python 3 none any Details

Total release size: 187.8 kB

Release files / yoru_cli-0.3.0.tar.gz

Download URL yoru_cli-0.3.0.tar.gz
Size 119.2 kB
Tags Source
SHA-256 checksum
How to use checksums
7d324aff13a4b5edd7128d7248c5b01e591e83d33ff4089e9863472b96e7ffac
BLAKE2b-256 checksum
How to use checksums
263e5162236db8bb19f3b8ecb15b3555bdb1e33495fb0e07d8fe0b082107ae55
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

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.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 3, 2026.

Transparency log

Release files / yoru_cli-0.3.0-py3-none-any.whl

Download URL yoru_cli-0.3.0-py3-none-any.whl
Size 68.6 kB
Tags Python 3
SHA-256 checksum
How to use checksums
174b409d23ebe407fa4b3e920264c99f5e1d8947f4e97e25c97f76e99390c0b2
BLAKE2b-256 checksum
How to use checksums
84125ed9062a62ff0fbbc033c17ac761a86b0097e013c565cfc95b4030b025e4
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

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.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 3, 2026.

Transparency log

Release history Release notifications | RSS feed

This release

0.3.0 This release

2 release files

0.2.0

2 release files

0.1.3

2 release files

0.1.2

2 release files

0.1.1

2 release files

0.1.0

2 release 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