Skip to main content

Overview

Build trusted marketplaces where buyer/seller reputation reduces fraud and improves transaction confidence.

Implementation

async function getSellerTrustLevel(seller) {
  const score = await zkScore.getScore(seller);
  const attestations = await trustRegistry.getReceivedAttestationUIDs(seller);
  
  if (score.total >= 700 && attestations.length >= 5) return 'verified';
  if (score.total >= 400) return 'trusted';
  return 'new';
}