EnergyPro is an open source, decentralized marketplace for peer-to-peer energy trading. Built with Next.js, MongoDB, and Solana blockchain integration, EnergyPro empowers individuals and organizations to buy and sell renewable energy directly, securely, and transparently.
Traditional energy markets are centralized and often inaccessible to small producers and consumers. EnergyPro leverages blockchain technology to democratize energy trading, enabling a greener and more efficient energy ecosystem.
- Unified Dashboard: Seamlessly list energy for sale, browse available offers, and purchase energy—all from a single, intuitive dashboard.
- Secure Authentication: Powered by Civic Auth for enterprise-grade security and seamless user experience.
- Blockchain-Powered Transactions: All trades are recorded on the Solana blockchain for transparency and security.
- Solana Wallet Integration: Connect your Solana wallet (Phantom, Solflare, etc.) for direct, trustless payments.
- Scalable Seller Support: Currently, the seller address is hardcoded for demonstration. The architecture is designed to easily support multiple sellers in the future.
- Open Source: Built for the community, by the community. Contributions are welcome!
- Sign in with Civic Auth to access the platform securely.
- Connect your Solana wallet to enable blockchain transactions.
- List energy for sale or browse available energy on the dashboard.
- Buy or sell energy—all transactions are securely processed and recorded on-chain.
- Frontend: Next.js, React, TailwindCSS
- Backend: Next.js API Routes
- Database: MongoDB (with Mongoose)
- Blockchain: Solana (Smart Contract + SPL Tokens)
- Authentication: Civic Auth
- Node.js (v18+)
- MongoDB database (local or cloud, e.g., MongoDB Atlas)
- Solana wallet (Phantom, Solflare, etc.)
- Solana devnet tokens for testing
- Civic Auth account and API credentials
- Clone the repository
git clone https://github.com/yourusername/energy-pro.git
cd energy-pro- Install dependencies
npm install- Set up environment variables
Copy the example environment file and update it with your configuration:
cp .env.example .env.localEdit .env.local with your:
- MongoDB connection string
- Civic Auth credentials
- Solana configuration
- Other required variables
Required environment variables:
NEXT_PUBLIC_CIVIC_CLIENT_ID=your_civic_client_id
NEXTAUTH_URL=http://localhost:3000- Run the development server
npm run devThe application will be available at http://localhost:3000.
- Fork this repository to your GitHub account
- Sign up or log in to Vercel
- Create a new project and import your GitHub repository
- Configure the environment variables in the Vercel dashboard
- Deploy the project
For other platforms, ensure you set up the following:
- MongoDB database
- Environment variables (see
.env.example) - Build command:
next build - Start command:
next start
The platform uses a Solana smart contract for secure energy trading:
- Program ID: You can easily generate your own
- Token Mint: BIJLEE/ ANY TOKEN
We welcome contributions from the community! To get started:
- Fork the repository
- Create a new branch for your feature or bugfix
- Make your changes and commit them
- Open a pull request describing your changes
Please see the CONTRIBUTING.md file for more details (or create one if it doesn't exist yet).