Solana accounts are not free. They cost "Rent" (storage fees). When you abandon an account, that SOL is locked forever.
Think of it like Tupperware.
When you open a Solana account, you're essentially buying a container to hold your data. You pay a deposit (rent) to reserve that space. When the data inside is no longer needed the account goes idle you should return the container and get your deposit back.
Most people forget. The containers pile up. The SOL stays locked.
Flux returns the containers.
Kora is a transaction sponsorship service for Solana. It lets apps pay transaction fees and account creation costs on behalf of their users.
When a user needs to create a new account (like a token account), the app can ask Kora to pay the costs:
- User initiates action (e.g., receive a token for the first time)
- Kora operator pays the rent (SOL locked as a storage deposit)
- Account is created (user can now receive tokens)
- User never pays a fee (better UX, app covers the cost)
Every time Kora sponsors an account creation, SOL gets locked:
| Account Type | Typical Rent | Purpose |
|---|---|---|
| Token Account | ~0.002 SOL | Holds user tokens |
| Associated Token Account | ~0.002 SOL | Standard token wallet |
| Custom Program Account | Varies | App specific data |
Over time, operators sponsor thousands of accounts. Many become inactive. The SOL stays locked.
- Users abandon accounts after transferring tokens out
- Apps shut down but accounts remain open
- Nobody is tracking which accounts are still needed
- Operators lose capital to "rent leak" without realizing it
Flux monitors all accounts sponsored by a Kora operator and:
- Scans for inactive sponsored accounts
- Judges each account (is it safe to close?)
- Reclaims the rent when safe, returning SOL to the operator
Flux is a dashboard that monitors and reclaims rent from idle Kora-sponsored accounts. It consists of three modules:
| Module | What It Does |
|---|---|
| Scanner | Finds all accounts sponsored by your operator wallet. Identifies which ones are idle and eligible for reclamation. |
| Judge | Checks safety rules before any action. Makes sure we never close an account that still has active data. |
| Executioner | Actually closes the accounts and returns the rent to the operator. Only runs after the Judge approves. |
This table shows how Flux meets the hackathon requirements.
| Requirement | Status | How We Handle It |
|---|---|---|
| Never close accounts with active data | Done | judge.ts checks lamports = 0 and data is empty before approval |
| Simulation mode for safe testing | Done | Toggle in settings enables "dry run" - logs what would happen without doing it |
| Clear logging of all actions | Done | Every scan, judgment, and reclaim is stored in the database with timestamps |
| Requirement | Status | How We Handle It |
|---|---|---|
| Works without wallet setup | Done | Mock Mode loads demo data automatically |
| One-command startup | Done | npm run dev handles database setup and starts the app |
| Clean, readable interface | Done | Dark mode dashboard shows stats, accounts, and activity logs |
| Requirement | Status | How We Handle It |
|---|---|---|
| Devnet compatible | Done | Default RPC is Solana Devnet |
| Mainnet ready | Done | Just change SOLANA_RPC_URL in .env to go live |
| Persistent storage | Done | SQLite via Prisma stores all accounts and logs locally |
git clone <repo-url>
cd flux
npm run devNote: This command handles the full setup for you. It installs the tools, creates the database, and loads demo data so you can start testing immediately.
Open http://localhost:3000 to see the dashboard.
Don't have a wallet? No problem.
If you don't set the OPERATOR_PRIVATE_KEY environment variable, the app launches in Mock Mode. This means:
- The dashboard loads with demo data
- All buttons and features work
- You can see exactly how the UI behaves
- No real Solana transactions happen
This is perfect for judges who want to test the interface without setting up wallets or connecting to Solana.
Security Warning: Only use a burner wallet with no real funds. Never use your main wallet's private key.
The most secure approach would be an encrypted keystore protected by a password. We didn't use this because automation requires zero friction. If the key were locked behind a password, the bot would get stuck waiting for human input every time it tried to run a scan, which defeats the purpose of an "automated" tool.
For a hackathon demo, a burner wallet is the safest approach.
Step 1: Create a Burner Wallet
- Use Phantom, Solflare, or any Solana wallet to create a new wallet
- Export the private key (keep it secret, never share it)
- Copy the wallet address (this is your public key)
Step 2: Configure the Environment
- Open the
.envfile in the project root - Add your keys in this exact format:
OPERATOR_PUBLIC_KEY="YourWalletAddressHere"
OPERATOR_PRIVATE_KEY="YourPrivateKeyHere"- Save the file
Step 3: Restart the Server
- Stop the running server by pressing
Ctrl + Cin the terminal - Start it again:
npm run devStep 4: Open the Dashboard
- Go to http://localhost:3000
- By default, you will see 14 simulated demo accounts
Step 5: Switch to Live Mode
- Toggle "Simulation Mode" OFF (switch turns amber/warning color)
- Click "Scan Now"
- The dashboard will scan your real wallet on Solana Devnet
Step 6: Interpret the Results
- New or empty wallet? Expect 0 accounts. This means the connection is working, there is just nothing to find yet.
- Wallet with history? You will see any accounts your wallet has sponsored.
Step 7: Switch Back to Simulation
- Toggle "Simulation Mode" back ON
- Click "Scan Now" again
- The 14 demo accounts will be restored automatically
| Network | RPC URL | When to Use |
|---|---|---|
| Devnet | https://api.devnet.solana.com |
Testing with fake SOL |
| Mainnet | https://api.mainnet-beta.solana.com |
Production (real money) |
| Custom | Your Helius/QuickNode URL | Better rate limits |
- Frontend: Next.js 16, React 19, TypeScript, Tailwind CSS
- Backend: Next.js API Routes
- Database: SQLite + Prisma ORM
- Blockchain: Solana Web3.js
MIT
