Inspiration

Where we live in Ogun State, when the grid goes off, generators start up across the street within a minute. Many homes and schools have added rooftop solar to cut that diesel bill. Every hour those panels run during an outage, a generator stays off. That's real CO₂ avoided, and nobody counts it.

Certificate markets weren't built for a 5 kW rooftop. Registering for I-RECs costs more than a small site's certificates are worth, so some of the cleanest hours of energy go unrecorded. On the other side, companies trying to prove they run on clean power hour by hour, not just on annual paper, can't find supply they can trust. We wanted to connect the two, and make the certificate say what each hour actually replaced.

What it does

SUNMINT turns every hour of small-scale solar into a verified certificate on-chain, weighted by the CO₂ it avoided. Each meter has its own key. Every 5 minutes it signs a reading: energy produced, grid voltage, timestamp and a counter that can't repeat. A verifier checks each reading: the signature matches the meter registered on-chain, it isn't a replay, and it's physically possible. No solar output when the sun is down, and nothing above what the panels can produce. When the hour ends, the meter signs a summary tied to a fingerprint (a Merkle root) of its 12 readings. The contract checks the meter's signature and the verifier's co-signature, then issues exactly one certificate for that meter and hour. The contract decides what the hour displaced. If the grid read 0 V all hour and the site has a registered generator, the hour counts at the diesel rate. Otherwise it counts at that country's grid rate. Companies upload their hourly power use, see how much of each hour is matched by clean supply, and buy and retire certificates in one transaction. Retired certificates are burned, and the public receipt traces back to every signed reading. The app has six screens plus a landing page: Daylight: a live world map of the sites. Rooftop: the producer's view, with generator hours marked. Match: the company market, sortable per kWh or per tonne of CO₂. Trace: any certificate's full history, from meter to retirement. Proof: a shareable retirement receipt. Break it: anyone can run six real attacks against the verifier and contract and watch each one fail.

How we built it

Smart contracts (Solidity, Foundry, OpenZeppelin): the certificates are ERC-1155 tokens. There's one token per meter-hour, and its balance is in watt-hours, so a certificate can be partly sold or retired. A market contract lets a buyer purchase and retire in one call, and a test stablecoin covers payments. The meter signatures use EIP-712 and are checked by the contract itself. Minting costs about 138k gas. Verifier (Rust, Axum, Tokio, SQLite): runs the five checks (signature, freshness, physics, displacement, on-chain), co-signs hour summaries, mints and lists certificates, matches company load against supply, handles retirement, and runs the Break it attacks. Without chain settings it runs offline and applies the contract's rules in memory, so the whole demo works without a blockchain. Meter simulator (Rust): six sites in Lagos, Nairobi, Jaipur, Manila, Seville and São Paulo, with output based on real sun positions, passing clouds, and blackout schedules for the sites that run generators. Web app (React, Vite): installable on phones, works offline once loaded, dark and light themes. Testing: 12 contract tests, one per attack, plus unit tests on the backend. We also ran the full system against a local test chain set up like Base Sepolia: register meters, mint, buy and retire, and trace.

Challenges we ran into

Proving a generator was displaced. A meter saying "the grid was down" isn't enough. We require two things together: a signed 0 V grid reading for the whole hour, and a generator registered to that site on-chain. Anything less defaults to the lower grid rate. A false blackout claim isn't rejected; it gets minted at the grid rate, so lying gains nothing. Keeping it affordable on-chain. Checking a signature for every 5-minute reading on-chain would cost too much gas. The meter instead signs one hourly summary tied to the fingerprint of its 12 readings. The contract checks one signature per hour, and anyone can still recompute the fingerprint from the raw readings. Physics checks without false alarms. Real solar output is spiky. The limits had to catch a fake 2 a.m. reading without rejecting a sunny noon. We settled on 5% above the panels' rated output and a sun-angle check. Making Rust and Solidity agree. The signatures made in Rust had to match what the contract computes, byte for byte. Registering all six meters on a local chain was how we proved it. Time zones. Blackout schedules are local, certificate hours are UTC, and producers want local time on their charts. Getting those three to agree took more care than expected. Being honest about nights. Solar can't cover them. We show those hours as unmatched rather than filling them with annual credits.

Accomplishments that we're proud of

Our own backend can't issue a certificate the meter didn't sign. The contract checks the meter's signature directly. Every attack on Break it is stopped at the stage it should be. The double-issue attack passes every check in our backend and is still refused by the contract. The full loop works end to end: signed reading → certificate → listing → purchase and retirement → receipt → trace. A 24-hour run across six sites produced 77 certificates, and generator hours appeared exactly when each site's blackout schedule said they should. Weighting by carbon showed us something we didn't expect: in Lagos, a solar hour that keeps a generator off avoids more than twice the CO₂ of the same hour on the grid. Per tonne, it's the cheapest real impact on the market.

What we learned

Where solar runs matters as much as how much it produces. Emission factors vary widely between grids, and diesel is in a different league. The energy industry is already moving toward hourly certificates. The hard part isn't the token; it's trustworthy data from the meter. Designing for a dishonest meter changed every decision: what gets signed, what the default is when we're unsure, and which rules live in the contract instead of our backend.

What's next for SUNMINT

Real hardware: an ESP32 meter with a secure chip that stores its key, plus a grid sensor on the changeover switch, cheap enough for one household. A pilot with a school or clinic in Lagos or Ogun State, moving from simulated to real readings. Cross-checking blackout claims against utility outage data and neighbouring meters. Sourced emission factors in place of the demo values. More than one verifier, so no single operator can co-sign alone. Closing night gaps with wind and battery certificates. Bridges to existing registries like I-REC, and an API for company sustainability reports.

Built With

Share this project:

Updates

Submission history