Contract 0x000001E1b2b5f9825f4d50bD4906aff2F298af4e 1

 
 
Txn Hash
Method
Block
From
To
Value
0x4dd93edac73654604e942f770d44b6fc6523f59ccd0997b0b30421aa5d0cb94fSet Approval For...151498212022-07-15 21:53:5635 days 1 hr ago0xb7b008b162096fc66dae91fa63f9baf0c8150db8 IN  0x000001e1b2b5f9825f4d50bd4906aff2f298af4e0 Ether0.00096274 20.86176707
0x03162e426691b45091cf60279655a141c1e8918936e2ab88e71a84c8cdfccea1Set Approval For...151349002022-07-13 14:51:5337 days 8 hrs ago0x11a3e98d538376108302be6b38ad9f183791767d IN  0x000001e1b2b5f9825f4d50bd4906aff2f298af4e0 Ether0.00303346 65.61252849
0x322a9efe45e36469bc8bde582c07852a07d955d37990ac4b21c61291281829daImbue150861372022-07-06 1:55:0244 days 21 hrs ago0x11a3e98d538376108302be6b38ad9f183791767d IN  0x000001e1b2b5f9825f4d50bd4906aff2f298af4e0 Ether0.00149025 29.14750873
0xaac72ddf80d2378be00d44d43a72d518fbdbd03d7e50cc86502a6ebec3bc6781Imbue150861292022-07-06 1:52:3344 days 21 hrs ago0x11a3e98d538376108302be6b38ad9f183791767d IN  0x000001e1b2b5f9825f4d50bd4906aff2f298af4e0 Ether0.00123057 24.19334417
0xed935339d0a787aee10e05570863fdd85606ebefe7e4702c48747de400ce0d5eTransfer From150828012022-07-05 13:32:2445 days 10 hrs ago0x11a3e98d538376108302be6b38ad9f183791767d IN  0x000001e1b2b5f9825f4d50bd4906aff2f298af4e0 Ether0.00600748 46.72829043
0xb5e35f357e4502e4a13819a3d12368755ca08d4adfac169b399e07d486c2cdedTransfer From150419352022-06-28 22:27:5852 days 1 hr ago0xe5afd4429e425c3d56f0f432bed63c9bfe77b43a IN  0x000001e1b2b5f9825f4d50bd4906aff2f298af4e0 Ether0.00476086 40.25488635
0x9fbce4a7de6ad38c4b6ed2f976c2eea139db29d863355297ec10ada20200da3eTransfer From150417642022-06-28 21:45:2452 days 1 hr ago0x11a3e98d538376108302be6b38ad9f183791767d IN  0x000001e1b2b5f9825f4d50bd4906aff2f298af4e0 Ether0.00561503 43.67569602
0x6a3732a599f49f96dc66798a1d4c87abaae55e9987659ea967e35eab2f53da5fImbue150320372022-06-27 2:17:3653 days 21 hrs ago0x11a3e98d538376108302be6b38ad9f183791767d IN  0x000001e1b2b5f9825f4d50bd4906aff2f298af4e0 Ether0.00126793 24.77012169
0x388dc6817b28161b75d5eadc131a50f578a7d4744cf7e64386d43ecf758d5664Transfer From150320182022-06-27 2:12:1253 days 21 hrs ago0x11a3e98d538376108302be6b38ad9f183791767d IN  0x000001e1b2b5f9825f4d50bd4906aff2f298af4e0 Ether0.00243028 18.9036412
0xc8f7fef9f170c0f8a9860f210629bd83509c9f8593904681d03b7511020a16bbTransfer From150158512022-06-24 1:32:1856 days 22 hrs ago0x11a3e98d538376108302be6b38ad9f183791767d IN  0x000001e1b2b5f9825f4d50bd4906aff2f298af4e0 Ether0.00584731 45.48245627
0xf2a59f72cc13de665baa4ec336061adf95f25a26bfb21ad044d98ce90d51d0a6Imbue150083262022-06-22 15:38:1958 days 7 hrs ago0xec5e053b5f0a19ccb9a1c392fec5567e821a6a54 IN  0x000001e1b2b5f9825f4d50bd4906aff2f298af4e0 Ether0.00208096 40.70109652
0x0fc8179d4dc57b882d253ad18d5d5e1d785aa0bcc4686946c14a3a9e7f548fecSet Approval For...149880862022-06-19 1:12:1061 days 22 hrs ago0x3b2cf7c5c7ead2ee4f3e70ea2f694749abb15b26 IN  0x000001e1b2b5f9825f4d50bd4906aff2f298af4e0 Ether0.0012714 27.55002981
0xad7f5ba0976fe9dc17d8d663dcfcb33a818f85a94802b61f572559d7770a0aceImbue149725752022-06-16 9:31:0664 days 14 hrs ago0x2bf33fea506a6eb92f8c044ce649939fa6ceab41 IN  0x000001e1b2b5f9825f4d50bd4906aff2f298af4e0 Ether0.00177806 34.89146423
0xddbc8e63af3076626c3f241165153c56a0e4dad11939e6e974e4cb3dada3a013Transfer From149725052022-06-16 9:14:0464 days 14 hrs ago0xf337cb41f627e0363d4fb5a968941eab29b25473 IN  0x000001e1b2b5f9825f4d50bd4906aff2f298af4e0 Ether0.00946012 73.5841838
0x4363bceae3f17a773cb140de350551c61ecc11f2736b9ede8c3513743d275b3dSet Approval For...149669932022-06-15 10:27:3965 days 13 hrs ago0xf337cb41f627e0363d4fb5a968941eab29b25473 IN  0x000001e1b2b5f9825f4d50bd4906aff2f298af4e0 Ether0.00481075 104.24403294
0xb30f74ef2097332bf426219e432b6d824cae7ef1ed7aac0c5d466bfc40b3336aTransfer From149663162022-06-15 7:29:5565 days 16 hrs ago0xf337cb41f627e0363d4fb5a968941eab29b25473 IN  0x000001e1b2b5f9825f4d50bd4906aff2f298af4e0 Ether0.00340301 29.27026772
0xcca47b324a804cf65313446da79b7a60fd0a9573867dd07eca9df72397d6fb08Imbue149265492022-06-08 11:52:4272 days 11 hrs agoENS Name tadaa.eth IN  0x000001e1b2b5f9825f4d50bd4906aff2f298af4e0 Ether0.0044085 86.38707068
0xa5e324a2984d2ee738a7e2dc2a8df2964dc1138b56736deae1613143e99bb3e2Set Approval For...148728812022-05-30 13:51:3781 days 9 hrs ago0x393376e59bd40a4fbedeed3e44697ec4e00299d9 IN  0x000001e1b2b5f9825f4d50bd4906aff2f298af4e0 Ether0.00287942 62.29686631
0x2ff61376f2de24c7ee561f782033f47ea8506170d8d32b7ed9d56fc523cdcde6Transfer From147401442022-05-09 3:48:31102 days 19 hrs ago0xc110eb0b6aeba00255b3bade0f4231938103682c IN  0x000001e1b2b5f9825f4d50bd4906aff2f298af4e0 Ether0.00404083 35.01044821
0xb944038f51ca6a94f4c228b302cdd5f7f137f5c9d7d77c9530e5874287227b6eSet Approval For...146223962022-04-20 14:15:20121 days 9 hrs ago0x3b2cf7c5c7ead2ee4f3e70ea2f694749abb15b26 IN  0x000001e1b2b5f9825f4d50bd4906aff2f298af4e0 Ether0.00310515 67.16310109
0x5beb896159780b1d181071562ba5ff9e63f3dad897c091875aac9aabe16d0aacSet Approval For...145551832022-04-10 2:01:39131 days 21 hrs ago0xc64a308b6b93952174c8077ab297402e3db7e0f6 IN  0x000001e1b2b5f9825f4d50bd4906aff2f298af4e0 Ether0.00097586 21.10754492
0x60265ba3e3eb1252062d7ade76a36a64bcb008ae2e7e32d2d045b7681c0a7d86Set Approval For...145547802022-04-10 0:36:54131 days 22 hrs ago0xb7b008b162096fc66dae91fa63f9baf0c8150db8 IN  0x000001e1b2b5f9825f4d50bd4906aff2f298af4e0 Ether0.00179935 38.91936133
0x4915c5ecb4d251cfcf1109e23c1430f20d5ada0a43ae92ac24e4eba3aed49564Set Approval For...145336592022-04-06 17:34:42135 days 6 hrs ago0xc64a308b6b93952174c8077ab297402e3db7e0f6 IN  0x000001e1b2b5f9825f4d50bd4906aff2f298af4e0 Ether0.00257007 55.58960927
0xafbb694487495427bebb9b25db3913736f19a9d1bb9e8142b57edd79a1971d93Transfer From145326202022-04-06 13:29:20135 days 10 hrs ago0xc7ceb1c42346813edbaac7ebdeaa5886310fed56 IN  0x000001e1b2b5f9825f4d50bd4906aff2f298af4e0 Ether0.00652079 56.49723503
0x844d7a031a480a65c31d51624788778f868947c52c378f89de42199b5f735d53Set Edition Tran...141720692022-02-09 13:05:01191 days 10 hrs ago0x34eee73e731fb2a428444e2b2957c36a9b145017 IN  0x000001e1b2b5f9825f4d50bd4906aff2f298af4e0 Ether0.00255188 79.40889607
[ Download CSV Export 
View more zero value Internal Transactions in Advanced View mode
Loading

Contract Source Code Verified (Exact Match)

Contract Name:
ImbuedNFT

Compiler Version
v0.8.7+commit.e28d00a7

Optimization Enabled:
Yes with 200 runs

Other Settings:
default evmVersion
File 1 of 13 : ImbuedNFT.sol
//SPDX-License-Identifier: Unlicense
pragma solidity ^0.8.7;

import "@openzeppelin/contracts/access/Ownable.sol";
import "@openzeppelin/contracts/token/ERC721/ERC721.sol";
import "@openzeppelin/contracts/token/ERC721/extensions/ERC721Enumerable.sol";

/** @title NFT contract for imbued works of art
    @author 0xsublime.eth
    @notice This contract is the persistent center of the Imbued Art project,
    and allows unstoppable ownership of the NFTs. The minting is controlled by a
    separate contract, which is upgradeable. This contract enforces a 700 token
    limit: 7 editions of 100 tokens.

    The dataContract is intended to serve as a store for metadata, animations,
    code, etc.

    The owner of a token can imbue it with meaning. The imbuement is a string,
    up to 32 bytes long. The history of a tokens owenrship and its imbuements
    are stored and are retrievable via view functions.

    Token transfers are initially turned off for all editions. Once a transfers
    are activated on an edition of tokens, it cannot be disallowed again.
 */
contract ImbuedNFT is ERC721Enumerable, Ownable {

    /// @dev The contract controlling minting
    address public mintContract;
    /// @dev For storing metadata, animations, code.
    address public dataContract; 

    uint256 constant public NUM_EDITIONS = 7;
    uint256 constant public EDITION_SIZE = 100;
    /// Tokens are marked transferable at the edition level.
    bool[] public editionTransferable = new bool[](NUM_EDITIONS);

    string public baseURI = "https://api.imbuedart.com/api/token/";

    /// Maps a token to its history of owners.
    mapping (uint256 => address[]) public id2provenance;
    /// Maps a (token, owner) pair to its imbuement.
    mapping (uint256 => mapping (address => string)) public idAndOwner2imbuement;

    event Imbued(uint256 indexed tokenId, address indexed owner, string imbuement);
    event EditionTransferable(uint256 indexed edition);

    constructor() ERC721("Imbued Art", "IMBUED") { }

    // ===================================
    // Mint contract privileged functions.
    // ===================================

    /** @dev The mint function can only be called by the minter address.
        @param recipient The recipient of the minted token, needs to be an EAO or a contract which accepts ERC721s.
        @param tokenId The token ID to mint.
     */
    function mint(address recipient, uint256 tokenId) external {
        require(msg.sender == mintContract, "Only the mint contract can mint");
        require(tokenId < NUM_EDITIONS * EDITION_SIZE, "Token ID is too high");
        id2provenance[tokenId].push(recipient);
        _safeMint(recipient, tokenId);
    }

    // ==============
    // NFT functions.
    // ==============

    /** Saves an imbuement for a token and owner.
        An imbuement is a string, up to 32 bytes (equivalent to 32 ASCII
        characters).  Once set, it is immuatble.  Only the owner, or an address
        which has permission to control the token, can imbue it.
        @param tokenId The token to imbue.
        @param imbuement The string that should be saved
     */
    function imbue(uint256 tokenId, string calldata imbuement) external {
        require(_isApprovedOrOwner(msg.sender, tokenId), "Can only imbue token you control");
        require(bytes(imbuement).length <= 32, "Only 32 bytes allowed.");
        address own = ownerOf(tokenId);
        string storage currentImbuement = idAndOwner2imbuement[tokenId][own];
        require(keccak256((abi.encodePacked(currentImbuement))) == keccak256(abi.encodePacked(""))
            , "One imbument per token and owner");
        idAndOwner2imbuement[tokenId][own] = imbuement;
        emit Imbued(tokenId, own, imbuement);
    }

    /// @dev Tokens transfers are initially blocked. Once released, they are always transferable.
    function _transfer(address from, address to, uint256 id) internal override {
        require(editionTransferable[id / EDITION_SIZE], "Edition transfer not active");
        id2provenance[id].push(to);
        super._transfer(from, to, id);
    }

    // ===============
    // View functions.
    // ===============

    /// Get the complete list of imbuements for a token.
    /// @param id ID of the token to get imbuements for
    /// @param start start of the range to return (inclusive)
    /// @param end end of the range to return (non-inclusive), or 0 for max length.
    /// @return A string array, each string at most 32 bytes.
    function imbuements(uint256 id, uint256 start, uint256 end) external view returns (string[] memory) {
        address own;
        address[] storage owners = id2provenance[id];
        if (end == 0) {
            end = owners.length;
        }
        string[] memory result = new string[](end - start);
        for (uint256 i = start; i < end; i++) {
            own = owners[i];
            result[i - start] = idAndOwner2imbuement[id][own];
        }
        return result;
    }

    /// Get the chronological list of owners of a token.
    /// @param id The token ID to get the provenance for.
    /// @param start start of the range to return (inclusive)
    /// @param end end of the range to return (non-inclusive), or 0 for max length.
    /// @return An address array of all owners, listed chornologically.
    function provenance(uint256 id, uint256 start, uint256 end) external view returns (address[] memory) {
        address own;
        address[] storage owners = id2provenance[id];
        if (end == 0) {
            end = owners.length;
        }
        address[] memory result = new address[](end - start);
        for (uint256 i = start; i < end; i++) {
            own = owners[i];
            result[i - start] = own;
        }
        return result;
    }

    // ==========================
    // Internal helper functions.
    // ==========================

    function _baseURI() internal view override returns (string memory) {
        return baseURI;
    }

    // =====================
    // Only owner functions.
    // =====================

    function setMintContract(address _mintContract) external onlyOwner() {
        mintContract = _mintContract;
    }

    function setDataContract(address _dataContract) external onlyOwner() {
        dataContract = _dataContract;
    }

    function setBaseURI(string memory newBaseURI) external onlyOwner() {
        baseURI = newBaseURI;
    }

    /// @dev Edition transfers can only be allowed, there is no way to disallow them later.
    function setEditionTransferable(uint256 edition) external onlyOwner {
        editionTransferable[edition] = true;
        emit EditionTransferable(edition);
    }
}

File 2 of 13 : Ownable.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

import "../utils/Context.sol";

/**
 * @dev Contract module which provides a basic access control mechanism, where
 * there is an account (an owner) that can be granted exclusive access to
 * specific functions.
 *
 * By default, the owner account will be the one that deploys the contract. This
 * can later be changed with {transferOwnership}.
 *
 * This module is used through inheritance. It will make available the modifier
 * `onlyOwner`, which can be applied to your functions to restrict their use to
 * the owner.
 */
abstract contract Ownable is Context {
    address private _owner;

    event OwnershipTransferred(address indexed previousOwner, address indexed newOwner);

    /**
     * @dev Initializes the contract setting the deployer as the initial owner.
     */
    constructor() {
        _setOwner(_msgSender());
    }

    /**
     * @dev Returns the address of the current owner.
     */
    function owner() public view virtual returns (address) {
        return _owner;
    }

    /**
     * @dev Throws if called by any account other than the owner.
     */
    modifier onlyOwner() {
        require(owner() == _msgSender(), "Ownable: caller is not the owner");
        _;
    }

    /**
     * @dev Leaves the contract without owner. It will not be possible to call
     * `onlyOwner` functions anymore. Can only be called by the current owner.
     *
     * NOTE: Renouncing ownership will leave the contract without an owner,
     * thereby removing any functionality that is only available to the owner.
     */
    function renounceOwnership() public virtual onlyOwner {
        _setOwner(address(0));
    }

    /**
     * @dev Transfers ownership of the contract to a new account (`newOwner`).
     * Can only be called by the current owner.
     */
    function transferOwnership(address newOwner) public virtual onlyOwner {
        require(newOwner != address(0), "Ownable: new owner is the zero address");
        _setOwner(newOwner);
    }

    function _setOwner(address newOwner) private {
        address oldOwner = _owner;
        _owner = newOwner;
        emit OwnershipTransferred(oldOwner, newOwner);
    }
}

File 3 of 13 : ERC721.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

import "./IERC721.sol";
import "./IERC721Receiver.sol";
import "./extensions/IERC721Metadata.sol";
import "../../utils/Address.sol";
import "../../utils/Context.sol";
import "../../utils/Strings.sol";
import "../../utils/introspection/ERC165.sol";

/**
 * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including
 * the Metadata extension, but not including the Enumerable extension, which is available separately as
 * {ERC721Enumerable}.
 */
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata {
    using Address for address;
    using Strings for uint256;

    // Token name
    string private _name;

    // Token symbol
    string private _symbol;

    // Mapping from token ID to owner address
    mapping(uint256 => address) private _owners;

    // Mapping owner address to token count
    mapping(address => uint256) private _balances;

    // Mapping from token ID to approved address
    mapping(uint256 => address) private _tokenApprovals;

    // Mapping from owner to operator approvals
    mapping(address => mapping(address => bool)) private _operatorApprovals;

    /**
     * @dev Initializes the contract by setting a `name` and a `symbol` to the token collection.
     */
    constructor(string memory name_, string memory symbol_) {
        _name = name_;
        _symbol = symbol_;
    }

    /**
     * @dev See {IERC165-supportsInterface}.
     */
    function supportsInterface(bytes4 interfaceId) public view virtual override(ERC165, IERC165) returns (bool) {
        return
            interfaceId == type(IERC721).interfaceId ||
            interfaceId == type(IERC721Metadata).interfaceId ||
            super.supportsInterface(interfaceId);
    }

    /**
     * @dev See {IERC721-balanceOf}.
     */
    function balanceOf(address owner) public view virtual override returns (uint256) {
        require(owner != address(0), "ERC721: balance query for the zero address");
        return _balances[owner];
    }

    /**
     * @dev See {IERC721-ownerOf}.
     */
    function ownerOf(uint256 tokenId) public view virtual override returns (address) {
        address owner = _owners[tokenId];
        require(owner != address(0), "ERC721: owner query for nonexistent token");
        return owner;
    }

    /**
     * @dev See {IERC721Metadata-name}.
     */
    function name() public view virtual override returns (string memory) {
        return _name;
    }

    /**
     * @dev See {IERC721Metadata-symbol}.
     */
    function symbol() public view virtual override returns (string memory) {
        return _symbol;
    }

    /**
     * @dev See {IERC721Metadata-tokenURI}.
     */
    function tokenURI(uint256 tokenId) public view virtual override returns (string memory) {
        require(_exists(tokenId), "ERC721Metadata: URI query for nonexistent token");

        string memory baseURI = _baseURI();
        return bytes(baseURI).length > 0 ? string(abi.encodePacked(baseURI, tokenId.toString())) : "";
    }

    /**
     * @dev Base URI for computing {tokenURI}. If set, the resulting URI for each
     * token will be the concatenation of the `baseURI` and the `tokenId`. Empty
     * by default, can be overriden in child contracts.
     */
    function _baseURI() internal view virtual returns (string memory) {
        return "";
    }

    /**
     * @dev See {IERC721-approve}.
     */
    function approve(address to, uint256 tokenId) public virtual override {
        address owner = ERC721.ownerOf(tokenId);
        require(to != owner, "ERC721: approval to current owner");

        require(
            _msgSender() == owner || isApprovedForAll(owner, _msgSender()),
            "ERC721: approve caller is not owner nor approved for all"
        );

        _approve(to, tokenId);
    }

    /**
     * @dev See {IERC721-getApproved}.
     */
    function getApproved(uint256 tokenId) public view virtual override returns (address) {
        require(_exists(tokenId), "ERC721: approved query for nonexistent token");

        return _tokenApprovals[tokenId];
    }

    /**
     * @dev See {IERC721-setApprovalForAll}.
     */
    function setApprovalForAll(address operator, bool approved) public virtual override {
        require(operator != _msgSender(), "ERC721: approve to caller");

        _operatorApprovals[_msgSender()][operator] = approved;
        emit ApprovalForAll(_msgSender(), operator, approved);
    }

    /**
     * @dev See {IERC721-isApprovedForAll}.
     */
    function isApprovedForAll(address owner, address operator) public view virtual override returns (bool) {
        return _operatorApprovals[owner][operator];
    }

    /**
     * @dev See {IERC721-transferFrom}.
     */
    function transferFrom(
        address from,
        address to,
        uint256 tokenId
    ) public virtual override {
        //solhint-disable-next-line max-line-length
        require(_isApprovedOrOwner(_msgSender(), tokenId), "ERC721: transfer caller is not owner nor approved");

        _transfer(from, to, tokenId);
    }

    /**
     * @dev See {IERC721-safeTransferFrom}.
     */
    function safeTransferFrom(
        address from,
        address to,
        uint256 tokenId
    ) public virtual override {
        safeTransferFrom(from, to, tokenId, "");
    }

    /**
     * @dev See {IERC721-safeTransferFrom}.
     */
    function safeTransferFrom(
        address from,
        address to,
        uint256 tokenId,
        bytes memory _data
    ) public virtual override {
        require(_isApprovedOrOwner(_msgSender(), tokenId), "ERC721: transfer caller is not owner nor approved");
        _safeTransfer(from, to, tokenId, _data);
    }

    /**
     * @dev Safely transfers `tokenId` token from `from` to `to`, checking first that contract recipients
     * are aware of the ERC721 protocol to prevent tokens from being forever locked.
     *
     * `_data` is additional data, it has no specified format and it is sent in call to `to`.
     *
     * This internal function is equivalent to {safeTransferFrom}, and can be used to e.g.
     * implement alternative mechanisms to perform token transfer, such as signature-based.
     *
     * Requirements:
     *
     * - `from` cannot be the zero address.
     * - `to` cannot be the zero address.
     * - `tokenId` token must exist and be owned by `from`.
     * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer.
     *
     * Emits a {Transfer} event.
     */
    function _safeTransfer(
        address from,
        address to,
        uint256 tokenId,
        bytes memory _data
    ) internal virtual {
        _transfer(from, to, tokenId);
        require(_checkOnERC721Received(from, to, tokenId, _data), "ERC721: transfer to non ERC721Receiver implementer");
    }

    /**
     * @dev Returns whether `tokenId` exists.
     *
     * Tokens can be managed by their owner or approved accounts via {approve} or {setApprovalForAll}.
     *
     * Tokens start existing when they are minted (`_mint`),
     * and stop existing when they are burned (`_burn`).
     */
    function _exists(uint256 tokenId) internal view virtual returns (bool) {
        return _owners[tokenId] != address(0);
    }

    /**
     * @dev Returns whether `spender` is allowed to manage `tokenId`.
     *
     * Requirements:
     *
     * - `tokenId` must exist.
     */
    function _isApprovedOrOwner(address spender, uint256 tokenId) internal view virtual returns (bool) {
        require(_exists(tokenId), "ERC721: operator query for nonexistent token");
        address owner = ERC721.ownerOf(tokenId);
        return (spender == owner || getApproved(tokenId) == spender || isApprovedForAll(owner, spender));
    }

    /**
     * @dev Safely mints `tokenId` and transfers it to `to`.
     *
     * Requirements:
     *
     * - `tokenId` must not exist.
     * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer.
     *
     * Emits a {Transfer} event.
     */
    function _safeMint(address to, uint256 tokenId) internal virtual {
        _safeMint(to, tokenId, "");
    }

    /**
     * @dev Same as {xref-ERC721-_safeMint-address-uint256-}[`_safeMint`], with an additional `data` parameter which is
     * forwarded in {IERC721Receiver-onERC721Received} to contract recipients.
     */
    function _safeMint(
        address to,
        uint256 tokenId,
        bytes memory _data
    ) internal virtual {
        _mint(to, tokenId);
        require(
            _checkOnERC721Received(address(0), to, tokenId, _data),
            "ERC721: transfer to non ERC721Receiver implementer"
        );
    }

    /**
     * @dev Mints `tokenId` and transfers it to `to`.
     *
     * WARNING: Usage of this method is discouraged, use {_safeMint} whenever possible
     *
     * Requirements:
     *
     * - `tokenId` must not exist.
     * - `to` cannot be the zero address.
     *
     * Emits a {Transfer} event.
     */
    function _mint(address to, uint256 tokenId) internal virtual {
        require(to != address(0), "ERC721: mint to the zero address");
        require(!_exists(tokenId), "ERC721: token already minted");

        _beforeTokenTransfer(address(0), to, tokenId);

        _balances[to] += 1;
        _owners[tokenId] = to;

        emit Transfer(address(0), to, tokenId);
    }

    /**
     * @dev Destroys `tokenId`.
     * The approval is cleared when the token is burned.
     *
     * Requirements:
     *
     * - `tokenId` must exist.
     *
     * Emits a {Transfer} event.
     */
    function _burn(uint256 tokenId) internal virtual {
        address owner = ERC721.ownerOf(tokenId);

        _beforeTokenTransfer(owner, address(0), tokenId);

        // Clear approvals
        _approve(address(0), tokenId);

        _balances[owner] -= 1;
        delete _owners[tokenId];

        emit Transfer(owner, address(0), tokenId);
    }

    /**
     * @dev Transfers `tokenId` from `from` to `to`.
     *  As opposed to {transferFrom}, this imposes no restrictions on msg.sender.
     *
     * Requirements:
     *
     * - `to` cannot be the zero address.
     * - `tokenId` token must be owned by `from`.
     *
     * Emits a {Transfer} event.
     */
    function _transfer(
        address from,
        address to,
        uint256 tokenId
    ) internal virtual {
        require(ERC721.ownerOf(tokenId) == from, "ERC721: transfer of token that is not own");
        require(to != address(0), "ERC721: transfer to the zero address");

        _beforeTokenTransfer(from, to, tokenId);

        // Clear approvals from the previous owner
        _approve(address(0), tokenId);

        _balances[from] -= 1;
        _balances[to] += 1;
        _owners[tokenId] = to;

        emit Transfer(from, to, tokenId);
    }

    /**
     * @dev Approve `to` to operate on `tokenId`
     *
     * Emits a {Approval} event.
     */
    function _approve(address to, uint256 tokenId) internal virtual {
        _tokenApprovals[tokenId] = to;
        emit Approval(ERC721.ownerOf(tokenId), to, tokenId);
    }

    /**
     * @dev Internal function to invoke {IERC721Receiver-onERC721Received} on a target address.
     * The call is not executed if the target address is not a contract.
     *
     * @param from address representing the previous owner of the given token ID
     * @param to target address that will receive the tokens
     * @param tokenId uint256 ID of the token to be transferred
     * @param _data bytes optional data to send along with the call
     * @return bool whether the call correctly returned the expected magic value
     */
    function _checkOnERC721Received(
        address from,
        address to,
        uint256 tokenId,
        bytes memory _data
    ) private returns (bool) {
        if (to.isContract()) {
            try IERC721Receiver(to).onERC721Received(_msgSender(), from, tokenId, _data) returns (bytes4 retval) {
                return retval == IERC721Receiver.onERC721Received.selector;
            } catch (bytes memory reason) {
                if (reason.length == 0) {
                    revert("ERC721: transfer to non ERC721Receiver implementer");
                } else {
                    assembly {
                        revert(add(32, reason), mload(reason))
                    }
                }
            }
        } else {
            return true;
        }
    }

    /**
     * @dev Hook that is called before any token transfer. This includes minting
     * and burning.
     *
     * Calling conditions:
     *
     * - When `from` and `to` are both non-zero, ``from``'s `tokenId` will be
     * transferred to `to`.
     * - When `from` is zero, `tokenId` will be minted for `to`.
     * - When `to` is zero, ``from``'s `tokenId` will be burned.
     * - `from` and `to` are never both zero.
     *
     * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks].
     */
    function _beforeTokenTransfer(
        address from,
        address to,
        uint256 tokenId
    ) internal virtual {}
}

File 4 of 13 : ERC721Enumerable.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

import "../ERC721.sol";
import "./IERC721Enumerable.sol";

/**
 * @dev This implements an optional extension of {ERC721} defined in the EIP that adds
 * enumerability of all the token ids in the contract as well as all token ids owned by each
 * account.
 */
abstract contract ERC721Enumerable is ERC721, IERC721Enumerable {
    // Mapping from owner to list of owned token IDs
    mapping(address => mapping(uint256 => uint256)) private _ownedTokens;

    // Mapping from token ID to index of the owner tokens list
    mapping(uint256 => uint256) private _ownedTokensIndex;

    // Array with all token ids, used for enumeration
    uint256[] private _allTokens;

    // Mapping from token id to position in the allTokens array
    mapping(uint256 => uint256) private _allTokensIndex;

    /**
     * @dev See {IERC165-supportsInterface}.
     */
    function supportsInterface(bytes4 interfaceId) public view virtual override(IERC165, ERC721) returns (bool) {
        return interfaceId == type(IERC721Enumerable).interfaceId || super.supportsInterface(interfaceId);
    }

    /**
     * @dev See {IERC721Enumerable-tokenOfOwnerByIndex}.
     */
    function tokenOfOwnerByIndex(address owner, uint256 index) public view virtual override returns (uint256) {
        require(index < ERC721.balanceOf(owner), "ERC721Enumerable: owner index out of bounds");
        return _ownedTokens[owner][index];
    }

    /**
     * @dev See {IERC721Enumerable-totalSupply}.
     */
    function totalSupply() public view virtual override returns (uint256) {
        return _allTokens.length;
    }

    /**
     * @dev See {IERC721Enumerable-tokenByIndex}.
     */
    function tokenByIndex(uint256 index) public view virtual override returns (uint256) {
        require(index < ERC721Enumerable.totalSupply(), "ERC721Enumerable: global index out of bounds");
        return _allTokens[index];
    }

    /**
     * @dev Hook that is called before any token transfer. This includes minting
     * and burning.
     *
     * Calling conditions:
     *
     * - When `from` and `to` are both non-zero, ``from``'s `tokenId` will be
     * transferred to `to`.
     * - When `from` is zero, `tokenId` will be minted for `to`.
     * - When `to` is zero, ``from``'s `tokenId` will be burned.
     * - `from` cannot be the zero address.
     * - `to` cannot be the zero address.
     *
     * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks].
     */
    function _beforeTokenTransfer(
        address from,
        address to,
        uint256 tokenId
    ) internal virtual override {
        super._beforeTokenTransfer(from, to, tokenId);

        if (from == address(0)) {
            _addTokenToAllTokensEnumeration(tokenId);
        } else if (from != to) {
            _removeTokenFromOwnerEnumeration(from, tokenId);
        }
        if (to == address(0)) {
            _removeTokenFromAllTokensEnumeration(tokenId);
        } else if (to != from) {
            _addTokenToOwnerEnumeration(to, tokenId);
        }
    }

    /**
     * @dev Private function to add a token to this extension's ownership-tracking data structures.
     * @param to address representing the new owner of the given token ID
     * @param tokenId uint256 ID of the token to be added to the tokens list of the given address
     */
    function _addTokenToOwnerEnumeration(address to, uint256 tokenId) private {
        uint256 length = ERC721.balanceOf(to);
        _ownedTokens[to][length] = tokenId;
        _ownedTokensIndex[tokenId] = length;
    }

    /**
     * @dev Private function to add a token to this extension's token tracking data structures.
     * @param tokenId uint256 ID of the token to be added to the tokens list
     */
    function _addTokenToAllTokensEnumeration(uint256 tokenId) private {
        _allTokensIndex[tokenId] = _allTokens.length;
        _allTokens.push(tokenId);
    }

    /**
     * @dev Private function to remove a token from this extension's ownership-tracking data structures. Note that
     * while the token is not assigned a new owner, the `_ownedTokensIndex` mapping is _not_ updated: this allows for
     * gas optimizations e.g. when performing a transfer operation (avoiding double writes).
     * This has O(1) time complexity, but alters the order of the _ownedTokens array.
     * @param from address representing the previous owner of the given token ID
     * @param tokenId uint256 ID of the token to be removed from the tokens list of the given address
     */
    function _removeTokenFromOwnerEnumeration(address from, uint256 tokenId) private {
        // To prevent a gap in from's tokens array, we store the last token in the index of the token to delete, and
        // then delete the last slot (swap and pop).

        uint256 lastTokenIndex = ERC721.balanceOf(from) - 1;
        uint256 tokenIndex = _ownedTokensIndex[tokenId];

        // When the token to delete is the last token, the swap operation is unnecessary
        if (tokenIndex != lastTokenIndex) {
            uint256 lastTokenId = _ownedTokens[from][lastTokenIndex];

            _ownedTokens[from][tokenIndex] = lastTokenId; // Move the last token to the slot of the to-delete token
            _ownedTokensIndex[lastTokenId] = tokenIndex; // Update the moved token's index
        }

        // This also deletes the contents at the last position of the array
        delete _ownedTokensIndex[tokenId];
        delete _ownedTokens[from][lastTokenIndex];
    }

    /**
     * @dev Private function to remove a token from this extension's token tracking data structures.
     * This has O(1) time complexity, but alters the order of the _allTokens array.
     * @param tokenId uint256 ID of the token to be removed from the tokens list
     */
    function _removeTokenFromAllTokensEnumeration(uint256 tokenId) private {
        // To prevent a gap in the tokens array, we store the last token in the index of the token to delete, and
        // then delete the last slot (swap and pop).

        uint256 lastTokenIndex = _allTokens.length - 1;
        uint256 tokenIndex = _allTokensIndex[tokenId];

        // When the token to delete is the last token, the swap operation is unnecessary. However, since this occurs so
        // rarely (when the last minted token is burnt) that we still do the swap here to avoid the gas cost of adding
        // an 'if' statement (like in _removeTokenFromOwnerEnumeration)
        uint256 lastTokenId = _allTokens[lastTokenIndex];

        _allTokens[tokenIndex] = lastTokenId; // Move the last token to the slot of the to-delete token
        _allTokensIndex[lastTokenId] = tokenIndex; // Update the moved token's index

        // This also deletes the contents at the last position of the array
        delete _allTokensIndex[tokenId];
        _allTokens.pop();
    }
}

File 5 of 13 : Context.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

/**
 * @dev Provides information about the current execution context, including the
 * sender of the transaction and its data. While these are generally available
 * via msg.sender and msg.data, they should not be accessed in such a direct
 * manner, since when dealing with meta-transactions the account sending and
 * paying for execution may not be the actual sender (as far as an application
 * is concerned).
 *
 * This contract is only required for intermediate, library-like contracts.
 */
abstract contract Context {
    function _msgSender() internal view virtual returns (address) {
        return msg.sender;
    }

    function _msgData() internal view virtual returns (bytes calldata) {
        return msg.data;
    }
}

File 6 of 13 : IERC721.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

import "../../utils/introspection/IERC165.sol";

/**
 * @dev Required interface of an ERC721 compliant contract.
 */
interface IERC721 is IERC165 {
    /**
     * @dev Emitted when `tokenId` token is transferred from `from` to `to`.
     */
    event Transfer(address indexed from, address indexed to, uint256 indexed tokenId);

    /**
     * @dev Emitted when `owner` enables `approved` to manage the `tokenId` token.
     */
    event Approval(address indexed owner, address indexed approved, uint256 indexed tokenId);

    /**
     * @dev Emitted when `owner` enables or disables (`approved`) `operator` to manage all of its assets.
     */
    event ApprovalForAll(address indexed owner, address indexed operator, bool approved);

    /**
     * @dev Returns the number of tokens in ``owner``'s account.
     */
    function balanceOf(address owner) external view returns (uint256 balance);

    /**
     * @dev Returns the owner of the `tokenId` token.
     *
     * Requirements:
     *
     * - `tokenId` must exist.
     */
    function ownerOf(uint256 tokenId) external view returns (address owner);

    /**
     * @dev Safely transfers `tokenId` token from `from` to `to`, checking first that contract recipients
     * are aware of the ERC721 protocol to prevent tokens from being forever locked.
     *
     * Requirements:
     *
     * - `from` cannot be the zero address.
     * - `to` cannot be the zero address.
     * - `tokenId` token must exist and be owned by `from`.
     * - If the caller is not `from`, it must be have been allowed to move this token by either {approve} or {setApprovalForAll}.
     * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer.
     *
     * Emits a {Transfer} event.
     */
    function safeTransferFrom(
        address from,
        address to,
        uint256 tokenId
    ) external;

    /**
     * @dev Transfers `tokenId` token from `from` to `to`.
     *
     * WARNING: Usage of this method is discouraged, use {safeTransferFrom} whenever possible.
     *
     * Requirements:
     *
     * - `from` cannot be the zero address.
     * - `to` cannot be the zero address.
     * - `tokenId` token must be owned by `from`.
     * - If the caller is not `from`, it must be approved to move this token by either {approve} or {setApprovalForAll}.
     *
     * Emits a {Transfer} event.
     */
    function transferFrom(
        address from,
        address to,
        uint256 tokenId
    ) external;

    /**
     * @dev Gives permission to `to` to transfer `tokenId` token to another account.
     * The approval is cleared when the token is transferred.
     *
     * Only a single account can be approved at a time, so approving the zero address clears previous approvals.
     *
     * Requirements:
     *
     * - The caller must own the token or be an approved operator.
     * - `tokenId` must exist.
     *
     * Emits an {Approval} event.
     */
    function approve(address to, uint256 tokenId) external;

    /**
     * @dev Returns the account approved for `tokenId` token.
     *
     * Requirements:
     *
     * - `tokenId` must exist.
     */
    function getApproved(uint256 tokenId) external view returns (address operator);

    /**
     * @dev Approve or remove `operator` as an operator for the caller.
     * Operators can call {transferFrom} or {safeTransferFrom} for any token owned by the caller.
     *
     * Requirements:
     *
     * - The `operator` cannot be the caller.
     *
     * Emits an {ApprovalForAll} event.
     */
    function setApprovalForAll(address operator, bool _approved) external;

    /**
     * @dev Returns if the `operator` is allowed to manage all of the assets of `owner`.
     *
     * See {setApprovalForAll}
     */
    function isApprovedForAll(address owner, address operator) external view returns (bool);

    /**
     * @dev Safely transfers `tokenId` token from `from` to `to`.
     *
     * Requirements:
     *
     * - `from` cannot be the zero address.
     * - `to` cannot be the zero address.
     * - `tokenId` token must exist and be owned by `from`.
     * - If the caller is not `from`, it must be approved to move this token by either {approve} or {setApprovalForAll}.
     * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer.
     *
     * Emits a {Transfer} event.
     */
    function safeTransferFrom(
        address from,
        address to,
        uint256 tokenId,
        bytes calldata data
    ) external;
}

File 7 of 13 : IERC721Receiver.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

/**
 * @title ERC721 token receiver interface
 * @dev Interface for any contract that wants to support safeTransfers
 * from ERC721 asset contracts.
 */
interface IERC721Receiver {
    /**
     * @dev Whenever an {IERC721} `tokenId` token is transferred to this contract via {IERC721-safeTransferFrom}
     * by `operator` from `from`, this function is called.
     *
     * It must return its Solidity selector to confirm the token transfer.
     * If any other value is returned or the interface is not implemented by the recipient, the transfer will be reverted.
     *
     * The selector can be obtained in Solidity with `IERC721.onERC721Received.selector`.
     */
    function onERC721Received(
        address operator,
        address from,
        uint256 tokenId,
        bytes calldata data
    ) external returns (bytes4);
}

File 8 of 13 : IERC721Metadata.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

import "../IERC721.sol";

/**
 * @title ERC-721 Non-Fungible Token Standard, optional metadata extension
 * @dev See https://eips.ethereum.org/EIPS/eip-721
 */
interface IERC721Metadata is IERC721 {
    /**
     * @dev Returns the token collection name.
     */
    function name() external view returns (string memory);

    /**
     * @dev Returns the token collection symbol.
     */
    function symbol() external view returns (string memory);

    /**
     * @dev Returns the Uniform Resource Identifier (URI) for `tokenId` token.
     */
    function tokenURI(uint256 tokenId) external view returns (string memory);
}

File 9 of 13 : Address.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

/**
 * @dev Collection of functions related to the address type
 */
library Address {
    /**
     * @dev Returns true if `account` is a contract.
     *
     * [IMPORTANT]
     * ====
     * It is unsafe to assume that an address for which this function returns
     * false is an externally-owned account (EOA) and not a contract.
     *
     * Among others, `isContract` will return false for the following
     * types of addresses:
     *
     *  - an externally-owned account
     *  - a contract in construction
     *  - an address where a contract will be created
     *  - an address where a contract lived, but was destroyed
     * ====
     */
    function isContract(address account) internal view returns (bool) {
        // This method relies on extcodesize, which returns 0 for contracts in
        // construction, since the code is only stored at the end of the
        // constructor execution.

        uint256 size;
        assembly {
            size := extcodesize(account)
        }
        return size > 0;
    }

    /**
     * @dev Replacement for Solidity's `transfer`: sends `amount` wei to
     * `recipient`, forwarding all available gas and reverting on errors.
     *
     * https://eips.ethereum.org/EIPS/eip-1884[EIP1884] increases the gas cost
     * of certain opcodes, possibly making contracts go over the 2300 gas limit
     * imposed by `transfer`, making them unable to receive funds via
     * `transfer`. {sendValue} removes this limitation.
     *
     * https://diligence.consensys.net/posts/2019/09/stop-using-soliditys-transfer-now/[Learn more].
     *
     * IMPORTANT: because control is transferred to `recipient`, care must be
     * taken to not create reentrancy vulnerabilities. Consider using
     * {ReentrancyGuard} or the
     * https://solidity.readthedocs.io/en/v0.5.11/security-considerations.html#use-the-checks-effects-interactions-pattern[checks-effects-interactions pattern].
     */
    function sendValue(address payable recipient, uint256 amount) internal {
        require(address(this).balance >= amount, "Address: insufficient balance");

        (bool success, ) = recipient.call{value: amount}("");
        require(success, "Address: unable to send value, recipient may have reverted");
    }

    /**
     * @dev Performs a Solidity function call using a low level `call`. A
     * plain `call` is an unsafe replacement for a function call: use this
     * function instead.
     *
     * If `target` reverts with a revert reason, it is bubbled up by this
     * function (like regular Solidity function calls).
     *
     * Returns the raw returned data. To convert to the expected return value,
     * use https://solidity.readthedocs.io/en/latest/units-and-global-variables.html?highlight=abi.decode#abi-encoding-and-decoding-functions[`abi.decode`].
     *
     * Requirements:
     *
     * - `target` must be a contract.
     * - calling `target` with `data` must not revert.
     *
     * _Available since v3.1._
     */
    function functionCall(address target, bytes memory data) internal returns (bytes memory) {
        return functionCall(target, data, "Address: low-level call failed");
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], but with
     * `errorMessage` as a fallback revert reason when `target` reverts.
     *
     * _Available since v3.1._
     */
    function functionCall(
        address target,
        bytes memory data,
        string memory errorMessage
    ) internal returns (bytes memory) {
        return functionCallWithValue(target, data, 0, errorMessage);
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],
     * but also transferring `value` wei to `target`.
     *
     * Requirements:
     *
     * - the calling contract must have an ETH balance of at least `value`.
     * - the called Solidity function must be `payable`.
     *
     * _Available since v3.1._
     */
    function functionCallWithValue(
        address target,
        bytes memory data,
        uint256 value
    ) internal returns (bytes memory) {
        return functionCallWithValue(target, data, value, "Address: low-level call with value failed");
    }

    /**
     * @dev Same as {xref-Address-functionCallWithValue-address-bytes-uint256-}[`functionCallWithValue`], but
     * with `errorMessage` as a fallback revert reason when `target` reverts.
     *
     * _Available since v3.1._
     */
    function functionCallWithValue(
        address target,
        bytes memory data,
        uint256 value,
        string memory errorMessage
    ) internal returns (bytes memory) {
        require(address(this).balance >= value, "Address: insufficient balance for call");
        require(isContract(target), "Address: call to non-contract");

        (bool success, bytes memory returndata) = target.call{value: value}(data);
        return verifyCallResult(success, returndata, errorMessage);
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],
     * but performing a static call.
     *
     * _Available since v3.3._
     */
    function functionStaticCall(address target, bytes memory data) internal view returns (bytes memory) {
        return functionStaticCall(target, data, "Address: low-level static call failed");
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`],
     * but performing a static call.
     *
     * _Available since v3.3._
     */
    function functionStaticCall(
        address target,
        bytes memory data,
        string memory errorMessage
    ) internal view returns (bytes memory) {
        require(isContract(target), "Address: static call to non-contract");

        (bool success, bytes memory returndata) = target.staticcall(data);
        return verifyCallResult(success, returndata, errorMessage);
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],
     * but performing a delegate call.
     *
     * _Available since v3.4._
     */
    function functionDelegateCall(address target, bytes memory data) internal returns (bytes memory) {
        return functionDelegateCall(target, data, "Address: low-level delegate call failed");
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`],
     * but performing a delegate call.
     *
     * _Available since v3.4._
     */
    function functionDelegateCall(
        address target,
        bytes memory data,
        string memory errorMessage
    ) internal returns (bytes memory) {
        require(isContract(target), "Address: delegate call to non-contract");

        (bool success, bytes memory returndata) = target.delegatecall(data);
        return verifyCallResult(success, returndata, errorMessage);
    }

    /**
     * @dev Tool to verifies that a low level call was successful, and revert if it wasn't, either by bubbling the
     * revert reason using the provided one.
     *
     * _Available since v4.3._
     */
    function verifyCallResult(
        bool success,
        bytes memory returndata,
        string memory errorMessage
    ) internal pure returns (bytes memory) {
        if (success) {
            return returndata;
        } else {
            // Look for revert reason and bubble it up if present
            if (returndata.length > 0) {
                // The easiest way to bubble the revert reason is using memory via assembly

                assembly {
                    let returndata_size := mload(returndata)
                    revert(add(32, returndata), returndata_size)
                }
            } else {
                revert(errorMessage);
            }
        }
    }
}

File 10 of 13 : Strings.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

/**
 * @dev String operations.
 */
library Strings {
    bytes16 private constant _HEX_SYMBOLS = "0123456789abcdef";

    /**
     * @dev Converts a `uint256` to its ASCII `string` decimal representation.
     */
    function toString(uint256 value) internal pure returns (string memory) {
        // Inspired by OraclizeAPI's implementation - MIT licence
        // https://github.com/oraclize/ethereum-api/blob/b42146b063c7d6ee1358846c198246239e9360e8/oraclizeAPI_0.4.25.sol

        if (value == 0) {
            return "0";
        }
        uint256 temp = value;
        uint256 digits;
        while (temp != 0) {
            digits++;
            temp /= 10;
        }
        bytes memory buffer = new bytes(digits);
        while (value != 0) {
            digits -= 1;
            buffer[digits] = bytes1(uint8(48 + uint256(value % 10)));
            value /= 10;
        }
        return string(buffer);
    }

    /**
     * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation.
     */
    function toHexString(uint256 value) internal pure returns (string memory) {
        if (value == 0) {
            return "0x00";
        }
        uint256 temp = value;
        uint256 length = 0;
        while (temp != 0) {
            length++;
            temp >>= 8;
        }
        return toHexString(value, length);
    }

    /**
     * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation with fixed length.
     */
    function toHexString(uint256 value, uint256 length) internal pure returns (string memory) {
        bytes memory buffer = new bytes(2 * length + 2);
        buffer[0] = "0";
        buffer[1] = "x";
        for (uint256 i = 2 * length + 1; i > 1; --i) {
            buffer[i] = _HEX_SYMBOLS[value & 0xf];
            value >>= 4;
        }
        require(value == 0, "Strings: hex length insufficient");
        return string(buffer);
    }
}

File 11 of 13 : ERC165.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

import "./IERC165.sol";

/**
 * @dev Implementation of the {IERC165} interface.
 *
 * Contracts that want to implement ERC165 should inherit from this contract and override {supportsInterface} to check
 * for the additional interface id that will be supported. For example:
 *
 * ```solidity
 * function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) {
 *     return interfaceId == type(MyInterface).interfaceId || super.supportsInterface(interfaceId);
 * }
 * ```
 *
 * Alternatively, {ERC165Storage} provides an easier to use but more expensive implementation.
 */
abstract contract ERC165 is IERC165 {
    /**
     * @dev See {IERC165-supportsInterface}.
     */
    function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) {
        return interfaceId == type(IERC165).interfaceId;
    }
}

