UNPKG

@allo-team/allo-v2-sdk

Version:
297 lines (295 loc) 5.33 kB
// Factory for DirectGrantsLiteStrategy v1.0 export const getAddress = (chainId: number): `0x${string}` => { switch (chainId) { case 300: // ZkSync Era Testnet case 324: // ZkSync Era Mainnet return "0x235bd2A867056Ba72d48ceC08d82b418fA977D1c"; default: throw new Error("Chain not supported by SDK"); } }; export const abi = [ { inputs: [ { internalType: "address", name: "_allo", type: "address", }, { internalType: "string", name: "_name", type: "string", }, ], stateMutability: "nonpayable", type: "constructor", }, { inputs: [], name: "NewOwnerIsZeroAddress", type: "error", }, { inputs: [], name: "NoHandoverRequest", type: "error", }, { inputs: [], name: "Unauthorized", type: "error", }, { anonymous: false, inputs: [ { indexed: false, internalType: "address", name: "allo", type: "address", }, ], name: "AlloUpdated", type: "event", }, { anonymous: false, inputs: [ { indexed: false, internalType: "string", name: "name", type: "string", }, ], name: "NameUpdated", type: "event", }, { anonymous: false, inputs: [ { indexed: true, internalType: "address", name: "pendingOwner", type: "address", }, ], name: "OwnershipHandoverCanceled", type: "event", }, { anonymous: false, inputs: [ { indexed: true, internalType: "address", name: "pendingOwner", type: "address", }, ], name: "OwnershipHandoverRequested", type: "event", }, { anonymous: false, inputs: [ { indexed: true, internalType: "address", name: "oldOwner", type: "address", }, { indexed: true, internalType: "address", name: "newOwner", type: "address", }, ], name: "OwnershipTransferred", type: "event", }, { anonymous: false, inputs: [ { indexed: false, internalType: "address", name: "strategy", type: "address", }, ], name: "StrategyCreated", type: "event", }, { inputs: [], name: "allo", outputs: [ { internalType: "address", name: "", type: "address", }, ], stateMutability: "view", type: "function", }, { inputs: [], name: "cancelOwnershipHandover", outputs: [], stateMutability: "payable", type: "function", }, { inputs: [ { internalType: "address", name: "pendingOwner", type: "address", }, ], name: "completeOwnershipHandover", outputs: [], stateMutability: "payable", type: "function", }, { inputs: [ { internalType: "address", name: "_allo", type: "address", }, { internalType: "string", name: "_name", type: "string", }, ], name: "createCustomStrategy", outputs: [ { internalType: "address", name: "strategy", type: "address", }, ], stateMutability: "nonpayable", type: "function", }, { inputs: [], name: "createStrategy", outputs: [ { internalType: "address", name: "strategy", type: "address", }, ], stateMutability: "nonpayable", type: "function", }, { inputs: [], name: "name", outputs: [ { internalType: "string", name: "", type: "string", }, ], stateMutability: "view", type: "function", }, { inputs: [], name: "owner", outputs: [ { internalType: "address", name: "result", type: "address", }, ], stateMutability: "view", type: "function", }, { inputs: [ { internalType: "address", name: "pendingOwner", type: "address", }, ], name: "ownershipHandoverExpiresAt", outputs: [ { internalType: "uint256", name: "result", type: "uint256", }, ], stateMutability: "view", type: "function", }, { inputs: [], name: "renounceOwnership", outputs: [], stateMutability: "payable", type: "function", }, { inputs: [], name: "requestOwnershipHandover", outputs: [], stateMutability: "payable", type: "function", }, { inputs: [ { internalType: "address", name: "newOwner", type: "address", }, ], name: "transferOwnership", outputs: [], stateMutability: "payable", type: "function", }, { inputs: [ { internalType: "address", name: "_allo", type: "address", }, ], name: "updateAllo", outputs: [], stateMutability: "nonpayable", type: "function", }, { inputs: [ { internalType: "string", name: "_name", type: "string", }, ], name: "updateName", outputs: [], stateMutability: "nonpayable", type: "function", }, ] as const;