Skip to content
DoraHacks BUIDL · KeeperHub Main Track
AgentBadge AgentBadge
integrates
KeeperHub KeeperHub

Onchain Trust Records for the Agentic Web

AgentBadge scans any site for agent-readiness, records the result onchain through a KeeperHub workflow (Base Sepolia), and mints a soulbound trust badge. KeeperHub Agent Economy hackathon (Sep 6-18, 2026).

3
KeeperHub workflows
2
Trust contracts
4
MCP tools
$0.01
x402 per record
⚙️ KeeperHub Workflows (3) ▾

Three KeeperHub workflows power the onchain trust record pipeline:

1. record-scan

Triggered after each AgentBadge scan. Calls TrustRegistry.recordScan() on Base Sepolia with the scan result, site URL, score, and rule breakdown. Creates a permanent onchain trust record.

2. mint-trust-badge

Triggered when scan score ≥ 85. Calls TrustBadge.mint() to mint a soulbound ERC-721 NFT on Base Sepolia. The badge is non-transferable and permanently linked to the scanned site.

3. audit-stream

Long-running workflow that listens for RecordScan events on TrustRegistry and streams them via SSE to the audit trail table. No page refresh needed — rows appear live.

📜 Trust Contracts (2) ▾

Two smart contracts on Base Sepolia (84532) form the onchain trust layer:

TrustRegistry.sol

Base Sepolia

Stores scan records onchain. Key functions:

  • recordScan(siteUrl, score, rulesPassed, rulesTotal) — creates a trust record
  • getRecord(id) — returns scan data for verification
  • recordCount() — total records onchain

Emits RecordScan event → consumed by audit-stream workflow.

TrustBadge.sol

ERC-721 SBT

Soulbound (non-transferable) NFT contract. Key functions:

  • mint(to, siteUrl, score) — mints badge (score ≥ 85 only)
  • tokenURI(tokenId) — onchain metadata JSON
  • _update() — override: revert on transfer (soulbound)

Implements ERC-721 with _update override to prevent transfers.

Contract interaction flow:

AgentBadge Scan
    ↓ (score + rules)
KeeperHub Workflow: record-scan
    ↓
TrustRegistry.recordScan()  ──→  emits RecordScan event
    ↓                                    ↓
TrustBadge.mint() (if score ≥ 85)    audit-stream → SSE → browser
🔧 MCP Tools (4) ▾

Four MCP tools expose the trust record system to AI agents:

keeperhub-scan

Triggers an AgentBadge scan on a given URL. Returns scan ID, score, and rule breakdown. Supports dry-run mode (no onchain tx).

keeperhub-record

Records a scan result onchain via KeeperHub workflow. Calls TrustRegistry.recordScan(). Returns tx hash + Basescan link.

keeperhub-audit

Queries the onchain audit trail. Returns recent trust records with tx hashes, timestamps, and scan scores.

keeperhub-badge

Checks if a site has a TrustBadge NFT. Returns token ID, mint tx, and onchain metadata if badge exists.

Agents discover these tools via the MCP server descriptor at /.well-known/mcp.json and call them directly — no UI needed.

💵 x402 Payment ($0.01/record) ▾

Agents pay for onchain records via the x402 protocol — native HTTP 402 payment:

  1. Agent calls keeperhub-record MCP tool
  2. Server returns 402 Payment Required with x402 challenge
  3. Agentic Wallet skill signs an EIP-3009 USDC authorization
  4. Server settles payment and executes the KeeperHub workflow
  5. Two onchain receipts: USDC transfer + TrustRegistry record

Cost breakdown: $0.01 USDC per record (gas on Base Sepolia is negligible)

Architecture

Every arrow is one verifiable transaction on Base Sepolia (84532).

⚡ AgentBadge Site URL https://example.com web2 1. scan AgentBadge Scan 40 rules, score 0-100 web2 2. trigger KeeperHub Workflow webhook, write-contract MCP 3. record TrustRegistry recordScan() on Base EVM 4. stream Audit Trail + SSE live feed + Basescan SSE 5. score >= 85 → mint TrustBadge mint soulbound ERC-721 SBT ERC-721