File 12 of 13 : IERC165.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

/**
 * @dev Interface of the ERC165 standard, as defined in the
 * https://eips.ethereum.org/EIPS/eip-165[EIP].
 *
 * Implementers can declare support of contract interfaces, which can then be
 * queried by others ({ERC165Checker}).
 *
 * For an implementation, see {ERC165}.
 */
interface IERC165 {
    /**
     * @dev Returns true if this contract implements the interface defined by
     * `interfaceId`. See the corresponding
     * https://eips.ethereum.org/EIPS/eip-165#how-interfaces-are-identified[EIP section]
     * to learn more about how these ids are created.
     *
     * This function call must use less than 30 000 gas.
     */
    function supportsInterface(bytes4 interfaceId) external view returns (bool);
}

File 13 of 13 : IERC721Enumerable.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

import "../IERC721.sol";

/**
 * @title ERC-721 Non-Fungible Token Standard, optional enumeration extension
 * @dev See https://eips.ethereum.org/EIPS/eip-721
 */
interface IERC721Enumerable is IERC721 {
    /**
     * @dev Returns the total amount of tokens stored by the contract.
     */
    function totalSupply() external view returns (uint256);

    /**
     * @dev Returns a token ID owned by `owner` at a given `index` of its token list.
     * Use along with {balanceOf} to enumerate all of ``owner``'s tokens.
     */
    function tokenOfOwnerByIndex(address owner, uint256 index) external view returns (uint256 tokenId);

