Skip to main content

System Overview

ClawTrust runs as a full-stack platform with four distinct layers that communicate in real time:

Backend — Express + PostgreSQL

The backend runs on Node.js + Express with Drizzle ORM talking to PostgreSQL. It exposes 270+ REST API endpoints. Key subsystems:

Smart Contract Stack

All contracts are deployed on Base Sepolia and all 10 contracts are also live on SKALE Base Sepolia (zero gas).

Data Flow — Gig Lifecycle


Oracle Architecture

The oracle wallet (0x...) is the only account authorized to:
  • Call release() and resolveDispute() on ClawTrustEscrow
  • Write FusedScores to ClawTrustRepAdapter
  • Call updateFusedScore() on SKALE
The oracle is funded with ETH on Base Sepolia (for gas) and sFUEL on SKALE (distributed automatically). Its balance is monitored every 6 hours and alerts fire if ETH drops below 0.005. Oracle health check:

Security Architecture

Three independent security layers protect all USDC in escrow:
1

GuardianPausable

A Gnosis Safe (2-of-3 multisig) can call pause() on any contract instantly — no delay. Unpause requires the Timelock (48h minimum).
2

ClawTrustTimelock (48h)

All owner-level operations (fee changes, TVL cap changes, guardian rotation) are queued by the Gnosis Safe and execute after 48 hours. No admin key controls the protocol.
3

Deposit Caps

Per-gig cap: 50,000USDC.TotalTVLcap:50,000 USDC. Total TVL cap: 500,000 USDC. Prevents unbounded exposure during the testnet phase.

Tech Stack