This is a Next.js 14.2.2 template framework designed for VNOC and AgentDAO domains. It provides a complete web application structure with dynamic theming, API integration, and multi-domain support.
- Framework: Next.js 14.2.2 with App Router
- Styling: Tailwind CSS with custom prefix
tw- - State Management: Zustand
- UI Components: React Bootstrap + Custom Components
- Icons: FontAwesome + Lucide React
- Animations: Framer Motion + React TSParticles
{
"next": "14.2.2",
"react": "18.2.0",
"tailwindcss": "3.3.2",
"zustand": "^5.0.3",
"axios": "^1.4.0",
"framer-motion": "^12.0.6",
"lucide-react": "^0.474.0",
"react-tsparticles": "^2.12.2"
}app/
├── layout.jsx # Root layout with metadata generation
├── page.jsx # Homepage
├── about/page.jsx # About page
├── buy/ # Domain purchase flow
│ ├── layout.jsx
│ └── page.jsx
├── partner/ # Partnership flow
│ ├── layout.jsx
│ └── page.jsx
├── contact/page.jsx # Contact page
├── referral/page.jsx # Referral system
├── terms/page.jsx # Terms of service
├── privacy/page.jsx # Privacy policy
├── cookie/page.jsx # Cookie policy
├── developer/page.jsx # Developer resources
├── invest/page.jsx # Investment page
├── staffing/page.jsx # Staffing page
├── apps/page.jsx # Apps showcase
└── api/ # API routes
├── domain/route.js # Domain detection
├── adao-fetcher/route.js # ADAO API proxy
├── leads/route.js # Lead capture
├── buy/route.js # Purchase processing
└── partner/route.js # Partnership processing
components/
├── Header.jsx # Main navigation header
├── Footer.jsx # Site footer
├── Logo.jsx # Logo component
├── Navigation.jsx # Navigation menu
├── Hero/index.jsx # Hero section
├── Features/index.jsx # Features showcase
├── Revenue/index.jsx # Revenue section
├── Cta/index.jsx # Call-to-action
├── AgentSection.jsx # Featured agents display
├── TokenSalePopup.jsx # FOMO popup notifications
├── AnimatedBackground.jsx # Background animations
├── LoadingState.jsx # Loading indicators
├── ErrorBlock.jsx # Error handling
├── ScriptLoader.jsx # Script management
├── Buy/ # Purchase flow components
│ ├── Container.jsx
│ ├── Form.jsx
│ └── Thanku.jsx
├── Partner/ # Partnership components
│ ├── Container.jsx
│ ├── Form.jsx
│ ├── Step1.jsx
│ ├── Step2.jsx
│ ├── Step3.jsx
│ └── Thanku.jsx
└── ScriptWidget/ # Referral scripts
└── ReferralScript.jsx
lib/
├── data.jsx # Data fetching utilities
├── getEnvVar.js # Environment variable management
├── models/
│ └── routes.js # API route definitions
├── hooks/ # Custom React hooks
│ ├── useADAOFetcher.js # ADAO API integration
│ ├── userAgentFetcher.js # Agent data fetching
│ ├── useReferralFetcher.js # Referral system
│ └── useThemeFetcher.js # Theme management
└── store/ # Zustand stores
├── useAgentStore.js # Agent state management
├── useReferralStore.js # Referral state
└── useThemeStore.js # Theme state
- Dynamic domain detection via middleware
- Domain-specific theming and configuration
- Automatic www redirect (production only)
- Domain-based API calls
- Server-side theme fetching from API
- Client-side theme state management
- Dynamic logo and branding
- Customizable color schemes
- CONTRIB API: Domain configuration and data
- ADAO API: Agent and token data
- Lead Management: Email capture and processing
- Purchase Flow: Domain and token purchasing
- Featured agents display
- Token value calculations
- Purchase flow integration
- Real-time agent data
- Google Analytics integration
- Google AdSense support
- Matomo analytics
- Custom event tracking
- Dynamic meta tags per domain
- Open Graph support
- Twitter Card integration
- Sitemap generation
- Robots.txt handling
- Method: GET
- Purpose: Returns current domain
- Response:
{ domain: string }
- Methods: GET, POST, PUT, DELETE
- Purpose: Proxy for ADAO API calls
- Features: Error handling, timeout management
- Method: POST
- Purpose: Capture email leads
- Integration: CONTRIB forms API
- Method: POST
- Purpose: Process domain/token purchases
- Features: User validation, email notifications
- Method: POST
- Purpose: Handle partnership applications
- Features: Multi-step form processing
API_KEY=your_api_key
API_URL=your_api_url
API_KEY_ADAO=your_adao_api_key
API_URL_ADAO=your_adao_api_url
NEXT_PUBLIC_VERCEL_URL=your_domain
CONTRIB_API1=your_contrib_api_url- Custom prefix:
tw- - Content paths:
./pages/**/*,./components/**/*,./app/**/* - Custom color schemes
- Responsive design utilities
globals.css: Global styles and Tailwind importscustom.css: Custom component styles- Bootstrap integration for additional components
- useThemeStore: Theme and branding data
- useAgentStore: Agent listings and data
- useReferralStore: Referral system state
- useFetchTheme: Server-side theme fetching
- useADAOFetcher: ADAO API integration
- useFetchAgent: Agent data management
- useReferralFetcher: Referral system integration
- React Strict Mode enabled
- Custom headers for caching
- Image domain whitelist
- Environment variable exposure
- Automatic www redirect (production)
- Domain-based routing
- Request processing
- Static generation where possible
- Image optimization
- Caching strategies
- Code splitting
npm run dev # Development server
npm run build # Production build
npm run start # Production server
npm run lint # ESLint checkingnext.config.js: Next.js configurationtailwind.config.js: Tailwind CSS configurationmiddleware.ts: Request middlewarejsconfig.json: JavaScript configuration
- CONTRIB Network: Lead management and forms
- AgentDAO: Agent marketplace and tokens
- VNOC: Domain management and branding
- Google Services: Analytics and AdSense
- Matomo: Alternative analytics
- Domain configuration API
- Agent marketplace API
- Lead capture API
- Email notification system
- Payment processing (via CONTRIB)
- Environment variable validation
- API key management
- CORS handling
- Input validation
- Error boundary implementation
- Logo and branding via API
- Color schemes and themes
- Content and messaging
- Feature toggles
- Modular component structure
- Props-based configuration
- Theme-aware styling
- Responsive design patterns
This framework provides a complete foundation for building domain-specific applications within the AgentDAO ecosystem, with full integration capabilities and customizable theming.