terra0project / Two-Degrees

'Two Degrees' NFT code for Sotheby's 'Natively Digital: A Curated NTF Sale'

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

                      (
  *   )               )\ )
` )  /( (  (         (()/(     (   (  (  (      (    (
 ( )(_)))\))(    (    /(_))   ))\  )\))( )(    ))\  ))\ (
(_(_())((_)()\   )\  (_))_   /((_)((_))\(()\  /((_)/((_))\
|_   _|_(()((_) ((_)  |   \ (_))   (()(_)((_)(_)) (_)) ((_)
  | |  \ V  V // _ \  | |) |/ -_) / _` || '_|/ -_)/ -_)(_-<
  |_|   \_/\_/ \___/  |___/ \___| \__, ||_|  \___|\___|/__/
                                  |___/

This repo contains all of the code making up 'Two Degrees', a single NFT created for Sotheby's 'Natively Digital: A Curated NTF Sale' exhibition and auction.

A full write-up of the conceptual approach behind the project, plus a technical overview, can be found here.

Smart Contracts

There are two main smart contracts: an ERC721 Token, and a custom Oracle contract.

  • TemperatureOracle.sol stores the average annual temperature rise as decided by NASA in their annual report, which can be updated by the o-address, an automated event listener running on a server. When this value crosses the threshold of 2 degrees centigrade, the token is able to be burned by anyone who wants to call the token contract's burn() function and do so.

  • TemperatureToken implements a standard ERC721 interface using most OpenZeppelin functions. There is a small custom ACL which allows the TemperatureOracle contract to burn the minted token if the annual average temperature increase is > 2 degrees Celsius.

About

'Two Degrees' NFT code for Sotheby's 'Natively Digital: A Curated NTF Sale'


Languages

Language:JavaScript 69.9%Language:Solidity 28.1%Language:Python 1.5%Language:Dockerfile 0.5%