BCH BLAZEDeck ↗Code ↗
Build

Architecture

A Next.js app that runs in your browser and talks to the bridges, Cauldron and Electrum directly. One server route pays Base gas; there is no database.

Hashi's system map: swap screen, route engine and swap runner in the browser; the money path from your EVM or Solana wallet through NEAR Intents or THORChain to your Bitcoin Cash wallet, then Cauldron for PUSD or MUSD; Reown AppKit, the Hashi relayer, WizardConnect and Electrum servers beneath
Hashi in your browser, your dollars' path, and the services each step uses.

The parts

PartWhereWhat it does
Swap screenbrowserthe card, picker, routes, review, settings
Route enginebrowserasks NEAR Intents, THORChain and Cauldron for prices, adds the fees they leave out, ranks by what you keep
Swap runnerbrowserruns a swap one step at a time; each step saved in IndexedDB before the next (selling PUSD or MUSD, the sale and the send are saved together)
Wallet layerbrowserReown AppKit (EVM, Solana) and WizardConnect (Bitcoin Cash)
/api/relayserverpays Base gas for a gasless USDC deposit; nothing else
Landing numbersserverCauldron's indexer, NEAR's prices and THORChain's halts, rebuilt at most once a minute

The stack

PieceUsed for
Next.js 16, React 19the app, the landing page and the relayer route
Tailwind CSS 4, Base UIthe interface
TanStack Query 5quotes (fresh 10 s, refreshed 15 s, aborted when the request changes), prices, balances
viem, wagmi, Reown AppKitEVM transfers, allowances, THORChain deposits, EIP-3009 signatures
@solana/web3.js, @solana/spl-tokenSolana deposits
@wizardconnect/react, libauththe Bitcoin Cash wallet, addresses and transactions
@electrum-cash/networkBitcoin Cash coins, subscriptions and broadcasts
idb-keyvalswaps saved in the browser

Why the browser

Every provider Hashi uses answers browsers directly, so the money path has no Hashi server in it: quotes, deposits, trades and broadcasts go from your browser to NEAR Intents, THORChain, Cauldron, Electrum and your wallets. The only server code is the gas relayer and the landing page's numbers.

On this page