    /**
     * @dev Returns a token ID at a given `index` of all the tokens stored by the contract.
     * Use along with {totalSupply} to enumerate all tokens.
     */
    function tokenByIndex(uint256 index) external view returns (uint256);
}

Settings
{
  "optimizer": {
    "enabled": true,
    "runs": 200
  },
  "outputSelection": {
    "*": {
      "*": [
        "evm.bytecode",
        "evm.deployedBytecode",
        "devdoc",
        "userdoc",
        "metadata",
        "abi"
      ]
    }
  },
  "libraries": {}
}

Contract Security Audit

Contract ABI

[{"inputs":[],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"approved","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"Approval","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"operator","type":"address"},{"indexed":false,"internalType":"bool","name":"approved","type":"bool"}],"name":"ApprovalForAll","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"edition","type":"uint256"}],"name":"EditionTransferable","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"},{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":false,"internalType":"string","name":"imbuement","type":"string"}],"name":"Imbued","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"Transfer","type":"event"},{"inputs":[],"name":"EDITION_SIZE","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NUM_EDITIONS","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"approve","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"baseURI","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"dataContract","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"editionTransferable","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"getApproved","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"}],"name":"id2provenance","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"address","name":"","type":"address"}],"name":"idAndOwner2imbuement","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"string","name":"imbuement","type":"string"}],"name":"imbue","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"uint256","name":"start","type":"uint256"},{"internalType":"uint256","name":"end","type":"uint256"}],"name":"imbuements","outputs":[{"internalType":"string[]","name":"","type":"string[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"operator","type":"address"}],"name":"isApprovedForAll","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"recipient","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"mint","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"mintContract","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"ownerOf","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"uint256","name":"start","type":"uint256"},{"internalType":"uint256","name":"end","type":"uint256"}],"name":"provenance","outputs":[{"internalType":"address[]","name":"","type":"address[]"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"bytes","name":"_data","type":"bytes"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"operator","type":"address"},{"internalType":"bool","name":"approved","type":"bool"}],"name":"setApprovalForAll","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"string","name":"newBaseURI","type":"string"}],"name":"setBaseURI","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_dataContract","type":"address"}],"name":"setDataContract","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"edition","type":"uint256"}],"name":"setEditionTransferable","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_mintContract","type":"address"}],"name":"setMintContract","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes4","name":"interfaceId","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"index","type":"uint256"}],"name":"tokenByIndex","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"uint256","name":"index","type":"uint256"}],"name":"tokenOfOwnerByIndex","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"tokenURI","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"transferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"}]

