Skip to main content

What are ZKScore Smart Contracts?

ZKScore smart contracts provide the foundational infrastructure for on-chain identity, reputation scoring, achievements, and trust systems. Built on Ethereum and compatible with all EVM chains.

IdentitySBT

Soulbound identity NFTs for unique user identification

ScoreCalculator

On-chain reputation scoring engine

AchievementRegistry

Achievement system and NFT badges

TrustRegistry

Attestation and trust verification system

ProtocolRegistry

Protocol integration and module management

Contract Architecture

Core Contracts

IdentitySBT Contract

Non-transferable identity NFTs that represent unique individuals:
Key Features:
  • Soulbound (non-transferable) NFTs
  • Unique username system
  • Activation mechanism
  • Metadata management

ScoreCalculator Contract

On-chain reputation scoring with real-time updates:
Key Features:
  • Real-time score calculation
  • Multi-dimensional scoring
  • Historical score tracking
  • Authorized updater system

AchievementRegistry Contract

Gamified achievement system with NFT rewards:
Key Features:
  • Custom achievement creation
  • NFT badge rewards
  • Progress tracking
  • Point system

TrustRegistry Contract

Flexible attestation system for building trust:
Key Features:
  • Schema-based attestations
  • Revocable attestations
  • Multi-signature support
  • Time-bound attestations

ProtocolRegistry Contract

Integration hub for protocols and modules:

Integration Examples

Direct Contract Integration

Ethers.js Integration

Viem Integration

Wagmi Integration

Network Deployments

Ethereum Mainnet

IdentitySBT: 0x...
ScoreCalculator: 0x...
AchievementRegistry: 0x...

Base

IdentitySBT: 0x...
ScoreCalculator: 0x...
AchievementRegistry: 0x...

Polygon

IdentitySBT: 0x...
ScoreCalculator: 0x...
AchievementRegistry: 0x...

Arbitrum

IdentitySBT: 0x...
ScoreCalculator: 0x...
AchievementRegistry: 0x...

Optimism

IdentitySBT: 0x...
ScoreCalculator: 0x...
AchievementRegistry: 0x...

BSC

IdentitySBT: 0x...
ScoreCalculator: 0x...
AchievementRegistry: 0x...

Security Features

Access Control

Role-based permissions and multi-sig support

Upgradeable

Proxy patterns for contract upgrades

Pausable

Emergency pause functionality

Audited

Comprehensive security audits

Gas Optimization

  • Batch Operations: Combine multiple calls in single transaction
  • Storage Optimization: Efficient data structures
  • Event Optimization: Minimal event emissions
  • Proxy Patterns: Upgradeable without migration

Testing

Hardhat Integration

Foundry Integration

Event Monitoring

Best Practices

Error Handling

Always check return values and handle reverts

Gas Estimation

Estimate gas before transactions

Event Listening

Monitor events for state changes

Batch Operations

Combine multiple calls when possible

Common Patterns

Identity Verification

Score Gating

Achievement Tracking

Next Steps

1

Choose Integration Method

Select direct contracts, Ethers, Viem, or Wagmi Integration Guide →
2

Deploy Contracts

Deploy to your preferred network Deployment →
3

Start Building

Integrate contracts into your application Examples →
4

Test Thoroughly

Use our testing utilities and examples Testing →

Support & Resources

Contract Addresses

All deployed contract addresses

ABI Files

Contract ABI files

GitHub

Source code and issues

Discord

Developer community

Need help? Check our Discord or GitHub issues