Skip to content

Aditya-linux/Care-Fund

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

❤️ CareFund | Decentralized Crowdfunding on Stellar

Stellar License Status

CareFund is a transparent, trustless crowdfunding platform built on Stellar Smart Contracts (Soroban). It empowers users to create fundraising campaigns where every donation is verified on-chain, and funds are cryptographically secured so only the campaign owner can withdraw them.

Dashboard Preview


🔗 Live Links

Resource Link
🚀 Live Demo Launch App
📄 Smart Contract View on Stellar.Expert
🔗 Contract Calls View Recent Transactions

💡 How It Works

  1. Create: Users start a campaign by setting a name, target amount, and deadline. This deploys a new campaign state on the blockchain.
  2. Donate: Supporters send Native Tokens (XLM) directly to the campaign via the smart contract.
  3. Track: The dashboard updates in real-time, showing the progress bar and total raised matching on-chain data.
  4. Withdraw: Once the goal is met (or whenever needed), only the connected wallet that created the campaign sees the "Withdraw" button to retrieve funds.

✅ Key Features (Yellow Belt)

This project meets all Level 2 requirements for the Stellar Developer Challenge:

  • Smart Contract Logic: Custom Rust contract (smart-contract/src/lib.rs) handles state, donations, and withdrawals.
  • Multi-Wallet Support: Connect seamlessly with Freighter, Albedo, or xBull using StellarWalletsKit.
  • Real-Time Updates: UI reflects blockchain state instantly after every transaction.
  • Permissioned Withdrawals: Strict require_auth checks ensure only the owner can withdraw.
  • Robust Error Handling: Friendly toast notifications for network errors, user rejections, and connection states.

📸 Screenshots

Dashboard Wallet / Contract Interaction Owner Withdrawal
Dashboard Contract Sign Withdrawal

📂 Project Structure

CareFund/
├── smart-contract/          # 🦀 Rust Smart Contract (Soroban)
│   ├── src/lib.rs           # Core logic (create, donate, withdraw)
│   └── Cargo.toml           # Dependencies
├── frontend/                # ⚛️ Next.js + TypeScript DApp
│   ├── app/                 # Pages & Layouts (App Router)
│   ├── components/          # Reusable UI (Navbar, Modals)
│   └── contracts/           # Generated bindings for Type-Safe calls
└── assets/                  # 🖼️ Screenshot evidence

🛠️ Setup Instructions

1. Smart Contract (Rust)

cd smart-contract
cargo build --target wasm32-unknown-unknown --release
# Deploy to Testnet
soroban contract deploy --wasm target/wasm32-unknown-unknown/release/carefund.wasm --source-account alice --network testnet

2. Frontend (Next.js)

cd frontend
npm install

# Environment Variables (.env.local)
# NEXT_PUBLIC_CAREFUND_CONTRACT_ID=CCFEX...
# NEXT_PUBLIC_STELLAR_NETWORK=testnet

npm run dev

🏗️ Technology Stack

  • Frontend: Next.js 14, Tailwind CSS, TypeScript
  • Blockchain: Stellar Soroban (Rust)
  • Tools: soroban-cli, @stellar/stellar-sdk
  • UI: sonner (Toasts), Lucide Icons, Glassmorphism Design

Made with ❤️ for the Stellar Developer Challenge.

About

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors