XODE Sentinel — User Manual

1. What Sentinel does

Sentinel gives every automated decision your systems make — an approval, a refusal, a flag, a payout — a receipt that anyone can check against the XODE blockchain. A receipt shows that one decision record is exactly what you committed at the time, and that nobody, including you or XODE, has changed it since.

Your records never leave your servers. Sentinel only ever receives a 32-byte hash of each record.

What a receipt proves

  • This exact record — subject, verdict, reason, policy, model, time — was committed and has not changed by a single byte since.
  • It existed no later than the finalized XODE block it is anchored in, written there by Sentinel's own anchor account.
  • With a window bundle: every record from that window was disclosed, exactly once.

What it does not prove

  • That the decision was correct or fair.
  • That the record's own timestamp is accurate (the block gives an upper bound).
  • That you submitted decisions you chose not to submit. The remedy is to give each person their receipt id at the moment of decision.

2. Key terms

TermMeaning
RecordOne decision: kind, subject, verdict, reason, policy, model, time, nonce, evidence hash. Stays with you.
LeafThe 32-byte hash of a record. The only thing sent to Sentinel.
Nonce / receipt idA unique value inside each record. Give it to the person the decision was about.
WindowA 10-minute period. Leaves received in a window are committed together when it closes.
AnchorThe transaction on XODE that fixes a window's commitment.
ReceiptYour record plus the proof that connects it to an anchored block.
Window bundleEvery leaf you committed in one window — for completeness audits.
HistoryThe chain of your windows, each linked to the one before.

3. Quickstart (about 15 minutes)

  1. Get a key. Open the console at https://sentinel.xode.net/console and choose Start a free trial (10,000 records per month), or use a key we issued you. The key is shown once — store it in your secret manager.
  2. Get the client. Download xode_sentinel.py from the console (one file, Python standard library only), or call the HTTP API directly (§8).
  3. Record a decision.
from xode_sentinel import Sentinel, policy_id, subject_hash

POLICY = policy_id(open("credit_policy.md").read(), "risk-model-2026-09")
s = Sentinel("xsk_...", base_url="https://sentinel.xode.net")

rec = s.record(
    kind="loan_screen",
    subject=subject_hash(customer_id, salt=SUBJECT_SALT),
    verdict="deny", reason="dti_over_limit",
    policy=POLICY, model="risk-model-2026-09",
    evidence={"dti": 0.61, "limit": 0.45},
)
give_to_customer(receipt_id=rec["nonce"])
  1. Wait for the window to close (up to 10 minutes) and for the anchor to be finalized (usually under a minute more).
  2. Get the receipt and check it:
receipt = s.receipt(rec["nonce"])

Open https://sentinel.xode.net/verify, drop the receipt file, and press Verify receipt.

JavaScript and TypeScript (Node 18+, Bun, Deno): download xode-sentinel.mjs and its types xode-sentinel.d.ts from https://sentinel.xode.net/sdk/xode-sentinel.mjs (one file, no dependencies). The API is the same as the Python client's and produces byte-identical records, so either can read the other's journal.

import { Sentinel, policyId, subjectHash, shareLink } from "./xode-sentinel.mjs";

const POLICY = policyId(readFileSync("credit_policy.md", "utf8"), "risk-model-2026-09");
const s = new Sentinel(process.env.SENTINEL_KEY);

const rec = s.record({
  kind: "loan_screen",
  subject: subjectHash(customerId, SUBJECT_SALT),
  verdict: "deny", reason: "dti_over_limit",
  policy: POLICY, model: "risk-model-2026-09",
  evidence: { dti: 0.61, limit: 0.45 },
});
giveToCustomer(rec.nonce);
// later: const link = shareLink(await s.receipt(rec.nonce));

4. Integrating into your decision path

Where to call it. Call record() at the single point where the decision becomes final — after every rule and model has run, before the result is shown or acted on. Calling it in two places records the same decision twice.

It never blocks. record() writes to a local journal and queues the leaf; the network send happens in the background (autoflush, every 5 s by default). A slow or unreachable Sentinel never fails your decision path. If your process stops before sending, the client re-sends unsent journal entries the next time it starts.

Keep the journal. The journal (sentinel-journal.jsonl by default) holds your records. Sentinel cannot rebuild them. Back it up like any business record, or store each record and its leaf in your own database.

Field guidance

FieldUse
kindWhat decided: loan_screen, ad_reward, moderation, assistant.
subjectWho it was about. Never raw personal data — use subject_hash(value, salt). Keep the salt secret and stable; with it you can show an auditor who a record is about.
verdictThe outcome: allow, deny, review, flag, answer, refuse.
reasonA short machine code, not prose: dti_over_limit, cooldown_active.
policypolicy_id(...) over the actual policy text, prompt, thresholds and model id. Do not use a hand-maintained version number.
modelThe model identity if an AI was involved, else leave empty.
evidenceThe data behind the decision. Only its hash is recorded; keep the original if you may need to show it.

