DocsRun the app locally

Docs/Developers

Run the app locally

Install the frontend, configure it and start the dev server.

Install#

Terminal
cd Frontend
npm install

Environment variables#

Copy the template, then fill in your keys:

Terminal
cp .env.example .env.local
.env.local
# Base Sepolia RPC, used for reads and by the relayer
NEXT_PUBLIC_BASE_RPC=https://sepolia.base.org

# Relayer (server only, never prefix with NEXT_PUBLIC_)
RELAYER_PRIVATE_KEY=0xYourRelayerKey
RELAYER_REIMBURSEMENT_WEI=50000000000000

# IPFS uploads through Pinata
NEXT_PUBLIC_PINATA_API_KEY=yourPinataKey
NEXT_PUBLIC_PINATA_SECRET_KEY=yourPinataSecret
NEXT_PUBLIC_IPFS_GATEWAY=https://gateway.pinata.cloud/ipfs

# Optional: only to use your own contracts
# NEXT_PUBLIC_SCARF_ADDRESS=0x…
# NEXT_PUBLIC_FORWARDER_ADDRESS=0x…
# NEXT_PUBLIC_PAYMASTER_ADDRESS=0x…
VariableRequiredNotes
NEXT_PUBLIC_BASE_RPCYesA Base Sepolia RPC URL.
RELAYER_PRIVATE_KEYYesThe relayer wallet. Needs a little ETH for gas. Server-only.
NEXT_PUBLIC_PINATA_API_KEY / _SECRET_KEYFor filesWithout them, text works but uploads fail.
RELAYER_REIMBURSEMENT_WEINoRefund per message. Defaults to 50000000000000 (0.00005 ETH).
NEXT_PUBLIC_*_ADDRESSNoOverride the deployed contract addresses.
NEXT_PUBLIC_RELAYER_API_URLNoUse an external relayer instead of /api/relay.
NEXT_PUBLIC_IPFS_GATEWAYNoDefaults to the Pinata gateway.

Start#

Terminal
npm run dev
# http://localhost:3000