Official CA:GHKLMnGRwRA3QMjpHEDrYprdTRdaXsAZ3xwHEw3zpump

Documentation

Open source. Fork it. Build on it. Make it yours.

Overview

One Launch is an open-source Solana token launchpad with a pirate/ocean adventure theme. Users can recruit one of 50 pirate slots and launch a token on Pump.fun — all from the browser. Built with Next.js 16, React 19, Prisma, PostgreSQL, and Solana wallet adapters. Fully open source and community-driven.

Tech Stack

FrameworkNext.js 16 (App Router, Turbopack)
FrontendReact 19, Tailwind CSS 4, Framer Motion
DatabasePostgreSQL via Prisma ORM
BlockchainSolana (web3.js, Wallet Adapter)
Token LaunchPump.fun + PumpPortal API
Image StoragePump.fun IPFS + Pinata (optional)
Image ProcessingSharp (WebP, 512x512)
ValidationZod schemas
FontsOutfit, DM Sans, JetBrains Mono

Project Structure

onelaunch/
├── app/                    # Next.js pages & API routes
│   ├── api/
│   │   ├── build-create-tx/   # Build unsigned token creation tx
│   │   ├── confirm-claim/     # Record recruitment in database
│   │   ├── slots/             # Get all pirate slots
│   │   └── token/[address]/   # Token stats & trades
│   ├── create/             # Token creation form
│   ├── docs/               # This page
│   └── token/[address]/    # Individual token detail
├── components/
│   ├── creatures/          # Pirate cards, grids, forms
│   ├── layout/             # Header
│   ├── providers/          # Solana wallet provider
│   └── ui/                 # Button, Badge, Card, Input, etc.
├── lib/
│   ├── db.ts               # Prisma client singleton
│   ├── ipfs/upload.ts      # Pinata IPFS upload
│   ├── pumpfun/adapter.ts  # Pump.fun API integration
│   └── utils/              # Formatting, validation, sanitization
├── prisma/
│   ├── schema.prisma       # Database models
│   └── seed.ts             # Seed 50 pirate slots
├── public/creatures/       # 50 pirate PNG avatars
└── scripts/
    └── reset-slots.ts      # Wipe all launches (clean slate)

Environment Variables

DATABASE_URLPostgreSQL connection string (required)
NEXT_PUBLIC_RPC_URLSolana RPC endpoint (defaults to mainnet-beta)
PINATA_JWTPinata API token for IPFS backup (optional — uses placeholder in dev)

Getting Started

# Clone the repo
git clone https://github.com/onelaunch/onelaunch.git
cd onelaunch

# Install dependencies
npm install

# Set up environment
cp .env.example .env
# Edit .env with your DATABASE_URL

# Push database schema & seed pirate slots
npx prisma db push
npm run db:seed

# Start development server
npm run dev

Database Models

CreatureSlot          # 50 slots (id 1-50)
├── id                # Slot number
├── name              # Pirate name (e.g. "Monkey D. Luffy")
├── ticker            # Default ticker (e.g. "MONKEYDLU")
├── claimed           # Whether slot is recruited
├── claimedAt         # Timestamp of recruitment
└── tokenProfile →    # One-to-one relation

TokenProfile          # Created when a slot is recruited
├── name, symbol      # Token metadata
├── description       # Token description
├── artworkUrl        # Image URL (from Pump.fun IPFS)
├── tokenAddress      # Solana mint address
├── pumpUrl           # Pump.fun trading link
├── creatorWallet     # Creator's wallet address
├── stats →           # One-to-one StatsSnapshot
└── trades →          # One-to-many Trade records

StatsSnapshot         # Cached token stats (refreshed every 30s)
├── price, marketCap
├── volume24h
└── progressPct       # Bonding curve progress

Trade                 # Individual trade records
├── txSig, side       # Transaction signature, buy/sell
├── amount, price     # SOL amount, token price
└── timestamp         # Indexed for fast queries

Available Scripts

npm run devStart development server
npm run buildBuild for production
npm run startRun production build
npm run db:generateGenerate Prisma client
npm run db:pushPush schema to database
npm run db:seedSeed 50 pirate slots
npm run db:resetWipe all launches (clean slate)
npm run db:studioOpen Prisma Studio GUI

Token Creation Flow

1. User selects a pirate slot and clicks "Set Sail" 2. Fills in name, symbol, description, and uploads artwork 3. Client generates a mint keypair for the new token 4. Server processes the image (WebP 512x512), uploads metadata to Pump.fun IPFS 5. Server builds an unsigned transaction via PumpPortal API 6. Client signs with both the mint keypair and user's wallet 7. Transaction is sent to Solana and confirmed 8. Server records the recruitment in the database with token profile and initial stats 9. Stats auto-refresh every 30 seconds from the Pump.fun frontend API 10. Slots have an 11-minute lock window — after that, they can be re-recruited

One Launch is open source under the MIT license.

Star on GitHub