Tribe

Crypto ETFs built by traders. Copy one in a tap and earn an NFT card that grows with your profit.

Tribe

Created At

ETHGlobal Mumbai

Project Description

Tribe is a social trading app where anyone can build their own version of a crypto ETF and anyone else can copy it in one tap. We say "ETF" because it's the easiest way to picture a ready-made mix of assets, but these aren't regulated ETFs. There's no fund, no shares and no fund manager. Each one is a public recipe of tokens and weights, and when you copy it you buy those tokens yourself and hold them in your own wallet.

A creator picks up to 10 tokens, sets a target weight for each, and adds a stop and a target. They publish the ETF by buying it themselves, so every ETF on Tribe has the creator's own money behind it. Each ETF shows its mix of major coins, tokenized US stocks, altcoins and meme coins, along with a Steady, Balanced or Aggressive risk band and a set of simple safety checks. Its track record starts at 100 and moves with its token prices.

When you copy an ETF, Tribe splits your amount across the tokens at the right weights and places one order per token through Flash, with your own limits applied. Nothing is pooled, and you can close the copy at any time. If a creator changes the weights, that makes a new version and sends every copier the exact buys and sells to approve. Nothing moves without your OK.

Every ETF also earns a collectible. Creating one earns an Original card and copying one earns a numbered Copy card, each minted as a transferable NFT on Base Sepolia, with Tribe paying the gas. Cards level up from Base to Glitter to Holo as the ETF performs and gains copiers, and they keep the highest tier they reach, so your best run stays on your card.

Around this sits a full social layer: public profiles, a live feed, leaderboards, squads, streaks, quests and shareable cards. These reward safe habits like using stops and researching before you copy. Creators earn a share of the fees when people copy their ETFs.

How it's Made

Tribe is one TypeScript codebase on Node 22, running Express with server-rendered views. Most screens are plain template functions that return HTML, so there's no frontend framework to ship to a phone. React appears only on the sign-in and wallet pages, because Privy needs it, and those are bundled with esbuild. The app is a PWA with a manifest and a service worker. Data lives in SQLite through Node's built-in node:sqlite module, so there's no native build step and no database server. It's deployed from a Dockerfile to Railway, with SQLite on a mounted volume.

Trading runs on Flash, and it's the core of the product. We built our own client for the full order flow: quote, setup transaction, EIP-712 signature, then order. An ETF copy runs the user's limits and the safety check once for the whole amount, then places one Flash order per token at its weight. Flash let us attach a take-profit and stop-loss to the entry as a single order, so protection is part of the trade rather than a second step. Its orders WebSocket delivers fills live, and Permit2 with minimal allowances means no wallet carries an unlimited approval. Creators earn a share of the integrator fee, read from Flash fills, so the app makes money from the first copy. If one token won't fill, the others still go through and the copy shows as partly filled, with options to retry or close it.

Privy provides embedded wallets. This matters because a 5-token copy through MetaMask would take about 10 to 20 signature prompts, which kills the one-tap experience. Tribe's key is added as a signer with a per-wallet policy, so copies can be signed automatically while users keep control of their own withdrawals.

The onchain side uses viem and Solidity, compiled with solc, on Base Sepolia. BasketCards.sol is an ERC-721 we wrote by hand, with no library. Tiers can only move up, and it emits ERC-4906 metadata events so marketplaces refresh a card when it upgrades. Card art is generated as SVG on the server and served alongside the JSON metadata. A second contract, CopyGuard.sol, stores trader risk verdicts, and Tribe reads it right before every copy. The app can only be stricter than the chain, so editing our database can't unblock a paused trader.

A few hacky parts worth mentioning:

Fonts inside the cards: an SVG shown through an img tag can't load outside fonts, so we cut three typefaces down to basic Latin and embedded them in each card as base64. Crash-safe minting: a background worker mints cards and pays the gas, and it reads the chain before every write. If it crashes between sending a transaction and saving it, the next pass repairs the record instead of minting twice. If the mint transaction hash is lost, the row is simply stored as "unknown". Token ids are database row ids: this is the simplest possible mapping, but it means every database needs its own contract, so local and hosted each have one. One shared minter wallet: only one worker sends at a time to avoid nonce fights. Local and hosted still share the wallet, so nonces can clash, and we let the worker retry. A demo director page: a /director page drives a seeded, simulated story for the video, using the same code paths as live trading.

background image mobile

Join the mailing list

Get the latest news and updates

Tribe | ETHGlobal