Blockchain-powered SACCO operations on Cardano - Transforming cooperative finance through tokenization and transparency
AmanaDapp is a decentralized application for managing cooperative finance (SACCO) operations on the Cardano blockchain. It provides smart contract-based automation for entity management, member identity, treasury operations, and democratic governance.
- ποΈ Entity Registry: Smart contract-based SACCO creation and member management
- π€ Member NFTs: Unique on-chain identity certificates with embedded metadata
- π° Treasury Management: Multi-signature treasury with atomic operations
- π³οΈ Democratic Governance: NFT-gated voting with automated proposal execution
- π On-chain Transparency: All operations recorded immutably on Cardano
| Component | Technology |
|---|---|
| Blockchain | Cardano (Preprod/Preview Testnet, Mainnet-ready) |
| Smart Contracts | Aiken (Cardano-native functional language) |
| Blockchain Integration | Lucid Evolution |
| Wallet Integration | Mesh SDK (multi-wallet support) |
| Frontend | Next.js 14 with TypeScript |
| Styling | Tailwind CSS + Radix UI |
| Blockchain API | Blockfrost |
| State Management | React Context + localStorage |
| Backend | Node.js with Express |
| Database | MongoDB (off-chain data) |
Manages SACCO creation and member management with the following capabilities:
- Entity creation with founding member
- Member addition/removal with linked NFT minting
- Admin management
- Member status updates (Active/Inactive/Suspended)
Mints unique member identity NFTs atomically linked to entity registry operations:
- One NFT per member per entity
- Atomic transaction linking with registry updates
- Prevents unauthorized minting
- Supports member removal (NFT burning)
Secure multi-signature treasury operations:
- Contribution tracking with NFT verification
- Transaction proposals and approval workflow
- Multi-signature execution
- Complete audit trail
- Governance integration
Democratic decision-making with NFT-based verification:
- Proposal creation (NFT-gated)
- Multi-option voting (For/Against/Abstain)
- Automatic execution upon threshold
- Cross-contract operations
- Parameter management
- Node.js 18+ and npm/yarn
- Aiken installed via aikup (Installation Guide)
- Cardano Wallet (Eternl, Nami, or Flint)
- Blockfrost API Key (Get one here)
- Clone the repository
git clone https://github.com/your-org/amanadapp.git
cd amanadapp- Install dependencies
npm install- Set up environment variables
Create a .env.local file in the root directory:
# Network Configuration (Preview, Preprod, or Mainnet)
NETWORK=Preview
# Blockfrost API Configuration
NEXT_PUBLIC_BLOCKFROST_PROJECT_ID=your_blockfrost_project_id
# Deployment Configuration
MNEMONIC=your_mnemonic_phrase_for_deployment- Compile smart contracts
If you need to modify or recompile the Aiken smart contracts:
# Install Aiken if not already installed
curl --proto '=https' --tlsv1.2 -LsSf https://install.aiken-lang.org | sh
# Build contracts
aiken build- Deploy smart contracts (Optional - for new deployments)
# Deploy Entity Registry
npm run deploy:entity-registry
# Deploy Member NFT Policy
npm run deploy:member-nft
# Deploy Treasury Management
npm run deploy:treasury
# Deploy Governance
npm run deploy:governance- Run the development server
npm run devOpen http://localhost:3000 to see the application.
-
Connect Your Wallet
- Click "Connect Wallet" and select your Cardano wallet
- Ensure you're on the correct network (Preview/Preprod for testing)
-
Create a New Entity
- Navigate to "Entity Registry"
- Fill in your SACCO's name and description
- Submit the transaction and wait for confirmation
- Your entity is now live on the blockchain!
-
Add Members
- Select your entity
- Click "Add Member"
- Enter member details
- Member receives a unique NFT upon confirmation
-
Manage Treasury
- Navigate to "Treasury Management"
- Configure multi-signature settings
- Track contributions in real-time
- Propose and approve transactions
-
Create Governance Proposals
- Navigate to "Governance"
- Create proposal with details and voting deadline
- Members vote using their NFTs
- Proposals execute automatically upon approval
-
Receive Your Member NFT
- Your admin will add you to the entity
- You'll receive a unique NFT in your wallet
- This NFT grants you voting rights and member privileges
-
Participate in Governance
- View active proposals
- Cast your vote (For/Against/Abstain)
- Track proposal status in real-time
-
Make Contributions
- Navigate to "Treasury"
- Submit contribution with amount
- Transaction is recorded on-chain
-
Request Loans
- Create a loan proposal
- Members vote on approval
- Funds automatically disbursed upon approval
amanadapp/
βββ app/ # Next.js app directory
β βββ page.tsx # Landing page
β βββ entity-registry/ # Entity management pages
β βββ treasury/ # Treasury management pages
β βββ governance/ # Governance pages
βββ components/ # React components
β βββ ui/ # Radix UI components
β βββ wallet/ # Wallet connection components
βββ hooks/ # Custom React hooks
β βββ useEntityRegistry.ts # Entity registry interactions
β βββ useTreasury.ts # Treasury interactions
β βββ useGovernance.ts # Governance interactions
βββ lib/ # Utility libraries
β βββ cardano/ # Cardano integration utilities
βββ validators/ # Aiken smart contracts
β βββ entity_registry/ # Entity registry validator
β βββ nft_policy/ # Member NFT minting policy
β βββ treasury_management/ # Treasury validator
β βββ governance/ # Governance validator
βββ contract-deployment/ # Smart contract deployment scripts
β βββ deploy-entity-registry.ts
β βββ deploy-member-nft.ts
β βββ deploy-treasury.ts
β βββ deploy-governance.ts
βββ plutus.json # Compiled smart contracts blueprint
βββ aiken.toml # Aiken project configuration
βββ package.json # Node.js dependencies
# Development
npm run dev # Start development server
npm run build # Build for production
npm run start # Start production server
npm run lint # Run ESLint
# Smart Contract Deployment
npm run deploy:entity-registry # Deploy entity registry
npm run deploy:member-nft # Deploy member NFT policy
npm run deploy:treasury # Deploy treasury management
npm run deploy:governance # Deploy governance
# Aiken Commands
aiken build # Compile smart contracts
aiken check # Type-check and run tests
aiken docs # Generate documentation
aiken test # Run smart contract tests# Run all tests
aiken check
# Run specific test file
aiken check -m validators/entity_registry
# Run with verbose output
aiken check --verbose
# Generate test coverage
aiken build --trace-level verbose- Preview Testnet: For development and testing
- Preprod Testnet: For pre-production testing
- Faucet: Cardano Testnet Faucet
Ready for deployment to Cardano mainnet. Ensure thorough testing on testnets first.
- Preview: preview.cardanoscan.io
- Preprod: preprod.cardanoscan.io
- Mainnet: cardanoscan.io
We welcome contributions! Please see our Contributing Guide for details.
- Fork the repository
- Create a feature branch (
git checkout -b feature/amazing-feature) - Commit your changes (
git commit -m 'Add amazing feature') - Push to the branch (
git push origin feature/amazing-feature) - Open a Pull Request
- Smart contracts audited by [Auditor Name]
- Multi-signature treasury management
- Hardware wallet integration supported
- Regular security updates and patches
Report security vulnerabilities to: security@amanadapp.io
This project is licensed under the Apache License 2.0 - see the LICENSE file for details.
- Cardano Foundation for blockchain infrastructure
- Aiken Team for the smart contract language
- Mesh SDK for wallet integration
- Blockfrost for API services
Built for cooperative finance on Cardano