Skip to main content

Contributing / Local Setup

Early Stage Documentation

These docs are in an early stage. Content may change quickly and some details may be volatile or inaccurate. For questions or issues, contact the maintainer on Telegram: t.me/nickmura2.

This guide walks you through running dappTerminal locally for development or contribution.


Prerequisites

  • Node.js 20.0+ (or use nvm)
  • pnpm (recommended) or npm
  • PostgreSQL — required for the faucet and analytics tracking features
  • A browser wallet (MetaMask, Coinbase Wallet, or any RainbowKit-supported wallet)

Installation

# Clone the repository
git clone https://github.com/nickmura/dappterminal
cd dappterminal

# Install dependencies
pnpm install

Environment Setup

Copy the example environment file and fill in your values:

cp .env.example .env.local

Required Variables

VariableDescription
DATABASE_URLPostgreSQL connection string
ONEINCH_API_KEY1inch API key (get from 1inch dev portal)
VariableDescription
CLIENT_API_KEYSecret key for API route authentication
LIFI_API_KEYLiFi API key
NODE_ENVSet to production to enable API authentication

Faucet Variables (required for faucet feature)

VariableDescription
FAUCET_PRIVATE_KEYPrivate key for the faucet wallet (testnet only)
SEPOLIA_RPC_URLSepolia testnet RPC URL
BASE_SEPOLIA_RPC_URLBase Sepolia RPC URL

See Reference: Environment Variables for the complete list.


Database Setup

Run Prisma migrations to set up the database schema:

pnpm prisma migrate dev

If you're not using the faucet or analytics features, you can skip this step and run without a database.


Run the Development Server

pnpm dev

Open http://localhost:3000 in your browser.


Build for Production

pnpm build
pnpm start

Before deploying:

  • Set NODE_ENV=production
  • Set CLIENT_API_KEY to a secure random string
  • Set ONEINCH_API_KEY in the deployment environment
  • Update client code to include the x-api-key header on API calls
  • Run pnpm prisma migrate deploy against your production database

See Reference: Environment Variables for the full deployment checklist.