A visual React demo showing how a MessageBox server acts as a store-and-forward system. Messages are sent through the server, temporarily stored, then delivered to recipients — illustrated by an animated mailman running between people and a post office.
- A running MetaNet Client (for wallet authentication)
- A local message-box-server running on
http://localhost:8080
npm install
npm run devOpen http://localhost:5174 in your browser.
- Connect — The app uses
@bsv/message-box-clientto authenticate with your local message-box-server viaWalletClient - Send — Type a message and watch the mailman pick it up and run to the post office (MessageBox server)
- Store — The message is temporarily held at the post office (store phase)
- Forward — The mailman delivers the message from the post office to the recipient
The visualization shows the complete lifecycle of a message through the store-and-forward system.
- React 18 + TypeScript + Vite
- @bsv/message-box-client — MessageBox client with WebSocket + HTTP support
- @bsv/sdk — BSV wallet authentication
- SVG animations — Mailman, post office, and participant avatars
- CSS animations — Running legs, floating letters, cloud drifts
Edit src/App.tsx to change:
const MESSAGE_BOX_HOST = 'http://localhost:8080' // Your server URL
const MESSAGE_BOX_NAME = 'demo_chat' // MessageBox name
const POLL_INTERVAL = 3000 // Polling interval (ms)