MainStreet Oracle

EIP-712 signed reputation scores for any wallet on Base. Cryptographically verifiable on-chain. Free to fetch, free to verify, $0.25 for premium audit. The flag that turns an HTTP read into oracle-grade trust.

Live on Base mainnet · MainStreetVerifier contract: 0x7397adb9713934c36d22aa54b4dbbcd70263592b · basescan · ABI · source
EIP-712
Signature scheme
24h
Freshness window
$0
Fetch + verify cost
~$0.00003
Onchain verify (gas)

3 ways to use it

1. Off-chain via npm (Node / browser)

npm i @raskhaaa/mainstreet-oracle viem

import { requireMinScore } from '@raskhaaa/mainstreet-oracle/verifier';
import * as viem from 'viem';

// throws if score < 30 or signature invalid
const score = await requireMinScore('0xAgentAddr', 30, viem);
// proceed with payment / interaction

2. Server-side (no crypto deps)

const att = await fetch('https://avisradar.app/api/agent/attestation/0xAgentAddr').then(r => r.json());
const r = await fetch('https://avisradar.app/api/agent/verify', {
  method: 'POST',
  headers: { 'Content-Type': 'application/json' },
  body: JSON.stringify({ payload: att.payload, signature: att.signature, minScore: 30 }),
});
const { valid, score } = await r.json();

3. On-chain (Solidity)

interface IMainStreetVerifier {
  function requireMinScore(
    bytes32 subject, uint8 minScore,
    uint8 score, uint64 timestamp, uint64 nonce,
    bytes calldata signature
  ) external view returns (bool);
}

IMainStreetVerifier constant MS = IMainStreetVerifier(0x7397adb9713934c36d22aa54b4dbbcd70263592b);

function payAgent(address agent, /* ...attestation calldata */) external {
  MS.requireMinScore(subject, 30, score, timestamp, nonce, sig);
  // ... your payment logic ...
}

Why oracle-grade and not just an API?

SurfaceTrust modelCost
HTTP read of /scoreYou trust MainStreet's HTTP serverFree
Off-chain EIP-712 verifyYou trust MainStreet's signing key (the deployer of the verifier contract)Free
On-chain via deployed verifierSolidity proof. Tx reverts if signer ≠ operator or signature ≠ payload~$0.00003 in gas
Premium /auditBundled signed payload + 18 identity proofs + SLA + settlements$0.25 USDC via x402

What gets attested

Schema (must match off-chain signer):

Attestation(
  string version,         // "mainstreet-v1"
  string subjectType,     // "agent-onchain"
  bytes32 subject,        // sha256(toLowerCase(address))
  uint8 score,            // 0-100
  uint64 timestamp,       // unix seconds, ≤24h old
  address operator,       // 0xAC3ca7c5d3cDD7702fd08F9C4C28dAA22296aDa9
  uint64 nonce            // unique per attestation
)

Domain: { name: "MainStreet", version: "1", chainId: 8453 }. No verifyingContract — attestations are off-chain artifacts that any reader can verify against the deployed contract's OPERATOR().

Resources

Try a live attestation → Integrate in 10 lines → Verifier on basescan →