811 lines
85 KiB
JSON
811 lines
85 KiB
JSON
{
|
|
"_format": "hh-sol-artifact-1",
|
|
"contractName": "DAO",
|
|
"sourceName": "contracts/core/DAO.sol",
|
|
"abi": [
|
|
{
|
|
"inputs": [
|
|
{
|
|
"internalType": "contract Reputation",
|
|
"name": "reputation_",
|
|
"type": "address"
|
|
},
|
|
{
|
|
"internalType": "contract Forum",
|
|
"name": "forum_",
|
|
"type": "address"
|
|
},
|
|
{
|
|
"internalType": "contract Bench",
|
|
"name": "bench_",
|
|
"type": "address"
|
|
}
|
|
],
|
|
"stateMutability": "nonpayable",
|
|
"type": "constructor"
|
|
},
|
|
{
|
|
"anonymous": false,
|
|
"inputs": [
|
|
{
|
|
"indexed": false,
|
|
"internalType": "string",
|
|
"name": "id",
|
|
"type": "string"
|
|
}
|
|
],
|
|
"name": "PostAdded",
|
|
"type": "event"
|
|
},
|
|
{
|
|
"anonymous": false,
|
|
"inputs": [
|
|
{
|
|
"indexed": false,
|
|
"internalType": "uint256",
|
|
"name": "poolIndex",
|
|
"type": "uint256"
|
|
}
|
|
],
|
|
"name": "ValidationPoolInitiated",
|
|
"type": "event"
|
|
},
|
|
{
|
|
"anonymous": false,
|
|
"inputs": [
|
|
{
|
|
"indexed": false,
|
|
"internalType": "uint256",
|
|
"name": "poolIndex",
|
|
"type": "uint256"
|
|
},
|
|
{
|
|
"indexed": false,
|
|
"internalType": "bool",
|
|
"name": "votePasses",
|
|
"type": "bool"
|
|
},
|
|
{
|
|
"indexed": false,
|
|
"internalType": "bool",
|
|
"name": "quorumMet",
|
|
"type": "bool"
|
|
}
|
|
],
|
|
"name": "ValidationPoolResolved",
|
|
"type": "event"
|
|
},
|
|
{
|
|
"inputs": [
|
|
{
|
|
"components": [
|
|
{
|
|
"internalType": "uint256",
|
|
"name": "weightPPM",
|
|
"type": "uint256"
|
|
},
|
|
{
|
|
"internalType": "address",
|
|
"name": "authorAddress",
|
|
"type": "address"
|
|
}
|
|
],
|
|
"internalType": "struct Author[]",
|
|
"name": "authors",
|
|
"type": "tuple[]"
|
|
},
|
|
{
|
|
"internalType": "string",
|
|
"name": "postId",
|
|
"type": "string"
|
|
},
|
|
{
|
|
"components": [
|
|
{
|
|
"internalType": "int256",
|
|
"name": "weightPPM",
|
|
"type": "int256"
|
|
},
|
|
{
|
|
"internalType": "string",
|
|
"name": "targetPostId",
|
|
"type": "string"
|
|
}
|
|
],
|
|
"internalType": "struct Citation[]",
|
|
"name": "citations",
|
|
"type": "tuple[]"
|
|
}
|
|
],
|
|
"name": "addPost",
|
|
"outputs": [],
|
|
"stateMutability": "nonpayable",
|
|
"type": "function"
|
|
},
|
|
{
|
|
"inputs": [
|
|
{
|
|
"internalType": "address",
|
|
"name": "owner",
|
|
"type": "address"
|
|
},
|
|
{
|
|
"internalType": "address",
|
|
"name": "spender",
|
|
"type": "address"
|
|
}
|
|
],
|
|
"name": "allowance",
|
|
"outputs": [
|
|
{
|
|
"internalType": "uint256",
|
|
"name": "",
|
|
"type": "uint256"
|
|
}
|
|
],
|
|
"stateMutability": "view",
|
|
"type": "function"
|
|
},
|
|
{
|
|
"inputs": [
|
|
{
|
|
"internalType": "address",
|
|
"name": "account",
|
|
"type": "address"
|
|
}
|
|
],
|
|
"name": "balanceOf",
|
|
"outputs": [
|
|
{
|
|
"internalType": "uint256",
|
|
"name": "",
|
|
"type": "uint256"
|
|
}
|
|
],
|
|
"stateMutability": "view",
|
|
"type": "function"
|
|
},
|
|
{
|
|
"inputs": [
|
|
{
|
|
"internalType": "address",
|
|
"name": "account",
|
|
"type": "address"
|
|
},
|
|
{
|
|
"internalType": "uint256",
|
|
"name": "value",
|
|
"type": "uint256"
|
|
}
|
|
],
|
|
"name": "burn",
|
|
"outputs": [],
|
|
"stateMutability": "nonpayable",
|
|
"type": "function"
|
|
},
|
|
{
|
|
"inputs": [
|
|
{
|
|
"internalType": "uint256",
|
|
"name": "poolIndex",
|
|
"type": "uint256"
|
|
},
|
|
{
|
|
"internalType": "address",
|
|
"name": "owner",
|
|
"type": "address"
|
|
},
|
|
{
|
|
"internalType": "uint256",
|
|
"name": "amount",
|
|
"type": "uint256"
|
|
},
|
|
{
|
|
"internalType": "bool",
|
|
"name": "inFavor",
|
|
"type": "bool"
|
|
}
|
|
],
|
|
"name": "delegatedStakeOnValidationPool",
|
|
"outputs": [],
|
|
"stateMutability": "nonpayable",
|
|
"type": "function"
|
|
},
|
|
{
|
|
"inputs": [],
|
|
"name": "distributeFeeAmongMembers",
|
|
"outputs": [],
|
|
"stateMutability": "payable",
|
|
"type": "function"
|
|
},
|
|
{
|
|
"inputs": [
|
|
{
|
|
"internalType": "string",
|
|
"name": "id",
|
|
"type": "string"
|
|
}
|
|
],
|
|
"name": "emitPostAdded",
|
|
"outputs": [],
|
|
"stateMutability": "nonpayable",
|
|
"type": "function"
|
|
},
|
|
{
|
|
"inputs": [
|
|
{
|
|
"internalType": "uint256",
|
|
"name": "poolIndex",
|
|
"type": "uint256"
|
|
}
|
|
],
|
|
"name": "emitValidationPoolInitiated",
|
|
"outputs": [],
|
|
"stateMutability": "nonpayable",
|
|
"type": "function"
|
|
},
|
|
{
|
|
"inputs": [
|
|
{
|
|
"internalType": "uint256",
|
|
"name": "poolIndex",
|
|
"type": "uint256"
|
|
},
|
|
{
|
|
"internalType": "bool",
|
|
"name": "votePasses",
|
|
"type": "bool"
|
|
},
|
|
{
|
|
"internalType": "bool",
|
|
"name": "quorumMet",
|
|
"type": "bool"
|
|
}
|
|
],
|
|
"name": "emitValidationPoolResolved",
|
|
"outputs": [],
|
|
"stateMutability": "nonpayable",
|
|
"type": "function"
|
|
},
|
|
{
|
|
"inputs": [
|
|
{
|
|
"internalType": "uint256",
|
|
"name": "poolIndex",
|
|
"type": "uint256"
|
|
}
|
|
],
|
|
"name": "evaluateOutcome",
|
|
"outputs": [
|
|
{
|
|
"internalType": "bool",
|
|
"name": "",
|
|
"type": "bool"
|
|
}
|
|
],
|
|
"stateMutability": "nonpayable",
|
|
"type": "function"
|
|
},
|
|
{
|
|
"inputs": [
|
|
{
|
|
"internalType": "address",
|
|
"name": "owner",
|
|
"type": "address"
|
|
},
|
|
{
|
|
"internalType": "address",
|
|
"name": "to",
|
|
"type": "address"
|
|
},
|
|
{
|
|
"internalType": "uint256",
|
|
"name": "amount",
|
|
"type": "uint256"
|
|
}
|
|
],
|
|
"name": "forwardAllowance",
|
|
"outputs": [],
|
|
"stateMutability": "nonpayable",
|
|
"type": "function"
|
|
},
|
|
{
|
|
"inputs": [
|
|
{
|
|
"internalType": "string",
|
|
"name": "postId",
|
|
"type": "string"
|
|
}
|
|
],
|
|
"name": "getPostAuthors",
|
|
"outputs": [
|
|
{
|
|
"components": [
|
|
{
|
|
"internalType": "uint256",
|
|
"name": "weightPPM",
|
|
"type": "uint256"
|
|
},
|
|
{
|
|
"internalType": "address",
|
|
"name": "authorAddress",
|
|
"type": "address"
|
|
}
|
|
],
|
|
"internalType": "struct Author[]",
|
|
"name": "",
|
|
"type": "tuple[]"
|
|
}
|
|
],
|
|
"stateMutability": "view",
|
|
"type": "function"
|
|
},
|
|
{
|
|
"inputs": [
|
|
{
|
|
"internalType": "string",
|
|
"name": "postId",
|
|
"type": "string"
|
|
},
|
|
{
|
|
"internalType": "uint256",
|
|
"name": "duration",
|
|
"type": "uint256"
|
|
},
|
|
{
|
|
"internalType": "uint256[2]",
|
|
"name": "quorum",
|
|
"type": "uint256[2]"
|
|
},
|
|
{
|
|
"internalType": "uint256[2]",
|
|
"name": "winRatio",
|
|
"type": "uint256[2]"
|
|
},
|
|
{
|
|
"internalType": "uint256",
|
|
"name": "bindingPercent",
|
|
"type": "uint256"
|
|
},
|
|
{
|
|
"internalType": "bool",
|
|
"name": "redistributeLosingStakes",
|
|
"type": "bool"
|
|
},
|
|
{
|
|
"internalType": "bool",
|
|
"name": "callbackOnValidate",
|
|
"type": "bool"
|
|
},
|
|
{
|
|
"internalType": "bytes",
|
|
"name": "callbackData",
|
|
"type": "bytes"
|
|
}
|
|
],
|
|
"name": "initiateValidationPool",
|
|
"outputs": [
|
|
{
|
|
"internalType": "uint256",
|
|
"name": "",
|
|
"type": "uint256"
|
|
}
|
|
],
|
|
"stateMutability": "payable",
|
|
"type": "function"
|
|
},
|
|
{
|
|
"inputs": [
|
|
{
|
|
"internalType": "address",
|
|
"name": "",
|
|
"type": "address"
|
|
}
|
|
],
|
|
"name": "isMember",
|
|
"outputs": [
|
|
{
|
|
"internalType": "bool",
|
|
"name": "",
|
|
"type": "bool"
|
|
}
|
|
],
|
|
"stateMutability": "view",
|
|
"type": "function"
|
|
},
|
|
{
|
|
"inputs": [],
|
|
"name": "memberCount",
|
|
"outputs": [
|
|
{
|
|
"internalType": "uint256",
|
|
"name": "",
|
|
"type": "uint256"
|
|
}
|
|
],
|
|
"stateMutability": "view",
|
|
"type": "function"
|
|
},
|
|
{
|
|
"inputs": [
|
|
{
|
|
"internalType": "uint256",
|
|
"name": "",
|
|
"type": "uint256"
|
|
}
|
|
],
|
|
"name": "members",
|
|
"outputs": [
|
|
{
|
|
"internalType": "address",
|
|
"name": "",
|
|
"type": "address"
|
|
}
|
|
],
|
|
"stateMutability": "view",
|
|
"type": "function"
|
|
},
|
|
{
|
|
"inputs": [
|
|
{
|
|
"internalType": "address",
|
|
"name": "account",
|
|
"type": "address"
|
|
},
|
|
{
|
|
"internalType": "uint256",
|
|
"name": "value",
|
|
"type": "uint256"
|
|
}
|
|
],
|
|
"name": "mint",
|
|
"outputs": [],
|
|
"stateMutability": "nonpayable",
|
|
"type": "function"
|
|
},
|
|
{
|
|
"inputs": [
|
|
{
|
|
"internalType": "address",
|
|
"name": "target",
|
|
"type": "address"
|
|
},
|
|
{
|
|
"internalType": "bool",
|
|
"name": "votePasses",
|
|
"type": "bool"
|
|
},
|
|
{
|
|
"internalType": "bool",
|
|
"name": "quorumMet",
|
|
"type": "bool"
|
|
},
|
|
{
|
|
"internalType": "uint256",
|
|
"name": "stakedFor",
|
|
"type": "uint256"
|
|
},
|
|
{
|
|
"internalType": "uint256",
|
|
"name": "stakedAgainst",
|
|
"type": "uint256"
|
|
},
|
|
{
|
|
"internalType": "bytes",
|
|
"name": "callbackData",
|
|
"type": "bytes"
|
|
}
|
|
],
|
|
"name": "onValidate",
|
|
"outputs": [],
|
|
"stateMutability": "nonpayable",
|
|
"type": "function"
|
|
},
|
|
{
|
|
"inputs": [],
|
|
"name": "postCount",
|
|
"outputs": [
|
|
{
|
|
"internalType": "uint256",
|
|
"name": "",
|
|
"type": "uint256"
|
|
}
|
|
],
|
|
"stateMutability": "view",
|
|
"type": "function"
|
|
},
|
|
{
|
|
"inputs": [
|
|
{
|
|
"internalType": "uint256",
|
|
"name": "postIndex",
|
|
"type": "uint256"
|
|
}
|
|
],
|
|
"name": "postIds",
|
|
"outputs": [
|
|
{
|
|
"internalType": "string",
|
|
"name": "",
|
|
"type": "string"
|
|
}
|
|
],
|
|
"stateMutability": "view",
|
|
"type": "function"
|
|
},
|
|
{
|
|
"inputs": [
|
|
{
|
|
"internalType": "string",
|
|
"name": "postId",
|
|
"type": "string"
|
|
}
|
|
],
|
|
"name": "posts",
|
|
"outputs": [
|
|
{
|
|
"internalType": "string",
|
|
"name": "id",
|
|
"type": "string"
|
|
},
|
|
{
|
|
"internalType": "address",
|
|
"name": "sender",
|
|
"type": "address"
|
|
},
|
|
{
|
|
"internalType": "uint256",
|
|
"name": "reputation",
|
|
"type": "uint256"
|
|
}
|
|
],
|
|
"stateMutability": "view",
|
|
"type": "function"
|
|
},
|
|
{
|
|
"inputs": [
|
|
{
|
|
"internalType": "string",
|
|
"name": "postId",
|
|
"type": "string"
|
|
},
|
|
{
|
|
"internalType": "int256",
|
|
"name": "amount",
|
|
"type": "int256"
|
|
}
|
|
],
|
|
"name": "propagateReputation",
|
|
"outputs": [],
|
|
"stateMutability": "nonpayable",
|
|
"type": "function"
|
|
},
|
|
{
|
|
"inputs": [
|
|
{
|
|
"internalType": "address",
|
|
"name": "account",
|
|
"type": "address"
|
|
}
|
|
],
|
|
"name": "registerMember",
|
|
"outputs": [],
|
|
"stateMutability": "nonpayable",
|
|
"type": "function"
|
|
},
|
|
{
|
|
"inputs": [
|
|
{
|
|
"internalType": "address",
|
|
"name": "to",
|
|
"type": "address"
|
|
},
|
|
{
|
|
"internalType": "uint256",
|
|
"name": "value",
|
|
"type": "uint256"
|
|
},
|
|
{
|
|
"internalType": "uint256",
|
|
"name": "duration",
|
|
"type": "uint256"
|
|
}
|
|
],
|
|
"name": "stakeAvailability",
|
|
"outputs": [
|
|
{
|
|
"internalType": "bool",
|
|
"name": "",
|
|
"type": "bool"
|
|
}
|
|
],
|
|
"stateMutability": "nonpayable",
|
|
"type": "function"
|
|
},
|
|
{
|
|
"inputs": [
|
|
{
|
|
"internalType": "uint256",
|
|
"name": "poolIndex",
|
|
"type": "uint256"
|
|
},
|
|
{
|
|
"internalType": "uint256",
|
|
"name": "amount",
|
|
"type": "uint256"
|
|
},
|
|
{
|
|
"internalType": "bool",
|
|
"name": "inFavor",
|
|
"type": "bool"
|
|
}
|
|
],
|
|
"name": "stakeOnValidationPool",
|
|
"outputs": [],
|
|
"stateMutability": "nonpayable",
|
|
"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": "value",
|
|
"type": "uint256"
|
|
}
|
|
],
|
|
"name": "update",
|
|
"outputs": [],
|
|
"stateMutability": "nonpayable",
|
|
"type": "function"
|
|
},
|
|
{
|
|
"inputs": [],
|
|
"name": "validationPoolCount",
|
|
"outputs": [
|
|
{
|
|
"internalType": "uint256",
|
|
"name": "",
|
|
"type": "uint256"
|
|
}
|
|
],
|
|
"stateMutability": "view",
|
|
"type": "function"
|
|
},
|
|
{
|
|
"inputs": [
|
|
{
|
|
"internalType": "uint256",
|
|
"name": "poolIndex",
|
|
"type": "uint256"
|
|
}
|
|
],
|
|
"name": "validationPools",
|
|
"outputs": [
|
|
{
|
|
"internalType": "uint256",
|
|
"name": "id",
|
|
"type": "uint256"
|
|
},
|
|
{
|
|
"internalType": "address",
|
|
"name": "sender",
|
|
"type": "address"
|
|
},
|
|
{
|
|
"internalType": "uint256",
|
|
"name": "stakeCount",
|
|
"type": "uint256"
|
|
},
|
|
{
|
|
"components": [
|
|
{
|
|
"internalType": "uint256",
|
|
"name": "duration",
|
|
"type": "uint256"
|
|
},
|
|
{
|
|
"internalType": "uint256[2]",
|
|
"name": "quorum",
|
|
"type": "uint256[2]"
|
|
},
|
|
{
|
|
"internalType": "uint256[2]",
|
|
"name": "winRatio",
|
|
"type": "uint256[2]"
|
|
},
|
|
{
|
|
"internalType": "uint256",
|
|
"name": "bindingPercent",
|
|
"type": "uint256"
|
|
},
|
|
{
|
|
"internalType": "bool",
|
|
"name": "redistributeLosingStakes",
|
|
"type": "bool"
|
|
}
|
|
],
|
|
"internalType": "struct ValidationPoolParams",
|
|
"name": "params" |