UNPKG

@vechain/vebetterdao-contracts

Version:

Open-source repository that houses the smart contracts powering the decentralized VeBetterDAO on the VeChain Thor blockchain.

1,704 lines (1,703 loc) 37 kB
{ "_format": "hh-sol-artifact-1", "contractName": "IStargateNFT", "sourceName": "contracts/mocks/Stargate/interfaces/IStargateNFT.sol", "abi": [ { "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": false, "internalType": "string", "name": "oldBaseURI", "type": "string" }, { "indexed": false, "internalType": "string", "name": "newBaseURI", "type": "string" } ], "name": "BaseURIUpdated", "type": "event" }, { "anonymous": false, "inputs": [ { "indexed": true, "internalType": "address", "name": "owner", "type": "address" }, { "indexed": true, "internalType": "uint256", "name": "tokenId", "type": "uint256" }, { "indexed": false, "internalType": "uint256", "name": "amount", "type": "uint256" } ], "name": "BaseVTHORewardsClaimed", "type": "event" }, { "anonymous": false, "inputs": [ { "indexed": true, "internalType": "uint8", "name": "levelId", "type": "uint8" }, { "indexed": false, "internalType": "uint256", "name": "oldBoostPricePerBlock", "type": "uint256" }, { "indexed": false, "internalType": "uint256", "name": "newBoostPricePerBlock", "type": "uint256" } ], "name": "LevelBoostPricePerBlockUpdated", "type": "event" }, { "anonymous": false, "inputs": [ { "indexed": true, "internalType": "uint8", "name": "levelId", "type": "uint8" }, { "indexed": false, "internalType": "uint32", "name": "oldCap", "type": "uint32" }, { "indexed": false, "internalType": "uint32", "name": "newCap", "type": "uint32" } ], "name": "LevelCapUpdated", "type": "event" }, { "anonymous": false, "inputs": [ { "indexed": true, "internalType": "uint8", "name": "levelId", "type": "uint8" }, { "indexed": false, "internalType": "uint208", "name": "oldCirculatingSupply", "type": "uint208" }, { "indexed": false, "internalType": "uint208", "name": "newCirculatingSupply", "type": "uint208" } ], "name": "LevelCirculatingSupplyUpdated", "type": "event" }, { "anonymous": false, "inputs": [ { "indexed": true, "internalType": "uint8", "name": "levelId", "type": "uint8" }, { "indexed": false, "internalType": "string", "name": "name", "type": "string" }, { "indexed": false, "internalType": "bool", "name": "isX", "type": "bool" }, { "indexed": false, "internalType": "uint64", "name": "maturityBlocks", "type": "uint64" }, { "indexed": false, "internalType": "uint64", "name": "scaledRewardFactor", "type": "uint64" }, { "indexed": false, "internalType": "uint256", "name": "vetAmountRequiredToStake", "type": "uint256" } ], "name": "LevelUpdated", "type": "event" }, { "anonymous": false, "inputs": [ { "indexed": true, "internalType": "address", "name": "owner", "type": "address" }, { "indexed": true, "internalType": "uint8", "name": "levelId", "type": "uint8" }, { "indexed": false, "internalType": "uint256", "name": "tokenId", "type": "uint256" }, { "indexed": false, "internalType": "uint256", "name": "vetAmountStaked", "type": "uint256" } ], "name": "TokenBurned", "type": "event" }, { "anonymous": false, "inputs": [ { "indexed": true, "internalType": "uint256", "name": "tokenId", "type": "uint256" }, { "indexed": true, "internalType": "address", "name": "manager", "type": "address" } ], "name": "TokenManagerAdded", "type": "event" }, { "anonymous": false, "inputs": [ { "indexed": true, "internalType": "uint256", "name": "tokenId", "type": "uint256" }, { "indexed": true, "internalType": "address", "name": "manager", "type": "address" } ], "name": "TokenManagerRemoved", "type": "event" }, { "anonymous": false, "inputs": [ { "indexed": true, "internalType": "address", "name": "owner", "type": "address" }, { "indexed": true, "internalType": "uint8", "name": "levelId", "type": "uint8" }, { "indexed": true, "internalType": "bool", "name": "migrated", "type": "bool" }, { "indexed": false, "internalType": "uint256", "name": "tokenId", "type": "uint256" }, { "indexed": false, "internalType": "uint256", "name": "vetAmountStaked", "type": "uint256" } ], "name": "TokenMinted", "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" }, { "anonymous": false, "inputs": [ { "indexed": false, "internalType": "uint48", "name": "oldVthoGenerationEndTimestamp", "type": "uint48" }, { "indexed": false, "internalType": "uint48", "name": "newVthoGenerationEndTimestamp", "type": "uint48" } ], "name": "VthoGenerationEndTimestampSet", "type": "event" }, { "anonymous": false, "inputs": [ { "indexed": false, "internalType": "address", "name": "owner", "type": "address" } ], "name": "WhitelistEntryRemoved", "type": "event" }, { "inputs": [], "name": "CLOCK_MODE", "outputs": [ { "internalType": "string", "name": "", "type": "string" } ], "stateMutability": "view", "type": "function" }, { "inputs": [ { "internalType": "uint256", "name": "tokenId", "type": "uint256" } ], "name": "_burnCallback", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [ { "internalType": "address", "name": "to", "type": "address" }, { "internalType": "uint256", "name": "tokenId", "type": "uint256" } ], "name": "_safeMintCallback", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [ { "components": [ { "components": [ { "internalType": "string", "name": "name", "type": "string" }, { "internalType": "bool", "name": "isX", "type": "bool" }, { "internalType": "uint8", "name": "id", "type": "uint8" }, { "internalType": "uint64", "name": "maturityBlocks", "type": "uint64" }, { "internalType": "uint64", "name": "scaledRewardFactor", "type": "uint64" }, { "internalType": "uint256", "name": "vetAmountRequiredToStake", "type": "uint256" } ], "internalType": "struct DataTypes.Level", "name": "level", "type": "tuple" }, { "internalType": "uint208", "name": "circulatingSupply", "type": "uint208" }, { "internalType": "uint32", "name": "cap", "type": "uint32" } ], "internalType": "struct DataTypes.LevelAndSupply", "name": "_levelAndSupply", "type": "tuple" } ], "name": "addLevel", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [ { "internalType": "address", "name": "_manager", "type": "address" }, { "internalType": "uint256", "name": "_tokenId", "type": "uint256" } ], "name": "addTokenManager", "outputs": [], "stateMutability": "nonpayable", "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": "balance", "type": "uint256" } ], "stateMutability": "view", "type": "function" }, { "inputs": [], "name": "baseURI", "outputs": [ { "internalType": "string", "name": "", "type": "string" } ], "stateMutability": "view", "type": "function" }, { "inputs": [ { "internalType": "uint256", "name": "_tokenId", "type": "uint256" } ], "name": "boost", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [ { "internalType": "uint256", "name": "_tokenId", "type": "uint256" } ], "name": "boostAmount", "outputs": [ { "internalType": "uint256", "name": "", "type": "uint256" } ], "stateMutability": "view", "type": "function" }, { "inputs": [ { "internalType": "uint8", "name": "_levelId", "type": "uint8" } ], "name": "boostAmountOfLevel", "outputs": [ { "internalType": "uint256", "name": "", "type": "uint256" } ], "stateMutability": "view", "type": "function" }, { "inputs": [ { "internalType": "address", "name": "_sender", "type": "address" }, { "internalType": "uint256", "name": "_tokenId", "type": "uint256" } ], "name": "boostOnBehalfOf", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [ { "internalType": "uint8", "name": "_levelId", "type": "uint8" } ], "name": "boostPricePerBlock", "outputs": [ { "internalType": "uint256", "name": "", "type": "uint256" } ], "stateMutability": "view", "type": "function" }, { "inputs": [ { "internalType": "uint256", "name": "_tokenId", "type": "uint256" } ], "name": "burn", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [], "name": "clock", "outputs": [ { "internalType": "uint48", "name": "", "type": "uint48" } ], "stateMutability": "view", "type": "function" }, { "inputs": [ { "internalType": "uint256", "name": "tokenId", "type": "uint256" } ], "name": "getApproved", "outputs": [ { "internalType": "address", "name": "operator", "type": "address" } ], "stateMutability": "view", "type": "function" }, { "inputs": [ { "internalType": "uint8", "name": "_levelId", "type": "uint8" }, { "internalType": "uint48", "name": "_blockNumber", "type": "uint48" } ], "name": "getCirculatingSupplyAtBlock", "outputs": [ { "internalType": "uint208", "name": "", "type": "uint208" } ], "stateMutability": "view", "type": "function" }, { "inputs": [], "name": "getCurrentTokenId", "outputs": [ { "internalType": "uint256", "name": "", "type": "uint256" } ], "stateMutability": "view", "type": "function" }, { "inputs": [ { "internalType": "uint8", "name": "_levelId", "type": "uint8" } ], "name": "getLevel", "outputs": [ { "components": [ { "internalType": "string", "name": "name", "type": "string" }, { "internalType": "bool", "name": "isX", "type": "bool" }, { "internalType": "uint8", "name": "id", "type": "uint8" }, { "internalType": "uint64", "name": "maturityBlocks", "type": "uint64" }, { "internalType": "uint64", "name": "scaledRewardFactor", "type": "uint64" }, { "internalType": "uint256", "name": "vetAmountRequiredToStake", "type": "uint256" } ], "internalType": "struct DataTypes.Level", "name": "", "type": "tuple" } ], "stateMutability": "view", "type": "function" }, { "inputs": [], "name": "getLevelIds", "outputs": [ { "internalType": "uint8[]", "name": "", "type": "uint8[]" } ], "stateMutability": "view", "type": "function" }, { "inputs": [ { "internalType": "uint8", "name": "_levelId", "type": "uint8" } ], "name": "getLevelSupply", "outputs": [ { "internalType": "uint208", "name": "circulating", "type": "uint208" }, { "internalType": "uint32", "name": "cap", "type": "uint32" } ], "stateMutability": "view", "type": "function" }, { "inputs": [], "name": "getLevels", "outputs": [ { "components": [ { "internalType": "string", "name": "name", "type": "string" }, { "internalType": "bool", "name": "isX", "type": "bool" }, { "internalType": "uint8", "name": "id", "type": "uint8" }, { "internalType": "uint64", "name": "maturityBlocks", "type": "uint64" }, { "internalType": "uint64", "name": "scaledRewardFactor", "type": "uint64" }, { "internalType": "uint256", "name": "vetAmountRequiredToStake", "type": "uint256" } ], "internalType": "struct DataTypes.Level[]", "name": "", "type": "tuple[]" } ], "stateMutability": "view", "type": "function" }, { "inputs": [], "name": "getLevelsCirculatingSupplies", "outputs": [ { "internalType": "uint208[]", "name": "", "type": "uint208[]" } ], "stateMutability": "view", "type": "function" }, { "inputs": [ { "internalType": "uint48", "name": "_blockNumber", "type": "uint48" } ], "name": "getLevelsCirculatingSuppliesAtBlock", "outputs": [ { "internalType": "uint208[]", "name": "", "type": "uint208[]" } ], "stateMutability": "view", "type": "function" }, { "inputs": [], "name": "getStargate", "outputs": [ { "internalType": "address", "name": "", "type": "address" } ], "stateMutability": "view", "type": "function" }, { "inputs": [ { "internalType": "uint256", "name": "_tokenId", "type": "uint256" } ], "name": "getToken", "outputs": [ { "components": [ { "internalType": "uint256", "name": "tokenId", "type": "uint256" }, { "internalType": "uint8", "name": "levelId", "type": "uint8" }, { "internalType": "uint64", "name": "mintedAtBlock", "type": "uint64" }, { "internalType": "uint256", "name": "vetAmountStaked", "type": "uint256" }, { "internalType": "uint48", "name": "lastVetGeneratedVthoClaimTimestamp_deprecated", "type": "uint48" } ], "internalType": "struct DataTypes.Token", "name": "", "type": "tuple" } ], "stateMutability": "view", "type": "function" }, { "inputs": [ { "internalType": "uint256", "name": "_tokenId", "type": "uint256" } ], "name": "getTokenLevel", "outputs": [ { "internalType": "uint8", "name": "", "type": "uint8" } ], "stateMutability": "view", "type": "function" }, { "inputs": [ { "internalType": "uint256", "name": "_tokenId", "type": "uint256" } ], "name": "getTokenManager", "outputs": [ { "internalType": "address", "name": "", "type": "address" } ], "stateMutability": "view", "type": "function" }, { "inputs": [], "name": "getVthoTokenAddress", "outputs": [ { "internalType": "address", "name": "", "type": "address" } ], "stateMutability": "view", "type": "function" }, { "inputs": [ { "internalType": "address", "name": "_user", "type": "address" } ], "name": "idsManagedBy", "outputs": [ { "internalType": "uint256[]", "name": "", "type": "uint256[]" } ], "stateMutability": "view", "type": "function" }, { "inputs": [ { "internalType": "address", "name": "_owner", "type": "address" } ], "name": "idsOwnedBy", "outputs": [ { "internalType": "uint256[]", "name": "", "type": "uint256[]" } ], "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": "uint256", "name": "_tokenId", "type": "uint256" } ], "name": "isManagedByOwner", "outputs": [ { "internalType": "bool", "name": "", "type": "bool" } ], "stateMutability": "view", "type": "function" }, { "inputs": [ { "internalType": "address", "name": "_manager", "type": "address" }, { "internalType": "uint256", "name": "_tokenId", "type": "uint256" } ], "name": "isTokenManager", "outputs": [ { "internalType": "bool", "name": "", "type": "bool" } ], "stateMutability": "view", "type": "function" }, { "inputs": [ { "internalType": "uint256", "name": "_tokenId", "type": "uint256" } ], "name": "isUnderMaturityPeriod", "outputs": [ { "internalType": "bool", "name": "", "type": "bool" } ], "stateMutability": "view", "type": "function" }, { "inputs": [ { "internalType": "uint256", "name": "_tokenId", "type": "uint256" } ], "name": "isXToken", "outputs": [ { "internalType": "bool", "name": "", "type": "bool" } ], "stateMutability": "view", "type": "function" }, { "inputs": [], "name": "legacyNodes", "outputs": [ { "internalType": "contract ITokenAuction", "name": "", "type": "address" } ], "stateMutability": "view", "type": "function" }, { "inputs": [ { "internalType": "uint256", "name": "_tokenId", "type": "uint256" } ], "name": "maturityPeriodEndBlock", "outputs": [ { "internalType": "uint64", "name": "", "type": "uint64" } ], "stateMutability": "view", "type": "function" }, { "inputs": [ { "internalType": "uint256", "name": "_tokenId", "type": "uint256" } ], "name": "migrate", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [ { "internalType": "uint256", "name": "_tokenId", "type": "uint256" }, { "internalType": "address", "name": "_manager", "type": "address" } ], "name": "migrateTokenManager", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [ { "internalType": "uint8", "name": "_levelId", "type": "uint8" }, { "internalType": "address", "name": "_to", "type": "address" } ], "name": "mint", "outputs": [ { "internalType": "uint256", "name": "tokenId", "type": "uint256" } ], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [ { "internalType": "uint256", "name": "tokenId", "type": "uint256" } ], "name": "ownerOf", "outputs": [ { "internalType": "address", "name": "owner", "type": "address" } ], "stateMutability": "view", "type": "function" }, { "inputs": [ { "internalType": "address", "name": "_owner", "type": "address" } ], "name": "ownerTotalVetStaked", "outputs": [ { "internalType": "uint256", "name": "", "type": "uint256" } ], "stateMutability": "view", "type": "function" }, { "inputs": [ { "internalType": "address", "name": "_owner", "type": "address" } ], "name": "ownsXToken", "outputs": [ { "internalType": "bool", "name": "", "type": "bool" } ], "stateMutability": "view", "type": "function" }, { "inputs": [], "name": "pause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [ { "internalType": "uint256", "name": "_tokenId", "type": "uint256" } ], "name": "removeTokenManager", "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": "_baseTokenURI", "type": "string" } ], "name": "setBaseURI", "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": "timestamp", "outputs": [ { "internalType": "uint48", "name": "", "type": "uint48" } ], "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": "uint256", "name": "_tokenId", "type": "uint256" } ], "name": "tokenExists", "outputs": [ { "internalType": "bool", "name": "", "type": "bool" } ], "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": "address", "name": "_user", "type": "address" } ], "name": "tokensManagedBy", "outputs": [ { "components": [ { "internalType": "uint256", "name": "tokenId", "type": "uint256" }, { "internalType": "uint8", "name": "levelId", "type": "uint8" }, { "internalType": "uint64", "name": "mintedAtBlock", "type": "uint64" }, { "internalType": "uint256", "name": "vetAmountStaked", "type": "uint256" }, { "internalType": "uint48", "name": "lastVetGeneratedVthoClaimTimestamp_deprecated", "type": "uint48" } ], "internalType": "struct DataTypes.Token[]", "name": "", "type": "tuple[]" } ], "stateMutability": "view", "type": "function" }, { "inputs": [ { "internalType": "address", "name": "_user", "type": "address" } ], "name": "tokensOverview", "outputs": [ { "components": [ { "internalType": "uint256", "name": "id", "type": "uint256" }, { "internalType": "address", "name": "owner", "type": "address" }, { "internalType": "address", "name": "manager", "type": "address" }, { "internalType": "uint8", "name": "levelId", "type": "uint8" } ], "internalType": "struct DataTypes.TokenOverview[]", "name": "", "type": "tuple[]" } ], "stateMutability": "view", "type": "function" }, { "inputs": [ { "internalType": "address", "name": "_owner", "type": "address" } ], "name": "tokensOwnedBy", "outputs": [ { "components": [ { "internalType": "uint256", "name": "tokenId", "type": "uint256" }, { "internalType": "uint8", "name": "levelId", "type": "uint8" }, { "internalType": "uint64", "name": "mintedAtBlock", "type": "uint64" }, { "internalType": "uint256", "name": "vetAmountStaked", "type": "uint256" }, { "internalType": "uint48", "name": "lastVetGeneratedVthoClaimTimestamp_deprecated", "type": "uint48" } ], "internalType": "struct DataTypes.Token[]", "name": "", "type": "tuple[]" } ], "stateMutability": "view", "type": "function" }, { "inputs": [], "name": "totalSupply", "outputs": [ { "internalType": "uint256", "name": "", "type": "uint256" } ], "stateMutability": "view", "type": "function" }, { "inputs": [ { "internalType": "uint256", "name": "amount", "type": "uint256" } ], "name": "transferBalance", "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": "transferFrom", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [], "name": "unpause", "outputs": [], "stateMutability": "nonpayable", "type": "function" }, { "inputs": [], "name": "version", "outputs": [ { "internalType": "uint256", "name": "", "type": "uint256" } ], "stateMutability": "view", "type": "function" }, { "inputs": [], "name": "xTokensCount", "outputs": [ { "internalType": "uint208", "name": "", "type": "uint208" } ], "stateMutability": "view", "type": "function" } ], "bytecode": "0x", "deployedBytecode": "0x", "linkReferences": {}, "deployedLinkReferences": {} }