Technical Details
Technical information for developers
This document provides comprehensive technical information about FrensPool's architecture, smart contracts, and integration points for developers who want to build on or interact with the platform.
Architecture Overview
FrensPool uses a modern web3 architecture consisting of:
Smart Contracts: Solidity contracts deployed on Monad Testnet
Frontend Application: Next.js web application with React
Backend Services: Supabase for data indexing and user management
Blockchain Interactions: Ethers.js v6 for contract interactions
State Management: React context and hooks for frontend state
Styling: Tailwind CSS with shadcn/ui components
title FrensPool Architecture
graph TD
A[Frontend (Next.js)] --> B[Smart Contracts (Solidity)]
A --> C[Supabase Backend]
B --> D[Monad Blockchain]
B --> E[Chainlink Oracles]
C --> F[Database]
C --> G[Authentication]
A --> H[Ethers.js]
H --> BSmart Contract Details
Contract Address
Monad Testnet: 0x2535fe5De9A5BfAF6cf27316f141a5f67239E65A
Contract Architecture
The FrensPool contract inherits from OpenZeppelin's Ownable and ReentrancyGuard:
Uses:
Ownable: Access controlReentrancyGuard: Prevent reentrancyAggregatorV3Interface: Chainlink price feeds
Key Data Structures
Enums
Pool Struct
Constants
Key Functions
Create Pool
Cast Vote
Close Pool
Resolve Pool (Manual)
Claim Winnings
Events
Frontend Integration
Contract ABI
Refer to the FRENS_POOL_ABI for simplified interaction.
Connecting with Ethers.js
Setup
Create Pool Example
This documentation will continue to evolve as FrensPool adds features, optimizations, and mainnet support. For full ABI, helper functions, and additional integrations (e.g., Farcaster mini-app context), refer to the frenspool-dev-kit repo.
Last updated