Skip to content

e3o8o/trig-hackathon

Repository files navigation

πŸš€ Trig Protocol + StewardChain: 72-Hour Hackathon

A Financial Stewardship Platform on Blockchain

Built on Base Sepolia testnet with DeFi backing integration.


🎯 What We're Building

Steward helps users practice faithful financial stewardship through:

  • Automated Tithing: Set it once, tithe automatically
  • Mission Protection: Insurance for international mission trips
  • Church Verification: Blockchain-based accountability with staking

Powered by Trig Protocol - an omnichain parametric condition execution engine.


πŸ—οΈ Architecture

trig-hackathon/
β”œβ”€β”€ contracts/          # Smart contracts
β”‚   β”œβ”€β”€ core/          # TrigImmutableCore protocol
β”‚   β”œβ”€β”€ steward/       # Steward applications
β”‚   β”œβ”€β”€ defi/          # DeFi backing integration
β”‚   β”œβ”€β”€ mocks/         # Test contracts
β”‚   └── interfaces/    # Contract interfaces
β”œβ”€β”€ test/              # Smart contract tests
β”‚   β”œβ”€β”€ unit/          # Unit tests
β”‚   └── integration/   # Integration tests
β”œβ”€β”€ scripts/           # Deployment scripts
β”œβ”€β”€ frontend/          # Next.js frontend
└── docs/              # Documentation

πŸš€ Quick Start

Prerequisites

  • Node.js v18+
  • npm or yarn
  • MetaMask wallet
  • Base Sepolia testnet ETH

Installation

# Install dependencies
npm install

# Set up environment
cp .env.example .env
# Add your private key and RPC URLs to .env

# Compile contracts
npx hardhat compile

# Run tests
npx hardhat test

# Deploy to Base Sepolia
npx hardhat run scripts/deploy-core.ts --network baseSepolia

Frontend Setup

cd frontend
npm install
npm run dev

Visit http://localhost:3000 to see the application.


πŸ“š Documentation


🎯 Core Features

Trig Protocol (Core)

  • βœ… Time-based conditions
  • βœ… Token balance conditions
  • βœ… Multisig conditions
  • βœ… Cross-chain ready (LayerZero OApp)

Steward Applications

  • βœ… Automated Tithe System
  • βœ… Mission Trip Protection
  • βœ… Steward Oracle Registry
  • βœ… Staking-based verification

DeFi Integration

  • βœ… Backing pool with real deposits
  • βœ… Simplified yield distribution
  • βœ… Mock Morpho adapter

πŸ§ͺ Testing

# Run all tests
npx hardhat test

# Run with coverage
npx hardhat coverage

# Run specific test
npx hardhat test test/unit/TrigImmutableCore.t.sol

🚒 Deployment

Base Sepolia Testnet

# Deploy core protocol
npx hardhat run scripts/deploy-core.ts --network baseSepolia

# Deploy Steward contracts
npx hardhat run scripts/deploy-steward.js --network baseSepolia

# Verify contracts
npx hardhat verify --network baseSepolia <CONTRACT_ADDRESS>

Deployed contract addresses are saved in deployments/base-sepolia.json.


🎬 Demo

Live Demo

Visit: StewardChain Demo (to be deployed)

Demo Video

Watch: 5-Minute Demo (to be recorded)

Demo Script

  1. Automated Tithe: Create commitment and execute payment
  2. Mission Protection: Purchase policy and file claim
  3. Church Verification: Register church and verify leaders
  4. DeFi Backing: Add backing capital and view yield

πŸ‘₯ Team

  • Developer 1: Smart contracts, testing, deployment
  • Developer 2: Frontend, integration, UI/UX
  • Product Manager: User stories, demo, presentation

πŸ› οΈ Tech Stack

Smart Contracts

  • Solidity 0.8.22
  • Hardhat
  • OpenZeppelin Contracts
  • LayerZero OApp

Frontend

  • Next.js 14
  • TypeScript
  • Tailwind CSS
  • shadcn/ui
  • wagmi + viem
  • RainbowKit

Infrastructure

  • Base Sepolia testnet
  • IPFS for metadata
  • The Graph for indexing

πŸ“Š Success Metrics

Hackathon Goals

  • βœ… Working demo on testnet
  • βœ… 2+ use cases operational
  • βœ… DeFi backing integrated
  • βœ… Polished frontend UI
  • βœ… 5-minute demo video

Post-Hackathon Vision

  • Multi-chain deployment
  • Real DeFi protocol integration
  • Production security audit
  • Mobile application
  • $50B+ market opportunity

πŸ”’ Security

This is a hackathon project. DO NOT USE IN PRODUCTION without:

  • Professional security audit
  • Comprehensive testing
  • Legal compliance review
  • Economic security analysis

πŸ“„ License

MIT License - See LICENSE for details


πŸ™ Acknowledgments

Built for [Hackathon Name] 2025

Special thanks to:

  • Base for testnet infrastructure
  • LayerZero for cross-chain messaging
  • OpenZeppelin for security patterns
  • Morpho for DeFi inspiration

πŸ“ž Contact


Built with ❀️ for faithful stewardship

About

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 2

  •  
  •