@allo-team/allo-v2-sdk
Version:
300 lines (299 loc) • 6.89 kB
JavaScript
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.abi = exports.getAddress = void 0;
// Factory for DirectGrantsLiteStrategy v1.0
const getAddress = (chainId) => {
switch (chainId) {
case 300: // ZkSync Era Testnet
case 324: // ZkSync Era Mainnet
return "0x235bd2A867056Ba72d48ceC08d82b418fA977D1c";
default:
throw new Error("Chain not supported by SDK");
}
};
exports.getAddress = getAddress;
exports.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",
},
];