Skip to main content

ctrlrun-openclaw

The Python half of CTRLRun for OpenClaw: a loopback bridge that answers OpenClaw's before_tool_call from a CTRLRun policy, and records what the tool actually did.

pip install ctrlrun-openclaw
ctrlrun init
export CTRLRUN_OPENCLAW_TOKEN=$(python3 -c 'import secrets;print(secrets.token_urlsafe(32))')
ctrlrun-openclaw-bridge --agent openclaw-gateway

Then install the plugin in OpenClaw:

openclaw plugins install clawhub:@ctrlrun/openclaw

Why a bridge and not a policy file

OpenClaw already has tool-authorization plugins, and each is a decision engine: policy in, allow or deny out. This is the half after the decision.

after_tool_call is an observation hook. OpenClaw's own reference says handlers run concurrently, return values are ignored, and to use a fail-closed gate rather than assume an observation hook will reject anything on failure. So nothing in OpenClaw today separates the tool failed from we cannot tell whether it committed.

This bridge holds Control.execute open across the host's tool call, which makes OpenClaw the executor and its report the outcome. A call the host never reports on is not lost: the effect stays reserved, the state is AMBIGUOUS, and the next attempt on the same key is refused until a human runs ctrlrun resolve.

Approvals route through OpenClaw's own prompt using InterruptApprovalProvider, so the grant is written by the same path ctrlrun approve uses, never by this adapter.

Verified

OpenClaw 2026.9.4, Node 24.21.0. One real agent turn, both hooks firing:

[bridge] "POST /v1/decide"    200
[bridge] "POST /v1/outcome"   200

$ ctrlrun receipts
read  deny/denied      openclaw-gateway   # policy did not name this action
read  allow/committed  openclaw-gateway   # allowed, ran, outcome reported

The bridge binds loopback only and requires a shared secret on every request. It fronts your approval authority and refuses to start on a non-loopback interface.

Apache-2.0. Full documentation, limits and known upstream issues in the repository README.

Metadata

Release files for ctrlrun-openclaw 0.1.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 ctrlrun-openclaw 0.1.0
File Size Uploaded
ctrlrun_openclaw-0.1.0.tar.gz 13.2 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for ctrlrun-openclaw 0.1.0
File Interpreter ABI Platform
ctrlrun_openclaw-0.1.0-py3-none-any.whl Python 3 none any Details

Total release size: 28.2 kB

Release files / ctrlrun_openclaw-0.1.0.tar.gz

Download URL ctrlrun_openclaw-0.1.0.tar.gz
Size 13.2 kB
Tags Source
SHA-256 checksum
How to use checksums
8e02358e784889964e0616eef9e074038a3148db4a42832a20dd60ac1f48f895
BLAKE2b-256 checksum
How to use checksums
780b914361cabf705a51318e7e0fdbd4f1fd6774ec9eb448a2135c7ae535f807
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 15, 2026.

Transparency log

Release files / ctrlrun_openclaw-0.1.0-py3-none-any.whl

Download URL ctrlrun_openclaw-0.1.0-py3-none-any.whl
Size 15.0 kB
Tags Python 3
SHA-256 checksum
How to use checksums
c4aaff507d03cf9b680c90e24adad3a8c417814bf07e7eba861eb26140c0ea2e
BLAKE2b-256 checksum
How to use checksums
f6d7692af5a61f625c7aaf435d9417d4bce436be3695a9a4c9558d731da789cb
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 15, 2026.

Transparency log

Release history Release notifications | RSS feed

0.1.2

2 release files

0.1.1

2 release files

This release

0.1.0 This release

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