Base Sepolia testnet — every arrow is one verifiable tx

⚡ AgentBadge components in this flow ▾

The AgentBadge Scan, Audit Trail + SSE, and TrustBadge mint nodes (dashed border in the diagram) are AgentBadge components:

  • AgentBadge Scan — runs a 40-rule agent-readiness scan, produces a score (0-100) and structured report
  • Audit Trail + SSE — live server-sent events feed streaming onchain records to the browser in real-time
  • TrustBadge mint — when score ≥ 85, mints a soulbound ERC-721 trust badge on Base Sepolia
  • KeeperHub Workflow and TrustRegistry are KeeperHub infrastructure components
📋 Step-by-step data flow ▾
  1. Scan — AgentBadge scans the site URL with 40 agent-readiness rules, producing a score and structured report
  2. Trigger — Scan result triggers a KeeperHub workflow via webhook (write-contract MCP tool)
  3. Record — KeeperHub workflow calls TrustRegistry.recordScan() on Base Sepolia, creating an onchain trust record
  4. Stream — The onchain record streams live via SSE to the audit trail table (no page refresh needed)
  5. Mint — If the scan score ≥ 85, a soulbound TrustBadge (ERC-721 SBT) is minted on Base Sepolia
❓ FAQ ▾

What is KeeperHub?

KeeperHub is an onchain workflow automation platform that lets smart contracts trigger external actions via MCP tools — webhooks, contract writes, and API calls.

How does AgentBadge use KeeperHub?

AgentBadge triggers a KeeperHub workflow after each scan. The workflow calls TrustRegistry.recordScan() on Base Sepolia, creating a permanent onchain trust record.

What is a dry-run?

A dry-run preview shows exactly what would be executed onchain (function arguments, workflow name, target contract) without actually sending a transaction. You confirm before anything goes onchain.

What is the TrustBadge?

A soulbound (non-transferable) ERC-721 NFT minted on Base Sepolia when a site scores ≥ 85 on the agent-readiness scan. It serves as a permanent onchain proof of agent-readiness.

How do agents pay?

Agents pay via x402 protocol — a 402 challenge triggers the Agentic Wallet skill to sign an EIP-3009 USDC transfer. Two onchain receipts: payment settlement + trust record.

How it works

1

Scan

40-rule agent-readiness scan (SSRF-guarded, free dry-run)

2

Confirm

Dry-run preview shows exactly what lands onchain (functionArgs), then confirm

3

Record

KeeperHub executes the workflow: TrustRegistry.recordScan onchain, tx on Basescan

4

Verify

Audit trail (live SSE) + keeperhub-audit MCP tool; agents pay via x402 (USDC)

Try it: scan → onchain record

One POST away from a permanent onchain trust record.

Agents can pay per onchain record via x402 (USDC on Base): POST /api/keeperhub/scan/premium

Live Audit Trail

Onchain records, streamed as they happen.

Status Site Score Tx Recorded

Source: TrustRegistry on Base Sepolia · each Tx links to Basescan

Stack

KeeperHub MCP
workflow engine, org key
Base Sepolia
84532, Basescan
TrustRegistry / TrustBadge
Solidity 0.8.30, OZ 5.1
x402 v2
EIP-3009 USDC, facilitator
MCP tools
4 keeperhub-* tools
SSE
live audit stream
Hono + hono/html
server-rendered, zero client framework

API Surface

Every public endpoint and MCP tool from Phase C/D.

Surface Endpoint / Tool Auth Returns
Scan (free) POST /api/keeperhub/scan — dry-run preview or onchain tx
Scan (premium) POST /api/keeperhub/scan/premium x402 · $0.01 onchain tx (paid via USDC)
Audit API GET /api/keeperhub/audit — events + onchain + Basescan links
Live stream GET /api/keeperhub/audit/stream — event: audit frames (SSE)
MCP tools keeperhub-record-scan · mint-trust-badge · workflow-status · audit MCP session via AgentBadge MCP server

Run the demo above

A permanent onchain record is 30 seconds away.

Support: support@agentbadge.xyz