Nexfluence is a comprehensive Web3 platform that connects brands with influencers through smart contracts, AI-powered matching, and a dual-token economy (USDC + NEX) on the Polygon network.
- USDC Payments: All campaign payments processed in USDC for stability and transparency
- NEX Utility Token: Platform governance, staking, and tier-based benefits
- Staking System: Five-tier staking with lock periods and reward multipliers
- Fee Discounts: Platform fee reductions based on NEX staking tier
- Enhanced Escrow: Milestone-based payments with automated releases
- NEX Token: ERC20 with vesting, minting controls, and transfer restrictions
- Staking Contract: Tier-based staking with yield farming and governance power
- Dynamic Fees: Platform fees adjusted based on user's staking tier
- Intelligent Matching: Advanced algorithms match brands with perfect influencers
- Content Analysis: NLP-powered content analysis and sentiment detection
- Fraud Detection: AI-based fraud detection and risk assessment
- Performance Optimization: Data-driven recommendations for campaign success
- IPFS Integration: Campaign data and content stored on IPFS
- Metadata Management: Structured metadata for profiles and campaigns
- Content Verification: Immutable content storage and verification
Nexfluence is built as a Next.js monolith application with the following components:
- Frontend: Next.js 13+ with App Router and React 18
- Database: PostgreSQL for all data storage
- ORM: Prisma for type-safe database access
- Authentication: JWT-based auth with wallet signatures
- Blockchain Integration: Ethers.js for Web3 connectivity
- AI/ML: Natural language processing for content analysis and matching
- Storage: IPFS via Pinata for decentralized storage
- Deployment: Docker for containerization, AWS Lightsail for hosting
- Node.js 18+ and npm
- PostgreSQL database
- MetaMask wallet
- Git
-
Clone the repository
git clone https://github.com/your-org/nexfluence.git cd nexfluence -
Install dependencies
npm install
-
Environment Setup Create a
.env.localfile:# Database DATABASE_URL="postgresql://postgres:postgres@localhost:5432/nexfluence?schema=public" # Authentication NEXTAUTH_URL="http://localhost:3000" NEXTAUTH_SECRET="your-nextauth-secret" JWT_SECRET="your-jwt-secret" # Blockchain Configuration NEXT_PUBLIC_NETWORK="amoy" NEXT_PUBLIC_INFLUENCER_NEXUS_ADDRESS="0x..." NEXT_PUBLIC_USDC_ADDRESS="0x2791Bca1f2de4661ED88A30C99A7a9449Aa84174" NEXT_PUBLIC_NEX_TOKEN_ADDRESS="0x..." NEXT_PUBLIC_STAKING_ADDRESS="0x..." NEXT_PUBLIC_ESCROW_V2_ADDRESS="0x..." PRIVATE_KEY="your-private-key" INFURA_PROJECT_ID="your-infura-project-id" POLYGONSCAN_API_KEY="your-polygonscan-api-key" # IPFS Configuration PINATA_API_KEY="your-pinata-api-key" PINATA_API_SECRET="your-pinata-api-secret" PINATA_JWT="your-pinata-jwt" PINATA_GATEWAY_URL="https://gateway.pinata.cloud"
-
Database Setup
# Create database schema npx prisma migrate dev # Seed the database with initial data npx prisma db seed
-
Start Development Server
npm run dev
-
Build for Production
npm run build npm start
# Start PostgreSQL database only
docker-compose -f docker-compose.dev.yml up -d
# Run the app locally
npm run dev# Build and start all services
docker-compose up -d --build
# View logs
docker-compose logs -f| Tier | Min Stake | Lock Period | Reward Multiplier | Fee Discount | Max Campaigns |
|---|---|---|---|---|---|
| Bronze | 1,000 NEX | 30 days | 100% (5% APY) | 5% | 5 |
| Silver | 5,000 NEX | 60 days | 120% (6% APY) | 10% | 15 |
| Gold | 25,000 NEX | 90 days | 150% (7.5% APY) | 15% | 50 |
| Platinum | 100,000 NEX | 180 days | 200% (10% APY) | 20% | 200 |
| Diamond | 500,000 NEX | 365 days | 300% (15% APY) | 25% | 1,000 |
# Run all tests
npm test
# Run specific test suite
npm test -- -t "authentication"POST /api/auth/wallet
Body: { walletAddress, signature, message }
GET /api/campaigns
Query: { category, minBudget, maxBudget, minFollowers, location }
GET /api/campaigns/:id
POST /api/campaigns
Body: { title, description, category, totalBudget, ... }
POST /api/campaigns/:id/apply
Body: { proposedContent, proposedTimeline, customMessage }
GET /api/users/me
PUT /api/users/profile
Body: { name, bio, location, ... }
- β Monolith application architecture
- β Smart contract integration
- β AI-powered matching algorithm
- β IPFS content storage
- β Basic analytics dashboard
- π Mobile application
- π Enhanced analytics
- π Multi-chain support
- π Advanced AI features
- π DAO governance implementation
- π NFT integration for achievements
- π Advanced dispute resolution
- π Enterprise features
- π Institutional staking pools
We welcome contributions! Please see our Contributing Guide for details.
This project is licensed under the MIT License - see the LICENSE file for details.
- OpenZeppelin: Smart contract security standards and implementations
- Polygon: Layer 2 scaling solution for fast, low-cost transactions
- IPFS/Pinata: Decentralized storage protocol
- Next.js: React framework for production applications
- Prisma: Type-safe database client
- shadcn/ui: Beautiful and accessible component library
- Documentation: docs.nexfluence.tech
- Discord: Join our community
- Twitter: @Nexfluence
- Email: support@nexfluence.tech
Built with β€οΈ for the creator economy. Powered by Web3 technology and enhanced with dual-token economics.