Skip to content

Tigersame/farcaster-nft-marketplace

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 

History

133 Commits
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

๐Ÿ–ผ๏ธ FarcastMints - NFT Marketplace

Farcaster Base Next.js TypeScript TailwindCSS License

A complete NFT marketplace built for the Farcaster ecosystem with MiniKit integration and Base network optimization

๐Ÿš€ Live Demo โ€ข ๐Ÿ“– Documentation โ€ข ๐ŸŽฏ Features โ€ข ๐Ÿ› ๏ธ Setup

๐ŸŽฏ Features

๐Ÿ–ผ๏ธ Farcaster Native Experience

  • Interactive Frames - Share NFTs directly in Farcaster feeds with purchase buttons
  • MiniKit Integration - Seamless wallet connection and social authentication
  • Frame Discovery - Browse and test all available NFT frames
  • Viral Sharing - One-click sharing to Warpcast and Farcaster clients

๐ŸŒ™ Modern UI/UX

  • Dark Mode System - Complete light/dark theme with persistence
  • Responsive Design - Perfect experience on mobile and desktop
  • Smooth Animations - 60fps transitions with Framer Motion
  • Real-time Updates - Live marketplace activity and user counters

โšก Base Network Optimized

  • Gasless Transactions - FREE gas fees sponsored by Base Paymaster (NEW!)
  • Smart Accounts - ERC-4337 Account Abstraction for seamless UX
  • Low Fees - Leveraging Base L2 for affordable transactions
  • Fast Confirmations - Quick NFT purchases and listings
  • Wallet Integration - RainbowKit with Base network support
  • Chain Validation - Automatic Base network detection and switching

๐ŸŽฎ Advanced Engagement

  • Social Proof - Live user counters and trending items
  • Activity Feed - Real-time marketplace transactions and interactions
  • XMTP Chat - Base App Quick Actions integration
  • Progress Tracking - User engagement and achievement system

๐Ÿš€ Quick Start

Prerequisites

  • Node.js 18+ and npm
  • Git for version control
  • A Farcaster account for testing frames

Installation

# Clone the repository
git clone https://github.com/YOUR_USERNAME/farcaster-nft-marketplace.git
cd farcaster-nft-marketplace

# Install dependencies
npm install

# Set up environment variables
cp .env.example .env.local
# Edit .env.local with your configuration

# Start development server
npm run dev

Visit http://localhost:3000 to see the marketplace in action!

Environment Setup

Create a .env.local file with the following variables:

NEXT_PUBLIC_BASE_RPC_URL=https://mainnet.base.org
NEXT_PUBLIC_FARCASTER_HUB_URL=https://nemes.farcaster.xyz:2283
MINIKIT_APP_ID=your-minikit-app-id
NEXT_PUBLIC_WALLETCONNECT_PROJECT_ID=your-project-id

๐Ÿ—๏ธ Tech Stack

Frontend

Web3 Integration

Farcaster Ecosystem

๐Ÿ“ Project Structure

src/
โ”œโ”€โ”€ app/
โ”‚   โ”œโ”€โ”€ page.tsx                 # Main application entry
โ”‚   โ”œโ”€โ”€ marketplace.tsx          # Core marketplace component  
โ”‚   โ”œโ”€โ”€ providers.tsx            # Web3 and context providers
โ”‚   โ”œโ”€โ”€ globals.css              # Global styles + dark mode
โ”‚   โ””โ”€โ”€ api/
โ”‚       โ”œโ”€โ”€ frames/              # Farcaster Frame endpoints
โ”‚       โ””โ”€โ”€ test-frame/          # Frame testing utilities
โ”œโ”€โ”€ components/
โ”‚   โ”œโ”€โ”€ Header.tsx              # Navigation with dark mode
โ”‚   โ”œโ”€โ”€ NFTCard.tsx             # Enhanced NFT display cards
โ”‚   โ”œโ”€โ”€ DarkModeToggle.tsx      # Theme switching components
โ”‚   โ”œโ”€โ”€ FrameShare.tsx          # Frame sharing modal
โ”‚   โ”œโ”€โ”€ SocialProof.tsx         # Activity feed & social widgets
โ”‚   โ”œโ”€โ”€ GaslessUI.tsx           # Gasless transaction UI components
โ”‚   โ””โ”€โ”€ ...                     # Additional UI components
โ”œโ”€โ”€ contexts/
โ”‚   โ””โ”€โ”€ ThemeContext.tsx        # Dark mode state management
โ”œโ”€โ”€ hooks/
โ”‚   โ””โ”€โ”€ useSmartAccount.ts      # Smart Account & gasless transactions
โ””โ”€โ”€ lib/
    โ”œโ”€โ”€ wagmi.ts                # Web3 configuration
    โ””โ”€โ”€ paymaster.ts            # Base Paymaster configuration

