@excubiae/contracts
Version:
1 lines • 12.4 kB
JSON
{"abi":[{"type":"function","name":"createHat","inputs":[{"name":"admin","type":"uint256","internalType":"uint256"},{"name":"details","type":"string","internalType":"string"},{"name":"maxSupply","type":"uint32","internalType":"uint32"},{"name":"eligibility","type":"address","internalType":"address"},{"name":"toggle","type":"address","internalType":"address"},{"name":"isMutable","type":"bool","internalType":"bool"},{"name":"imageURI","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"uint256","internalType":"uint256"}],"stateMutability":"nonpayable"},{"type":"function","name":"isWearerOfHat","inputs":[{"name":"account","type":"address","internalType":"address"},{"name":"hat","type":"uint256","internalType":"uint256"}],"outputs":[{"name":"","type":"bool","internalType":"bool"}],"stateMutability":"view"},{"type":"function","name":"mintHat","inputs":[{"name":"hatId","type":"uint256","internalType":"uint256"},{"name":"wearer","type":"address","internalType":"address"}],"outputs":[{"name":"success","type":"bool","internalType":"bool"}],"stateMutability":"nonpayable"},{"type":"function","name":"mintTopHat","inputs":[{"name":"target","type":"address","internalType":"address"},{"name":"details","type":"string","internalType":"string"},{"name":"imageURI","type":"string","internalType":"string"}],"outputs":[{"name":"","type":"uint256","internalType":"uint256"}],"stateMutability":"nonpayable"}],"bytecode":{"object":"0x","sourceMap":"","linkReferences":{}},"deployedBytecode":{"object":"0x","sourceMap":"","linkReferences":{}},"methodIdentifiers":{"createHat(uint256,string,uint32,address,address,bool,string)":"b052925e","isWearerOfHat(address,uint256)":"4352409a","mintHat(uint256,address)":"641f776e","mintTopHat(address,string,string)":"1a64dfad"},"rawMetadata":"{\"compiler\":{\"version\":\"0.8.28+commit.7893614a\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"admin\",\"type\":\"uint256\"},{\"internalType\":\"string\",\"name\":\"details\",\"type\":\"string\"},{\"internalType\":\"uint32\",\"name\":\"maxSupply\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"eligibility\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"toggle\",\"type\":\"address\"},{\"internalType\":\"bool\",\"name\":\"isMutable\",\"type\":\"bool\"},{\"internalType\":\"string\",\"name\":\"imageURI\",\"type\":\"string\"}],\"name\":\"createHat\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"hat\",\"type\":\"uint256\"}],\"name\":\"isWearerOfHat\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"hatId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"wearer\",\"type\":\"address\"}],\"name\":\"mintHat\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"string\",\"name\":\"details\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"imageURI\",\"type\":\"string\"}],\"name\":\"mintTopHat\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}],\"devdoc\":{\"details\":\"Includes only the functions required for the HatsGatekeepers and associated tests\",\"kind\":\"dev\",\"methods\":{\"createHat(uint256,string,uint32,address,address,bool,string)\":{\"details\":\"Initializes a new Hat struct, but does not mint any tokens.\",\"params\":{\"admin\":\"The id of the Hat that will control who wears the newly created hat\",\"details\":\"A description of the Hat. Should not be larger than 7000 bytes (enforced in changeHatDetails)\",\"eligibility\":\"The address that can report on the Hat wearer's status\",\"imageURI\":\"The image uri for this hat and the fallback for its downstream hats [optional]. Should not be larger than 7000 bytes (enforced in changeHatImageURI)\",\"isMutable\":\"Whether the hat's properties are changeable after creation\",\"maxSupply\":\"The total instances of the Hat that can be worn at once\",\"toggle\":\"The address that can deactivate the Hat\"},\"returns\":{\"_0\":\"newHatId The id of the newly created Hat\"}},\"isWearerOfHat(address,uint256)\":{\"details\":\"Convenience function that wraps `balanceOf`\",\"params\":{\"account\":\"The address in question\",\"hat\":\"The id of the Hat that the `_user` might wear\"},\"returns\":{\"_0\":\"isWearer Whether the `_user` wears the Hat.\"}},\"mintHat(uint256,address)\":{\"details\":\"The msg.sender must wear an admin Hat of `_hatId`, and the recipient must be eligible to wear `_hatId`\",\"params\":{\"hatId\":\"The id of the Hat to mint\",\"wearer\":\"The address to which the Hat is minted\"},\"returns\":{\"success\":\"Whether the mint succeeded\"}},\"mintTopHat(address,string,string)\":{\"details\":\"A topHat has no eligibility and no toggle\",\"params\":{\"details\":\"A description of the Hat [optional]. Should not be larger than 7000 bytes (enforced in changeHatDetails)\",\"imageURI\":\"The image uri for this top hat and the fallback for its downstream hats [optional]. Should not be larger than 7000 bytes (enforced in changeHatImageURI)\",\"target\":\"The address to which the newly created topHat is minted\"},\"returns\":{\"_0\":\"topHatId The id of the newly created topHat\"}}},\"title\":\"IHats\",\"version\":1},\"userdoc\":{\"kind\":\"user\",\"methods\":{\"createHat(uint256,string,uint32,address,address,bool,string)\":{\"notice\":\"Creates a new hat. The msg.sender must wear the `_admin` hat.\"},\"isWearerOfHat(address,uint256)\":{\"notice\":\"Checks whether a given address wears a given Hat\"},\"mintHat(uint256,address)\":{\"notice\":\"Mints an ERC1155-similar token of the Hat to an eligible recipient, who then \\\"wears\\\" the hat\"},\"mintTopHat(address,string,string)\":{\"notice\":\"Creates and mints a Hat that is its own admin, i.e. a \\\"topHat\\\"\"}},\"notice\":\"Minimal interface for the Hats Protocol contract\",\"version\":1}},\"settings\":{\"compilationTarget\":{\"contracts/extensions/hats/IHats.sol\":\"IHats\"},\"evmVersion\":\"cancun\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"ipfs\"},\"optimizer\":{\"enabled\":true,\"runs\":200000},\"remappings\":[\":@openzeppelin/=node_modules/@openzeppelin/\",\":@semaphore-protocol/=node_modules/@semaphore-protocol/\",\":@solady/=node_modules/solady/\",\":@zk-kit/=node_modules/@zk-kit/\",\":eth-gas-reporter/=node_modules/eth-gas-reporter/\",\":forge-std/=node_modules/forge-std/\",\":hardhat/=node_modules/hardhat/\",\":poseidon-solidity/=node_modules/poseidon-solidity/\",\":solady/=node_modules/solady/\"]},\"sources\":{\"contracts/extensions/hats/IHats.sol\":{\"keccak256\":\"0x1150a7016f54df47f8a0e19ceb74dfbe05c3be72aa391e9f6ff0f1fa6487967e\",\"license\":\"MIT\",\"urls\":[\"bzz-raw://a5c30bebc7ee680dcf87309640153e1cbd93fefd80da4584e360824feb3da38d\",\"dweb:/ipfs/QmRJ5vP65M3t7uqCj156b4xVkedLYrQ1iw4S6Gvj38oJBZ\"]}},\"version\":1}","metadata":{"compiler":{"version":"0.8.28+commit.7893614a"},"language":"Solidity","output":{"abi":[{"inputs":[{"internalType":"uint256","name":"admin","type":"uint256"},{"internalType":"string","name":"details","type":"string"},{"internalType":"uint32","name":"maxSupply","type":"uint32"},{"internalType":"address","name":"eligibility","type":"address"},{"internalType":"address","name":"toggle","type":"address"},{"internalType":"bool","name":"isMutable","type":"bool"},{"internalType":"string","name":"imageURI","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"createHat","outputs":[{"internalType":"uint256","name":"","type":"uint256"}]},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256","name":"hat","type":"uint256"}],"stateMutability":"view","type":"function","name":"isWearerOfHat","outputs":[{"internalType":"bool","name":"","type":"bool"}]},{"inputs":[{"internalType":"uint256","name":"hatId","type":"uint256"},{"internalType":"address","name":"wearer","type":"address"}],"stateMutability":"nonpayable","type":"function","name":"mintHat","outputs":[{"internalType":"bool","name":"success","type":"bool"}]},{"inputs":[{"internalType":"address","name":"target","type":"address"},{"internalType":"string","name":"details","type":"string"},{"internalType":"string","name":"imageURI","type":"string"}],"stateMutability":"nonpayable","type":"function","name":"mintTopHat","outputs":[{"internalType":"uint256","name":"","type":"uint256"}]}],"devdoc":{"kind":"dev","methods":{"createHat(uint256,string,uint32,address,address,bool,string)":{"details":"Initializes a new Hat struct, but does not mint any tokens.","params":{"admin":"The id of the Hat that will control who wears the newly created hat","details":"A description of the Hat. Should not be larger than 7000 bytes (enforced in changeHatDetails)","eligibility":"The address that can report on the Hat wearer's status","imageURI":"The image uri for this hat and the fallback for its downstream hats [optional]. Should not be larger than 7000 bytes (enforced in changeHatImageURI)","isMutable":"Whether the hat's properties are changeable after creation","maxSupply":"The total instances of the Hat that can be worn at once","toggle":"The address that can deactivate the Hat"},"returns":{"_0":"newHatId The id of the newly created Hat"}},"isWearerOfHat(address,uint256)":{"details":"Convenience function that wraps `balanceOf`","params":{"account":"The address in question","hat":"The id of the Hat that the `_user` might wear"},"returns":{"_0":"isWearer Whether the `_user` wears the Hat."}},"mintHat(uint256,address)":{"details":"The msg.sender must wear an admin Hat of `_hatId`, and the recipient must be eligible to wear `_hatId`","params":{"hatId":"The id of the Hat to mint","wearer":"The address to which the Hat is minted"},"returns":{"success":"Whether the mint succeeded"}},"mintTopHat(address,string,string)":{"details":"A topHat has no eligibility and no toggle","params":{"details":"A description of the Hat [optional]. Should not be larger than 7000 bytes (enforced in changeHatDetails)","imageURI":"The image uri for this top hat and the fallback for its downstream hats [optional]. Should not be larger than 7000 bytes (enforced in changeHatImageURI)","target":"The address to which the newly created topHat is minted"},"returns":{"_0":"topHatId The id of the newly created topHat"}}},"version":1},"userdoc":{"kind":"user","methods":{"createHat(uint256,string,uint32,address,address,bool,string)":{"notice":"Creates a new hat. The msg.sender must wear the `_admin` hat."},"isWearerOfHat(address,uint256)":{"notice":"Checks whether a given address wears a given Hat"},"mintHat(uint256,address)":{"notice":"Mints an ERC1155-similar token of the Hat to an eligible recipient, who then \"wears\" the hat"},"mintTopHat(address,string,string)":{"notice":"Creates and mints a Hat that is its own admin, i.e. a \"topHat\""}},"version":1}},"settings":{"remappings":["@openzeppelin/=node_modules/@openzeppelin/","@semaphore-protocol/=node_modules/@semaphore-protocol/","@solady/=node_modules/solady/","@zk-kit/=node_modules/@zk-kit/","eth-gas-reporter/=node_modules/eth-gas-reporter/","forge-std/=node_modules/forge-std/","hardhat/=node_modules/hardhat/","poseidon-solidity/=node_modules/poseidon-solidity/","solady/=node_modules/solady/"],"optimizer":{"enabled":true,"runs":200000},"metadata":{"bytecodeHash":"ipfs"},"compilationTarget":{"contracts/extensions/hats/IHats.sol":"IHats"},"evmVersion":"cancun","libraries":{}},"sources":{"contracts/extensions/hats/IHats.sol":{"keccak256":"0x1150a7016f54df47f8a0e19ceb74dfbe05c3be72aa391e9f6ff0f1fa6487967e","urls":["bzz-raw://a5c30bebc7ee680dcf87309640153e1cbd93fefd80da4584e360824feb3da38d","dweb:/ipfs/QmRJ5vP65M3t7uqCj156b4xVkedLYrQ1iw4S6Gvj38oJBZ"],"license":"MIT"}},"version":1},"id":33}