600760808181526101806040529060a060e080368337505081516200002c92600d9250602001906200014b565b5060405180606001604052806024815260200162002b0a6024913980516200005d91600e91602090910190620001f7565b503480156200006b57600080fd5b50604080518082018252600a815269125b589d595908105c9d60b21b60208083019182528351808501909452600684526512535095515160d21b908401528151919291620000bc91600091620001f7565b508051620000d2906001906020840190620001f7565b505050620000ef620000e9620000f560201b60201c565b620000f9565b620002c8565b3390565b600a80546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b82805482825590600052602060002090601f01602090048101928215620001e55791602002820160005b83821115620001b457835183826101000a81548160ff021916908315150217905550926020019260010160208160000104928301926001030262000175565b8015620001e35782816101000a81549060ff0219169055600101602081600001049283019260010302620001b4565b505b50620001f392915062000274565b5090565b82805462000205906200028b565b90600052602060002090601f016020900481019282620002295760008555620001e5565b82601f106200024457805160ff1916838001178555620001e5565b82800160010185558215620001e5579182015b82811115620001e557825182559160200191906001019062000257565b5b80821115620001f3576000815560010162000275565b600181811c90821680620002a057607f821691505b60208210811415620002c257634e487b7160e01b600052602260045260246000fd5b50919050565b61283280620002d86000396000f3fe608060405234801561001057600080fd5b50600436106102115760003560e01c806366a865ef11610125578063b88d4fde116100ad578063e441b8881161007c578063e441b88814610447578063e985e9c51461045a578063f2fde38b14610496578063f6174515146104a9578063fa8f6e28146104c957600080fd5b8063b88d4fde146103fb578063c87b56dd1461040e578063d0b6b6db14610421578063d8698df11461043457600080fd5b80637943a8b6116100f45780637943a8b6146103a95780638da5cb5b146103bc5780638fe3c404146103cd57806395d89b41146103e0578063a22cb465146103e857600080fd5b806366a865ef1461037e5780636c0360eb1461038657806370a082311461038e578063715018a6146103a157600080fd5b806323b872dd116101a857806342842e0e1161017757806342842e0e1461031f5780634f6ccce71461033257806355f804b3146103455780635fb64a6a146103585780636352211e1461036b57600080fd5b806323b872dd146102de5780632bdcbd7d146102f15780632f745c59146102f957806340c10f191461030c57600080fd5b8063095ea7b3116101e4578063095ea7b3146102935780630d668818146102a65780630e1d5554146102b957806318160ddd146102cc57600080fd5b806301ffc9a71461021657806303959bb71461023e57806306fdde0314610253578063081812fc14610268575b600080fd5b6102296102243660046121fa565b6104e9565b60405190151581526020015b60405180910390f35b61025161024c36600461208e565b610514565b005b61025b610569565b6040516102359190612595565b61027b61027636600461227d565b6105fb565b6040516001600160a01b039091168152602001610235565b6102516102a13660046121d0565b610690565b600c5461027b906001600160a01b031681565b6102516102c73660046122b9565b6107a6565b6008545b604051908152602001610235565b6102516102ec3660046120dc565b610970565b6102d0606481565b6102d06103073660046121d0565b6109a1565b61025161031a3660046121d0565b610a37565b61025161032d3660046120dc565b610b27565b6102d061034036600461227d565b610b42565b610251610353366004612234565b610bd5565b61025161036636600461208e565b610c12565b61027b61037936600461227d565b610c5e565b6102d0600781565b61025b610cd5565b6102d061039c36600461208e565b610d63565b610251610dea565b6102296103b736600461227d565b610e20565b600a546001600160a01b031661027b565b6102516103db36600461227d565b610e54565b61025b610eec565b6102516103f6366004612194565b610efb565b610251610409366004612118565b610fc0565b61025b61041c36600461227d565b610ff8565b600b5461027b906001600160a01b031681565b61027b610442366004612335565b6110d3565b61025b610455366004612296565b61110b565b6102296104683660046120a9565b6001600160a01b03918216600090815260056020908152604080832093909416825291909152205460ff1690565b6102516104a436600461208e565b61112f565b6104bc6104b7366004612357565b6111ca565b6040516102359190612504565b6104dc6104d7366004612357565b61135d565b60405161023591906124b7565b60006001600160e01b0319821663780e9d6360e01b148061050e575061050e82611442565b92915050565b600a546001600160a01b031633146105475760405162461bcd60e51b815260040161053e906125fa565b60405180910390fd5b600c80546001600160a01b0319166001600160a01b0392909216919091179055565b6060600080546105789061270e565b80601f01602080910402602001604051908101604052809291908181526020018280546105a49061270e565b80156105f15780601f106105c6576101008083540402835291602001916105f1565b820191906000526020600020905b8154815290600101906020018083116105d457829003601f168201915b5050505050905090565b6000818152600260205260408120546001600160a01b03166106745760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a20617070726f76656420717565727920666f72206e6f6e657860448201526b34b9ba32b73a103a37b5b2b760a11b606482015260840161053e565b506000908152600460205260409020546001600160a01b031690565b600061069b82610c5e565b9050806001600160a01b0316836001600160a01b031614156107095760405162461bcd60e51b815260206004820152602160248201527f4552433732313a20617070726f76616c20746f2063757272656e74206f776e656044820152603960f91b606482015260840161053e565b336001600160a01b038216148061072557506107258133610468565b6107975760405162461bcd60e51b815260206004820152603860248201527f4552433732313a20617070726f76652063616c6c6572206973206e6f74206f7760448201527f6e6572206e6f7220617070726f76656420666f7220616c6c0000000000000000606482015260840161053e565b6107a18383611492565b505050565b6107b03384611500565b6107fc5760405162461bcd60e51b815260206004820181905260248201527f43616e206f6e6c7920696d62756520746f6b656e20796f7520636f6e74726f6c604482015260640161053e565b60208111156108465760405162461bcd60e51b815260206004820152601660248201527527b7363c90199910313cba32b99030b63637bbb2b21760511b604482015260640161053e565b600061085184610c5e565b60008581526010602090815260408083206001600160a01b03851684528252808320815193845291830180825283519020939450909291610894918491016123de565b60405160208183030381529060405280519060200120146108f75760405162461bcd60e51b815260206004820181905260248201527f4f6e6520696d62756d656e742070657220746f6b656e20616e64206f776e6572604482015260640161053e565b60008581526010602090815260408083206001600160a01b03861684529091529020610924908585611eef565b50816001600160a01b0316857f21671d7ca67eaa0d90e51a66d5258244d86faba179340c1eb104f6cc9dcafa7c8686604051610961929190612566565b60405180910390a35050505050565b61097a3382611500565b6109965760405162461bcd60e51b815260040161053e9061262f565b6107a18383836115f7565b60006109ac83610d63565b8210610a0e5760405162461bcd60e51b815260206004820152602b60248201527f455243373231456e756d657261626c653a206f776e657220696e646578206f7560448201526a74206f6620626f756e647360a81b606482015260840161053e565b506001600160a01b03919091166000908152600660209081526040808320938352929052205490565b600b546001600160a01b03163314610a915760405162461bcd60e51b815260206004820152601f60248201527f4f6e6c7920746865206d696e7420636f6e74726163742063616e206d696e7400604482015260640161053e565b610a9d606460076126ac565b8110610ae25760405162461bcd60e51b81526020600482015260146024820152730a8ded6cadc40928840d2e640e8dede40d0d2ced60631b604482015260640161053e565b6000818152600f602090815260408220805460018101825590835291200180546001600160a01b0319166001600160a01b038416179055610b2382826116c2565b5050565b6107a183838360405180602001604052806000815250610fc0565b6000610b4d60085490565b8210610bb05760405162461bcd60e51b815260206004820152602c60248201527f455243373231456e756d657261626c653a20676c6f62616c20696e646578206f60448201526b7574206f6620626f756e647360a01b606482015260840161053e565b60088281548110610bc357610bc36127ba565b90600052602060002001549050919050565b600a546001600160a01b03163314610bff5760405162461bcd60e51b815260040161053e906125fa565b8051610b2390600e906020840190611f73565b600a546001600160a01b03163314610c3c5760405162461bcd60e51b815260040161053e906125fa565b600b80546001600160a01b0319166001600160a01b0392909216919091179055565b6000818152600260205260408120546001600160a01b03168061050e5760405162461bcd60e51b815260206004820152602960248201527f4552433732313a206f776e657220717565727920666f72206e6f6e657869737460448201526832b73a103a37b5b2b760b91b606482015260840161053e565b600e8054610ce29061270e565b80601f0160208091040260200160405190810160405280929190818152602001828054610d0e9061270e565b8015610d5b5780601f10610d3057610100808354040283529160200191610d5b565b820191906000526020600020905b815481529060010190602001808311610d3e57829003601f168201915b505050505081565b60006001600160a01b038216610dce5760405162461bcd60e51b815260206004820152602a60248201527f4552433732313a2062616c616e636520717565727920666f7220746865207a65604482015269726f206164647265737360b01b606482015260840161053e565b506001600160a01b031660009081526003602052604090205490565b600a546001600160a01b03163314610e145760405162461bcd60e51b815260040161053e906125fa565b610e1e60006116dc565b565b600d8181548110610e3057600080fd5b9060005260206000209060209182820401919006915054906101000a900460ff1681565b600a546001600160a01b03163314610e7e5760405162461bcd60e51b815260040161053e906125fa565b6001600d8281548110610e9357610e936127ba565b90600052602060002090602091828204019190066101000a81548160ff021916908315150217905550807f3038fa8dd54e5895751b7c858d22cc6f7030b03389b109a24855832a09748dad60405160405180910390a250565b6060600180546105789061270e565b6001600160a01b038216331415610f545760405162461bcd60e51b815260206004820152601960248201527f4552433732313a20617070726f766520746f2063616c6c657200000000000000604482015260640161053e565b3360008181526005602090815260408083206001600160a01b03871680855290835292819020805460ff191686151590811790915590519081529192917f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a35050565b610fca3383611500565b610fe65760405162461bcd60e51b815260040161053e9061262f565b610ff28484848461172e565b50505050565b6000818152600260205260409020546060906001600160a01b03166110775760405162461bcd60e51b815260206004820152602f60248201527f4552433732314d657461646174613a2055524920717565727920666f72206e6f60448201526e3732bc34b9ba32b73a103a37b5b2b760891b606482015260840161053e565b6000611081611761565b905060008151116110a157604051806020016040528060008152506110cc565b806110ab84611770565b6040516020016110bc9291906123af565b6040516020818303038152906040525b9392505050565b600f60205281600052604060002081815481106110ef57600080fd5b6000918252602090912001546001600160a01b03169150829050565b601060209081526000928352604080842090915290825290208054610ce29061270e565b600a546001600160a01b031633146111595760405162461bcd60e51b815260040161053e906125fa565b6001600160a01b0381166111be5760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b606482015260840161053e565b6111c7816116dc565b50565b6000838152600f6020526040812060609190836111e657805493505b60006111f286866126cb565b67ffffffffffffffff81111561120a5761120a6127d0565b60405190808252806020026020018201604052801561123d57816020015b60608152602001906001900390816112285790505b509050855b858110156113525782818154811061125c5761125c6127ba565b60009182526020808320909101548a83526010825260408084206001600160a01b039092168085529190925291208054919550906112999061270e565b80601f01602080910402602001604051908101604052809291908181526020018280546112c59061270e565b80156113125780601f106112e757610100808354040283529160200191611312565b820191906000526020600020905b8154815290600101906020018083116112f557829003601f168201915b505050505082888361132491906126cb565b81518110611334576113346127ba565b6020026020010181905250808061134a90612749565b915050611242565b509695505050505050565b6000838152600f60205260408120606091908361137957805493505b600061138586866126cb565b67ffffffffffffffff81111561139d5761139d6127d0565b6040519080825280602002602001820160405280156113c6578160200160208202803683370190505b509050855b85811015611352578281815481106113e5576113e56127ba565b6000918252602090912001546001600160a01b03169350838261140889846126cb565b81518110611418576114186127ba565b6001600160a01b03909216602092830291909101909101528061143a81612749565b9150506113cb565b60006001600160e01b031982166380ac58cd60e01b148061147357506001600160e01b03198216635b5e139f60e01b145b8061050e57506301ffc9a760e01b6001600160e01b031983161461050e565b600081815260046020526040902080546001600160a01b0319166001600160a01b03841690811790915581906114c782610c5e565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45050565b6000818152600260205260408120546001600160a01b03166115795760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a206f70657261746f7220717565727920666f72206e6f6e657860448201526b34b9ba32b73a103a37b5b2b760a11b606482015260840161053e565b600061158483610c5e565b9050806001600160a01b0316846001600160a01b031614806115bf5750836001600160a01b03166115b4846105fb565b6001600160a01b0316145b806115ef57506001600160a01b0380821660009081526005602090815260408083209388168352929052205460ff165b949350505050565b600d611604606483612698565b81548110611614576116146127ba565b90600052602060002090602091828204019190069054906101000a900460ff166116805760405162461bcd60e51b815260206004820152601b60248201527f45646974696f6e207472616e73666572206e6f74206163746976650000000000604482015260640161053e565b6000818152600f602090815260408220805460018101825590835291200180546001600160a01b0319166001600160a01b0384161790556107a183838361186e565b610b23828260405180602001604052806000815250611a19565b600a80546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b6117398484846115f7565b61174584848484611a4c565b610ff25760405162461bcd60e51b815260040161053e906125a8565b6060600e80546105789061270e565b6060816117945750506040805180820190915260018152600360fc1b602082015290565b8160005b81156117be57806117a881612749565b91506117b79050600a83612698565b9150611798565b60008167ffffffffffffffff8111156117d9576117d96127d0565b6040519080825280601f01601f191660200182016040528015611803576020820181803683370190505b5090505b84156115ef576118186001836126cb565b9150611825600a86612764565b611830906030612680565b60f81b818381518110611845576118456127ba565b60200101906001600160f81b031916908160001a905350611867600a86612698565b9450611807565b826001600160a01b031661188182610c5e565b6001600160a01b0316146118e95760405162461bcd60e51b815260206004820152602960248201527f4552433732313a207472616e73666572206f6620746f6b656e2074686174206960448201526839903737ba1037bbb760b91b606482015260840161053e565b6001600160a01b03821661194b5760405162461bcd60e51b8152602060048201526024808201527f4552433732313a207472616e7366657220746f20746865207a65726f206164646044820152637265737360e01b606482015260840161053e565b611956838383611b59565b611961600082611492565b6001600160a01b038316600090815260036020526040812080546001929061198a9084906126cb565b90915550506001600160a01b03821660009081526003602052604081208054600192906119b8908490612680565b909155505060008181526002602052604080822080546001600160a01b0319166001600160a01b0386811691821790925591518493918716917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef91a4505050565b611a238383611c11565b611a306000848484611a4c565b6107a15760405162461bcd60e51b815260040161053e906125a8565b60006001600160a01b0384163b15611b4e57604051630a85bd0160e11b81526001600160a01b0385169063150b7a0290611a9090339089908890889060040161247a565b602060405180830381600087803b158015611aaa57600080fd5b505af1925050508015611ada575060408051601f3d908101601f19168201909252611ad791810190612217565b60015b611b34573d808015611b08576040519150601f19603f3d011682016040523d82523d6000602084013e611b0d565b606091505b508051611b2c5760405162461bcd60e51b815260040161053e906125a8565b805181602001fd5b6001600160e01b031916630a85bd0160e11b1490506115ef565b506001949350505050565b6001600160a01b038316611bb457611baf81600880546000838152600960205260408120829055600182018355919091527ff3f7a9fe364faab93b216da50a3214154f22a0a2b415b23a84c8169e8b636ee30155565b611bd7565b816001600160a01b0316836001600160a01b031614611bd757611bd78382611d5f565b6001600160a01b038216611bee576107a181611dfc565b826001600160a01b0316826001600160a01b0316146107a1576107a18282611eab565b6001600160a01b038216611c675760405162461bcd60e51b815260206004820181905260248201527f4552433732313a206d696e7420746f20746865207a65726f2061646472657373604482015260640161053e565b6000818152600260205260409020546001600160a01b031615611ccc5760405162461bcd60e51b815260206004820152601c60248201527f4552433732313a20746f6b656e20616c7265616479206d696e74656400000000604482015260640161053e565b611cd860008383611b59565b6001600160a01b0382166000908152600360205260408120805460019290611d01908490612680565b909155505060008181526002602052604080822080546001600160a01b0319166001600160a01b03861690811790915590518392907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a45050565b60006001611d6c84610d63565b611d7691906126cb565b600083815260076020526040902054909150808214611dc9576001600160a01b03841660009081526006602090815260408083208584528252808320548484528184208190558352600790915290208190555b5060009182526007602090815260408084208490556001600160a01b039094168352600681528383209183525290812055565b600854600090611e0e906001906126cb565b60008381526009602052604081205460088054939450909284908110611e3657611e366127ba565b906000526020600020015490508060088381548110611e5757611e576127ba565b6000918252602080832090910192909255828152600990915260408082208490558582528120556008805480611e8f57611e8f6127a4565b6001900381819060005260206000200160009055905550505050565b6000611eb683610d63565b6001600160a01b039093166000908152600660209081526040808320868452825280832085905593825260079052919091209190915550565b828054611efb9061270e565b90600052602060002090601f016020900481019282611f1d5760008555611f63565b82601f10611f365782800160ff19823516178555611f63565b82800160010185558215611f63579182015b82811115611f63578235825591602001919060010190611f48565b50611f6f929150611fe7565b5090565b828054611f7f9061270e565b90600052602060002090601f016020900481019282611fa15760008555611f63565b82601f10611fba57805160ff1916838001178555611f63565b82800160010185558215611f63579182015b82811115611f63578251825591602001919060010190611fcc565b5b80821115611f6f5760008155600101611fe8565b600067ffffffffffffffff80841115612017576120176127d0565b604051601f8501601f19908116603f0116810190828211818310171561203f5761203f6127d0565b8160405280935085815286868601111561205857600080fd5b858560208301376000602087830101525050509392505050565b80356001600160a01b038116811461208957600080fd5b919050565b6000602082840312156120a057600080fd5b6110cc82612072565b600080604083850312156120bc57600080fd5b6120c583612072565b91506120d360208401612072565b90509250929050565b6000806000606084860312156120f157600080fd5b6120fa84612072565b925061210860208501612072565b9150604084013590509250925092565b6000806000806080858703121561212e57600080fd5b61213785612072565b935061214560208601612072565b925060408501359150606085013567ffffffffffffffff81111561216857600080fd5b8501601f8101871361217957600080fd5b61218887823560208401611ffc565b91505092959194509250565b600080604083850312156121a757600080fd5b6121b083612072565b9150602083013580151581146121c557600080fd5b809150509250929050565b600080604083850312156121e357600080fd5b6121ec83612072565b946020939093013593505050565b60006020828403121561220c57600080fd5b81356110cc816127e6565b60006020828403121561222957600080fd5b81516110cc816127e6565b60006020828403121561224657600080fd5b813567ffffffffffffffff81111561225d57600080fd5b8201601f8101841361226e57600080fd5b6115ef84823560208401611ffc565b60006020828403121561228f57600080fd5b5035919050565b600080604083850312156122a957600080fd5b823591506120d360208401612072565b6000806000604084860312156122ce57600080fd5b83359250602084013567ffffffffffffffff808211156122ed57600080fd5b818601915086601f83011261230157600080fd5b81358181111561231057600080fd5b87602082850101111561232257600080fd5b6020830194508093505050509250925092565b6000806040838503121561234857600080fd5b50508035926020909101359150565b60008060006060848603121561236c57600080fd5b505081359360208301359350604090920135919050565b6000815180845261239b8160208601602086016126e2565b601f01601f19169290920160200192915050565b600083516123c18184602088016126e2565b8351908301906123d58183602088016126e2565b01949350505050565b600080835481600182811c9150808316806123fa57607f831692505b602080841082141561241a57634e487b7160e01b86526022600452602486fd5b81801561242e576001811461243f5761246c565b60ff1986168952848901965061246c565b60008a81526020902060005b868110156124645781548b82015290850190830161244b565b505084890196505b509498975050505050505050565b6001600160a01b03858116825284166020820152604081018390526080606082018190526000906124ad90830184612383565b9695505050505050565b6020808252825182820181905260009190848201906040850190845b818110156124f85783516001600160a01b0316835292840192918401916001016124d3565b50909695505050505050565b6000602080830181845280855180835260408601915060408160051b870101925083870160005b8281101561255957603f19888603018452612547858351612383565b9450928501929085019060010161252b565b5092979650505050505050565b60208152816020820152818360408301376000818301604090810191909152601f909201601f19160101919050565b6020815260006110cc6020830184612383565b60208082526032908201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560408201527131b2b4bb32b91034b6b83632b6b2b73a32b960711b606082015260800190565b6020808252818101527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604082015260600190565b60208082526031908201527f4552433732313a207472616e736665722063616c6c6572206973206e6f74206f6040820152701ddb995c881b9bdc88185c1c1c9bdd9959607a1b606082015260800190565b6000821982111561269357612693612778565b500190565b6000826126a7576126a761278e565b500490565b60008160001904831182151516156126c6576126c6612778565b500290565b6000828210156126dd576126dd612778565b500390565b60005b838110156126fd5781810151838201526020016126e5565b83811115610ff25750506000910152565b600181811c9082168061272257607f821691505b6020821081141561274357634e487b7160e01b600052602260045260246000fd5b50919050565b600060001982141561275d5761275d612778565b5060010190565b6000826127735761277361278e565b500690565b634e487b7160e01b600052601160045260246000fd5b634e487b7160e01b600052601260045260246000fd5b634e487b7160e01b600052603160045260246000fd5b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052604160045260246000fd5b6001600160e01b0319811681146111c757600080fdfea2646970667358221220560496dc6aa89de364e47109962e68dfda1a89b15445febb274caf036c77469864736f6c6343000807003368747470733a2f2f6170692e696d627565646172742e636f6d2f6170692f746f6b656e2f

Block Transaction Difficulty Gas Used Reward
Block Uncle Number Difficulty Gas Used Reward
Loading
Loading
Make sure to use the "Vote Down" button for any spammy posts, and the "Vote Up" for interesting conversations.

A contract address hosts a smart contract, which is a set of code stored on the blockchain that runs when predetermined conditions are met. Learn more about addresses in our Knowledge Base.