UNPKG

@augmentedfinance/protocol-v1

Version:

Augmented Protocol smart contracts

1,549 lines 38.5 kB
"use strict"; /* Autogenerated file. Do not edit manually. */ /* tslint:disable */ /* eslint-disable */ Object.defineProperty(exports, "__esModule", { value: true }); exports.RewardedStakeBaseFactory = void 0; const ethers_1 = require("ethers"); class RewardedStakeBaseFactory { static connect(address, signerOrProvider) { return new ethers_1.Contract(address, _abi, signerOrProvider); } } exports.RewardedStakeBaseFactory = RewardedStakeBaseFactory; const _abi = [ { anonymous: false, inputs: [ { indexed: true, internalType: "address", name: "owner", type: "address", }, { indexed: true, internalType: "address", name: "spender", type: "address", }, { indexed: false, internalType: "uint256", name: "value", type: "uint256", }, ], name: "Approval", type: "event", }, { anonymous: false, inputs: [ { indexed: false, internalType: "uint16", name: "", type: "uint16", }, ], name: "BaselinePercentageUpdated", type: "event", }, { anonymous: false, inputs: [ { indexed: true, internalType: "address", name: "account", type: "address", }, { indexed: false, internalType: "uint32", name: "at", type: "uint32", }, ], name: "CooldownStarted", type: "event", }, { anonymous: false, inputs: [ { indexed: false, internalType: "uint32", name: "cooldownPeriod", type: "uint32", }, { indexed: false, internalType: "uint32", name: "unstakePeriod", type: "uint32", }, ], name: "CooldownUpdated", type: "event", }, { anonymous: false, inputs: [ { indexed: true, internalType: "address", name: "by", type: "address", }, { indexed: false, internalType: "bool", name: "paused", type: "bool", }, ], name: "EmergencyPaused", type: "event", }, { anonymous: false, inputs: [ { components: [ { internalType: "contract IMarketAccessController", name: "stakeController", type: "address", }, { internalType: "contract IERC20", name: "stakedToken", type: "address", }, { internalType: "contract IUnderlyingStrategy", name: "strategy", type: "address", }, { internalType: "uint32", name: "cooldownPeriod", type: "uint32", }, { internalType: "uint32", name: "unstakePeriod", type: "uint32", }, { internalType: "uint16", name: "maxSlashable", type: "uint16", }, { internalType: "uint8", name: "stakedTokenDecimals", type: "uint8", }, ], indexed: false, internalType: "struct StakeTokenConfig", name: "params", type: "tuple", }, { indexed: false, internalType: "string", name: "tokenName", type: "string", }, { indexed: false, internalType: "string", name: "tokenSymbol", type: "string", }, ], name: "Initialized", type: "event", }, { anonymous: false, inputs: [ { indexed: false, internalType: "uint16", name: "maxSlash", type: "uint16", }, ], name: "MaxSlashUpdated", type: "event", }, { anonymous: false, inputs: [ { indexed: false, internalType: "address", name: "provider", type: "address", }, { indexed: false, internalType: "address", name: "token", type: "address", }, ], name: "ProviderAdded", type: "event", }, { anonymous: false, inputs: [ { indexed: false, internalType: "address", name: "provider", type: "address", }, ], name: "ProviderRemoved", type: "event", }, { anonymous: false, inputs: [ { indexed: false, internalType: "uint256", name: "rate", type: "uint256", }, ], name: "RateUpdated", type: "event", }, { anonymous: false, inputs: [ { indexed: false, internalType: "bool", name: "redeemable", type: "bool", }, ], name: "RedeemableUpdated", type: "event", }, { anonymous: false, inputs: [ { indexed: true, internalType: "address", name: "from", type: "address", }, { indexed: true, internalType: "address", name: "to", type: "address", }, { indexed: false, internalType: "uint256", name: "amount", type: "uint256", }, { indexed: false, internalType: "uint256", name: "underlyingAmount", type: "uint256", }, ], name: "Redeemed", type: "event", }, { anonymous: false, inputs: [ { indexed: false, internalType: "address", name: "to", type: "address", }, { indexed: false, internalType: "uint256", name: "amount", type: "uint256", }, { indexed: false, internalType: "uint256", name: "totalBeforeSlash", type: "uint256", }, ], name: "Slashed", type: "event", }, { anonymous: false, inputs: [ { indexed: true, internalType: "address", name: "from", type: "address", }, { indexed: true, internalType: "address", name: "to", type: "address", }, { indexed: false, internalType: "uint256", name: "amount", type: "uint256", }, { indexed: true, internalType: "uint256", name: "referal", type: "uint256", }, ], name: "Staked", type: "event", }, { anonymous: false, inputs: [ { indexed: true, internalType: "address", name: "from", type: "address", }, { indexed: true, internalType: "address", name: "to", type: "address", }, { indexed: false, internalType: "uint256", name: "value", type: "uint256", }, ], name: "Transfer", type: "event", }, { inputs: [], name: "COOLDOWN_PERIOD", outputs: [ { internalType: "uint256", name: "", type: "uint256", }, ], stateMutability: "view", type: "function", }, { inputs: [], name: "DOMAIN_SEPARATOR", outputs: [ { internalType: "bytes32", name: "", type: "bytes32", }, ], stateMutability: "view", type: "function", }, { inputs: [], name: "EIP712_REVISION", outputs: [ { internalType: "bytes", name: "", type: "bytes", }, ], stateMutability: "view", type: "function", }, { inputs: [], name: "PERMIT_TYPEHASH", outputs: [ { internalType: "bytes32", name: "", type: "bytes32", }, ], stateMutability: "view", type: "function", }, { inputs: [], name: "UNDERLYING_ASSET_ADDRESS", outputs: [ { internalType: "address", name: "", type: "address", }, ], stateMutability: "view", type: "function", }, { inputs: [], name: "UNSTAKE_PERIOD", outputs: [ { internalType: "uint256", name: "", type: "uint256", }, ], stateMutability: "view", type: "function", }, { inputs: [ { internalType: "address", name: "", type: "address", }, ], name: "_nonces", outputs: [ { internalType: "uint256", name: "", type: "uint256", }, ], stateMutability: "view", type: "function", }, { inputs: [ { internalType: "address", name: "", type: "address", }, { internalType: "address", name: "", type: "address", }, ], name: "addRewardProvider", outputs: [], stateMutability: "view", 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: "spender", type: "address", }, { internalType: "uint256", name: "amount", type: "uint256", }, ], name: "approve", outputs: [ { internalType: "bool", name: "", type: "bool", }, ], stateMutability: "nonpayable", type: "function", }, { inputs: [], name: "attachedToRewardController", outputs: [ { internalType: "uint256", name: "", type: "uint256", }, ], stateMutability: "nonpayable", type: "function", }, { inputs: [ { internalType: "address", name: "holder", type: "address", }, ], name: "balanceAndCooldownOf", outputs: [ { internalType: "uint256", name: "", type: "uint256", }, { internalType: "uint32", name: "windowStart", type: "uint32", }, { internalType: "uint32", name: "windowEnd", type: "uint32", }, ], 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", }, ], name: "balanceOfUnderlying", outputs: [ { internalType: "uint256", name: "", type: "uint256", }, ], stateMutability: "view", type: "function", }, { inputs: [ { internalType: "address", name: "holder", type: "address", }, { internalType: "uint32", name: "at", type: "uint32", }, ], name: "calcRewardFor", outputs: [ { internalType: "uint256", name: "amount", type: "uint256", }, { internalType: "uint256", name: "", type: "uint256", }, { internalType: "uint32", name: "since", type: "uint32", }, ], stateMutability: "view", type: "function", }, { inputs: [ { internalType: "address", name: "holder", type: "address", }, ], name: "claimRewardFor", outputs: [ { internalType: "uint256", name: "", type: "uint256", }, { internalType: "uint32", name: "", type: "uint32", }, { internalType: "bool", name: "", type: "bool", }, ], stateMutability: "nonpayable", type: "function", }, { inputs: [ { internalType: "address", name: "holder", type: "address", }, { internalType: "uint256", name: "baseAmount", type: "uint256", }, { internalType: "uint256", name: "limit", type: "uint256", }, { internalType: "uint16", name: "minPct", type: "uint16", }, ], name: "claimRewardWithLimitFor", outputs: [ { internalType: "uint256", name: "amount", type: "uint256", }, { internalType: "uint32", name: "since", type: "uint32", }, { internalType: "bool", name: "keepPull", type: "bool", }, { internalType: "uint256", name: "newLimit", type: "uint256", }, ], stateMutability: "nonpayable", type: "function", }, { inputs: [], name: "cooldown", outputs: [], stateMutability: "nonpayable", type: "function", }, { inputs: [], name: "decimals", outputs: [ { internalType: "uint8", name: "", type: "uint8", }, ], stateMutability: "view", type: "function", }, { inputs: [ { internalType: "address", name: "spender", type: "address", }, { internalType: "uint256", name: "subtractedValue", type: "uint256", }, ], name: "decreaseAllowance", outputs: [ { internalType: "bool", name: "", type: "bool", }, ], stateMutability: "nonpayable", type: "function", }, { inputs: [], name: "detachedFromRewardController", outputs: [ { internalType: "uint256", name: "", type: "uint256", }, ], stateMutability: "nonpayable", type: "function", }, { inputs: [], name: "exchangeRate", outputs: [ { internalType: "uint256", name: "", type: "uint256", }, ], stateMutability: "view", type: "function", }, { inputs: [], name: "getBaselinePercentage", outputs: [ { internalType: "uint16", name: "", type: "uint16", }, ], stateMutability: "view", type: "function", }, { inputs: [ { internalType: "address", name: "holder", type: "address", }, ], name: "getCooldown", outputs: [ { internalType: "uint32", name: "", type: "uint32", }, ], stateMutability: "view", type: "function", }, { inputs: [], name: "getIncentivesController", outputs: [ { internalType: "address", name: "", type: "address", }, ], stateMutability: "view", type: "function", }, { inputs: [], name: "getMaxSlashablePercentage", outputs: [ { internalType: "uint16", name: "", type: "uint16", }, ], stateMutability: "view", type: "function", }, { inputs: [], name: "getOwner", outputs: [ { internalType: "address", name: "", type: "address", }, ], stateMutability: "view", type: "function", }, { inputs: [], name: "getPoolName", outputs: [ { internalType: "string", name: "", type: "string", }, ], stateMutability: "view", type: "function", }, { inputs: [], name: "getRate", outputs: [ { internalType: "uint256", name: "", type: "uint256", }, ], stateMutability: "view", type: "function", }, { inputs: [], name: "getRewardController", outputs: [ { internalType: "address", name: "", type: "address", }, ], stateMutability: "view", type: "function", }, { inputs: [ { internalType: "address", name: "spender", type: "address", }, { internalType: "uint256", name: "addedValue", type: "uint256", }, ], name: "increaseAllowance", outputs: [ { internalType: "bool", name: "", type: "bool", }, ], stateMutability: "nonpayable", type: "function", }, { inputs: [ { components: [ { internalType: "contract IRewardController", name: "controller", type: "address", }, { internalType: "string", name: "poolName", type: "string", }, { internalType: "uint16", name: "baselinePercentage", type: "uint16", }, ], internalType: "struct IInitializableRewardPool.InitRewardPoolData", name: "config", type: "tuple", }, ], name: "initializeRewardPool", outputs: [], stateMutability: "nonpayable", type: "function", }, { inputs: [ { components: [ { internalType: "contract IMarketAccessController", name: "stakeController", type: "address", }, { internalType: "contract IERC20", name: "stakedToken", type: "address", }, { internalType: "contract IUnderlyingStrategy", name: "strategy", type: "address", }, { internalType: "uint32", name: "cooldownPeriod", type: "uint32", }, { internalType: "uint32", name: "unstakePeriod", type: "uint32", }, { internalType: "uint16", name: "maxSlashable", type: "uint16", }, { internalType: "uint8", name: "stakedTokenDecimals", type: "uint8", }, ], internalType: "struct StakeTokenConfig", name: "params", type: "tuple", }, { internalType: "string", name: "name", type: "string", }, { internalType: "string", name: "symbol", type: "string", }, ], name: "initializeStakeToken", outputs: [], stateMutability: "nonpayable", type: "function", }, { inputs: [], name: "initializedRewardPoolWith", outputs: [ { components: [ { internalType: "contract IRewardController", name: "controller", type: "address", }, { internalType: "string", name: "poolName", type: "string", }, { internalType: "uint16", name: "baselinePercentage", type: "uint16", }, ], internalType: "struct IInitializableRewardPool.InitRewardPoolData", name: "", type: "tuple", }, ], stateMutability: "view", type: "function", }, { inputs: [], name: "initializedStakeTokenWith", outputs: [ { components: [ { internalType: "contract IMarketAccessController", name: "stakeController", type: "address", }, { internalType: "contract IERC20", name: "stakedToken", type: "address", }, { internalType: "contract IUnderlyingStrategy", name: "strategy", type: "address", }, { internalType: "uint32", name: "cooldownPeriod", type: "uint32", }, { internalType: "uint32", name: "unstakePeriod", type: "uint32", }, { internalType: "uint16", name: "maxSlashable", type: "uint16", }, { internalType: "uint8", name: "stakedTokenDecimals", type: "uint8", }, ], internalType: "struct StakeTokenConfig", name: "params", type: "tuple", }, { internalType: "string", name: "name_", type: "string", }, { internalType: "string", name: "symbol_", type: "string", }, ], stateMutability: "view", type: "function", }, { inputs: [], name: "isPaused", outputs: [ { internalType: "bool", name: "", type: "bool", }, ], stateMutability: "view", type: "function", }, { inputs: [], name: "isRedeemable", outputs: [ { internalType: "bool", name: "", type: "bool", }, ], stateMutability: "view", type: "function", }, { inputs: [], name: "name", outputs: [ { internalType: "string", name: "", type: "string", }, ], stateMutability: "view", type: "function", }, { inputs: [ { internalType: "address", name: "addr", type: "address", }, ], name: "nonces", outputs: [ { internalType: "uint256", name: "", type: "uint256", }, ], stateMutability: "view", type: "function", }, { inputs: [ { internalType: "address", name: "owner", type: "address", }, { internalType: "address", name: "spender", type: "address", }, { internalType: "uint256", name: "value", type: "uint256", }, { internalType: "uint256", name: "deadline", type: "uint256", }, { internalType: "uint8", name: "v", type: "uint8", }, { internalType: "bytes32", name: "r", type: "bytes32", }, { internalType: "bytes32", name: "s", type: "bytes32", }, ], name: "permit", outputs: [], stateMutability: "nonpayable", type: "function", }, { inputs: [ { internalType: "address", name: "to", type: "address", }, { internalType: "uint256", name: "stakeAmount", type: "uint256", }, ], name: "redeem", outputs: [ { internalType: "uint256", name: "stakeAmount_", type: "uint256", }, ], stateMutability: "nonpayable", type: "function", }, { inputs: [ { internalType: "address", name: "to", type: "address", }, { internalType: "uint256", name: "underlyingAmount", type: "uint256", }, ], name: "redeemUnderlying", outputs: [ { internalType: "uint256", name: "underlyingAmount_", type: "uint256", }, ], stateMutability: "nonpayable", type: "function", }, { inputs: [ { internalType: "address", name: "provider", type: "address", }, ], name: "removeRewardProvider", outputs: [], stateMutability: "nonpayable", type: "function", }, { inputs: [ { internalType: "address", name: "account", type: "address", }, ], name: "rewardedBalanceOf", outputs: [ { internalType: "uint256", name: "", type: "uint256", }, ], stateMutability: "view", type: "function", }, { inputs: [ { internalType: "uint16", name: "factor", type: "uint16", }, ], name: "setBaselinePercentage", outputs: [], stateMutability: "nonpayable", type: "function", }, { inputs: [ { internalType: "uint32", name: "cooldownPeriod", type: "uint32", }, { internalType: "uint32", name: "unstakePeriod", type: "uint32", }, ], name: "setCooldown", outputs: [], stateMutability: "nonpayable", type: "function", }, { inputs: [ { internalType: "address", name: "", type: "address", }, ], name: "setIncentivesController", outputs: [], stateMutability: "view", type: "function", }, { inputs: [ { internalType: "uint16", name: "slashPct", type: "uint16", }, ], name: "setMaxSlashablePercentage", outputs: [], stateMutability: "nonpayable", type: "function", }, { inputs: [ { internalType: "bool", name: "paused", type: "bool", }, ], name: "setPaused", outputs: [], stateMutability: "nonpayable", type: "function", }, { inputs: [ { internalType: "bool", name: "redeemable", type: "bool", }, ], name: "setRedeemable", outputs: [], stateMutability: "nonpayable", type: "function", }, { inputs: [ { internalType: "address", name: "destination", type: "address", }, { internalType: "uint256", name: "minAmount", type: "uint256", }, { internalType: "uint256", name: "maxAmount", type: "uint256", }, ], name: "slashUnderlying", outputs: [ { internalType: "uint256", name: "amount", type: "uint256", }, { internalType: "bool", name: "erc20Transfer", type: "bool", }, ], stateMutability: "nonpayable", type: "function", }, { inputs: [ { internalType: "address", name: "to", type: "address", }, { internalType: "uint256", name: "underlyingAmount", type: "uint256", }, { internalType: "uint256", name: "referral", type: "uint256", }, ], name: "stake", outputs: [ { internalType: "uint256", name: "", type: "uint256", }, ], stateMutability: "nonpayable", type: "function", }, { inputs: [], name: "symbol", outputs: [ { internalType: "string", name: "", type: "string", }, ], stateMutability: "view", type: "function", }, { inputs: [], name: "totalSupply", outputs: [ { internalType: "uint256", name: "", type: "uint256", }, ], stateMutability: "view", type: "function", }, { inputs: [ { internalType: "address", name: "recipient", type: "address", }, { internalType: "uint256", name: "amount", type: "uint256", }, ], name: "transfer", outputs: [ { internalType: "bool", name: "", type: "bool", }, ], stateMutability: "nonpayable", type: "function", }, { inputs: [ { internalType: "address", name: "sender", type: "address", }, { internalType: "address", name: "recipient", type: "address", }, { internalType: "uint256", name: "amount", type: "uint256", }, ], name: "transferFrom", outputs: [ { internalType: "bool", name: "", type: "bool", }, ], stateMutability: "nonpayable", type: "function", }, { inputs: [ { internalType: "uint256", name: "baseline", type: "uint256", }, ], name: "updateBaseline", outputs: [ { internalType: "bool", name: "hasBaseline", type: "bool", }, { internalType: "uint256", name: "appliedRate", type: "uint256", }, ], stateMutability: "nonpayable", type: "function", }, { inputs: [ { internalType: "address", name: "owner", type: "address", }, { internalType: "uint256", name: "subtractedValue", type: "uint256", }, ], name: "useAllowance", outputs: [ { internalType: "bool", name: "", type: "bool", }, ], stateMutability: "nonpayable", type: "function", }, ]; //# sourceMappingURL=RewardedStakeBaseFactory.js.map