fluid-contracts-public/deployments/arbitrum/VaultFactory.json

1333 lines
146 KiB
JSON
Raw Permalink Normal View History

{
"address": "0x324c5Dc1fC42c7a4D43d92df1eBA58a54d13Bf2d",
"abi": [
{
"inputs": [
{
"internalType": "address",
"name": "owner_",
"type": "address"
}
],
"stateMutability": "nonpayable",
"type": "constructor"
},
{
"inputs": [
{
"internalType": "uint256",
"name": "colLiquidated",
"type": "uint256"
},
{
"internalType": "uint256",
"name": "debtLiquidated",
"type": "uint256"
}
],
"name": "FluidLiquidateResult",
"type": "error"
},
{
"inputs": [
{
"internalType": "uint256",
"name": "errorId_",
"type": "uint256"
}
],
"name": "FluidVaultError",
"type": "error"
},
{
"anonymous": false,
"inputs": [
{
"indexed": true,
"internalType": "address",
"name": "owner",
"type": "address"
},
{
"indexed": true,
"internalType": "address",
"name": "spender",
"type": "address"
},
{
"indexed": true,
"internalType": "uint256",
"name": "id",
"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": "address",
"name": "deployer",
"type": "address"
},
{
"indexed": true,
"internalType": "bool",
"name": "allowed",
"type": "bool"
}
],
"name": "LogSetDeployer",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": true,
"internalType": "address",
"name": "globalAuth",
"type": "address"
},
{
"indexed": true,
"internalType": "bool",
"name": "allowed",
"type": "bool"
}
],
"name": "LogSetGlobalAuth",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": true,
"internalType": "address",
"name": "vaultAuth",
"type": "address"
},
{
"indexed": true,
"internalType": "bool",
"name": "allowed",
"type": "bool"
},
{
"indexed": true,
"internalType": "address",
"name": "vault",
"type": "address"
}
],
"name": "LogSetVaultAuth",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": true,
"internalType": "address",
"name": "vaultDeploymentLogic",
"type": "address"
},
{
"indexed": true,
"internalType": "bool",
"name": "allowed",
"type": "bool"
}
],
"name": "LogSetVaultDeploymentLogic",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": true,
"internalType": "address",
"name": "vault",
"type": "address"
},
{
"indexed": true,
"internalType": "address",
"name": "user",
"type": "address"
},
{
"indexed": true,
"internalType": "uint256",
"name": "tokenId",
"type": "uint256"
}
],
"name": "NewPositionMinted",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": true,
"internalType": "address",
"name": "user",
"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": "id",
"type": "uint256"
}
],
"name": "Transfer",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": true,
"internalType": "address",
"name": "vault",
"type": "address"
},
{
"indexed": true,
"internalType": "uint256",
"name": "vaultId",
"type": "uint256"
}
],
"name": "VaultDeployed",
"type": "event"
},
{
"inputs": [
{
"internalType": "address",
"name": "spender_",
"type": "address"
},
{
"internalType": "uint256",
"name": "id_",
"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": [
{
"internalType": "address",
"name": "vaultDeploymentLogic_",
"type": "address"
},
{
"internalType": "bytes",
"name": "vaultDeploymentData_",
"type": "bytes"
}
],
"name": "deployVault",
"outputs": [
{
"internalType": "address",
"name": "vault_",
"type": "address"
}
],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "uint256",
"name": "",
"type": "uint256"
}
],
"name": "getApproved",
"outputs": [
{
"internalType": "address",
"name": "",
"type": "address"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "uint256",
"name": "vaultId_",
"type": "uint256"
}
],
"name": "getVaultAddress",
"outputs": [
{
"internalType": "address",
"name": "vault_",
"type": "address"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "",
"type": "address"
},
{
"internalType": "address",
"name": "",
"type": "address"
}
],
"name": "isApprovedForAll",
"outputs": [
{
"internalType": "bool",
"name": "",
"type": "bool"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "deployer_",
"type": "address"
}
],
"name": "isDeployer",
"outputs": [
{
"internalType": "bool",
"name": "",
"type": "bool"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "globalAuth_",
"type": "address"
}
],
"name": "isGlobalAuth",
"outputs": [
{
"internalType": "bool",
"name": "",
"type": "bool"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "vault_",
"type": "address"
}
],
"name": "isVault",
"outputs": [
{
"internalType": "bool",
"name": "",
"type": "bool"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "vault_",
"type": "address"
},
{
"internalType": "address",
"name": "vaultAuth_",
"type": "address"
}
],
"name": "isVaultAuth",
"outputs": [
{
"internalType": "bool",
"name": "",
"type": "bool"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "vaultDeploymentLogic_",
"type": "address"
}
],
"name": "isVaultDeploymentLogic",
"outputs": [
{
"internalType": "bool",
"name": "",
"type": "bool"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "uint256",
"name": "vaultId_",
"type": "uint256"
},
{
"internalType": "address",
"name": "user_",
"type": "address"
}
],
"name": "mint",
"outputs": [
{
"internalType": "uint256",
"name": "tokenId_",
"type": "uint256"
}
],
"stateMutability": "nonpayable",
"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": "id_",
"type": "uint256"
}
],
"name": "ownerOf",
"outputs": [
{
"internalType": "address",
"name": "owner_",
"type": "address"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "bytes32",
"name": "slot_",
"type": "bytes32"
}
],
"name": "readFromStorage",
"outputs": [
{
"internalType": "uint256",
"name": "result_",
"type": "uint256"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "from_",
"type": "address"
},
{
"internalType": "address",
"name": "to_",
"type": "address"
},
{
"internalType": "uint256",
"name": "id_",
"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": "id_",
"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": "address",
"name": "deployer_",
"type": "address"
},
{
"internalType": "bool",
"name": "allowed_",
"type": "bool"
}
],
"name": "setDeployer",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "globalAuth_",
"type": "address"
},
{
"internalType": "bool",
"name": "allowed_",
"type": "bool"
}
],
"name": "setGlobalAuth",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "vault_",
"type": "address"
},
{
"internalType": "address",
"name": "vaultAuth_",
"type": "address"
},
{
"internalType": "bool",
"name": "allowed_",
"type": "bool"
}
],
"name": "setVaultAuth",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "deploymentLogic_",
"type": "address"
},
{
"internalType": "bool",
"name": "allowed_",
"type": "bool"
}
],
"name": "setVaultDeploymentLogic",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "target_",
"type": "address"
},
{
"internalType": "bytes",
"name": "data_",
"type": "bytes"
}
],
"name": "spell",
"outputs": [
{
"internalType": "bytes",
"name": "response_",
"type": "bytes"
}
],
"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": "id_",
"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": [],
"name": "totalVaults",
"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": "id_",
"type": "uint256"
}
],
"name": "transferFrom",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "newOwner",
"type": "address"
}
],
"name": "transferOwnership",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
}
],
"args": [
"0x4F6F977aCDD1177DCD81aB83074855EcB9C2D49e"
],
"numDeployments": 1,
"solcInputHash": "8229d0a2b99e4833044b24bf8dcbcc02",
"metadata": "{\"compiler\":{\"version\":\"0.8.21+commit.d9974bed\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner_\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"colLiquidated\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"debtLiquidated\",\"type\":\"uint256\"}],\"name\":\"FluidLiquidateResult\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"errorId_\",\"type\":\"uint256\"}],\"name\":\"FluidVaultError\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"spender\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"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\":\"address\",\"name\":\"deployer\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"bool\",\"name\":\"allowed\",\"type\":\"bool\"}],\"name\":\"LogSetDeployer\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"globalAuth\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"bool\",\"name\":\"allowed\",\"type\":\"bool\"}],\"name\":\"LogSetGlobalAuth\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"vaultAuth\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"bool\",\"name\":\"allowed\",\"type\":\"bool\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"vault\",\"type\":\"address\"}],\"name\":\"LogSetVaultAuth\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"vaultDeploymentLogic\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"bool\",\"name\":\"allowed\",\"type\":\"bool\"}],\"name\":\"LogSetVaultDeploymentLogic\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"vault\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"user\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"tokenId\",\"type\":\"uint256\"}],\"name\":\"NewPositionMinted\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"user\",\"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\":\"id\",\"type\":\"uint256\"}],\"name\":\"Transfer\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"vault\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"vaultId\",\"type\":\"uint256\"}],\"name\":\"VaultDeployed\",\"type\":\"event\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"spender_\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"id_\",\"type\":\"uint256\"}],\"name\":\"approve\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner_\",\"type\":\"address\"}],\"name\":\"balanceOf\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\
"bytecode": "0x60806040523480156200001157600080fd5b5060405162002ea838038062002ea883398101604081905262000034916200011d565b604080518082018252600b81526a119b1d5a590815985d5b1d60aa1b6020808301919091528251808401845260048152631995931560e21b91810191909152600080546001600160a01b0319166001600160a01b0386169081178255935185948594939285927f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908290a3506001620000ce8382620001f4565b506002620000dd8282620001f4565b50839250506001600160a01b038216905062000114576040516330090e6560e11b8152617534600482015260240160405180910390fd5b505050620002c0565b6000602082840312156200013057600080fd5b81516001600160a01b03811681146200014857600080fd5b9392505050565b634e487b7160e01b600052604160045260246000fd5b600181811c908216806200017a57607f821691505b6020821081036200019b57634e487b7160e01b600052602260045260246000fd5b50919050565b601f821115620001ef57600081815260208120601f850160051c81016020861015620001ca5750805b601f850160051c820191505b81811015620001eb57828155600101620001d6565b5050505b505050565b81516001600160401b038111156200021057620002106200014f565b620002288162000221845462000165565b84620001a1565b602080601f831160018114620002605760008415620002475750858301515b600019600386901b1c1916600185901b178555620001eb565b600085815260208120601f198616915b82811015620002915788860151825594840194600190910190840162000270565b5085821015620002b05787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b612bd880620002d06000396000f3fe608060405234801561001057600080fd5b506004361061020b5760003560e01c80637faa1d211161012a578063a34b5ee8116100bd578063c87b56dd1161008c578063e6bd26a211610071578063e6bd26a2146104d9578063e985e9c5146104ec578063f2fde38b1461051a57600080fd5b8063c87b56dd146104a5578063e04c8e5d146104c657600080fd5b8063a34b5ee81461045a578063b5c736e41461046d578063b88d4fde1461047f578063c7acb01f1461049257600080fd5b806394bf804d116100f957806394bf804d1461041957806395d89b411461042c578063968cbade14610434578063a22cb4651461044757600080fd5b80637faa1d21146103cb5780638d654023146103de5780638da5cb5b146103e65780638f2db95d1461040657600080fd5b80632f745c59116101a257806350c358a41161017157806350c358a41461037f5780636352211e14610392578063652b9b41146103a557806370a08231146103b857600080fd5b80632f745c591461033357806342842e0e146103465780634502d063146103595780634f6ccce71461036c57600080fd5b8063095ea7b3116101de578063095ea7b3146102bd57806317e7681c146102d057806318160ddd1461030957806323b872dd1461032057600080fd5b806301ffc9a71461021057806306fdde0314610238578063081812fc1461024d57806308a892d9146102a8575b600080fd5b61022361021e366004612489565b61052d565b60405190151581526020015b60405180910390f35b61024061065e565b60405161022f9190612514565b61028361025b366004612527565b60066020526000908152604090205473ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200161022f565b6102bb6102b6366004612574565b6106ec565b005b6102bb6102cb3660046125a7565b610844565b6102236102de3660046125d1565b73ffffffffffffffffffffffffffffffffffffffff166000908152600c602052604090205460ff1690565b61031260055481565b60405190815260200161022f565b6102bb61032e3660046125ec565b610962565b6103126103413660046125a7565b610b17565b6102bb6103543660046125ec565b610bd1565b6102236103673660046125d1565b610d0f565b61031261037a366004612527565b610d60565b61022361038d3660046125d1565b610dac565b6102836103a0366004612527565b610dfd565b6102236103b33660046125d1565b610e62565b6103126103c63660046125d1565b610f70565b6102bb6103d9366004612628565b610ffd565b600b54610312565b6000546102839073ffffffffffffffffffffffffffffffffffffffff1681565b6102bb610414366004612574565b611164565b61031261042736600461266b565b6112b7565b610240611382565b6102836104423660046126d7565b61138f565b6102bb610455366004612574565b6115b2565b6102bb610468366004612574565b611649565b61031261047b366004612527565b5490565b6102bb61048d36600461272a565b61179c565b6102406104a036600461285d565b6118ca565b6102406104b3366004612527565b5060408051602081019091526000815290565b6102236104d43660046128ee565b611998565b6102836104e7366004612527565b6119fc565b6102236104fa3660046128ee565b600760209081526000928352604080842090915290825290205460ff1681565b6102bb6105283660046125d1
"deployedBytecode": "0x608060405234801561001057600080fd5b506004361061020b5760003560e01c80637faa1d211161012a578063a34b5ee8116100bd578063c87b56dd1161008c578063e6bd26a211610071578063e6bd26a2146104d9578063e985e9c5146104ec578063f2fde38b1461051a57600080fd5b8063c87b56dd146104a5578063e04c8e5d146104c657600080fd5b8063a34b5ee81461045a578063b5c736e41461046d578063b88d4fde1461047f578063c7acb01f1461049257600080fd5b806394bf804d116100f957806394bf804d1461041957806395d89b411461042c578063968cbade14610434578063a22cb4651461044757600080fd5b80637faa1d21146103cb5780638d654023146103de5780638da5cb5b146103e65780638f2db95d1461040657600080fd5b80632f745c59116101a257806350c358a41161017157806350c358a41461037f5780636352211e14610392578063652b9b41146103a557806370a08231146103b857600080fd5b80632f745c591461033357806342842e0e146103465780634502d063146103595780634f6ccce71461036c57600080fd5b8063095ea7b3116101de578063095ea7b3146102bd57806317e7681c146102d057806318160ddd1461030957806323b872dd1461032057600080fd5b806301ffc9a71461021057806306fdde0314610238578063081812fc1461024d57806308a892d9146102a8575b600080fd5b61022361021e366004612489565b61052d565b60405190151581526020015b60405180910390f35b61024061065e565b60405161022f9190612514565b61028361025b366004612527565b60066020526000908152604090205473ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200161022f565b6102bb6102b6366004612574565b6106ec565b005b6102bb6102cb3660046125a7565b610844565b6102236102de3660046125d1565b73ffffffffffffffffffffffffffffffffffffffff166000908152600c602052604090205460ff1690565b61031260055481565b60405190815260200161022f565b6102bb61032e3660046125ec565b610962565b6103126103413660046125a7565b610b17565b6102bb6103543660046125ec565b610bd1565b6102236103673660046125d1565b610d0f565b61031261037a366004612527565b610d60565b61022361038d3660046125d1565b610dac565b6102836103a0366004612527565b610dfd565b6102236103b33660046125d1565b610e62565b6103126103c63660046125d1565b610f70565b6102bb6103d9366004612628565b610ffd565b600b54610312565b6000546102839073ffffffffffffffffffffffffffffffffffffffff1681565b6102bb610414366004612574565b611164565b61031261042736600461266b565b6112b7565b610240611382565b6102836104423660046126d7565b61138f565b6102bb610455366004612574565b6115b2565b6102bb610468366004612574565b611649565b61031261047b366004612527565b5490565b6102bb61048d36600461272a565b61179c565b6102406104a036600461285d565b6118ca565b6102406104b3366004612527565b5060408051602081019091526000815290565b6102236104d43660046128ee565b611998565b6102836104e7366004612527565b6119fc565b6102236104fa3660046128ee565b600760209081526000928352604080842090915290825290205460ff1681565b6102bb6105283660046125d1565b611e5f565b60007f01ffc9a7000000000000000000000000000000000000000000000000000000007fffffffff00000000000000000000000000000000000000000000000000000000831614806105c057507f80ac58cd000000000000000000000000000000000000000000000000000000007fffffffff000000000000000000000000000000000000000000000000000000008316145b8061060c57507f5b5e139f000000000000000000000000000000000000000000000000000000007fffffffff000000000000000000000000000000000000000000000000000000008316145b8061065857507f780e9d63000000000000000000000000000000000000000000000000000000007fffffffff000000000000000000000000000000000000000000000000000000008316145b92915050565b6001805461066b90612918565b80601f016020809104026020016040519081016040528092919081815260200182805461069790612918565b80156106e45780601f106106b9576101008083540402835291602001916106e4565b820191906000526020600020905b8154815290600101906020018083116106c757829003601f168201915b505050505081565b60005473ffffffffffffffffffffffffffffffffffffffff163314610772576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600c60248201527f554e415554484f52495a4544000000000000000000000000000000000000000060448201526064015b60405180910390fd5b8173ffffffffffffffffffffffffffffffffffffffff81166107c4576040517f60121cca0000000000000000000000000000000000000000000000000000000081526175346004820152602401610769565b73ffffffffffffffffffffffffffffffffffffffff83166000818152600c602052604080822080547fffffffffff
"devdoc": {
"details": "Note the deployed vaults start out with no config at Liquidity contract. This must be done by Liquidity auths in a separate step, otherwise no deposits will be possible. This contract is not upgradeable. It supports adding new vault deployment logic contracts for new, future vaults.",
"events": {
"LogSetDeployer(address,bool)": {
"details": "Emitted when the deployer is modified by owner.",
"params": {
"allowed": "Indicates whether the address is authorized as a deployer or not.",
"deployer": "Address whose deployer status is updated."
}
},
"LogSetGlobalAuth(address,bool)": {
"details": "Emitted when the globalAuth is modified by owner.",
"params": {
"allowed": "Indicates whether the address is authorized as a deployer or not.",
"globalAuth": "Address whose globalAuth status is updated."
}
},
"LogSetVaultAuth(address,bool,address)": {
"details": "Emitted when the vaultAuth is modified by owner.",
"params": {
"allowed": "Indicates whether the address is authorized as a deployer or not.",
"vault": "Address of the specific vault related to the authorization change.",
"vaultAuth": "Address whose vaultAuth status is updated."
}
},
"LogSetVaultDeploymentLogic(address,bool)": {
"details": "Emitted when the vault deployment logic is modified by owner.",
"params": {
"allowed": "Indicates whether the address is authorized as a deployer or not.",
"vaultDeploymentLogic": "The address of the vault deployment logic contract."
}
},
"NewPositionMinted(address,address,uint256)": {
"details": "Emitted when a new token/position is minted by a vault.",
"params": {
"tokenId": "The ID of the newly minted token.",
"user": "The address of the user who received the minted token.",
"vault": "The address of the vault that minted the token."
}
},
"VaultDeployed(address,uint256)": {
"details": "Emitted when a new vault is deployed.",
"params": {
"vault": "The address of the newly deployed vault.",
"vaultId": "The id of the newly deployed vault."
}
}
},
"kind": "dev",
"methods": {
"deployVault(address,bytes)": {
"params": {
"vaultDeploymentData_": "The data to be used for vault deployment.",
"vaultDeploymentLogic_": "The address of the vault deployment logic contract."
},
"returns": {
"vault_": " Returns the address of the newly deployed vault."
}
},
"getVaultAddress(uint256)": {
"params": {
"vaultId_": "The ID of the vault."
},
"returns": {
"vault_": " Returns the computed address of the vault."
}
},
"isDeployer(address)": {
"params": {
"deployer_": "The address to be checked for deployer authorization."
},
"returns": {
"_0": "Returns `true` if the address is a deployer, otherwise `false`."
}
},
"isGlobalAuth(address)": {
"params": {
"globalAuth_": "The address to be checked for global authorization privileges."
},
"returns": {
"_0": "Returns `true` if the given address has global authorization privileges, otherwise `false`."
}
},
"isVault(address)": {
"params": {
"vault_": "The vault address to check."
},
"returns": {
"_0": "Returns `true` if the given address corresponds to a valid vault, otherwise `false`."
}
},
"isVaultAuth(address,address)": {
"params": {
"vaultAuth_": "The address to be checked for vault authorization privileges.",
"vault_": "The address of the vault to check."
},
"returns": {
"_0": "Returns `true` if the given address has vault authorization privileges for the specified vault, otherwise `false`."
}
},
"isVaultDeploymentLogic(address)": {
"params": {
"vaultDeploymentLogic_": "The address of the vault deploy logic to check for authorization privileges."
},
"returns": {
"_0": "Returns `true` if the given address has authorization privileges for vault deployment, otherwise `false`."
}
},
"mint(uint256,address)": {
"params": {
"user_": "The address receiving the minted token.",
"vaultId_": "The ID of the vault that's minting the token."
},
"returns": {
"tokenId_": " The ID of the newly minted token."
}
},
"setDeployer(address,bool)": {
"params": {
"allowed_": "A boolean indicating whether the specified address is allowed to deploy vaults.",
"deployer_": "The address to be set as deployer."
}
},
"setGlobalAuth(address,bool)": {
"params": {
"allowed_": "A boolean indicating whether the specified address is allowed to update any vault config.",
"globalAuth_": "The address to be set as global authorization."
}
},
"setVaultAuth(address,address,bool)": {
"params": {
"allowed_": "A boolean indicating whether the specified address is allowed to update the specific vault config.",
"vaultAuth_": "The address to be set as vault authorization.",
"vault_": "The address of the vault for which the authorization is being set."
}
},
"setVaultDeploymentLogic(address,bool)": {
"params": {
"allowed_": "A boolean indicating whether the specified address is allowed to deploy new type of vault.",
"deploymentLogic_": "The address of the vault deployment logic contract to be set."
}
},
"spell(address,bytes)": {
"params": {
"data_": "Data to execute at the delegated address",
"target_": "Address to which the call needs to be delegated"
}
},
"tokenURI(uint256)": {
"params": {
"id_": "The ID of the token to query."
},
"returns": {
"_0": "An empty string since no specific URI is defined in this implementation."
}
},
"totalVaults()": {
"returns": {
"_0": "Returns the total number of vaults."
}
}
},
"title": "Fluid VaultFactory",
"version": 1
},
"userdoc": {
"errors": {
"FluidLiquidateResult(uint256,uint256)": [
{
"notice": "used to simulate liquidation to find the maximum liquidatable amounts"
}
]
},
"kind": "user",
"methods": {
"approve(address,uint256)": {
"notice": "approves an NFT with `id_` to be spent (transferred) by `spender_`"
},
"balanceOf(address)": {
"notice": "returns total count of NFTs owned by `owner_`"
},
"deployVault(address,bytes)": {
"notice": "Deploys a new vault using the specified deployment logic `vaultDeploymentLogic_` and data `vaultDeploymentData_`. Only accounts with deployer access or the owner can deploy a new vault."
},
"getApproved(uint256)": {
"notice": "trackes if a NFT id is approved for a certain address."
},
"getVaultAddress(uint256)": {
"notice": "Computes the address of a vault based on its given ID (`vaultId_`)."
},
"isApprovedForAll(address,address)": {
"notice": "trackes if all the NFTs of an owner are approved for a certain other address."
},
"isDeployer(address)": {
"notice": "Checks if the provided address (`deployer_`) is authorized as a deployer."
},
"isGlobalAuth(address)": {
"notice": "Checks if the provided address (`globalAuth_`) has global vault authorization privileges."
},
"isVault(address)": {
"notice": "Checks if a given address (`vault_`) corresponds to a valid vault."
},
"isVaultAuth(address,address)": {
"notice": "Checks if the provided address (`vaultAuth_`) has vault authorization privileges for the specified vault (`vault_`)."
},
"isVaultDeploymentLogic(address)": {
"notice": "Checks if the provided (`vaultDeploymentLogic_`) address has authorization for vault deployment."
},
"mint(uint256,address)": {
"notice": "Mints a new ERC721 token for a specific vault (`vaultId_`) to a specified user (`user_`). Only the corresponding vault is authorized to mint a token."
},
"ownerOf(uint256)": {
"notice": "returns `owner_` of NFT with `id_`"
},
"safeTransferFrom(address,address,uint256)": {
"notice": "transfers an NFT with `id_` `from_` address `to_` address"
},
"safeTransferFrom(address,address,uint256,bytes)": {
"notice": "transfers an NFT with `id_` `from_` address `to_` address, passing `data_` to `onERC721Received` callback"
},
"setApprovalForAll(address,bool)": {
"notice": "approves all NFTs owned by msg.sender to be spent (transferred) by `operator_`"
},
"setDeployer(address,bool)": {
"notice": "Sets an address (`deployer_`) as allowed deployer or not. This function can only be called by the owner."
},
"setGlobalAuth(address,bool)": {
"notice": "Sets an address (`globalAuth_`) as a global authorization or not. This function can only be called by the owner."
},
"setVaultAuth(address,address,bool)": {
"notice": "Sets an address (`vaultAuth_`) as allowed vault authorization or not for a specific vault (`vault_`). This function can only be called by the owner."
},
"setVaultDeploymentLogic(address,bool)": {
"notice": "Sets an address as allowed vault deployment logic (`deploymentLogic_`) contract or not. This function can only be called by the owner."
},
"spell(address,bytes)": {
"notice": "Spell allows owner aka governance to do any arbitrary call on factory"
},
"tokenByIndex(uint256)": {
"notice": "Returns a token ID at a given `index_` of all the tokens stored by the contract. Use along with {totalSupply} to enumerate all tokens."
},
"tokenOfOwnerByIndex(address,uint256)": {
"notice": "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."
},
"tokenURI(uint256)": {
"notice": "Returns the URI of the specified token ID (`id_`). In this implementation, an empty string is returned as no specific URI is defined."
},
"totalSupply()": {
"notice": "total amount of tokens stored by the contract."
},
"totalVaults()": {
"notice": "Returns the total number of vaults deployed by the factory."
},
"transferFrom(address,address,uint256)": {
"notice": "transfers an NFT with `id_` `from_` address `to_` address without safe check"
}
},
"notice": "creates Fluid vault protocol vaults, which are interacting with Fluid Liquidity to deposit / borrow funds. Vaults are created at a deterministic address, given an incrementing `vaultId` (see `getVaultAddress()`). Vaults can only be deployed by allow-listed deployer addresses. This factory also implements ERC721-Enumerable, the NFTs are used to represent created user positions. Only vaults can mint new NFTs.",
"version": 1
},
"storageLayout": {
"storage": [
{
"astId": 10873,
"contract": "contracts/protocols/vault/factory/main.sol:FluidVaultFactory",
"label": "owner",
"offset": 0,
"slot": "0",
"type": "t_address"
},
{
"astId": 5160,
"contract": "contracts/protocols/vault/factory/main.sol:FluidVaultFactory",
"label": "name",
"offset": 0,
"slot": "1",
"type": "t_string_storage"
},
{
"astId": 5162,
"contract": "contracts/protocols/vault/factory/main.sol:FluidVaultFactory",
"label": "symbol",
"offset": 0,
"slot": "2",
"type": "t_string_storage"
},
{
"astId": 5173,
"contract": "contracts/protocols/vault/factory/main.sol:FluidVaultFactory",
"label": "_tokenConfig",
"offset": 0,
"slot": "3",
"type": "t_mapping(t_uint256,t_uint256)"
},
{
"astId": 5179,
"contract": "contracts/protocols/vault/factory/main.sol:FluidVaultFactory",
"label": "_ownerConfig",
"offset": 0,
"slot": "4",
"type": "t_mapping(t_address,t_mapping(t_uint256,t_uint256))"
},
{
"astId": 5247,
"contract": "contracts/protocols/vault/factory/main.sol:FluidVaultFactory",
"label": "totalSupply",
"offset": 0,
"slot": "5",
"type": "t_uint256"
},
{
"astId": 5252,
"contract": "contracts/protocols/vault/factory/main.sol:FluidVaultFactory",
"label": "getApproved",
"offset": 0,
"slot": "6",
"type": "t_mapping(t_uint256,t_address)"
},
{
"astId": 5259,
"contract": "contracts/protocols/vault/factory/main.sol:FluidVaultFactory",
"label": "isApprovedForAll",
"offset": 0,
"slot": "7",
"type": "t_mapping(t_address,t_mapping(t_address,t_bool))"
},
{
"astId": 6140,
"contract": "contracts/protocols/vault/factory/main.sol:FluidVaultFactory",
"label": "_deployers",
"offset": 0,
"slot": "8",
"type": "t_mapping(t_address,t_bool)"
},
{
"astId": 6145,
"contract": "contracts/protocols/vault/factory/main.sol:FluidVaultFactory",
"label": "_globalAuths",
"offset": 0,
"slot": "9",
"type": "t_mapping(t_address,t_bool)"
},
{
"astId": 6152,
"contract": "contracts/protocols/vault/factory/main.sol:FluidVaultFactory",
"label": "_vaultAuths",
"offset": 0,
"slot": "10",
"type": "t_mapping(t_address,t_mapping(t_address,t_bool))"
},
{
"astId": 6155,
"contract": "contracts/protocols/vault/factory/main.sol:FluidVaultFactory",
"label": "_totalVaults",
"offset": 0,
"slot": "11",
"type": "t_uint256"
},
{
"astId": 6160,
"contract": "contracts/protocols/vault/factory/main.sol:FluidVaultFactory",
"label": "_vaultDeploymentLogics",
"offset": 0,
"slot": "12",
"type": "t_mapping(t_address,t_bool)"
}
],
"types": {
"t_address": {
"encoding": "inplace",
"label": "address",
"numberOfBytes": "20"
},
"t_bool": {
"encoding": "inplace",
"label": "bool",
"numberOfBytes": "1"
},
"t_mapping(t_address,t_bool)": {
"encoding": "mapping",
"key": "t_address",
"label": "mapping(address => bool)",
"numberOfBytes": "32",
"value": "t_bool"
},
"t_mapping(t_address,t_mapping(t_address,t_bool))": {
"encoding": "mapping",
"key": "t_address",
"label": "mapping(address => mapping(address => bool))",
"numberOfBytes": "32",
"value": "t_mapping(t_address,t_bool)"
},
"t_mapping(t_address,t_mapping(t_uint256,t_uint256))": {
"encoding": "mapping",
"key": "t_address",
"label": "mapping(address => mapping(uint256 => uint256))",
"numberOfBytes": "32",
"value": "t_mapping(t_uint256,t_uint256)"
},
"t_mapping(t_uint256,t_address)": {
"encoding": "mapping",
"key": "t_uint256",
"label": "mapping(uint256 => address)",
"numberOfBytes": "32",
"value": "t_address"
},
"t_mapping(t_uint256,t_uint256)": {
"encoding": "mapping",
"key": "t_uint256",
"label": "mapping(uint256 => uint256)",
"numberOfBytes": "32",
"value": "t_uint256"
},
"t_string_storage": {
"encoding": "bytes",
"label": "string",
"numberOfBytes": "32"
},
"t_uint256": {
"encoding": "inplace",
"label": "uint256",
"numberOfBytes": "32"
}
}
}
}