KARMA · Casper Agentic Buildathon

An RWA price oracle that pays and gets paid
without a human in the loop.

An agent discovers a real-world-asset price feed, pays for it over a signed x402 envelope, and settles the job on a Casper smart contract — the trust comes from Odra escrow + cryptography, not a server anyone has to trust.

120/120 Odra contract tests passing Real ECDSA/SHA-256 payment verification Casper-native secp256k1 keystore Real ~538KB compiled wasm, verified Deployed + verified end-to-end on Testnet Real dispute ruled live — reputation slashed 50→40

Where this sits

One of the buildathon's four reference shapes — a price-feed agent that proves who it is before it gets paid.

01

RWA oracle

rwa_price_oracle — a signed BTC/ETH/gold feed, priced per call, discoverable by any agent through KARMA-MCP.

02

Verified identity

identity_policy is a real field on the Odra contract — a skill can require a fresh, verified caller before it will run.

03

Escrow, not trust

Payment sits in the Odra registry's pull-payment ledger until the buyer confirms — never a bare promise.

04

Agent decides

The autonomous loop picks the highest expected-profit skill under a hard budget cap and invokes it itself — no human clicks "buy".

The loop, end to end

Every box below is real code that actually ran to produce this page — not a mockup.

1 · discover
KARMA-MCP
finds rwa_price_oracle
2 · pay
x402 envelope
secp256k1-signed, off-chain
3 · verify
ECDSA / SHA-256
provider checks it, live
4 · settle
Odra registry
create_job escrow on Casper

See it run

Captured verbatim from this repo — pnpm exec tsx src/scripts/demo_casper_x402_live.ts. A real local HTTP server issues a real 402, a real signature gets verified, nothing is printed by hand.

$ pnpm exec tsx src/scripts/demo_casper_x402_live.ts
[demo] provider stub listening on http://localhost:8934/invoke
[client] step 1: probe /invoke (no payment)
┌── Step 1 — 402 Payment Required (real HTTP) ──┐
│ accepts[0].amount = 10000000 motes             │
│ accepts[0].payTo  = account-hash-c863d5...6234 │
└─────────────────────────────────────────────────┘
[client] step 2: sign a real x402 payment envelope (secp256k1/SHA-256/DER)...
[client] step 3: POST /invoke with X-Payment — one request, real signature verified server-side
[provider] X-Payment received, verifying (real ECDSA/SHA-256, no facilitator round-trip)...
[provider] verified OK — payer: account-hash-4372145f...2ffd9
[provider] price feed: BTC/USD = $63076.00 (source: coingecko)
┌── Step 3 — provider response ──┐
│ status = 200                    │
│ feed = {"feed":"BTC/USD","price":"63076.00",...} │
└──────────────────────────────────┘
[demo] HTTP + crypto loop PASS (offline — re-run --live once a funded key submits the on-chain leg)
$ cargo +nightly test --manifest-path contracts-odra/Cargo.toml
...
test result: ok. 120 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out

Reproduce both yourself — no funded wallet needed for either command above. The price above is a live CoinGecko quote, not a fixed stub — it'll differ every run. There's also a real animated terminal-cast recording of this exact run, captured with asciinema — same content as the transcript above, played back frame-by-frame.

The courtroom, run for real

Every agent economy needs a way to settle "I didn't get what I paid for" — most demos skip this. KARMA's arbiter is itself an on-chain role, distinct from both sides of the deal. This ran live on Testnet on 2026-07-07, real transactions, real verdict:

1 · deliver
provider
submits a result
2 · dispute
requester
posts a bond, contests it
3 · respond
provider
matches the bond
4 · arbitrate
neutral arbiter
a 3rd on-chain account rules

Verdict: ProviderAtFault. Result, read straight off the contract afterward — not asserted, read: escrow + both bonds returned to the requester (getJob().status == "Refunded"), and the provider's skill reputation actually dropped 50 → 40. Full tx-by-tx trail — including two real mistakes hit live along the way (an underfunded throwaway key, a duplicate task hash, both caught by the contract's own error codes) — in DEMO_CASPER.md.

What's real today, what's the last step

Said plainly, on purpose — a claim we can't back up is worse than no claim.

LayerStatusDetail
Odra AgentSkillRegistry logicreal620 LoC, 120 tests: escrow, dispute, evaluator, identity gate, Sybil bond.
x402 payment enveloperealsecp256k1/SHA-256/DER signed and independently re-verified — not a structural stub.
HTTP 402 → pay → verify looprealRuns against a live local server, shown above verbatim.
Casper keystorerealSame secp256k1 key already signing Ethereum/Stellar — one backup, three chains.
MCP tool surfacereal25 tools (casper_register_skill, casper_create_job, casper_get_account_state, composition, evaluator/dispute/arbitration, cross-chain-rep governance, …) — any MCP client can drive this directly, not just a terminal script.
Compiled contract wasmreal~538,000 bytes, WebAssembly.validate()-clean, all 59 entry points exported — contracts-odra/build-wasm.sh, reproducible today.
On-chain deploy + settlement txrealDeployed at hash-29b7daeb… (governance-hardened redeploy), verified end-to-end: deploy, deposit_bond, create_job, deliver_result confirmed on the original deploy; the redeploy's real 2-of-2 multisig + 48h timelock confirmed by decoding the contract's own GovernanceConfigured event. See DEMO_CASPER.md for tx-by-tx evidence.
Full job lifecyclerealregister → bond → escrow → deliver → confirm → withdraw, six real transactions, provider reputation bumped live to 55.
Courtroom — dispute + arbitraterealA real contested delivery, ruled by a neutral on-chain arbiter — ProviderAtFault, reputation slashed 50→40, escrow refunded. Previously unit-tested only; now run live.
Cross-chain reputation governancereal / pendingpropose_set_cross_chain_rep + approve_proposal both real and confirmed on-chain; execute_proposal correctly reverts TimelockNotElapsed against the real 48h clock — completes ~2026-07-09.
Full reproduction guide → Project README Odra contract source