A distraction-free writing platform with blockchain-powered copyright protection, built with Next.js and deployed on Polygon.
- Email/password authentication with OTP verification
- Google OAuth integration
- Role-based access (Reader/Writer)
- Secure session management with NextAuth
- Rich text editor with formatting toolbar
- Auto-save functionality with local storage
- Tags system for content discovery
- Article search and filtering
- Real-time preview mode
- Clean, distraction-free writing interface
- Explore page with article listings
- Tag-based filtering and search
- Article analytics and engagement metrics
- Comment system for reader interaction
- Writer analytics: views, engagement rates
- Reader dashboard: reading stats
- Performance metrics and trends
- Content statistics
- Real blockchain registration on Polygon Amoy testnet
- Immutable copyright proof with content hashing (SHA-256)
- Public verification via Polygonscan
- Plagiarism detection before registration
- MetaMask wallet integration
- Permanent ownership records accessible worldwide
- Select any article for blockchain protection
- Generate unique content hashes
- Pay minimal gas fees (0.001 MATIC)
- Get permanent, tamper-proof ownership proof
- Verify copyright status online anytime
- Next.js 13.5.1 - React framework with App Router
- TypeScript - Type safety
- Tailwind CSS - Styling
- Shadcn/ui - UI components
- NextAuth.js - Authentication
- MongoDB - Database with Mongoose ODM
- Node.js - Runtime environment
- Vercel - Deployment platform
- Polygon Amoy Testnet - Layer 2 blockchain
- Ethers.js v6 - Blockchain interaction
- Hardhat - Smart contract development
- Solidity 0.8.20 - Smart contract language
- MetaMask - Wallet integration
- CopyrightProtection.sol - Content registration and verification
- Deployed on Polygon Amoy:
0xeAeE2316D793068c34EbC322e1F8a98dCBAF9f69
- Node.js 18+ and pnpm
- MongoDB database
- MetaMask wallet (for blockchain features)
- Polygon Amoy testnet MATIC tokens
# Database
MONGODB_URI=your_mongodb_connection_string
# Authentication
NEXTAUTH_URL=http://localhost:3000
NEXTAUTH_SECRET=your_secret_key
GOOGLE_CLIENT_ID=your_google_client_id
GOOGLE_CLIENT_SECRET=your_google_client_secret
# Email (Optional)
RESEND_API_KEY=your_resend_api_key
# Blockchain
NEXT_PUBLIC_COPYRIGHT_PROTECTION_ADDRESS=0xeAeE2316D793068c34EbC322e1F8a98dCBAF9f69
POLYGON_AMOY_RPC=https://rpc-amoy.polygon.technology/
PRIVATE_KEY=your_wallet_private_key_for_deployment- Clone the repository
git clone <repository-url>
cd contentplatform- Install dependencies
pnpm install- Set up environment variables
cp .env.example .env.local
# Fill in your environment variables- Run the development server
pnpm dev- Access the application Open http://localhost:3000
The platform uses real blockchain technology for copyright protection:
- Connect MetaMask to Polygon Amoy testnet
- Select an article you want to protect
- Register copyright - pays 0.001 MATIC gas fee
- Get permanent proof - verifiable on Polygonscan
- Chain: Polygon Amoy Testnet
- Chain ID: 80002
- RPC: https://rpc-amoy.polygon.technology/
- Explorer: https://amoy.polygonscan.com/
- Faucet: https://faucet.polygon.technology/
Visit: https://amoy.polygonscan.com/address/0xeAeE2316D793068c34EbC322e1F8a98dCBAF9f69
- Sign up with email or Google
- Write articles using the rich text editor
- Publish content with tags for discovery
- Protect copyright via blockchain registration
- Track analytics in the dashboard
- Browse articles on the explore page
- Search by tags or keywords
- Read engaging content from verified writers
- Interact through comments
- Connect your GitHub repo to Vercel
- Add environment variables in Vercel dashboard
- Deploy - platform works immediately with real blockchain features
Update NEXTAUTH_URL to your production domain:
NEXTAUTH_URL=https://your-app.vercel.app- Secure authentication with password hashing
- Session management with NextAuth
- Input validation and sanitization
- Rate limiting for API endpoints
- MongoDB injection protection
- Blockchain transaction validation
- β Real blockchain integration (not demo)
- β Production database with MongoDB
- β Secure authentication system
- β Error handling and validation
- β Performance optimized for Vercel
- β Mobile responsive design
- β SEO optimized with proper meta tags
- Fork the repository
- Create a feature branch
- Make your changes
- Test thoroughly
- Submit a pull request
This project is licensed under the MIT License.
- Live Demo: [Deploy on Vercel]
- Blockchain Explorer: Polygon Amoy Scan
- Documentation: Next.js Docs
Built with β€οΈ using Next.js, Polygon, and modern web technologies.