Give out receipt ids. Return rec["nonce"] to the person concerned (on the screen, in the email, in the API response). If a receipt for that id can later not be produced, its absence is itself evidence.

5. Receipt lifecycle

StatusMeaningTypical time
openThe leaf is in the current window.until the window closes (≤ 10 min)
sealingThe window closed and is being committed.seconds
sealedCommitted; the anchor is being written and finalized.under a minute normally
anchoredIn a finalized XODE block. The receipt is complete.—

Every receipt, including one asked for while the window is still open, carries an ack: Sentinel's Ed25519 signature, made the moment the leaf arrived, over your company, the leaf, its window and the time it was received. Before sealed it is the only proof yet — it shows the record was submitted and when; the chain proof follows once the window is anchored, so ask again then. The signing key is pinned in both verifiers and published at /v1/status. An acknowledgement for a window whose anchored bundle lacks that leaf is proof that a record was dropped.

To let someone check a receipt themselves, send them a share link: share_link() in the Python SDK, or the button on the verify page after a check. The receipt travels in the part of the link after #, which browsers never send to any server.

Every anchored window is also timestamped on Bitcoin through the public OpenTimestamps calendars, so a receipt does not depend on trusting XODE alone. Once Bitcoin has confirmed it (usually within a few hours), receipts and bundles carry a bitcoin field, and the verifiers add step 6: they walk the proof from the window's global root and compare its end with the merkle root of the Bitcoin block it names, read from a public Bitcoin API (--btc-api to choose one). A proof that does not match fails the receipt; one still waiting for Bitcoin changes nothing.

6. Verifying a receipt

Anyone can verify, without an account and without trusting XODE.

In a browser — https://sentinel.xode.net/verify. Everything runs in the browser; the receipt is never uploaded. The page loads nothing from third parties, so you can save it and run it offline. Only one request leaves the browser: reading the block from a public XODE node (selectable under Advanced).

On the command line — download sentinel_verify.py (one file, Python 3.10+, standard library only):

python3 sentinel_verify.py receipt.json
python3 sentinel_verify.py receipt.json --rpc https://your-own-xode-node
python3 sentinel_verify.py receipt.json --offline     # hashes only

Results

Exit codeResultWhat to do
0VerifiedNothing — the record is proven.
1FailedThe record was changed, the file is malformed, or the anchor is not Sentinel's. Ask the issuer for the original receipt.
2Not on chain yetThe window is open, the block is not finalized, or the receipt came from a test server. Try again later.
3Chain unreachableTry another node with --rpc.
4Verifier errorThe file could not be read. This never means tampering.
5No record attachedThe receipt proves only that some 32 bytes were committed. Ask for the full receipt.

Who signed the anchor. Anyone can write data to a public chain from their own account, so a root "being on chain" proves nothing by itself. The verifiers accept only anchors signed by Sentinel's published anchor accounts, which are built into the verifier (not read from the receipt):

  • XqFJ46w2rZV89S6EoSzMuudFJh3qGwawP1PdnBa7R5HbVEjFv — sentinel.xode.net
  • XqBMcDhStCvxMaBoAPmThVKZm1unfNFebddJyzciv7Fbn1MLP — XODE omni

To check a deployment you run yourself, pass --signer <address>.

7. Audits

Completeness of a window. In the console, Committed windows → ↓ downloads a window bundle (every leaf of that window). Give it to the auditor with the records. The verifier (web or CLI) confirms that the disclosed leaves, each exactly once, rebuild the committed root and count — so nothing was withheld, added or repeated. To tie records to the bundle, the auditor hashes each record (the SDK's leaf_of()) and checks it is in the bundle.

Continuity of your history. History integrity → Run check re-checks that every window links to the one before it with no gaps or rewrites, and lets you download the chain for an auditor. A history check cannot show that the newest windows were not cut off; receipts held by your customers can.

The same log, a quarter later. Every window Sentinel publishes — yours and everyone else's — is an entry in one list that can only be added to, and the state of that list is written into the same blockchain transaction as the window. An auditor who writes down that one value on their first visit can ask, on any later visit, for a short proof that the list they are looking at now is the one they saw then with windows added and nothing else. The verifier does it for them: --log-head mine.json on the first run, the same flag on the next.

Two things follow. Your own history cannot be quietly rebuilt without that proof failing in the hands of anyone who kept a value. And we cannot show one history to you and a different one to someone else, because both would have to fit the same list. The proof is a few dozen numbers either way, whether the list is a thousand windows long or a million.

Decisions you never sent. Everything above protects what Sentinel received. A decision that was never submitted leaves no trace — unless you number them.

Give the client a stream name and it counts for you:

s = Sentinel("xsk_…", stream="loan-decisions")
rec = s.record(kind="loan_screen", ...)      # rec["seq"] == 1, then 2, 3 …

The name never leaves your building: the SDK sends its hash. The counter lives beside the journal and is written before the number is used, so a process that dies mid-decision burns a number instead of reusing it — and the hole it leaves is correct, something happened there.

In every window, Sentinel commits what the stream looks like — where it starts, how far it runs without a gap, and which numbers never arrived — as an ordinary leaf of your own tree. That statement is anchored with everything else, so a gap is a fact on two blockchains rather than a claim someone makes later. The console lists your streams and their holes; GET /v1/streams/{id} returns the same thing with the per-window statements.

What this is worth: "there was no such decision" stops being unanswerable. What it is not: a number you skip on purpose still only shows as a hole, and a stream you never start changes nothing.

One counter per writer. Two processes sharing one is the single case that produces duplicates, and a number reused with different content is reported as a conflict, not a gap — give each worker its own stream (stream=f"loans-{worker}") or a shared sequencer.

8. API reference

Base URL https://sentinel.xode.net. Authenticate with Authorization: Bearer <key>. Request bodies are JSON, at most 256 KB.

MethodPathKeyPurpose
POST/v1/leaves {"leaves":["0x…"]} (1–1000)ingest/adminSubmit leaves. Re-sending is safe.
GET/v1/receipts/{leaf}ingest/adminProof for one leaf.
GET/v1/windows?limit=50ingest/adminYour committed windows.
GET/v1/windows/{start}/bundleingest/adminEvery leaf of one window.
GET/v1/chainingest/adminYour full window history and its check.
GET/v1/me, /v1/usageingest/adminAccount, plan, usage this month.
GET/POST/DELETE/v1/keysadminList, create ({"label","role"}), revoke keys.
GET/v1/statusnoneIs the anchoring service healthy.
GET/v1/anchorsnoneEvery anchored root and its block.

Full reference: https://sentinel.xode.net/docs — the same endpoints with parameters and examples, rendered from /openapi.json. It opens for an API key or, if you do not have one yet, for a single confirmation in the omni app; this manual and the verifier need neither.

Leaves by hand. If you do not use the SDK, you must produce exactly the bytes the verifiers hash: JSON with sorted keys, no whitespace, UTF-8, the fields detail, kind, model, nonce, policy, reason, schema, subject, ts, verdict, with schema = "xode-sentinel/1" and ts an integer; the leaf is BLAKE2b-256 of those bytes. Copy canonical() from the SDK rather than re-implementing it.

9. Keys and roles

  • Admin keys can do everything, including creating and revoking keys. Keep them for people and the console.
  • Ingest keys can submit leaves and read receipts only. Use them in production services: a leaked ingest key cannot create replacement keys.
  • Keys are shown once and stored by us only as a hash. Revoking takes effect immediately; the console asks for a second click.
  • Security notifications. Set a webhook in the console (Security notifications) and Sentinel posts a signed JSON event when a key is created, revoked, or recovered. It is a URL, not an address: we ask for nothing about anyone. Each delivery carries X-Sentinel-Signature, an Ed25519 signature over "xode-sentinel/notify/1|" + body made with the key in /v1/status (the same key that signs acknowledgements). Deliveries retry for about eight hours and then stop; the console shows how the last few went.
  • If you lose every admin key, confirm in the omni app as the person who opened the account (Lost your admin key? in the console) and a new admin key is minted. Your other keys keep working. A trial account is opened the same way: one per person, confirmed in the app. Sentinel learns only that the same person came back — the subject it stores is random and means nothing anywhere else.

10. Limits

PlanRecords per month
Trial10,000
Starter1,000,000
Growth20,000,000
Enterpriseunmetered

Requests: up to 50 per second per key; batch leaves (up to 1,000 per request) instead of sending one at a time. Duplicates do not count against the quota.

11. Privacy and data

  • Sentinel stores 32-byte leaves, your account, and key hashes. It never sees your records, evidence or customer identities.
  • The chain receives one root per window for all customers together; nothing on chain identifies you, your customers, or your volume.
  • Records you hand to auditors or customers are yours to share; pseudonymise subjects with subject_hash.

12. Troubleshooting

SymptomCauseFix
401Key missing, wrong or revoked.Check the Authorization header; issue a new key in the console.
403 on /v1/keysIngest key used for key management.Use an admin key.
413Body over 256 KB.Send at most 1,000 leaves per request.
422A leaf is not 0x + 64 hex characters.Send rec["leaf"] as produced by the SDK.
429Rate limit or monthly quota.Batch and retry after Retry-After; check usage in the console.
Receipt stays openThe window has not closed.Wait up to 10 minutes.
Verify page says "Not a Sentinel receipt"Wrong file.Use the JSON from s.receipt() or the console.
Result 5 "No record attached"Receipt fetched from the API without your record.Use s.receipt(nonce), which attaches the record from your journal.

13. Support

sentinel@xode.net. Service health: https://sentinel.xode.net/v1/status.