Skip to content

Yumstezy/hackatonsplit

Repository files navigation

Split 🔒

Private group expense splitting on Solana — powered by MagicBlock's Private Ephemeral Rollup

"Splitwise has 50M users and zero privacy. Split fixes that."

Live Demo Program Hackathon Demo Video: Watch here


The Problem

Every bill-splitting app — Splitwise, Venmo, PayPal — makes your amounts visible to everyone. On a public blockchain it's even worse: every expense is permanently on-chain for anyone to read.

You paid for the most expensive hotel room? Everyone knows. Splitting costs with a business partner? Your numbers are public forever.

Split fixes this. Expense amounts are processed inside a hardware-secured Intel TDX enclave via MagicBlock's Private Ephemeral Rollup. Nobody — not even the node operator — can read them. Only the final "who pays whom" settlement ever reaches Solana L1.


How It Works

1. Alice creates a group → on Solana L1 (public: member list, group name)

2. Members add expenses via the TEE RPC endpoint:
     Alice: Hotel $150 — split 3 ways   ← shielded in TEE, never on-chain
     Bob:   Tapas $60  — split 2 ways   ← shielded in TEE, never on-chain
     Carol: Museum $30 — split 3 ways   ← shielded in TEE, never on-chain

3. Alice triggers settlement → on-chain program computes:
     a) Net balances per member
     b) Minimum transfer graph (fewest transactions to settle all debts)

4. Only the transfer graph reaches Solana L1:
     Bob → Alice  $50 USDC
     Carol → Alice $60 USDC

5. Each person clicks Pay Now → USDC transfer executes on L1

Individual expense amounts never appear on-chain. Ever.


MagicBlock Primitives Used

Primitive How Split Uses It
Private Ephemeral Rollup (TEE) Expense amounts submitted to tee.magicblock.app — shielded inside Intel TDX. Settlement math runs in the enclave.
Ephemeral Rollup Real-time expense submission. Zero fee per expense.
Session Keys Per-member auth to the PER. Only group members can read/write.
Commit Accounts Settlement result committed from TEE back to Solana L1.

What's Private vs Public

Data Visibility
Group name & member list 🌐 Public (Solana L1)
Expense descriptions 🌐 Public (off-chain metadata)
Expense amounts 🔒 Private — TEE only, never on-chain
Final settlement transfers 🌐 Public (L1 after settlement)

Even Split's own database never sees individual expense amounts. The privacy guarantee is hardware-enforced, not just a policy.


Live Demo

App: https://hackatonsplit.vercel.app

Deployed Program: FNm3MQiJMqdr1dBMtBLKHZ1Bn7AsjkoPd5g6eQo798Lz on Solana devnet

View on Solana Explorer →

To test:

  1. Install Phantom wallet and switch to Devnet
  2. Get free devnet SOL at https://faucet.solana.com
  3. Go to https://hackatonsplit.vercel.app
  4. Connect wallet → Create Group → Add expenses → Settle Up

Smart Contract

4 on-chain instructions deployed at FNm3MQiJMqdr1dBMtBLKHZ1Bn7AsjkoPd5g6eQo798Lz:

// 1. Create group on Solana L1
pub fn create_group(group_id, name, members) -> Result<()>

// 2. Submit expense — routed via MagicBlock TEE RPC
//    Amount stays inside Intel TDX enclave
pub fn submit_expense(description, amount_lamports, paid_by, split_among) -> Result<()>

// 3. Settle — computes net balances + minimum transfer graph on-chain
pub fn settle_group() -> Result<()>

// 4. Execute a settlement transfer on L1 (USDC SPL token)
pub fn execute_transfer(transfer_index) -> Result<()>

Full source: program/lib.rs


Tech Stack

  • Solana — base settlement layer
  • MagicBlock Private Ephemeral Rollup — TEE privacy for expense amounts
  • Anchor 0.30.1 — smart contract framework
  • React + Vite + TypeScript — frontend
  • @solana/wallet-adapter — Phantom/Solflare wallet integration
  • Tailwind CSS + shadcn/ui — UI
  • Vercel — deployment

Local Development

# Frontend
git clone https://github.com/Yumstezy/hackatonsplit
cd hackatonsplit
npm install
npm run dev

# Smart contract (requires Anchor CLI + Solana CLI)
cd program
anchor build
anchor deploy --provider.cluster devnet

Why This Wins

The gap nobody filled: every existing Solana privacy project is DeFi — dark pools, private swaps. Nobody applied TEE-backed privacy to the everyday human problem of splitting bills with friends.

The insight: privacy here isn't a technical feature — it's about human awkwardness around money. Split makes on-chain privacy feel natural and useful to non-crypto users.

The market: Splitwise has 50 million users. A privacy-first, stablecoin-native version with zero gas per expense and hardware-enforced privacy is a real product.


Built solo for MagicBlock Solana Blitz V2 · March 2026

Split — because your bills shouldn't be everyone's business.

About

Private group expense splitting on Solana. Amounts shielded in MagicBlock's TEE — only settlements hit the chain.

Topics

Resources

Stars

Watchers

Forks

Packages

 
 
 

Contributors

Languages