A multi-service DeFi platform built on the Stacks blockchain with 4 fee-generating smart contracts.
All contracts are deployed and verified on Stacks Mainnet:
| Contract | Address | Description |
|---|---|---|
| NFT Marketplace | SP3FKNEZ86RG5RT7SZ5FBRGH85FZNG94ZH1MCGG6N.stackhub-nft-marketplace |
Mint, list, buy NFTs (1.25% platform fee) |
| Token Launchpad | SP3FKNEZ86RG5RT7SZ5FBRGH85FZNG94ZH1MCGG6N.stackhub-token-launchpad |
Create custom tokens (5 STX fee) |
| Staking Vault | SP3FKNEZ86RG5RT7SZ5FBRGH85FZNG94ZH1MCGG6N.stackhub-staking-vault |
Stake STX (0.5% / 2.5% withdrawal fees) |
| Service Registry | SP3FKNEZ86RG5RT7SZ5FBRGH85FZNG94ZH1MCGG6N.stackhub-service-registry |
Register services (2.5 STX + 1.5% tx fee) |
stackhub/
├── stackhub-contracts/ # Clarity smart contracts
│ ├── contracts/ # Contract source files
│ └── tests/ # Vitest unit tests
├── frontend/ # Next.js web application
│ ├── src/
│ │ ├── app/ # App router pages
│ │ ├── components/ # React components
│ │ └── config/ # Contract configurations
│ └── public/ # Static assets
└── README.md
- Mint NFTs with custom metadata URI
- List NFTs for sale at any price
- Buy NFTs with automatic fee distribution
- Platform fee: 1.25% on all sales
- Create custom tokens with name, symbol, decimals
- Mint additional tokens (owner only)
- Transfer & burn tokens
- Creation fee: 5 STX
- Stake STX to earn rewards
- Request unstake after lock period
- Normal withdrawal fee: 0.5%
- Early withdrawal fee: 2.5%
- Register services with description and price
- Pay for services through the platform
- Listing fee: 2.5 STX
- Transaction fee: 1.5%
cd stackhub-contracts
npm install
npm testAll 28 tests should pass.
cd frontend
npm install
npm run devOpen http://localhost:3000 to view the app.
- Smart Contracts: Clarity (version 4)
- Testing: Clarinet SDK + Vitest
- Frontend: Next.js 16 + React 19
- Stacks Wallet: @stacks/connect (Leather/Hiro Wallet)
- EVM Wallet: Reown AppKit + Wagmi (MetaMask, WalletConnect, etc.)
- Networks: Stacks Mainnet + EVM chains (Ethereum, Arbitrum, Optimism, Polygon, Base)
StackHub supports multiple wallet types:
- Leather Wallet
- Hiro Wallet
- Xverse
- MetaMask
- WalletConnect
- Coinbase Wallet
- Social logins (Google, Discord, etc.)
To enable EVM wallet support, get a project ID from Reown Cloud and add it to your .env.local:
NEXT_PUBLIC_REOWN_PROJECT_ID=your_project_id_hereMIT