GreenXchange

GreenXChange: blockchain-powered trading of verified green credits with PYUSD & full transparency.

GreenXchange

Created At

ETHOnline 2025

Project Description

GreenXChange is a blockchain-based platform that allows users to tokenize, verify, and trade green credits related to afforestation, carbon, water conservation, and renewable energy projects. It connects buyers, such as companies looking to meet environmental goals, with sellers, like agriculture or nature-based organizations that generate these credits.

Companies today are under growing pressure to balance their environmental impact, and green credit trading is becoming an important way to achieve that. GreenXChange makes this process transparent and secure by letting users register their projects, upload documents, and get them verified by auditors. Once verified, the projects are tokenized and minted on Ethereum, preventing fraud or double-counting.

Verified tokens can then be bought and sold freely on our decentralized marketplace, powered by PYUSD for secure on-chain payments. This open trading system ensures fair pricing and encourages more sustainable projects. Currently, GreenXchange includes tokenization, minting, and trading with sample data, but in production it will connect with real-world environmental databases to make green credit trading fully transparent and trustworthy.

How it's Made

GreenXchange is built using Ethereum smart contracts, Next.js, and Ethers.js to create a fully decentralized green credit marketplace. The system has two main smart contracts — GreenCreditToken (ERC-1155) for minting verified environmental credits, and GreenXchangeOrderbook for managing all buy and sell trades on-chain.

The GreenCreditToken contract handles project registration, approval, minting, and retirement of credits. Each credit type — carbon, water, renewable, or conservation — is stored as a unique ERC-1155 token, making it easy to track and manage.

The Orderbook contract is upgradeable and takes care of all trading activity. It uses escrow to hold tokens and payments safely during transactions and supports features like order placement, filling, canceling, platform fees, and referrer rewards. Everything runs automatically through smart contracts to keep trading transparent and secure.

For payments, the platform uses PYUSD, a stablecoin that provides safe and stable settlements on-chain. This ensures that trades are not affected by crypto price changes and remain easy to account for.

The frontend is built with Next.js 14, TailwindCSS, and Ethers.js. It connects directly to MetaMask, showing users their wallet balance, open orders, and credits in real time. React contexts handle contract connections and make blockchain calls simple for users.

We also did some creative work to make the contracts upgradeable using the UUPS proxy pattern and added extra safety with ReentrancyGuard and AccessControl from OpenZeppelin. This setup makes the system modular, secure, and ready for future updates without redeploying everything.

In short, GreenXchange combines smart contracts, stablecoin payments, and a modern web app to make green credit trading transparent, secure, and user-friendly.

background image mobile

Join the mailing list

Get the latest news and updates