raxit
Live demos

Quickstart tour

A real 60-second run: one allowed call permitted, one forbidden call denied with a named reason code, and the Ed25519-signed audit chain verified green — three SDK calls, no LLM in the decision path.

This is the smallest complete raxit loop, run for real: read_ticket matches an effect: allow rule and comes back permit; wire_funds matches effect: block and comes back deny (deny.default_or_forbid) — the call never runs. Both decisions land in the hash-chained, Ed25519-signed Decision Provenance log before their verdicts return, and the script verifies that chain as its finale. The decision is deterministic and replayable — same (policy, call), same verdict, no model in the loop.

Run it yourself

From a clone of the repo — this builds a local engine, rotates a signing key, spawns raxit serve, runs the demo, and tears everything down:

make -C examples demo-quickstart-py     # Python (the transcript below)
make -C examples demo-quickstart-ts     # TypeScript twin, same three calls

In your own project, the same flow is available from the published SDK (pip install raxit / npm install @raxitlabs/raxit) — the whole integration is three calls:

from raxit import RaxitClient

client = RaxitClient()

permit = client.govern.decide("read_ticket", {"id": "T-42"})        # -> permit
deny = client.govern.decide("wire_funds", {"amount_cents": 500000})  # -> deny.default_or_forbid
report = client.audit.verify(signatures=True, pubkeys=[pubkey])      # -> ok=True

The run, step by step

Every terminal line below is from a real captured run of examples/quickstart — nothing is mocked:

Quickstart — permit one call, deny another, verify the chain

The whole policy: two rules plus `default: block`. read_ticket is explicitly allowed; wire_funds is explicitly blocked; everything else is denied by default.

.raxit/security.yaml
apiVersion: raxit.security/v1
agent: quickstart-bot
default: block
rules:
  - effect: allow
    resource: read_ticket
  - effect: block
    resource: wire_funds
terminal
$ $ make -C examples demo-quickstart-py
raxit quickstart · agent=quickstart-bot · daemon=http://127.0.0.1:8261

How it works

The whole policy is two rules plus a default:

.raxit/security.yaml
apiVersion: raxit.security/v1
agent: quickstart-bot
default: block
rules:
  - effect: allow
    resource: read_ticket
  - effect: block
    resource: wire_funds
  • default: block — anything not listed is denied. The agent gets exactly what the policy names, nothing ambient.
  • decide() before the tool runs. The agent calls client.govern.decide(resource, args) and acts only on the returned effect. In this demo the decision is made at the decide level — no tool wrapper, no framework autopatch — so the loop is visible in three lines of code. (Wrapping real tools so a deny raises a [raxit BLOCKED] … refusal into the agent is what the framework integrations do — see Frameworks.)
  • Reason codes are part of the contract. Every decision carries a machine-checkable reason code (permit, deny.default_or_forbid, …); the demo's CI asserts on those exact strings, not on exit codes.
  • Audit before execute. Each decision is appended to the signed Decision Provenance log before its verdict returns — a failed audit write flips the decision to deny. The finale, client.audit.verify(signatures=True, pubkeys=[pubkey]), walks the hash chain and checks every Ed25519 signature: ok=True signatures_verified=True signed_count=2 count=2.

Why the SDK pins a public key

The SDK is zero-dependency and cannot verify Ed25519 locally, so it reads the daemon's public key from .raxit/keys/dpr_ed25519.pub and hands it to the engine's verify endpoint. Fail closed: no key, no signed finale.

What got denied — and why

CallDecisionReason codeWhy
read_ticketpermitpermitMatched the effect: allow rule — cleared to run.
wire_fundsdenydeny.default_or_forbidMatched the effect: block rule. The code is shared with default-deny on purpose: an unlisted tool under default: block is refused with the same reason, so forgetting a rule and forbidding one are equally closed.

Nothing in this run was deferred — the quickstart policy has no effect: review rule. The suspend-for-a-human path is its own demo: Human approval loop.

  • Quickstart — the install-and-init path for governing your own agent, including the zero-code raxit run flow.
  • Permit / defer / deny / modify / step-up — the full decision vocabulary and the Cedar resolution chain behind it.
  • Audit — the hash-chained, signed Decision Provenance log this demo verifies at the end.
  • Fail closed — why default-deny and forbid share a reason code, and what else refuses rather than degrades.

On this page