@sfpro/sdk
Version:
TypeScript SDK for Superfluid Protocol - stream money every second
1,320 lines (1,319 loc) • 23.6 kB
JSON
[
{
"inputs": [
{
"internalType": "contract ISuperfluid",
"name": "host",
"type": "address"
}
],
"stateMutability": "nonpayable",
"type": "constructor"
},
{
"inputs": [],
"name": "AccountInvalid",
"type": "error"
},
{
"inputs": [],
"name": "AlreadyExecuted",
"type": "error"
},
{
"inputs": [],
"name": "CFA_INVALID_FLOW_RATE",
"type": "error"
},
{
"inputs": [],
"name": "CannotClaimScheduleOnBehalf",
"type": "error"
},
{
"inputs": [],
"name": "CliffInvalid",
"type": "error"
},
{
"inputs": [],
"name": "FlowRateInvalid",
"type": "error"
},
{
"inputs": [],
"name": "InvalidNewTotalAmount",
"type": "error"
},
{
"inputs": [],
"name": "ScheduleAlreadyExists",
"type": "error"
},
{
"inputs": [],
"name": "ScheduleDoesNotExist",
"type": "error"
},
{
"inputs": [],
"name": "ScheduleNotClaimed",
"type": "error"
},
{
"inputs": [],
"name": "ScheduleNotFlowing",
"type": "error"
},
{
"inputs": [],
"name": "TimeWindowInvalid",
"type": "error"
},
{
"inputs": [],
"name": "ZeroAddress",
"type": "error"
},
{
"anonymous": false,
"inputs": [
{
"indexed": true,
"internalType": "contract ISuperToken",
"name": "superToken",
"type": "address"
},
{
"indexed": true,
"internalType": "address",
"name": "sender",
"type": "address"
},
{
"indexed": true,
"internalType": "address",
"name": "receiver",
"type": "address"
},
{
"indexed": false,
"internalType": "address",
"name": "claimer",
"type": "address"
}
],
"name": "VestingClaimed",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": true,
"internalType": "contract ISuperToken",
"name": "superToken",
"type": "address"
},
{
"indexed": true,
"internalType": "address",
"name": "sender",
"type": "address"
},
{
"indexed": true,
"internalType": "address",
"name": "receiver",
"type": "address"
},
{
"indexed": false,
"internalType": "uint32",
"name": "cliffAndFlowDate",
"type": "uint32"
},
{
"indexed": false,
"internalType": "int96",
"name": "flowRate",
"type": "int96"
},
{
"indexed": false,
"internalType": "uint256",
"name": "cliffAmount",
"type": "uint256"
},
{
"indexed": false,
"internalType": "uint256",
"name": "flowDelayCompensation",
"type": "uint256"
}
],
"name": "VestingCliffAndFlowExecuted",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": true,
"internalType": "contract ISuperToken",
"name": "superToken",
"type": "address"
},
{
"indexed": true,
"internalType": "address",
"name": "sender",
"type": "address"
},
{
"indexed": true,
"internalType": "address",
"name": "receiver",
"type": "address"
},
{
"indexed": false,
"internalType": "uint32",
"name": "endDate",
"type": "uint32"
},
{
"indexed": false,
"internalType": "uint256",
"name": "earlyEndCompensation",
"type": "uint256"
},
{
"indexed": false,
"internalType": "bool",
"name": "didCompensationFail",
"type": "bool"
}
],
"name": "VestingEndExecuted",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": true,
"internalType": "contract ISuperToken",
"name": "superToken",
"type": "address"
},
{
"indexed": true,
"internalType": "address",
"name": "sender",
"type": "address"
},
{
"indexed": true,
"internalType": "address",
"name": "receiver",
"type": "address"
},
{
"indexed": false,
"internalType": "uint32",
"name": "endDate",
"type": "uint32"
}
],
"name": "VestingEndFailed",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": true,
"internalType": "contract ISuperToken",
"name": "superToken",
"type": "address"
},
{
"indexed": true,
"internalType": "address",
"name": "sender",
"type": "address"
},
{
"indexed": true,
"internalType": "address",
"name": "receiver",
"type": "address"
},
{
"indexed": false,
"internalType": "uint32",
"name": "startDate",
"type": "uint32"
},
{
"indexed": false,
"internalType": "uint32",
"name": "cliffDate",
"type": "uint32"
},
{
"indexed": false,
"internalType": "int96",
"name": "flowRate",
"type": "int96"
},
{
"indexed": false,
"internalType": "uint32",
"name": "endDate",
"type": "uint32"
},
{
"indexed": false,
"internalType": "uint256",
"name": "cliffAmount",
"type": "uint256"
},
{
"indexed": false,
"internalType": "uint32",
"name": "claimValidityDate",
"type": "uint32"
},
{
"indexed": false,
"internalType": "uint96",
"name": "remainderAmount",
"type": "uint96"
}
],
"name": "VestingScheduleCreated",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": true,
"internalType": "contract ISuperToken",
"name": "superToken",
"type": "address"
},
{
"indexed": true,
"internalType": "address",
"name": "sender",
"type": "address"
},
{
"indexed": true,
"internalType": "address",
"name": "receiver",
"type": "address"
}
],
"name": "VestingScheduleDeleted",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": true,
"internalType": "contract ISuperToken",
"name": "superToken",
"type": "address"
},
{
"indexed": true,
"internalType": "address",
"name": "sender",
"type": "address"
},
{
"indexed": true,
"internalType": "address",
"name": "receiver",
"type": "address"
},
{
"indexed": false,
"internalType": "uint32",
"name": "endDate",
"type": "uint32"
},
{
"indexed": false,
"internalType": "uint96",
"name": "remainderAmount",
"type": "uint96"
},
{
"indexed": false,
"internalType": "int96",
"name": "flowRate",
"type": "int96"
},
{
"indexed": false,
"internalType": "uint256",
"name": "totalAmount",
"type": "uint256"
},
{
"indexed": false,
"internalType": "uint256",
"name": "settledAmount",
"type": "uint256"
}
],
"name": "VestingScheduleUpdated",
"type": "event"
},
{
"inputs": [],
"name": "END_DATE_VALID_BEFORE",
"outputs": [
{
"internalType": "uint32",
"name": "",
"type": "uint32"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "HOST",
"outputs": [
{
"internalType": "contract ISuperfluid",
"name": "",
"type": "address"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "MIN_VESTING_DURATION",
"outputs": [
{
"internalType": "uint32",
"name": "",
"type": "uint32"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "START_DATE_VALID_AFTER",
"outputs": [
{
"internalType": "uint32",
"name": "",
"type": "uint32"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "bytes32",
"name": "vestingId",
"type": "bytes32"
}
],
"name": "accountings",
"outputs": [
{
"internalType": "uint256",
"name": "settledAmount",
"type": "uint256"
},
{
"internalType": "uint256",
"name": "settledDate",
"type": "uint256"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "contract ISuperToken",
"name": "superToken",
"type": "address"
},
{
"internalType": "address",
"name": "receiver",
"type": "address"
},
{
"internalType": "uint256",
"name": "totalAmount",
"type": "uint256"
},
{
"internalType": "uint32",
"name": "totalDuration",
"type": "uint32"
}
],
"name": "createAndExecuteVestingScheduleFromAmountAndDuration",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "contract ISuperToken",
"name": "superToken",
"type": "address"
},
{
"internalType": "address",
"name": "receiver",
"type": "address"
},
{
"internalType": "uint32",
"name": "startDate",
"type": "uint32"
},
{
"internalType": "uint32",
"name": "cliffDate",
"type": "uint32"
},
{
"internalType": "int96",
"name": "flowRate",
"type": "int96"
},
{
"internalType": "uint256",
"name": "cliffAmount",
"type": "uint256"
},
{
"internalType": "uint32",
"name": "endDate",
"type": "uint32"
},
{
"internalType": "uint32",
"name": "claimValidityDate",
"type": "uint32"
}
],
"name": "createVestingSchedule",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "contract ISuperToken",
"name": "superToken",
"type": "address"
},
{
"internalType": "address",
"name": "receiver",
"type": "address"
},
{
"internalType": "uint32",
"name": "startDate",
"type": "uint32"
},
{
"internalType": "uint32",
"name": "cliffDate",
"type": "uint32"
},
{
"internalType": "int96",
"name": "flowRate",
"type": "int96"
},
{
"internalType": "uint256",
"name": "cliffAmount",
"type": "uint256"
},
{
"internalType": "uint32",
"name": "endDate",
"type": "uint32"
}
],
"name": "createVestingSchedule",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "contract ISuperToken",
"name": "superToken",
"type": "address"
},
{
"internalType": "address",
"name": "receiver",
"type": "address"
},
{
"internalType": "uint256",
"name": "totalAmount",
"type": "uint256"
},
{
"internalType": "uint32",
"name": "totalDuration",
"type": "uint32"
},
{
"internalType": "uint32",
"name": "startDate",
"type": "uint32"
},
{
"internalType": "uint32",
"name": "cliffPeriod",
"type": "uint32"
},
{
"internalType": "uint32",
"name": "claimPeriod",
"type": "uint32"
}
],
"name": "createVestingScheduleFromAmountAndDuration",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "contract ISuperToken",
"name": "superToken",
"type": "address"
},
{
"internalType": "address",
"name": "receiver",
"type": "address"
},
{
"internalType": "uint256",
"name": "totalAmount",
"type": "uint256"
},
{
"internalType": "uint32",
"name": "totalDuration",
"type": "uint32"
},
{
"internalType": "uint32",
"name": "startDate",
"type": "uint32"
},
{
"internalType": "uint32",
"name": "cliffPeriod",
"type": "uint32"
},
{
"internalType": "uint32",
"name": "claimPeriod",
"type": "uint32"
},
{
"internalType": "uint256",
"name": "cliffAmount",
"type": "uint256"
}
],
"name": "createVestingScheduleFromAmountAndDuration",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "contract ISuperToken",
"name": "superToken",
"type": "address"
},
{
"internalType": "address",
"name": "receiver",
"type": "address"
}
],
"name": "deleteVestingSchedule",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "contract ISuperToken",
"name": "superToken",
"type": "address"
},
{
"internalType": "address",
"name": "receiver",
"type": "address"
}
],
"name": "endVestingScheduleNow",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "contract ISuperToken",
"name": "superToken",
"type": "address"
},
{
"internalType": "address",
"name": "sender",
"type": "address"
},
{
"internalType": "address",
"name": "receiver",
"type": "address"
}
],
"name": "executeCliffAndFlow",
"outputs": [
{
"internalType": "bool",
"name": "success",
"type": "bool"
}
],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "contract ISuperToken",
"name": "superToken",
"type": "address"
},
{
"internalType": "address",
"name": "sender",
"type": "address"
},
{
"internalType": "address",
"name": "receiver",
"type": "address"
}
],
"name": "executeEndVesting",
"outputs": [
{
"internalType": "bool",
"name": "success",
"type": "bool"
}
],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "contract ISuperToken",
"name": "superToken",
"type": "address"
},
{
"internalType": "address",
"name": "sender",
"type": "address"
},
{
"internalType": "address",
"name": "receiver",
"type": "address"
}
],
"name": "getMaximumNeededTokenAllowance",
"outputs": [
{
"internalType": "uint256",
"name": "maxNeededAllowance",
"type": "uint256"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"components": [
{
"internalType": "uint32",
"name": "cliffAndFlowDate",
"type": "uint32"
},
{
"internalType": "uint32",
"name": "endDate",
"type": "uint32"
},
{
"internalType": "int96",
"name": "flowRate",
"type": "int96"
},
{
"internalType": "uint256",
"name": "cliffAmount",
"type": "uint256"
},
{
"internalType": "uint96",
"name": "remainderAmount",
"type": "uint96"
},
{
"internalType": "uint32",
"name": "claimValidityDate",
"type": "uint32"
}
],
"internalType": "struct IVestingSchedulerV3.VestingSchedule",
"name": "schedule",
"type": "tuple"
}
],
"name": "getMaximumNeededTokenAllowance",
"outputs": [
{
"internalType": "uint256",
"name": "maxNeededAllowance",
"type": "uint256"
}
],
"stateMutability": "pure",
"type": "function"
},
{
"inputs": [
{
"internalType": "contract ISuperToken",
"name": "superToken",
"type": "address"
},
{
"internalType": "address",
"name": "sender",
"type": "address"
},
{
"internalType": "address",
"name": "receiver",
"type": "address"
}
],
"name": "getTotalVestedAmount",
"outputs": [
{
"internalType": "uint256",
"name": "totalVestedAmount",
"type": "uint256"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "superToken",
"type": "address"
},
{
"internalType": "address",
"name": "sender",
"type": "address"
},
{
"internalType": "address",
"name": "receiver",
"type": "address"
}
],
"name": "getVestingSchedule",
"outputs": [
{
"components": [
{
"internalType": "uint32",
"name": "cliffAndFlowDate",
"type": "uint32"
},
{
"internalType": "uint32",
"name": "endDate",
"type": "uint32"
},
{
"internalType": "int96",
"name": "flowRate",
"type": "int96"
},
{
"internalType": "uint256",
"name": "cliffAmount",
"type": "uint256"
},
{
"internalType": "uint96",
"name": "remainderAmount",
"type": "uint96"
},
{
"internalType": "uint32",
"name": "claimValidityDate",
"type": "uint32"
}
],
"internalType": "struct IVestingSchedulerV3.VestingSchedule",
"name": "schedule",
"type": "tuple"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "forwarder",
"type": "address"
}
],
"name": "isTrustedForwarder",
"outputs": [
{
"internalType": "bool",
"name": "isForwarderTrusted",
"type": "bool"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "contract ISuperToken",
"name": "superToken",
"type": "address"
},
{
"internalType": "address",
"name": "sender",
"type": "address"
},
{
"internalType": "address",
"name": "receiver",
"type": "address"
},
{
"internalType": "uint256",
"name": "totalAmount",
"type": "uint256"
},
{
"internalType": "uint32",
"name": "totalDuration",
"type": "uint32"
},
{
"internalType": "uint32",
"name": "startDate",
"type": "uint32"
},
{
"internalType": "uint32",
"name": "cliffPeriod",
"type": "uint32"
},
{
"internalType": "uint32",
"name": "claimPeriod",
"type": "uint32"
},
{
"internalType": "uint256",
"name": "cliffAmount",
"type": "uint256"
}
],
"name": "mapCreateVestingScheduleParams",
"outputs": [
{
"components": [
{
"internalType": "contract ISuperToken",
"name": "superToken",
"type": "address"
},
{
"internalType": "address",
"name": "sender",
"type": "address"
},
{
"internalType": "address",
"name": "receiver",
"type": "address"
},
{
"internalType": "uint32",
"name": "startDate",
"type": "uint32"
},
{
"internalType": "uint32",
"name": "claimValidityDate",
"type": "uint32"
},
{
"internalType": "uint32",
"name": "cliffDate",
"type": "uint32"
},
{
"internalType": "int96",
"name": "flowRate",
"type": "int96"
},
{
"internalType": "uint256",
"name": "cliffAmount",
"type": "uint256"
},
{
"internalType": "uint32",
"name": "endDate",
"type": "uint32"
},
{
"internalType": "uint96",
"name": "remainderAmount",
"type": "uint96"
}
],
"internalType": "struct IVestingSchedulerV3.ScheduleCreationParams",
"name": "params",
"type": "tuple"
}
],
"stateMutability": "pure",
"type": "function"
},
{
"inputs": [
{
"internalType": "contract ISuperToken",
"name": "superToken",
"type": "address"
},
{
"internalType": "address",
"name": "sender",
"type": "address"
},
{
"internalType": "address",
"name": "receiver",
"type": "address"
},
{
"internalType": "uint256",
"name": "totalAmount",
"type": "uint256"
},
{
"internalType": "uint32",
"name": "totalDuration",
"type": "uint32"
},
{
"internalType": "uint32",
"name": "startDate",
"type": "uint32"
},
{
"internalType": "uint32",
"name": "cliffPeriod",
"type": "uint32"
},
{
"internalType": "uint32",
"name": "claimPeriod",
"type": "uint32"
}
],
"name": "mapCreateVestingScheduleParams",
"outputs": [
{
"components": [
{
"internalType": "contract ISuperToken",
"name": "superToken",
"type": "address"
},
{
"internalType": "address",
"name": "sender",
"type": "address"
},
{
"internalType": "address",
"name": "receiver",
"type": "address"
},
{
"internalType": "uint32",
"name": "startDate",
"type": "uint32"
},
{
"internalType": "uint32",
"name": "claimValidityDate",
"type": "uint32"
},
{
"internalType": "uint32",
"name": "cliffDate",
"type": "uint32"
},
{
"internalType": "int96",
"name": "flowRate",
"type": "int96"
},
{
"internalType": "uint256",
"name": "cliffAmount",
"type": "uint256"
},
{
"internalType": "uint32",
"name": "endDate",
"type": "uint32"
},
{
"internalType": "uint96",
"name": "remainderAmount",
"type": "uint96"
}
],
"internalType": "struct IVestingSchedulerV3.ScheduleCreationParams",
"name": "params",
"type": "tuple"
}
],
"stateMutability": "pure",
"type": "function"
},
{
"inputs": [
{
"internalType": "contract ISuperToken",
"name": "superToken",
"type": "address"
},
{
"internalType": "address",
"name": "receiver",
"type": "address"
},
{
"internalType": "uint32",
"name": "newEndDate",
"type": "uint32"
}
],
"name": "updateVestingSchedule",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "contract ISuperToken",
"name": "superToken",
"type": "address"
},
{
"internalType": "address",
"name": "receiver",
"type": "address"
},
{
"internalType": "uint256",
"name": "newTotalAmount",
"type": "uint256"
}
],
"name": "updateVestingScheduleFlowRateFromAmount",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "contract ISuperToken",
"name": "superToken",
"type": "address"
},
{
"internalType": "address",
"name": "receiver",
"type": "address"
},
{
"internalType": "uint256",
"name": "newTotalAmount",
"type": "uint256"
},
{
"internalType": "uint32",
"name": "newEndDate",
"type": "uint32"
}
],
"name": "updateVestingScheduleFlowRateFromAmountAndEndDate",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "contract ISuperToken",
"name": "superToken",
"type": "address"
},
{
"internalType": "address",
"name": "receiver",
"type": "address"
},
{
"internalType": "uint32",
"name": "newEndDate",
"type": "uint32"
}
],
"name": "updateVestingScheduleFlowRateFromEndDate",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [],
"name": "versionRecipient",
"outputs": [
{
"internalType": "string",
"name": "version",
"type": "string"
}
],
"stateMutability": "pure",
"type": "function"
},
{
"inputs": [
{
"internalType": "bytes32",
"name": "vestingId",
"type": "bytes32"
}
],
"name": "vestingSchedules",
"outputs": [
{
"internalType": "uint32",
"name": "cliffAndFlowDate",
"type": "uint32"
},
{
"internalType": "uint32",
"name": "endDate",
"type": "uint32"
},
{
"internalType": "int96",
"name": "flowRate",
"type": "int96"
},
{
"internalType": "uint256",
"name": "cliffAmount",
"type": "uint256"
},
{
"internalType": "uint96",
"name": "remainderAmount",
"type": "uint96"
},
{
"internalType": "uint32",
"name": "claimValidityDate",
"type": "uint32"
}
],
"stateMutability": "view",
"type": "function"
}
]