โœจ Gasless Transactions (NEW!)

Zero gas fees for your users! All transaction costs are sponsored by Base Paymaster.

Quick Setup (5 minutes)

  1. Get Paymaster RPC URL

  2. Add to Environment

    # .env.local
    NEXT_PUBLIC_PAYMASTER_RPC_URL=https://api.developer.coinbase.com/rpc/v1/base/YOUR_KEY
  3. Configure Allowlist

    • Add your NFT contract address in CDP
    • Allowlist functions: mintTo, buy, list
  4. Set Spending Limits

    • Per-user: $0.05/month, 1 operation
    • Global: $15,000/month (or your budget)
  5. Done! ๐ŸŽ‰ Users can now mint, buy, and list NFTs completely free.

๐Ÿ“– Full Guide: GASLESS_QUICKSTART.md
๐Ÿ“š Documentation: GASLESS_TRANSACTIONS.md
๐Ÿ“ Implementation: GASLESS_IMPLEMENTATION_SUMMARY.md

๐ŸŒ API Endpoints

Farcaster Frames

  • GET /api/frames - Frame discovery page
  • GET /api/frames/nft/[tokenId] - Interactive NFT frame
  • GET /api/frames/nft/[tokenId]/image - Dynamic frame image
  • GET /api/test-frame - Frame testing endpoint

Features Available

  • Browse NFTs - Complete marketplace interface
  • Dark Mode - Toggle in header (moon/sun icon)
  • Frame Sharing - Click "Share Frame" on NFT cards
  • Live Activity - Real-time marketplace updates
  • Wallet Connect - RainbowKit integration

๐ŸŽจ Screenshots

Light Mode

Light Mode Screenshot

Dark Mode

Dark Mode Screenshot

Farcaster Frame

Frame Screenshot

๐Ÿงช Testing Frames

Local Testing

# Start the development server
npm run dev

# Test frame endpoints
curl http://localhost:3000/api/frames/nft/1
curl http://localhost:3000/api/frames/nft/1/image

Farcaster Integration

  1. Share frame URL in a Farcaster cast
  2. View in Warpcast or other Farcaster clients
  3. Test interactive buttons and purchasing flow

๐Ÿš€ Deployment

Vercel (Recommended)

# Install Vercel CLI
npm i -g vercel

# Deploy
vercel

# Configure environment variables in Vercel dashboard
# Set up custom domain and SSL

Manual Deployment

# Build for production
npm run build

# Start production server  
npm start

See DEPLOYMENT_CHECKLIST.md for complete deployment guide.

๐Ÿ“– Documentation

๐Ÿค Contributing

We welcome contributions! Please see our Contributing Guide for details.

Development Workflow

  1. Fork the repository
  2. Create a feature branch: git checkout -b feature/amazing-feature
  3. Commit changes: git commit -m 'Add amazing feature'
  4. Push to branch: git push origin feature/amazing-feature
  5. Open a Pull Request

Code Standards

  • TypeScript for type safety
  • ESLint + Prettier for code formatting
  • Conventional commits for commit messages
  • Component documentation with JSDoc

๐Ÿ› Issues & Support

๐ŸŽฏ Roadmap

โœ… Completed (v1.0)

  • Complete marketplace interface with dark mode
  • Farcaster Frame integration with sharing
  • Real-time activity feed with emoji avatars
  • Base network integration with wallet support
  • XMTP chat and Base App Quick Actions

๐Ÿšง In Progress (v1.1)

  • NFT creation and minting flow
  • Smart contract integration for real transactions
  • User authentication with Farcaster profiles
  • WebSocket real-time updates

๐Ÿ”ฎ Future (v2.0)

  • Multi-chain support (Ethereum, Polygon)
  • Advanced filtering and search
  • Auction and bidding system
  • Creator royalties and revenue sharing
  • Mobile app with MiniKit

๐Ÿ“„ License

This project is licensed under the MIT License - see the LICENSE file for details.

๐Ÿ™ Acknowledgments

  • Farcaster for the decentralized social protocol
  • Base for the fast, low-cost L2 network
  • Coinbase for MiniKit and developer tools
  • Vercel for excellent Next.js hosting
  • Community contributors and testers

๐ŸŒŸ Star History

Star History Chart


Built with โค๏ธ for the Farcaster and Base ecosystem

๐Ÿฆ Follow Updates โ€ข ๐ŸŒ Website โ€ข ๐Ÿ“ง Contact

About

Complete NFT marketplace built for Farcaster ecosystem with MiniKit integration, Base network optimization, dark mode, and real-time features

Topics

Resources

License

Contributing

Security policy

Stars

Watchers

Forks

Packages

 
 
 

Contributors