swornly

Deterministic tools that AI agents pay for, one call at a time. Every answer comes back sworn — an HMAC-signed receipt you (or an auditor) can re-verify later. A chat tool narrates a result; swornly signs it. Two open payment rails, no accounts, no API keys.

pay-per-call signed receipts x402 (USDC / Base) L402 (Lightning) MCP · OpenAPI

The idea

Agents act on facts they can't check — "this command is safe to run", "this schema didn't break", "here's the file". swornly is a toll-booth of small, deterministic endpoints that return a checkable answer for a fraction of a cent: pay the 402, get the result plus a signed receipt. Same input always yields the same output, byte-for-byte — and the receipt proves which input produced which verdict, so the agent isn't just taking its own word for it.

Tools

Verification oracles

The core of swornly — deterministic checks an agent runs before it trusts itself. JSON in, JSON out, a signed receipt on every response.

POST /dry-run/command        # is this shell/git command destructive? what's the blast radius?
POST /diff/mcp-schema        # breaking vs non-breaking changes between two MCP tools/list
POST /snapshot/tool-contract # stable fingerprint of a tools/list (pin it, detect drift)
POST /receipts/verify        # free: re-verify any receipt

Documents

The first tool on the substrate: render Markdown to a styled PDF.

POST /convert                # Markdown -> PDF

Every paid path has an /l402 sibling for the Lightning rail — e.g. /dry-run/command/l402.

Pricing · per call

/dry-run/command          $0.02    cheap insurance against a wiped disk
/convert · /diff/mcp-schema   $0.01
/snapshot/tool-contract   $0.005
/receipts/verify          free

x402 prices in USDC on Base; the L402 rail bills the satoshi equivalent. No subscription, no key — the agent just pays the 402 challenge.

Quickstart · x402

USDC over the x402 protocol

First call returns 402 with payment requirements. Sign an EIP-3009 transferWithAuthorization and resubmit with the X-PAYMENT header to get the verdict + receipt.

curl -i -X POST https://swornly.luci.ws/dry-run/command \
  -H 'Content-Type: application/json' \
  -d '{"command":"git reset --hard"}'

Quickstart · L402

Lightning invoice + macaroon

First call returns 402 with a BOLT-11 invoice and a macaroon in WWW-Authenticate. Pay the invoice, then resubmit with Authorization: L402 <macaroon>:<preimage>.

curl -i -X POST https://swornly.luci.ws/dry-run/command/l402 \
  -H 'Content-Type: application/json' \
  -d '{"command":"rm -rf ../build"}'

Discovery

Testnet shakedown. This deployment runs Base Sepolia x402 + a mock L402 backend. No real money, no real Lightning node — safe to poke at, not safe to charge real users with.