@collabland/staking-contracts
Version:
Staking contracts supported by Collab.Land
448 lines (447 loc) • 11.6 kB
JSON
[
{
"inputs": [
{"internalType": "contract IERC721", "name": "_nft", "type": "address"}
],
"stateMutability": "nonpayable",
"type": "constructor"
},
{
"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": false,
"internalType": "bool",
"name": "notPaused",
"type": "bool"
}
],
"name": "PauseUpdated",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": false,
"internalType": "uint256",
"name": "nextPoolId",
"type": "uint256"
},
{
"indexed": false,
"internalType": "uint256",
"name": "firstTokenAllowed",
"type": "uint256"
},
{
"indexed": false,
"internalType": "uint256",
"name": "limitPool",
"type": "uint256"
},
{
"indexed": false,
"internalType": "uint256",
"name": "costElectricity",
"type": "uint256"
},
{
"indexed": false,
"internalType": "uint256",
"name": "lifeTime",
"type": "uint256"
},
{
"indexed": false,
"internalType": "string",
"name": "typeMachine",
"type": "string"
},
{
"indexed": false,
"internalType": "string",
"name": "area",
"type": "string"
}
],
"name": "PoolCreated",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": false,
"internalType": "uint256",
"name": "poolId",
"type": "uint256"
},
{
"indexed": false,
"internalType": "uint256",
"name": "firstTokenAllowed",
"type": "uint256"
},
{
"indexed": false,
"internalType": "uint256",
"name": "limitPool",
"type": "uint256"
},
{
"indexed": false,
"internalType": "uint256",
"name": "costElectricity",
"type": "uint256"
},
{
"indexed": false,
"internalType": "uint256",
"name": "lifetime",
"type": "uint256"
},
{
"indexed": false,
"internalType": "string",
"name": "typeMachine",
"type": "string"
},
{
"indexed": false,
"internalType": "string",
"name": "area",
"type": "string"
}
],
"name": "PoolInformationsUpdated",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": true,
"internalType": "address",
"name": "owner",
"type": "address"
},
{
"indexed": false,
"internalType": "uint256",
"name": "itemId",
"type": "uint256"
},
{
"indexed": false,
"internalType": "uint256",
"name": "poolId",
"type": "uint256"
}
],
"name": "Staked721",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": false,
"internalType": "uint256",
"name": "period",
"type": "uint256"
}
],
"name": "UnlockPeriodUpdated",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": true,
"internalType": "address",
"name": "owner",
"type": "address"
},
{
"indexed": false,
"internalType": "uint256",
"name": "itemId",
"type": "uint256"
},
{
"indexed": false,
"internalType": "uint256",
"name": "poolId",
"type": "uint256"
}
],
"name": "Unstaked721",
"type": "event"
},
{
"inputs": [
{"internalType": "uint256", "name": "_poolId", "type": "uint256"},
{"internalType": "uint256[]", "name": "_tokenIds", "type": "uint256[]"},
{"internalType": "string", "name": "_addressBTC", "type": "string"}
],
"name": "batchStakeERC721",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{"internalType": "uint256[]", "name": "_tokenIds", "type": "uint256[]"}
],
"name": "batchUnstakeERC721",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "uint256",
"name": "_firstTokenAllowed",
"type": "uint256"
},
{"internalType": "uint256", "name": "_limitPool", "type": "uint256"},
{
"internalType": "uint256",
"name": "_costElectricity",
"type": "uint256"
},
{"internalType": "uint256", "name": "_lifeTime", "type": "uint256"},
{"internalType": "string", "name": "_typeMachine", "type": "string"},
{"internalType": "string", "name": "_area", "type": "string"}
],
"name": "createPool",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [],
"name": "currentPoolId",
"outputs": [{"internalType": "uint256", "name": "", "type": "uint256"}],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [{"internalType": "address", "name": "_user", "type": "address"}],
"name": "getAllStakedERC721",
"outputs": [{"internalType": "uint256[]", "name": "", "type": "uint256[]"}],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{"internalType": "uint256", "name": "_poolId", "type": "uint256"}
],
"name": "getAllStakedERC721Pool",
"outputs": [{"internalType": "uint256[]", "name": "", "type": "uint256[]"}],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{"internalType": "uint256", "name": "_poolId", "type": "uint256"},
{"internalType": "address", "name": "_user", "type": "address"}
],
"name": "getAllStakedERC721PoolByUser",
"outputs": [{"internalType": "uint256[]", "name": "", "type": "uint256[]"}],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{"internalType": "address", "name": "_user", "type": "address"},
{"internalType": "uint256", "name": "_tokenId", "type": "uint256"}
],
"name": "getStakedERC721",
"outputs": [
{
"components": [
{"internalType": "address", "name": "owner", "type": "address"},
{"internalType": "uint256", "name": "poolId", "type": "uint256"},
{"internalType": "uint256", "name": "timestamp", "type": "uint256"},
{"internalType": "string", "name": "addressBTC", "type": "string"}
],
"internalType": "struct Staking.ItemInfo",
"name": "",
"type": "tuple"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{"internalType": "uint256", "name": "_poolId", "type": "uint256"},
{"internalType": "uint256", "name": "_tokenId", "type": "uint256"}
],
"name": "getStakedERC721Pool",
"outputs": [
{
"components": [
{"internalType": "address", "name": "owner", "type": "address"},
{"internalType": "uint256", "name": "poolId", "type": "uint256"},
{"internalType": "uint256", "name": "timestamp", "type": "uint256"},
{"internalType": "string", "name": "addressBTC", "type": "string"}
],
"internalType": "struct Staking.ItemInfo",
"name": "",
"type": "tuple"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{"internalType": "address", "name": "", "type": "address"},
{"internalType": "address", "name": "", "type": "address"},
{"internalType": "uint256", "name": "", "type": "uint256"},
{"internalType": "bytes", "name": "", "type": "bytes"}
],
"name": "onERC721Received",
"outputs": [{"internalType": "bytes4", "name": "", "type": "bytes4"}],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [],
"name": "owner",
"outputs": [{"internalType": "address", "name": "", "type": "address"}],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [{"internalType": "uint256", "name": "", "type": "uint256"}],
"name": "poolInfos",
"outputs": [
{
"internalType": "uint256",
"name": "firstTokenAllowed",
"type": "uint256"
},
{"internalType": "uint256", "name": "limitPool", "type": "uint256"},
{"internalType": "uint256", "name": "costElectricity", "type": "uint256"},
{"internalType": "uint256", "name": "lifeTime", "type": "uint256"},
{"internalType": "string", "name": "typeMachine", "type": "string"},
{"internalType": "string", "name": "area", "type": "string"}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "renounceOwnership",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{"internalType": "uint256", "name": "_poolId", "type": "uint256"},
{
"internalType": "uint256",
"name": "_firstTokenAllowed",
"type": "uint256"
},
{"internalType": "uint256", "name": "_limitPool", "type": "uint256"},
{
"internalType": "uint256",
"name": "_costElectricity",
"type": "uint256"
},
{"internalType": "uint256", "name": "_lifeTime", "type": "uint256"},
{"internalType": "string", "name": "_typeMachine", "type": "string"},
{"internalType": "string", "name": "_area", "type": "string"}
],
"name": "setPoolInformation",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{"internalType": "uint256", "name": "_period", "type": "uint256"}
],
"name": "setUnlockPeriod",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{"internalType": "uint256", "name": "_poolId", "type": "uint256"},
{"internalType": "uint256", "name": "_tokenId", "type": "uint256"},
{"internalType": "string", "name": "_addressBTC", "type": "string"}
],
"name": "stakeERC721",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [],
"name": "stakingPaused",
"outputs": [{"internalType": "bool", "name": "", "type": "bool"}],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "stakingUnlock",
"outputs": [{"internalType": "uint256", "name": "", "type": "uint256"}],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "toggleStakingPaused",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{"internalType": "address", "name": "newOwner", "type": "address"}
],
"name": "transferOwnership",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{"internalType": "uint256", "name": "_tokenId", "type": "uint256"}
],
"name": "unstakeERC721",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
}
]