Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
69 changes: 69 additions & 0 deletions contracts/EcoTradePassport.sol
Original file line number Diff line number Diff line change
@@ -0,0 +1,69 @@
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.0;

// Simplified VIP180 interface
interface VIP180 {
function transferFrom(address sender, address recipient, uint256 amount) external returns (bool);
}

// Minimal VIP181 (NFT) base
contract VIP181 {
mapping(uint256 => string) private _tokenURIs;
mapping(uint256 => address) private _owners;
uint256 private _totalSupply;

event Transfer(address indexed from, address indexed to, uint256 indexed tokenId);

function totalSupply() public view returns (uint256) {
return _totalSupply;
}

function ownerOf(uint256 tokenId) public view returns (address) {
return _owners[tokenId];
}

function _mint(address to, uint256 tokenId) internal {
_owners[tokenId] = to;
_totalSupply += 1;
emit Transfer(address(0), to, tokenId);
}

function setTokenURI(uint256 tokenId, string memory uri) public {
require(_owners[tokenId] != address(0), "Not minted");
_tokenURIs[tokenId] = uri;
}

function tokenURI(uint256 tokenId) public view returns (string memory) {
return _tokenURIs[tokenId];
}
}

contract EcoTradePassport is VIP181 {
VIP180 public ecoT;
uint256 public constant MINT_FEE = 100 * 10**18; // 100 EcoT

event PassportMinted(address indexed owner, uint256 indexed tokenId, string product, string batch);

constructor(address _ecoTAddress) {
ecoT = VIP180(_ecoTAddress);
}

function mintPassport(
address to,
string memory product,
string memory batch,
string memory certType
) external {
require(ecoT.transferFrom(msg.sender, address(this), MINT_FEE), "Insufficient EcoT");
uint256 tokenId = totalSupply() + 1;
_mint(to, tokenId);
string memory json = string(abi.encodePacked(
'{"name":"', product,
' - Green Passport","description":"Batch: ', batch,
' | Certified: ', certType,
'","image":"https://raw.githubusercontent.com/Cosmos369-art/EcoTrade/master/logo.png"}'
));
setTokenURI(tokenId, json);
emit PassportMinted(to, tokenId, product, batch);
}
}
37 changes: 37 additions & 0 deletions docs/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
# 🌱 EcoTrade Green Passport – VeChain dApp Specification

> **Official dApp for the EcoT Token (`0x7016...4fb4`) — Building trust in B2B green trade through blockchain verification.**

## 🎯 Purpose
EcoTrade Green Passport provides **tamper-proof, on-chain sustainability credentials** for certified eco-goods traded between businesses. By anchoring environmental claims to VeChain, we eliminate greenwashing and empower buyers to **verify before they buy**.

## 🔧 Core Features
- ✅ **Mint Green Passports**: Suppliers create digital certificates for product batches.
- ✅ **VIP-181 NFTs**: Each passport is an immutable NFT on VeChain (standard: [VIP-181](https://github.com/vechain/VIPs/blob/master/vips/VIP-181.md)).
- ✅ **EcoT Utility**: Passport creation requires payment in **EcoT** (VIP-180 token).
- ✅ **QR Code Verification**: Buyers scan to view real-time, on-chain proof of sustainability.
- ✅ **Public Transparency**: All data viewable on [VeChain Explorer](https://explore.vechain.org).

## ⚙️ Technical Stack
| Component | Technology |
|-----------------|------------|
| Token Standard | VIP-180 (EcoT), VIP-181 (Passport NFT) |
| Blockchain | VeChainThor Mainnet |
| Frontend | HTML/CSS/JS (hosted on GitHub Pages) |
| Wallet | VeChain Sync + Connex |
| Source Code | [github.com/Cosmos369-art/EcoTrade](https://github.com/Cosmos369-art/EcoTrade) |

## 🌍 Sustainability Impact
- Supports **UN SDG 12** (Responsible Consumption)
- Enables **auditable green supply chains**
- Accelerates adoption of **verified circular economy practices**

## 🔗 Live Resources
- **Website**: [https://ecotrade.life](https://ecotrade.life)
- **EcoT Token**: [`0x7016b857e85e831cd0fba1eb8d86d47870b84fb4`](https://explore.vechain.org/accounts/0x7016b857e85e831cd0fba1eb8d86d47870b84fb4)
- **GitHub**: [github.com/Cosmos369-art/EcoTrade](https://github.com/Cosmos369-art/EcoTrade)

---

> 💚 *"In the green economy, trust must be verifiable — not just claimed."*
> — **EcoTrade on VeChain**
57 changes: 57 additions & 0 deletions index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0"/>
<title>EcoTrade — Verified Green B2B Marketplace</title>
<link rel="icon" href="logo.png" />
<style>
body { font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif; background: #f9fdf9; color: #1a5c3a; margin: 0; padding: 0; }
.container { max-width: 900px; margin: 0 auto; padding: 20px; text-align: center; }
header { padding: 60px 20px 40px; }
h1 { font-size: 3.2em; margin: 0; color: #0d3b22; }
h2 { font-size: 1.6em; font-weight: 400; margin: 16px 0 30px; color: #2e7d55; }
p { font-size: 1.1em; line-height: 1.6; max-width: 700px; margin: 0 auto 25px; }
.token-box { background: #e8f5ed; border-radius: 12px; padding: 20px; margin: 30px auto; max-width: 600px; border: 1px solid #c0e0d0; }
.btn { display: inline-block; background: #0d3b22; color: white; text-decoration: none; padding: 12px 28px; margin: 10px 8px; border-radius: 30px; font-weight: 600; transition: opacity 0.2s; }
.btn:hover { opacity: 0.9; }
.news-section { background: white; border-radius: 12px; padding: 25px; margin: 40px 0; box-shadow: 0 2px 10px rgba(0,0,0,0.05); text-align: left; }
.news-section h3 { color: #0d3b22; margin-top: 0; }
.footer { margin-top: 50px; color: #666; font-size: 0.9em; }
@media (max-width: 600px) {
h1 { font-size: 2.4em; }
h2 { font-size: 1.3em; }
.btn { display: block; margin: 12px auto; width: 80%; }
}
</style>
</head>
<body>
<div class="container">
<header>
<h1>🌱 EcoTrade</h1>
<h2>The Verified Green B2B Marketplace</h2>
<p>Buy and sell certified sustainable goods with <strong>on-chain proof</strong> of origin, impact, and authenticity — powered by VeChain.</p>

<div class="token-box">
✅ <strong>EcoT Token Live on VeChain Mainnet</strong><br>
Contract: <code>0x7016b857e85e831cd0fba1eb8d86d47870b84fb4</code><br>
<a href="https://explore.vechain.org/accounts/0x7016b857e85e831cd0fba1eb8d86d47870b84fb4" target="_blank" style="color:#0d3b22; text-decoration:underline;">View on VeChain Explorer</a>
</div>

<a href="https://github.com/Cosmos369-art/EcoTrade/blob/master/docs/README.md" class="btn" target="_blank">Read Technical Spec</a>
<a href="mailto:hello@ecotrade.life?subject=EcoTrade Inquiry" class="btn">Contact Us</a>
</header>

<div class="news-section">
<h3>📰 Green Pulse: Insights for Sustainable Business</h3>
<p>Coming soon: Expert analysis on eco-certifications, green tech, circular supply chains, and global sustainability events — all curated for B2B leaders like you.</p>
<p><strong>Launching Q1 2026</strong> — Building trust in green trade, one blockchain-verified transaction at a time.</p>
</div>

<div class="footer">
<p>© 2026 EcoTrade. All rights reserved.</p>
<p>Powered by <a href="https://vechain.org" target="_blank">VeChain</a> | <a href="https://github.com/Cosmos369-art/EcoTrade" target="_blank">GitHub</a></p>
</div>
</div>
</body>
</html>
Binary file added logo.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
16 changes: 16 additions & 0 deletions main/0x7016b857e85e831cd0fba1eb8d86d47870b84fb4/additional.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
{
"website": "https://ecotrade.life",
"links": {
"twitter": "",
"telegram": "",
"medium": "",
"github": "",
"facebook": "",
"slack": ""
},
"whitePaper": "https://ecotrade.life/whitepaper.pdf",
"crossChainProvider": {
"name": "native",
"url": "https://native.org/bridge"
}
}
6 changes: 6 additions & 0 deletions main/0x7016b857e85e831cd0fba1eb8d86d47870b84fb4/info.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"name": "EcoTrade",
"symbol": "EcoT",
"decimals": 18,
"desc": "A sustainable blockchain platform focused on eco-friendly trading solutions."
}
1 change: 1 addition & 0 deletions main/0x7016b857e85e831cd0fba1eb8d86d47870b84fb4/token.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added token.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
9 changes: 9 additions & 0 deletions tokens/0x7016b857e85e831cd0fba1eb8d86d47870b84fb4.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
{
"name": "EcoTrade Token",
"symbol": "EcoT",
"decimals": 18,
"logo": "https://raw.githubusercontent.com/Cosmos369-art/EcoTrade/master/logo.png",
"website": "https://ecotrade.life",
"description": "EcoT is the utility token of the EcoTrade B2B platform, enabling verified trading of certified sustainable goods and services on VeChain. It supports green certification, carbon offsetting, and eco-supplier reputation systems.",
"github": "https://github.com/Cosmos369-art/EcoTrade"
}